/* ── Reset & Base ── */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  /* DARK theme (default) */
  --bg: #0a0d12;
  --bg-panel: #0e1117;
  --surface: #161b25;
  --surface-2: #1e2535;
  --text: #e8ecf4;
  --text-muted: #8a95ac;
  --border: rgba(255, 255, 255, 0.07);
  --accent: #38bdf8;
  --accent-2: #818cf8;
  --btn-text: #0a0d12;
  --overlay-start: #0a0d12cc;
  --overlay-end: #0a0d1280;
  --shape-color: rgba(56, 189, 248, 0.07);
  --progress-bg: rgba(255, 255, 255, 0.06);
  --sep-color: rgba(255, 255, 255, 0.25);
  --contact-color: #8a95ac;

  --font-display: "Syne", sans-serif;
  --font-body: "DM Sans", sans-serif;

  --transition: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="light"] {
  --bg: #f4f6fb;
  --bg-panel: #ffffff;
  --surface: #eef0f7;
  --surface-2: #e4e7f2;
  --text: #111827;
  --text-muted: #6b7280;
  --border: rgba(0, 0, 0, 0.07);
  --accent: #0284c7;
  --accent-2: #4f46e5;
  --btn-text: #ffffff;
  --overlay-start: #0a0d12dd;
  --overlay-end: #1a3a5a90;
  --shape-color: rgba(2, 132, 199, 0.09);
  --progress-bg: rgba(0, 0, 0, 0.07);
  --sep-color: rgba(0, 0, 0, 0.2);
  --contact-color: #6b7280;
}

html {
  height: 100%;
}

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  height: 100%;
  overflow: hidden;
  transition:
    background var(--transition),
    color var(--transition);
}

/* ── Layout ── */
.layout {
  display: flex;
  height: 100vh;
  width: 100vw;
}

/* ── LEFT PANEL ── */
.panel-left {
  position: relative;
  flex: 0 0 50%;
  display: flex;
  align-items: flex-end;
  justify-content: flex-start;
  overflow: hidden;
}

.bg-image {
  position: absolute;
  inset: 0;
  background: url("https://images.unsplash.com/photo-1545987796-200677ee1011?w=900&auto=format&fit=crop&q=80") center / cover no-repeat;
  transform: scale(1.05);
  animation: slowZoom 20s ease-in-out infinite alternate;
}

@keyframes slowZoom {
  from {
    transform: scale(1.05);
  }
  to {
    transform: scale(1.12);
  }
}

.bg-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, var(--overlay-start) 0%, var(--overlay-end) 100%);
  transition: background var(--transition);
}

/* Geometric decoration */
.shape {
  position: absolute;
  border-radius: 3px;
  background: var(--shape-color);
  border: 1px solid rgba(56, 189, 248, 0.12);
  animation: floatShape 8s ease-in-out infinite;
  pointer-events: none;
}
.shape-1 {
  width: 80px;
  height: 80px;
  top: 15%;
  left: 12%;
  transform: rotate(22deg);
  animation-delay: 0s;
}
.shape-2 {
  width: 50px;
  height: 50px;
  top: 35%;
  right: 18%;
  transform: rotate(-15deg);
  animation-delay: 2s;
}
.shape-3 {
  width: 110px;
  height: 110px;
  bottom: 28%;
  left: 22%;
  transform: rotate(42deg);
  animation-delay: 4s;
}

@keyframes floatShape {
  0%,
  100% {
    transform: translateY(0) rotate(22deg);
  }
  50% {
    transform: translateY(-14px) rotate(28deg);
  }
}
.shape-2 {
  animation: floatShape2 9s ease-in-out infinite 2s;
}
@keyframes floatShape2 {
  0%,
  100% {
    transform: translateY(0) rotate(-15deg);
  }
  50% {
    transform: translateY(-10px) rotate(-8deg);
  }
}
.shape-3 {
  animation: floatShape3 11s ease-in-out infinite 4s;
}
@keyframes floatShape3 {
  0%,
  100% {
    transform: translateY(0) rotate(42deg);
  }
  50% {
    transform: translateY(-18px) rotate(50deg);
  }
}

/* Countdown */
.countdown-container {
  position: relative;
  z-index: 2;
  padding: 0 44px 52px;
  width: 100%;
}

.countdown-label {
  font-family: var(--font-display);
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 20px;
  opacity: 0.9;
}

.countdown {
  display: flex;
  align-items: flex-end;
  gap: 0;
  flex-wrap: wrap;
}

.count-unit {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 62px;
}

.count-number {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3.2rem);
  font-weight: 800;
  color: #fff;
  line-height: 1;
  letter-spacing: -0.02em;
  text-shadow: 0 0 30px rgba(56, 189, 248, 0.3);
  transition: transform 0.15s;
}

.count-name {
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
  margin-top: 6px;
}

.count-sep {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3vw, 2.4rem);
  font-weight: 700;
  color: var(--accent);
  line-height: 1;
  padding: 0 4px;
  margin-bottom: 18px;
  opacity: 0.6;
}

.launch-date {
  margin-top: 20px;
  font-family: var(--font-display);
  font-size: 0.78rem;
  letter-spacing: 0.3em;
  color: rgba(255, 255, 255, 0.35);
  text-transform: uppercase;
}

/* ── RIGHT PANEL ── */
.panel-right {
  flex: 0 0 50%;
  background: var(--bg-panel);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow-y: auto;
  transition: background var(--transition);
}

.right-inner {
  width: 100%;
  max-width: 420px;
  padding: 52px 48px 52px 44px;
  display: flex;
  flex-direction: column;
  gap: 34px;
}

/* Logo */
.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--text);
}

.logo svg {
  flex-shrink: 0;
  color: var(--text);
  opacity: 0.9;
}

.logo-text {
  font-family: var(--font-display);
  font-size: 1.1rem;
  letter-spacing: 0.04em;
  color: var(--text);
}

.logo-text strong {
  font-weight: 800;
  color: var(--accent);
}

/* Hero */
.hero-text {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.eyebrow {
  font-family: var(--font-display);
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
}

h1 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 3.5vw, 2.8rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--text);
}

.subtitle {
  font-size: 0.92rem;
  line-height: 1.65;
  color: var(--text-muted);
  max-width: 360px;
}

/* Community CTA */
.community-cta {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.cta-desc {
  font-size: 0.9rem;
  line-height: 1.65;
  color: var(--text-muted);
}

.btn-community {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  align-self: flex-start;
  padding: 13px 28px;
  background: var(--accent);
  color: var(--btn-text);
  font-family: var(--font-display);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
  border-radius: 10px;
  transition:
    transform 0.2s,
    box-shadow 0.2s;
  box-shadow: 0 4px 24px rgba(56, 189, 248, 0.25);
}

.btn-community:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(56, 189, 248, 0.4);
}

.btn-community:active {
  transform: translateY(0);
}

.btn-icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

/* Progress */
.progress-section {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.progress-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.78rem;
  color: var(--text-muted);
  font-family: var(--font-display);
  letter-spacing: 0.04em;
}

.progress-bar {
  height: 4px;
  background: var(--progress-bg);
  border-radius: 9999px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  width: var(--pct);
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  border-radius: 9999px;
  animation: growBar 1.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
  transform-origin: left;
}

@keyframes growBar {
  from {
    width: 0;
  }
  to {
    width: var(--pct);
  }
}

/* Social links */
.social-links {
  display: flex;
  gap: 20px;
  align-items: center;
}

.social-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid var(--border);
  color: var(--text-muted);
  text-decoration: none;
  transition:
    border-color 0.2s,
    color 0.2s,
    background 0.2s,
    transform 0.2s;
}

.social-link svg {
  width: 16px;
  height: 16px;
}

.social-link:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(56, 189, 248, 0.06);
  transform: translateY(-3px);
}

/* Contact */
.contact-info {
  font-size: 0.8rem;
  color: var(--contact-color);
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
}

.sep {
  color: var(--sep-color);
}

/* ── Theme Toggle ── */
.theme-toggle {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 100;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1.5px solid rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  cursor: pointer;
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.35);
  transition:
    border-color 0.3s,
    background 0.3s;
}

.theme-toggle:hover {
  background: rgba(255, 255, 255, 0.16);
  border-color: rgba(255, 255, 255, 0.35);
}

.toggle-label {
  display: flex;
  align-items: center;
  color: rgba(255, 255, 255, 0.85);
  transition:
    color 0.3s,
    opacity 0.3s;
}

.t-icon {
  width: 15px;
  height: 15px;
}

/* Sun icon = left; always visible but dimmed when dark mode active */
.theme-toggle .toggle-label:first-child {
  opacity: 0.5;
}
[data-theme="light"] .theme-toggle .toggle-label:first-child {
  opacity: 1;
}
[data-theme="light"] .theme-toggle .toggle-label:last-child {
  opacity: 0.5;
}

/* Track */
.toggle-track {
  position: relative;
  width: 36px;
  height: 20px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 999px;
  border: 1.5px solid rgba(255, 255, 255, 0.25);
  transition: background 0.3s;
  flex-shrink: 0;
}

[data-theme="light"] .toggle-track {
  background: rgba(255, 255, 255, 0.4);
}

/* Thumb */
.toggle-thumb {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="light"] .toggle-thumb {
  transform: translateX(16px);
}

/* ── Responsive ── */
@media (max-width: 900px) {
  body {
    overflow: auto;
  }

  .layout {
    flex-direction: column;
    height: auto;
    min-height: 100vh;
  }

  .panel-left {
    flex: none;
    height: 52vh;
    min-height: 300px;
  }

  .countdown-container {
    padding: 0 28px 36px;
  }

  .count-unit {
    min-width: 48px;
  }
  .count-sep {
    padding: 0 2px;
    margin-bottom: 16px;
  }

  .panel-right {
    flex: none;
    min-height: 60vh;
  }

  .right-inner {
    padding: 40px 28px;
    max-width: 100%;
    gap: 28px;
  }
}

@media (max-width: 480px) {
  .panel-left {
    height: 44vh;
  }
  .countdown {
    gap: 0;
  }
  .count-unit {
    min-width: 40px;
  }
  .count-number {
    font-size: 1.6rem;
  }
  .count-sep {
    font-size: 1.2rem;
  }
  h1 {
    font-size: 1.9rem;
  }
  .btn-notify {
    align-self: stretch;
    text-align: center;
  }
}

/* Entry animations */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(22px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.logo {
  animation: fadeUp 0.6s ease both 0.15s;
}
.hero-text {
  animation: fadeUp 0.6s ease both 0.3s;
}
.community-cta {
  animation: fadeUp 0.6s ease both 0.45s;
}
.progress-section {
  animation: fadeUp 0.6s ease both 0.55s;
}
.social-links {
  animation: fadeUp 0.6s ease both 0.65s;
}
.contact-info {
  animation: fadeUp 0.6s ease both 0.75s;
}
.countdown-container {
  animation: fadeUp 0.8s ease both 0.2s;
}
