@charset "utf-8";

@import url('https://fonts.cdnfonts.com/css/apple-garamond');
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+KR:wght@400;500;700&display=swap');

@font-face {
  font-family: 'Hangyore';
  src: url('//cdn.jsdelivr.net/korean-webfonts/1/corps/hani/Hankc/Hankc.woff2') format('woff2'),
       url('//cdn.jsdelivr.net/korean-webfonts/1/corps/hani/Hankc/Hankc.woff') format('woff');
  font-weight: 400;
  font-display: swap;
}

*, a {
  cursor: none !important;
  box-sizing: border-box;
}

:root {
  --background-color: #fefefe;
  --text-color: #111111;
  --timeline-row-height: 180px;
  --timeline-row-gap: 32px;
  --timeline-radius: 28px;
  --timeline-line-color: rgba(0, 0, 0, 0.32);
  --timeline-bubble-bg: rgba(17, 17, 17, 0.04);
  --timeline-bubble-border: rgba(17, 17, 17, 0.08);
  --form-shadow: 0 18px 48px rgba(0, 0, 0, 0.08);
  --form-radius: 28px;
  --form-bg: rgba(255, 255, 255, 0.9);
  --status-warn: #ff2546;
  --status-success: #006fff;
}

html, body {
  margin: 0;
  padding: 0;
  background-color: var(--background-color);
  color: var(--text-color);
  min-height: 100%;
  font-family: 'Apple Garamond', 'Noto Sans KR', sans-serif;
  overflow-x: hidden;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: 'Apple Garamond', 'Noto Sans KR', sans-serif;
}

#project-name,
#project-name-right,
#clock-container {
  font-family: 'Courier New', 'Roboto Mono', monospace;
}

#header-bar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 24px 0;
  z-index: 1000;
  background: linear-gradient(to bottom, rgba(254, 254, 254, 0.9), rgba(254, 254, 254, 0.4));
  backdrop-filter: blur(8px);
  transition: background 0.3s ease;
}

#header-bar.overlay-active {
  background: rgba(254, 254, 254, 0.92);
}

#project-name,
#project-name-right,
#clock-container {
  position: fixed;
  top: 48px;
  font-size: 1.8rem;
  color: var(--text-color);
  z-index: 1100;
}

#project-name {
  left: 3%;
  font-family: monospace;
}

#project-name-right {
  right: 3%;
  display: flex;
  gap: 15px;
  align-items: center;
  cursor: pointer;
}

#clock-container {
  left: 50%;
  transform: translateX(-50%);
}

#clock {
  font-family: monospace;
  font-size: 1.6rem;
}

.mini-clock-wrapper {
  display: flex;
  gap: 15px;
  align-items: center;
}

.mini-clock {
  position: relative;
  width: 45px;
  height: 45px;
  border-radius: 50%;
  border: 3px solid currentColor;
  background: transparent;
  transition: transform 0.2s ease;
}

#project-name-right:hover .mini-clock {
  transform: scale(1.06);
}

.mini-clock__hand {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 3px;
  transform-origin: 50% 100%;
  transform: translate(-50%, -100%) rotate(var(--rotation, 0deg));
  border-radius: 999px;
  background: currentColor;
}

.mini-clock__hand--hour {
  height: 17px;
}

.mini-clock__hand--minute {
  height: 20px;
}

.mini-clock__hand--second {
  height: 22px;
}

.timeline-layout {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 160px 24px 220px;
  position: relative;
  z-index: 5;
}

.timeline-shell {
  width: 100%;
  max-width: 1200px;
  position: relative;
  z-index: 6;
}

.timeline-mask {
  position: relative;
  height: calc(var(--timeline-row-height) * 5 + var(--timeline-row-gap) * 4);
  overflow-y: auto;
  padding-right: 8px;
  scrollbar-width: thin;
  z-index: 7;
}

.timeline-mask::-webkit-scrollbar {
  width: 6px;
}

.timeline-mask::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.2);
  border-radius: 999px;
}

.timeline-list {
  display: flex;
  flex-direction: column;
  gap: var(--timeline-row-gap);
  padding: 0;
  margin: 0;
  position: relative;
  z-index: 8;
}

.timeline-row {
  --accent: #ff2546;
  --accent-secondary: #fff200;
  --accent-tertiary: #ffffff;
  background: transparent;
  border: none;
  padding: 0;
  min-height: var(--timeline-row-height);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  z-index: 9;
}

.timeline-row:focus {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

.timeline-row__meta,
.timeline-row__message {
  display: none;
}

.timeline-row__line {
  position: relative;
  height: 2px;
  background: var(--timeline-line-color);
  border-radius: 8px;
  width: 100%;
}

.timeline-row__timestamp {
  position: absolute;
  left: calc(var(--marker-position, 50) * 1%);
  bottom: calc(100% + 40px);
  transform: translateX(-50%);
  font-size: 10px;
  letter-spacing: 0.04em;
  color: var(--text-color);
  opacity: 0.55;
  line-height: 1;
  pointer-events: none;
  font-variant-numeric: tabular-nums;
}

.timeline-row__marker {
  position: absolute;
  top: 50%;
  left: calc(var(--marker-position, 50) * 1%);
  transform: translate(-50%, -50%);
  width: 120px;
  height: 120px;
  display: grid;
  place-items: center;
  cursor: pointer;
  background: none;
  border: none;
}

.timeline-row__marker svg {
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 8px 18px rgba(0, 0, 0, 0.08));
}

/* 중심점 제거 요청으로 after 삭제 */

.timeline-row__bubble {
  position: absolute;
  bottom: calc(100% + 2px);
  left: 50%;
  transform: translateX(-50%) translateY(8px);
  padding: 14px 18px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid rgba(0, 0, 0, 0.12);
  box-shadow: 0 16px 32px rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(6px);
  color: var(--text-color);
  font-size: 0.95rem;
  line-height: 1.4;
  writing-mode: horizontal-tb;
  text-orientation: mixed;
  white-space: normal;
  word-break: keep-all;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.18s ease, transform 0.18s ease;
  max-width: 600px;
  display: inline-block;
}

.timeline-row__marker.is-active .timeline-row__bubble {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.guestbook-form-wrapper {
  position: fixed;
  left: 50%;
  bottom: 22px;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  width: min(680px, 92vw);
  z-index: 1200;
}

.guestbook-form {
  width: 100%;
  display: flex;
  justify-content: center;
}

.guestbook-form__field {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px 16px;
  border-radius: var(--form-radius);
  background: var(--form-bg);
  box-shadow: var(--form-shadow);
}

.guestbook-input {
  flex: 1;
  border: none;
  background: transparent;
  font-size: 14px;
  font-family: inherit;
  color: var(--text-color);
}

.guestbook-input::placeholder {
  color: rgba(0, 0, 0, 0.4);
}

.guestbook-input:focus {
  outline: none;
}

.guestbook-submit {
  border: none;
  background: var(--text-color);
  color: #ffffff;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease;
}

.guestbook-submit:hover,
.guestbook-submit:focus-visible {
  outline: none;
  transform: translateY(-2px);
  background: var(--status-success);
}

.guestbook-submit svg {
  width: 14px;
  height: 14px;
  fill: currentColor;
}

#guestbook-status {
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  min-height: 1.2em;
  text-align: center;
  color: rgba(0, 0, 0, 0.55);
}

.overlay-open .guestbook-form-wrapper {
  display: none;
}

#guestbook-status[data-tone="warn"] {
  color: var(--status-warn);
}

#guestbook-status[data-tone="success"] {
  color: var(--status-success);
}

#floating-menu-overlay {
  --floating-bg: #00f2ff;
  --floating-fg: rgb(0, 0, 0);
  --floating-accent: #000000;
  --floating-hand-thickness: 2px;
  --floating-item-font: clamp(16px, 2.2vw, 28px);
  position: fixed;
  inset: 0;
  display: none;
  background: var(--floating-bg);
  color: var(--floating-fg);
  overflow: hidden;
  z-index: 80;
  font-family: 'Apple Garamond', sans-serif;
}

#floating-menu-overlay.active {
  display: block;
}

#floating-menu-overlay .floating-center-ellipse {
  position: fixed;
  left: 50%;
  top: 50%;
  width: 1200px;
  height: 1200px;
  transform: translate(-50%, -50%);
  background: #ffffff;
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
  mix-blend-mode: screen;
}

#floating-menu-overlay .floating-center-dot {
  position: fixed;
  left: 50%;
  top: 50%;
  width: 8px;
  height: 8px;
  transform: translate(-50%, -50%);
  background: var(--floating-accent);
  border-radius: 50%;
  z-index: 10;
  pointer-events: none;
}

#floating-menu-overlay .floating-hand {
  position: fixed;
  left: 50%;
  top: 50%;
  height: var(--floating-hand-thickness);
  width: 0;
  background: var(--floating-accent);
  transform-origin: 0% 50%;
  transform: translate(0, -50%) rotate(0deg);
  z-index: 9;
  pointer-events: none;
  border-radius: 999px;
  opacity: 0.9;
}

#floating-menu-overlay .floating-hour-hand,
#floating-menu-overlay .floating-minute-hand {
  position: fixed;
  left: 50%;
  top: 50%;
  transform-origin: 50% 100%;
  transform: translate(-50%, -100%) rotate(0deg);
  background: var(--floating-accent);
  border-radius: 999px;
  pointer-events: none;
  opacity: 0.9;
}

#floating-menu-overlay .floating-hour-hand {
  width: 10px;
  height: min(32vmin, 220px);
  z-index: 6;
}

#floating-menu-overlay .floating-minute-hand {
  width: 8px;
  height: min(40vmin, 280px);
  z-index: 7;
}

#floating-menu-overlay .floating-second-hand {
  position: fixed;
  left: 50%;
  top: 50%;
  width: 6px;
  height: min(45vmin, 320px);
  transform-origin: 50% 100%;
  transform: translate(-50%, -100%) rotate(0deg);
  background: #ff2546;
  border-radius: 999px;
  pointer-events: none;
  z-index: 8;
}

#floating-menu-overlay .floating-menu {
  position: relative;
  width: 100%;
  height: 100%;
}

#floating-menu-overlay .floating-menu-item {
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%) rotate(var(--rotate, 0deg)) translate(var(--radius, 0px)) rotate(calc(-1 * var(--rotate, 0deg))) scale(var(--scale, 1));
  transform-origin: center;
  color: inherit;
  text-decoration: none;
  font-size: var(--floating-item-font);
  opacity: 0.88;
  z-index: 5;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

#floating-menu-overlay .floating-menu-item:hover {
  --scale: 1.06;
  opacity: 1;
}

#floating-menu-overlay .floating-menu-item::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  z-index: -1;
}

@media (prefers-reduced-motion: reduce) {
  #floating-menu-overlay .floating-menu-item {
    transition: none;
  }
}

.cursor-circle {
  position: fixed;
  top: 0;
  left: 0;
  width: 40px;
  height: 40px;
  border: 2px solid rgb(0, 0, 0);
  background-color: #000000;
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: transform 0.1s ease-out;
}

@media (max-width: 768px) {
  #project-name,
  #project-name-right,
  #clock-container {
    font-size: 1.2rem;
    top: 36px;
  }

  .mini-clock {
    width: 36px;
    height: 36px;
  }

  .timeline-shell {
    padding: 140px 16px 220px;
  }

  .timeline-row {
    padding: 18px 24px;
    min-height: 150px;
  }

  .timeline-row__marker {
    width: 88px;
    height: 88px;
  }

  .guestbook-form__field {
    padding: 16px 20px;
  }

  .guestbook-submit {
    width: 46px;
    height: 46px;
  }
}
