/* ═══════════════════════════════════════════════════════════════════════════
   GarageBucket v6.0.0 — login page ("Sunset Bento" system, light-only)
   landing.js contract preserved: #landing gets `landing bg-*` classes,
   .login-input/.shake/.spinner/.hidden all still exist.
   ═══════════════════════════════════════════════════════════════════════════ */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --ink: #1A1523;
  --ink-soft: #3F3849;
  --ink-muted: #5D5470;
  --canvas: #F7F5F2;
  --surface: #FFFFFF;
  --border: #E9E4DD;
  --border-strong: #D8D1C7;
  --g1: #FF5A3C;
  --g2: #E11D48;
  --g3: #7C3AED;
  --grad: linear-gradient(135deg, var(--g1), var(--g2) 48%, var(--g3));
  --primary-strong: #6D28D9;
  --r-lg: 24px;
  --r-xl: 32px;
  --sh-md: 0 2px 4px rgba(26,21,35,.05), 0 14px 34px -10px rgba(26,21,35,.14);
  --sh-lg: 0 6px 16px rgba(26,21,35,.07), 0 28px 70px -16px rgba(109,40,217,.22);
  --spring: cubic-bezier(.34,1.56,.64,1);
  --ease: cubic-bezier(.22,1,.36,1);
  --font-display: 'Bricolage Grotesque', 'Instrument Sans', sans-serif;
  --font-ui: 'Instrument Sans', -apple-system, BlinkMacSystemFont, sans-serif;

  /* weather tint defaults (clear day) — bg-* classes override */
  --w1: #FFD9A8;
  --w2: #CDE4FF;
  --w3: #FBD3E2;
}

html { overflow-y: auto; }
html, body { min-height: 100%; }
body { font-family: var(--font-ui); color: var(--ink); -webkit-font-smoothing: antialiased; }

.landing {
  position: relative;
  min-height: 100dvh;
  background: var(--canvas);
  overflow: hidden;
  padding: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-bottom: max(24px, env(safe-area-inset-bottom));
}

/* ── weather-tinted ambient blobs ── */
.bg-blobs { position: absolute; inset: 0; pointer-events: none; }
.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: .55;
  transition: background 2s ease;
  animation: blobFade 1.2s var(--ease) both, blobDrift 24s ease-in-out infinite alternate;
}
.blob-1 { width: 540px; height: 540px; top: -160px; left: -120px; background: var(--w1); }
.blob-2 { width: 460px; height: 460px; top: 20%; right: -140px; background: var(--w2); animation-delay: 0s, -8s; }
.blob-3 { width: 420px; height: 420px; bottom: -150px; left: 34%; background: var(--w3); animation-delay: 0s, -15s; }
@keyframes blobFade { from { opacity: 0; } to { opacity: .55; } }
@keyframes blobDrift {
  from { margin-top: 0; margin-left: 0; }
  to   { margin-top: 55px; margin-left: -40px; }
}

/* weather condition tints (landing.js swaps these classes) */
.bg-clear-day   { --w1: #FFD9A8; --w2: #CDE4FF; --w3: #FBD3E2; }
.bg-clear-night { --w1: #C7C4F4; --w2: #B9D4F6; --w3: #E3D6FC; }
.bg-cloudy      { --w1: #DCD9E4; --w2: #CFE0EE; --w3: #E9E4DD; }
.bg-fog         { --w1: #E4E1E8; --w2: #DAD6DE; --w3: #EDEAF0; }
.bg-rain        { --w1: #BBD7F2; --w2: #C4C9F4; --w3: #D6E5F5; }
.bg-snow        { --w1: #E8F1FB; --w2: #DCE8F8; --w3: #EFF5FC; }
.bg-storm       { --w1: #C9C2E8; --w2: #ADB9E3; --w3: #E3D6FC; }

/* ── layout ── */
.landing-grid {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1060px;
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 40px;
  align-items: center;
}

/* ── left column ── */
.weather-section { display: flex; flex-direction: column; gap: 18px; }

.brand-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  animation: rise .6s var(--ease) both;
}
.brand-mark {
  width: 44px; height: 44px;
  border-radius: 14px;
  background: var(--grad);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 20px -8px rgba(225,29,72,.6);
}
.brand-name {
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.tile {
  background: rgba(255,255,255,.78);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-md);
  padding: 26px 28px;
  transition: transform .3s var(--spring), box-shadow .3s var(--ease);
}
.tile:hover { transform: translateY(-4px); box-shadow: var(--sh-lg); }

.time-block { animation: rise .6s .1s var(--ease) backwards; }
.time-clock {
  font-family: var(--font-display);
  font-size: clamp(2.6rem, 6vw, 4rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
  line-height: 1.05;
}
.time-date { font-size: 1.02rem; font-weight: 600; color: var(--ink-soft); margin-top: 6px; }
.time-location { font-size: .88rem; font-weight: 600; color: var(--ink-muted); margin-top: 2px; }

.weather-row {
  display: flex;
  align-items: flex-end;
  gap: 14px;
  animation: rise .6s .2s var(--ease) both;
}
.weather-block { flex: 1; display: grid; grid-template-columns: auto 1fr; gap: 2px 16px; align-items: center; }
.weather-icon { font-size: 2.6rem; grid-row: 1 / span 2; animation: floatY 3.4s ease-in-out infinite; }
@keyframes floatY {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-7px); }
}
.weather-temp {
  font-family: var(--font-display);
  font-size: 1.9rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.weather-desc { font-size: .95rem; font-weight: 700; color: var(--ink-soft); }
.weather-detail { grid-column: 2; font-size: .82rem; font-weight: 600; color: var(--ink-muted); }

.unit-toggle {
  border: 1.5px solid var(--border-strong);
  background: rgba(255,255,255,.78);
  color: var(--ink-soft);
  font-family: var(--font-ui);
  font-size: .82rem;
  font-weight: 700;
  min-height: 44px;
  padding: 10px 16px;
  border-radius: 999px;
  cursor: pointer;
  white-space: nowrap;
  transition: all .16s var(--ease);
}
.unit-toggle:hover { border-color: var(--g3); color: var(--primary-strong); transform: translateY(-1px); }

/* ── right column: login card ── */
.login-section { animation: cardIn .65s .25s var(--spring) both; }
@keyframes cardIn {
  from { opacity: 0; transform: translateY(30px) scale(.94); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.login-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  box-shadow: var(--sh-lg);
  padding: 44px 40px;
}
.login-title {
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 4vw, 2.5rem);
  font-weight: 800;
  letter-spacing: -0.025em;
}
.login-title .grad-word {
  background: var(--grad);
  background-size: 200% 200%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: gradShift 6s ease-in-out infinite alternate;
}
@keyframes gradShift { from { background-position: 0% 0%; } to { background-position: 100% 100%; } }
.login-sub-top { color: var(--ink-muted); font-weight: 600; margin: 6px 0 26px; }

.login-fields { display: flex; flex-direction: column; gap: 12px; margin-bottom: 18px; }
.login-input {
  width: 100%;
  font-family: var(--font-ui);
  font-size: 1rem;
  color: var(--ink);
  background: var(--canvas);
  border: 2px solid var(--border);
  border-radius: 16px;
  padding: 15px 18px;
  min-height: 52px;
  outline: none;
  transition: border-color .16s var(--ease), box-shadow .16s var(--ease), background .16s;
}
.login-input::placeholder { color: #8A8098; }
.login-input:focus {
  border-color: var(--g3);
  background: var(--surface);
  box-shadow: 0 0 0 4px rgba(124,58,237,.13);
}

/* wrong password shake (landing.js toggles .shake) */
.shake { animation: shake .5s var(--ease); }
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-9px); }
  40% { transform: translateX(8px); }
  60% { transform: translateX(-6px); }
  80% { transform: translateX(4px); }
}

.login-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: none;
  border-radius: 999px;
  min-height: 54px;
  padding: 14px 24px;
  background: var(--grad);
  background-size: 170% 170%;
  color: #fff;
  font-family: var(--font-ui);
  font-size: 1.05rem;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 10px 26px -8px rgba(225,29,72,.6);
  transition: background-position .45s var(--ease), transform .16s var(--spring), box-shadow .3s var(--ease);
}
.login-btn:hover { background-position: 100% 100%; transform: translateY(-2px); box-shadow: 0 14px 34px -8px rgba(124,58,237,.6); }
.login-btn:active { transform: scale(.97); }
.login-btn:disabled { opacity: .6; cursor: wait; }

.spinner {
  width: 20px; height: 20px;
  border: 3px solid rgba(255,255,255,.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin .7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.login-sub { margin-top: 18px; text-align: center; font-size: .88rem; font-weight: 600; }
.login-sub a { color: var(--ink-muted); text-decoration: none; }
.login-sub a:hover { color: var(--primary-strong); text-decoration: underline; }

.hidden { display: none !important; }

@keyframes rise {
  from { opacity: 0; transform: translateY(22px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── responsive ── */
@media (max-width: 860px) {
  .landing { align-items: flex-start; padding-top: 34px; }
  .landing-grid { grid-template-columns: 1fr; gap: 24px; max-width: 500px; }
  .login-card { padding: 32px 26px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
  .blob { animation: none; opacity: .55; }
}
