:root {
  color-scheme: light;
  --ink: #17191d;
  --muted: #626a73;
  --chrome-dark: #24272d;
  --chrome-mid: #9fa7b2;
  --chrome-light: #f7f9fb;
  --chrome-blue: #cbd8e8;
  --accent: #d7dde5;
  --accent-strong: #68727e;
  --shadow: rgba(35, 40, 48, 0.22);
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  font-family: ui-rounded, "SF Pro Rounded", "Avenir Next", system-ui, sans-serif;
  background:
    radial-gradient(circle at 18% 18%, rgba(255, 255, 255, 0.92), transparent 24%),
    radial-gradient(circle at 82% 16%, rgba(163, 176, 193, 0.52), transparent 26%),
    radial-gradient(circle at 70% 82%, rgba(222, 229, 238, 0.9), transparent 30%),
    linear-gradient(135deg, #f8fafc 0%, #d8dee7 36%, #eef2f6 62%, #aeb7c3 100%);
  color: var(--ink);
  cursor: none;
}

button,
input,
textarea {
  font: inherit;
}

button,
label,
input,
textarea {
  cursor: none;
}

.custom-cursor {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 9999;
  width: 56px;
  height: 56px;
  object-fit: contain;
  pointer-events: none;
  transform: translate(-6px, -4px);
  opacity: 0;
  transition: opacity 120ms ease, scale 120ms ease;
  filter: drop-shadow(0 10px 16px rgba(33, 28, 31, 0.24));
}

.custom-cursor.visible {
  opacity: 1;
}

.custom-cursor.clicking {
  scale: 0.9;
}

.page-shell {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 32px 18px;
  overflow: hidden;
}

.page-shell.is-locked {
  display: none;
}

.auth-screen {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 28px 18px;
  overflow: hidden;
  background:
    radial-gradient(circle at 24% 18%, rgba(255, 255, 255, 0.95), transparent 22%),
    radial-gradient(circle at 84% 82%, rgba(139, 150, 164, 0.28), transparent 26%),
    linear-gradient(145deg, #f6f7f8 0%, #d8dde4 48%, #f1f3f5 100%);
}

.login-panel {
  position: relative;
  z-index: 1;
  width: min(100%, 420px);
  display: grid;
  gap: 22px;
  padding: 34px;
  border: 1px solid rgba(21, 24, 29, 0.08);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(244, 246, 248, 0.9)),
    linear-gradient(135deg, rgba(255, 255, 255, 0.7), rgba(180, 188, 199, 0.28));
  box-shadow:
    0 28px 70px rgba(35, 40, 48, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  text-align: left;
  backdrop-filter: blur(18px);
}

.login-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: fit-content;
  color: #303640;
  font-size: 0.92rem;
  font-weight: 950;
}

.login-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: #17191d;
  color: #ffffff;
  font-size: 1.3rem;
  line-height: 1;
}

.auth-copy {
  display: grid;
  gap: 8px;
}

.auth-form {
  display: grid;
  gap: 16px;
}

.login-panel h1 {
  margin: 0;
  color: var(--ink);
  font-size: 2rem;
  font-weight: 950;
  line-height: 1;
}

.auth-copy p {
  margin: 0;
  color: #626a73;
  font-size: 0.98rem;
  font-weight: 700;
  line-height: 1.35;
}

.login-panel label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 900;
  text-align: left;
}

.login-panel input {
  width: 100%;
  min-height: 52px;
  border: 1px solid rgba(36, 40, 48, 0.13);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.86);
  color: var(--ink);
  padding: 12px 14px;
  font-weight: 800;
  outline: none;
  box-shadow: none;
}

.login-panel input:focus {
  border-color: rgba(23, 25, 29, 0.46);
  box-shadow:
    0 0 0 4px rgba(23, 25, 29, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.login-button,
.logout-button {
  border: 1px solid rgba(40, 46, 55, 0.22);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.88), rgba(199, 208, 219, 0.78)),
    linear-gradient(135deg, #f7f9fb, #aeb7c3);
  color: #232932;
  box-shadow:
    0 10px 20px rgba(35, 40, 48, 0.13),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  font-weight: 950;
}

.login-button {
  min-height: 52px;
  border: 0;
  border-radius: 12px;
  background: #17191d;
  color: #ffffff;
  box-shadow: 0 14px 28px rgba(23, 25, 29, 0.2);
}

.text-button {
  min-height: 28px;
  border: 0;
  background: transparent;
  color: #303640;
  font-size: 0.9rem;
  font-weight: 900;
  text-decoration: underline;
  text-underline-offset: 3px;
  padding: 0;
}

.auth-actions {
  display: flex;
  justify-content: center;
}

.login-button:disabled {
  opacity: 0.62;
}

.login-status {
  min-height: 22px;
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 850;
  line-height: 1.25;
  text-align: center;
}

.sky {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.anniversary-countdown {
  position: fixed;
  top: 18px;
  right: 18px;
  z-index: 2;
  width: 128px;
  padding: 11px 12px 12px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 22px;
  background:
    linear-gradient(120deg, rgba(255, 255, 255, 0.8) 0%, rgba(255, 255, 255, 0.18) 42%, transparent 58%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.74), rgba(183, 193, 205, 0.54));
  box-shadow:
    0 16px 34px rgba(35, 40, 48, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.84),
    inset 0 -3px 0 rgba(42, 48, 56, 0.08);
  color: var(--ink);
  text-align: center;
  backdrop-filter: blur(14px);
}

.countdown-label {
  display: block;
  color: #5f6a77;
  font-size: 2rem;
  font-weight: 800;
  line-height: 0.82;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.7);
}

.anniversary-countdown strong {
  display: block;
  margin-top: 7px;
  font-size: 1.08rem;
  line-height: 1.1;
  white-space: nowrap;
}

.weather-widget {
  position: fixed;
  top: 18px;
  left: 18px;
  z-index: 2;
  width: 218px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.68);
  border-radius: 22px;
  background:
    linear-gradient(120deg, rgba(255, 255, 255, 0.74), rgba(255, 255, 255, 0.12) 54%, transparent),
    linear-gradient(135deg, rgba(255, 255, 255, 0.66), rgba(181, 192, 205, 0.46));
  box-shadow:
    0 16px 34px rgba(35, 40, 48, 0.13),
    inset 0 1px 0 rgba(255, 255, 255, 0.82),
    inset 0 -3px 0 rgba(42, 48, 56, 0.07);
  color: var(--ink);
  backdrop-filter: blur(14px);
}

.weather-title {
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 900;
  line-height: 1;
  margin-bottom: 10px;
}

.weather-list {
  display: grid;
  gap: 9px;
}

.weather-card {
  display: grid;
  grid-template-columns: 34px 1fr auto;
  align-items: center;
  gap: 9px;
  min-height: 44px;
}

.weather-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.55);
  color: #4e5965;
  font-size: 1.28rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.76);
}

.weather-place {
  display: block;
  font-weight: 900;
  line-height: 1.1;
}

.weather-desc {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 750;
  line-height: 1.1;
}

.weather-temp {
  font-size: 1.18rem;
  font-weight: 950;
  white-space: nowrap;
}

.weather-loading {
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 800;
}

.cloud,
.heart,
.plane {
  position: absolute;
  display: block;
}

.cloud {
  width: 140px;
  height: 44px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.52);
  box-shadow: 0 18px 40px rgba(105, 116, 130, 0.12);
}

.cloud::before,
.cloud::after {
  content: "";
  position: absolute;
  bottom: 12px;
  border-radius: 50%;
  background: inherit;
}

.cloud::before {
  left: 22px;
  width: 50px;
  height: 50px;
}

.cloud::after {
  right: 20px;
  width: 62px;
  height: 62px;
}

.cloud-one {
  top: 12%;
  left: 7%;
  animation: drift 12s ease-in-out infinite;
}

.cloud-two {
  right: 9%;
  bottom: 16%;
  transform: scale(0.8);
  animation: drift 15s ease-in-out infinite reverse;
}

.heart {
  width: 22px;
  height: 22px;
  transform: rotate(45deg);
  background: linear-gradient(135deg, #f9fbfd, #98a2ae);
  opacity: 0.76;
  animation: float-heart 6s ease-in-out infinite;
}

.heart::before,
.heart::after {
  content: "";
  position: absolute;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: inherit;
}

.heart::before {
  left: -11px;
}

.heart::after {
  top: -11px;
}

.heart-one {
  left: 18%;
  bottom: 22%;
}

.heart-two {
  right: 22%;
  top: 22%;
  width: 16px;
  height: 16px;
  background: linear-gradient(135deg, #ffffff, #7d8793);
  animation-delay: -2s;
}

.heart-two::before,
.heart-two::after {
  width: 16px;
  height: 16px;
}

.heart-two::before {
  left: -8px;
}

.heart-two::after {
  top: -8px;
}

.heart-three {
  right: 14%;
  bottom: 28%;
  background: linear-gradient(135deg, #f8fafc, #b8c1cc);
  animation-delay: -4s;
}

.plane {
  color: rgba(82, 92, 106, 0.5);
  font-size: clamp(1.15rem, 2.2vw, 1.9rem);
  line-height: 1;
  filter: drop-shadow(0 8px 14px rgba(35, 40, 48, 0.12));
  opacity: 0.62;
}

.plane::after {
  content: "";
  position: absolute;
  right: 78%;
  top: 50%;
  width: 74px;
  height: 1px;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0), rgba(115, 126, 140, 0.22));
}

.plane-one {
  top: 20%;
  left: -12%;
  animation: plane-fly-right 18s linear infinite;
}

.plane-two {
  top: 64%;
  right: -12%;
  rotate: 180deg;
  animation: plane-fly-left 24s linear infinite;
  animation-delay: -8s;
}

.plane-three {
  top: 38%;
  left: -12%;
  scale: 0.75;
  animation: plane-fly-right 28s linear infinite;
  animation-delay: -15s;
}

.rain-layer {
  position: absolute;
  inset: 0;
  overflow: hidden;
  opacity: 0;
  transition: opacity 260ms ease;
}

.rain-layer.active {
  opacity: 1;
}

.rain-drop {
  position: absolute;
  top: -18vh;
  width: 1px;
  height: var(--drop-height);
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0), rgba(98, 108, 121, 0.52));
  left: var(--drop-left);
  animation: rain-fall var(--drop-duration) linear infinite;
  animation-delay: var(--drop-delay);
}

.fireworks-layer {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.firework {
  position: absolute;
  left: var(--burst-x);
  top: var(--burst-y);
  width: 8px;
  height: 8px;
}

.spark {
  position: absolute;
  left: 0;
  top: 0;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--spark-color);
  box-shadow: 0 0 12px var(--spark-color);
  animation: spark-burst 1550ms ease-out forwards;
  rotate: var(--spark-angle);
}

.center-stage {
  position: relative;
  z-index: 1;
  width: min(620px, 100%);
  text-align: center;
  padding: clamp(28px, 5vw, 52px);
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--accent-strong);
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
  font-size: 0.8rem;
}

h1 {
  margin: 0;
  font-size: clamp(3.6rem, 13vw, 7rem);
  line-height: 0.9;
  letter-spacing: 0;
}

.subcopy {
  max-width: 440px;
  margin: 18px auto 28px;
  color: var(--muted);
  font-size: clamp(1rem, 3vw, 1.18rem);
}

.big-button {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 82px;
  min-width: 300px;
  padding: 14px 34px;
  border: 0;
  border-radius: 999px;
  background:
    linear-gradient(120deg, rgba(255,255,255,0.8) 0%, rgba(255,255,255,0.16) 18%, transparent 34%),
    linear-gradient(135deg, #f9fbfd 0%, #bdc6d1 34%, #6d7682 53%, #edf1f5 76%, #8f99a6 100%);
  color: #16191e;
  font-size: clamp(1.2rem, 4vw, 1.55rem);
  font-weight: 900;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.68);
  box-shadow:
    0 18px 42px var(--shadow),
    inset 0 2px 0 rgba(255, 255, 255, 0.82),
    inset 0 -5px 0 rgba(35, 40, 48, 0.18);
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.big-button:hover {
  transform: translateY(-3px) scale(1.01);
  box-shadow:
    0 24px 52px var(--shadow),
    inset 0 2px 0 rgba(255, 255, 255, 0.9),
    inset 0 -5px 0 rgba(35, 40, 48, 0.2);
}

.big-button:active {
  transform: translateY(1px) scale(0.99);
}

.request-panel {
  width: min(500px, 100%);
  margin: 28px auto 0;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.8);
  border-radius: 24px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, 0.7), rgba(213, 221, 231, 0.48));
  box-shadow: 0 20px 42px rgba(42, 48, 56, 0.18);
  backdrop-filter: blur(16px);
}

.mode-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 14px;
}

.mode-tab,
.send-button,
.music-toggle {
  border: 0;
  font-weight: 800;
}

.mode-tab {
  padding: 10px 12px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.62);
  color: var(--muted);
}

.mode-tab.active {
  background: linear-gradient(135deg, #ffffff, #aeb8c5);
  color: #1b2027;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

.field-grid {
  display: grid;
  gap: 12px;
}

.two-cols {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

label {
  display: grid;
  gap: 7px;
  text-align: left;
  color: var(--muted);
  font-size: 0.94rem;
  font-weight: 800;
}

input,
textarea {
  width: 100%;
  border: 1px solid rgba(82, 91, 102, 0.2);
  border-radius: 16px;
  padding: 12px 14px;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.78);
  outline: none;
}

input:focus,
textarea:focus {
  border-color: #788493;
  box-shadow: 0 0 0 4px rgba(144, 154, 167, 0.22);
}

.note-field {
  margin-top: 12px;
}

.send-button {
  width: 100%;
  margin-top: 14px;
  padding: 13px 16px;
  border-radius: 18px;
  background: linear-gradient(135deg, #252a31, #5d6672);
  color: #fff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18);
}

.send-button:disabled {
  opacity: 0.6;
}

.status {
  min-height: 22px;
  margin: 12px 0 0;
  color: #49535f;
  font-weight: 800;
}

.music-box {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 8px;
}

.logout-button {
  position: fixed;
  left: 18px;
  bottom: 18px;
  z-index: 2;
  min-height: 38px;
  padding: 0 15px;
  border-radius: 999px;
  font-size: 0.9rem;
}

.rain-toggle,
.music-toggle,
.spotify-link {
  width: 112px;
  min-height: 46px;
  padding: 11px 16px;
  border-radius: 999px;
  background: rgba(34, 39, 46, 0.88);
  color: white;
  font-size: 1rem;
  font-weight: 800;
  line-height: 1;
  text-align: center;
  box-shadow: 0 14px 30px rgba(34, 39, 46, 0.22);
}

.spotify-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  background: #1db954;
}

@media (pointer: coarse) {
  body,
  button,
  label,
  input,
  textarea {
    cursor: auto;
  }

  .custom-cursor {
    display: none;
  }
}

@keyframes drift {
  0%,
  100% {
    translate: 0 0;
  }
  50% {
    translate: 18px -8px;
  }
}

@keyframes float-heart {
  0%,
  100% {
    translate: 0 0;
  }
  50% {
    translate: 0 -16px;
  }
}

@keyframes plane-fly-right {
  0% {
    translate: -10vw 0;
  }
  100% {
    translate: 124vw -10vh;
  }
}

@keyframes plane-fly-left {
  0% {
    translate: 10vw 0;
  }
  100% {
    translate: -124vw 9vh;
  }
}

@keyframes rain-fall {
  from {
    translate: 0 -12vh;
  }
  to {
    translate: -32px 126vh;
  }
}

@keyframes spark-burst {
  0% {
    opacity: 1;
    transform: translate(0, 0) scale(1);
  }
  100% {
    opacity: 0;
    transform: translate(var(--spark-distance), 0) scale(0.2);
  }
}

@media (max-width: 560px) {
  .page-shell {
    padding: 24px 14px 76px;
  }

  .anniversary-countdown {
    top: 14px;
    right: 14px;
    width: 116px;
    padding: 10px 10px 11px;
    border-radius: 18px;
  }

  .weather-widget {
    top: 14px;
    left: 14px;
    width: 158px;
    padding: 11px;
    border-radius: 18px;
  }

  .weather-title {
    margin-bottom: 8px;
  }

  .weather-card {
    grid-template-columns: 28px 1fr;
    gap: 7px;
  }

  .weather-icon {
    width: 28px;
    height: 28px;
    font-size: 1rem;
  }

  .weather-temp {
    grid-column: 2;
    font-size: 0.95rem;
  }

  .weather-desc {
    display: none;
  }

  .countdown-label {
    font-size: 1.8rem;
  }

  .anniversary-countdown strong {
    font-size: 0.98rem;
  }

  .center-stage {
    padding: 18px 0;
  }

  .big-button {
    width: 100%;
    padding-right: 18px;
    padding-left: 18px;
  }

  .two-cols {
    grid-template-columns: 1fr;
  }
}
