:root {
  --paper: #f7f4ee;
  --card: #fffdf9;
  --ink: #292c29;
  --muted: #6e716d;
  --forest: #355d4f;
  --forest-dark: #24483d;
  --sage: #dce8df;
  --sunflower: #ffd85a;
  --navigation-blue: #1677a5;
  --terracotta: #bd654e;
  --terracotta-soft: #f1d8ce;
  --line: #dedbd3;
  --shadow: 0 16px 42px rgba(41, 44, 41, .11);
  --radius: 22px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-width: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.55;
}
button, input, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
img { display: block; max-width: 100%; }
[hidden] { display: none !important; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 68px;
  padding: 10px max(14px, env(safe-area-inset-left));
  background: rgba(250, 244, 237, .96);
  border-bottom: 1px solid rgba(91, 91, 85, .12);
  backdrop-filter: blur(14px);
}
.brand {
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  text-decoration: none;
  color: var(--forest-dark);
}
.brand-logo {
  display: block;
  width: clamp(170px, 17vw, 240px);
  height: auto;
  border-radius: 4px;
}
.mobile-menu-toggle {
  display: none;
  align-items: center;
  gap: 7px;
  min-height: 42px;
  border: 1px solid rgba(53, 93, 79, .24);
  border-radius: 999px;
  padding: 7px 13px;
  background: var(--card);
  color: var(--forest-dark);
  font-weight: 800;
  cursor: pointer;
}
.mobile-menu-toggle > span:first-child { color: var(--navigation-blue); font-size: 1.18rem; line-height: 1; }
.brand-flower {
  width: 44px;
  height: 44px;
  flex: 0 0 auto;
  overflow: visible;
  filter: drop-shadow(0 3px 3px rgba(41, 44, 41, .14));
}
.flower-stem { fill: none; stroke: #52794d; stroke-linecap: round; stroke-width: 2.2; }
.flower-leaf { stroke: #3f6943; stroke-width: .7; }
.flower-leaf-left { fill: #7ea66b; }
.flower-leaf-right { fill: #5d8b58; }
.flower-petals ellipse { fill: var(--sunflower); stroke: #e9a92e; stroke-width: .75; }
.flower-center { fill: #f2b93d; stroke: #d58e23; stroke-width: 1; }
.flower-letter {
  fill: #294f42;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 11px;
  font-weight: 800;
}
.brand-word {
  color: #294f42;
  font-family: "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  font-size: 1.08rem;
  font-style: italic;
  font-weight: 700;
  letter-spacing: .075em;
  line-height: 1;
  text-shadow: 0 1px 0 rgba(255,255,255,.8);
}
.main-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  min-width: 0;
  overflow-x: auto;
  margin-left: auto;
  padding: 4px 2px;
  scrollbar-width: none;
  white-space: nowrap;
}
.main-nav::-webkit-scrollbar { display: none; }
.main-nav a, .nav-button, .nav-disabled {
  flex: 0 0 auto;
  border: 0;
  padding: 7px 0;
  background: none;
  color: var(--ink);
  font-size: .88rem;
  font-weight: 650;
  text-decoration: none;
  cursor: pointer;
}
.main-nav a:hover, .nav-button:hover { color: var(--terracotta); }
.nav-disabled { color: #a4a39e; cursor: default; }
.pwa-install-button { color: var(--navigation-blue); }

.flash {
  position: fixed;
  z-index: 80;
  top: 78px;
  left: 50%;
  width: min(92vw, 560px);
  transform: translateX(-50%);
  padding: 13px 18px;
  border-radius: 14px;
  background: var(--forest-dark);
  color: #fff;
  box-shadow: var(--shadow);
  text-align: center;
  font-weight: 650;
  animation: flash-in .24s ease-out;
}
.flash-error { background: #8d3e35; }
.flash-info { background: #46616a; }
.flash-hide { opacity: 0; transform: translate(-50%, -8px); transition: opacity .28s ease, transform .28s ease; pointer-events: none; }
@keyframes flash-in { from { transform: translate(-50%, -8px); opacity: 0; } }

.eyebrow {
  margin: 0 0 5px;
  color: var(--terracotta);
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .15em;
  text-transform: uppercase;
}
h1, h2 { font-family: Georgia, "Times New Roman", serif; line-height: 1.15; }
h1 { margin: 0; font-size: clamp(2rem, 8vw, 4rem); font-weight: 500; }
h2 { margin: 0; font-weight: 500; }
.muted { color: var(--muted); }
.album-date { margin: 5px 0 0; color: var(--muted); font-weight: 650; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 11px 22px;
  font-weight: 750;
  text-decoration: none;
  cursor: pointer;
}
.button.primary { background: var(--forest); color: #fff; box-shadow: 0 8px 20px rgba(53, 93, 79, .2); }
.button.primary:hover { background: var(--forest-dark); }
.button.secondary { border-color: var(--forest); background: transparent; color: var(--forest-dark); }
.text-button, .link-button {
  border: 0;
  padding: 6px 0;
  background: none;
  color: var(--forest-dark);
  font-weight: 750;
  text-decoration: underline;
  text-decoration-color: rgba(53, 93, 79, .28);
  text-underline-offset: 4px;
  cursor: pointer;
}
.danger { color: #a34438 !important; }

.auth-shell {
  display: grid;
  min-height: calc(100svh - 68px);
  padding: 20px 16px 42px;
}
.auth-story {
  display: none;
  min-height: 520px;
  border-radius: 32px;
  background:
    linear-gradient(155deg, rgba(36,72,61,.08), rgba(189,101,78,.12)),
    radial-gradient(circle at 25% 20%, #f5ceb9, transparent 38%),
    radial-gradient(circle at 78% 78%, #afcabc, transparent 44%), #e9e5da;
  overflow: hidden;
}
.story-frame {
  position: relative;
  isolation: isolate;
  display: grid;
  place-items: center;
  width: 62%;
  height: 68%;
  margin: 11% auto;
  padding: clamp(24px, 4vw, 60px);
  border: 12px solid rgba(255,255,255,.78);
  border-radius: 6px;
  background: #718276;
  box-shadow: var(--shadow);
  transform: rotate(-2deg);
  overflow: hidden;
}
.story-frame::before {
  content: "";
  position: absolute;
  z-index: -2;
  inset: -12px;
  background: url('auth-mediterranean-v1.webp') center / cover no-repeat;
  filter: blur(1.2px) saturate(.9);
  transform: scale(1.015);
}
.story-frame::after {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0;
  background: linear-gradient(155deg, rgba(33,67,56,.23), rgba(82,54,42,.27));
}
.story-logo { position: relative; z-index: 1; width: 100%; transform: rotate(2deg); }
.story-logo-image {
  display: block;
  width: min(100%, 720px);
  height: auto;
  margin: 0 auto;
  border-radius: 12px;
  box-shadow: 0 10px 24px rgba(25,48,40,.22);
}
.auth-card {
  width: min(100%, 470px);
  margin: auto;
  padding: 34px 24px;
  border-radius: var(--radius);
  background: var(--card);
  box-shadow: var(--shadow);
}
.auth-card h1 { font-size: clamp(2.4rem, 10vw, 3.8rem); }
.stack-form { display: grid; gap: 10px; margin-top: 24px; }
.stack-form label, .description-form label { font-weight: 750; }
input, textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: #fff;
  color: var(--ink);
  padding: 13px 14px;
  outline: none;
}
input:focus, textarea:focus { border-color: var(--forest); box-shadow: 0 0 0 3px rgba(53,93,79,.12); }
textarea { resize: vertical; }
.field-help { display: block; margin-top: 6px; color: var(--muted); font-size: .82rem; }
.check-row { display: flex; align-items: flex-start; gap: 10px; margin: 7px 0; color: var(--muted); font-weight: 550 !important; }
.check-row input { width: 21px; height: 21px; flex: 0 0 auto; accent-color: var(--forest); }
.password-field { position: relative; }
.password-field input { padding-right: 54px; }
.password-visibility {
  position: absolute;
  top: 50%;
  right: 7px;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  transform: translateY(-50%);
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--forest-dark);
  font-size: 1.15rem;
  cursor: pointer;
}
.password-visibility:hover { background: var(--sage); }
.password-visibility:focus-visible { outline: 3px solid var(--sunflower); outline-offset: 1px; }
.auth-switch { margin: 20px 0 0; color: var(--muted); text-align: center; }
.auth-switch a { color: var(--forest-dark); font-weight: 750; }
.logout-form { margin-top: 24px; }

.narrow-page { width: min(100% - 32px, 800px); margin: 0 auto; padding: 58px 0 80px; }
.elevated-form { margin-top: 28px; padding: 24px; border-radius: var(--radius); background: var(--card); box-shadow: var(--shadow); }
.search-form { display: grid; grid-template-columns: 1fr auto; gap: 10px; margin: 28px 0 30px; }
.album-results { display: grid; gap: 14px; }
.album-result {
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 16px;
  min-height: 112px;
  padding: 10px;
  border-radius: 18px;
  background: var(--card);
  box-shadow: 0 8px 24px rgba(41,44,41,.07);
  text-decoration: none;
}
.album-result img, .result-placeholder { width: 112px; height: 112px; border-radius: 13px; object-fit: cover; }
.result-placeholder { display: grid; place-items: center; background: var(--sage); color: var(--forest); font: 700 2rem Georgia,serif; }
.album-result h2 { margin: 7px 0 3px; font-size: 1.3rem; }
.album-result p, .album-result span { margin: 0; color: var(--muted); font-size: .9rem; }
.empty-note { color: var(--muted); }

.empty-state { min-height: calc(100svh - 68px); display: grid; place-items: center; align-content: center; gap: 14px; padding: 30px; text-align: center; }
.empty-state h1 { font-size: clamp(2.2rem, 10vw, 4.2rem); }
.empty-state p { margin: 0 0 12px; color: var(--muted); }
.empty-icon { display: grid; place-items: center; width: 78px; height: 78px; border-radius: 28px 28px 28px 8px; background: var(--sage); color: var(--forest); font: 700 2.5rem Georgia,serif; }

.album-hero { position: relative; width: 100%; height: auto; max-height: 54svh; min-height: 0; aspect-ratio: 16 / 10; overflow: hidden; border: 4px solid var(--forest); border-radius: 0; background: #d9ddd7; }
.album-hero > img, .album-hero > video { width: 100%; height: 100%; object-fit: cover; }
.album-hero > video { object-fit: contain; background: #111; }
.album-hero::before { content: ""; position: absolute; inset: 0; z-index: 3; border: 2px solid var(--sunflower); pointer-events: none; }
.album-hero::after { content: ""; position: absolute; inset: auto 0 0; height: 30%; background: linear-gradient(transparent, rgba(20,28,24,.36)); pointer-events: none; }
.hero-placeholder { display: grid; place-items: center; width: 100%; height: 100%; background: radial-gradient(circle at 25% 22%, #f3d3c3, transparent 38%), radial-gradient(circle at 76% 70%, #b6cdbf, transparent 40%), #ece8df; color: var(--forest-dark); font: 500 1.5rem Georgia,serif; }
.cover-button {
  position: absolute;
  right: 16px;
  bottom: 18px;
  z-index: 2;
  border: 1px solid rgba(53,93,79,.22);
  border-radius: 999px;
  padding: 8px 12px;
  background: rgba(255,255,255,.92);
  color: var(--forest-dark);
  box-shadow: 0 6px 20px rgba(0,0,0,.2);
  font-size: .76rem;
  font-weight: 800;
  cursor: pointer;
}
.album-content { width: min(100% - 16px, 1180px); margin: 0 auto; padding: 3px 0 90px; }
.album-meta {
  width: 100%;
  padding: 0 0 8px;
  border-bottom: 1px solid var(--line);
}
.album-meta-line {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  width: 100%;
  min-height: 26px;
  color: var(--ink);
  font-size: .875rem;
  line-height: 1.2;
  white-space: nowrap;
}
.album-meta-line > * { font-size: inherit; }
.album-actions-line { margin-top: 2px; }
.album-title-inline { font-weight: 800; }
.album-title-button {
  border: 0;
  border-radius: 4px;
  padding: 2px 1px;
  background: none;
  color: inherit;
  cursor: pointer;
  text-decoration-line: underline;
  text-decoration-style: dotted;
  text-decoration-color: rgba(53, 93, 79, .55);
  text-underline-offset: 3px;
}
.album-title-button:hover { color: var(--forest-dark); }
.album-title-button:focus-visible { outline: 2px solid var(--sunflower); outline-offset: 3px; }
.meta-separator { color: #aaa8a0; }
.meta-action { border: 0; padding: 2px 0; background: none; color: var(--forest-dark); font-weight: 800; cursor: pointer; }
.description-toggle::after { content: "⌄"; display: inline-block; margin-left: 4px; transition: transform .18s ease; }
.description-toggle[aria-expanded="true"]::after { transform: rotate(180deg); }
.description-toggle.has-description,
.photo-actions details > summary { color: var(--navigation-blue); font-weight: 800; }
.album-description-panel { margin: 0 0 24px; padding: 16px 0 18px; border-bottom: 1px solid var(--line); }
.description-read > p { max-width: 800px; margin: 0 0 10px; }
.description-read .text-button { font-size: .875rem; }
.editor-actions { display: flex; gap: 16px; align-items: center; }
.muted-action { color: var(--muted); }
.description-form { display: grid; gap: 7px; }
.description-form textarea { font-size: .95rem; }

.photo-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.photo-card { min-width: 0; overflow: hidden; border-radius: 0; background: var(--card); box-shadow: 0 7px 24px rgba(41,44,41,.08); }
.photo-wrap { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: #dfe2dd; }
.photo-wrap > img, .photo-wrap > video { width: 100%; height: 100%; object-fit: cover; transition: transform .3s ease; }
.photo-wrap > video { object-fit: contain; background: #111; }
.photo-card:hover .photo-wrap > img { transform: scale(1.015); }
.zoom-button { position: absolute; right: 9px; bottom: 9px; display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: rgba(255,255,255,.94); color: var(--forest-dark); box-shadow: 0 4px 12px rgba(0,0,0,.2); font-size: 1.1rem; line-height: 1; text-decoration: none; }
.photo-wrap.has-video .zoom-button { top: 9px; bottom: auto; }
.photo-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 12px; padding: 11px 12px 13px; font-size: .82rem; }
.photo-actions details { width: 100%; border-bottom: 1px solid var(--line); }
.photo-actions details:not([open]) { width: auto; border-bottom: 0; }
.photo-actions summary { padding: 4px 0; }
.photo-description-body { padding: 4px 0 10px; font-size: .875rem; }
.photo-description-body p { margin: 0 0 8px; }
.inline-form { display: inline; margin: 0; }
.link-button { font-size: inherit; }
.photo-actions .link-button { font-weight: 400; }
.empty-photos { padding: 60px 18px; text-align: center; border: 1px dashed #bcbdb7; border-radius: var(--radius); color: var(--muted); }

.upload-sheet { position: fixed; inset: 0; z-index: 100; display: grid; align-items: end; }
.sheet-backdrop { position: absolute; inset: 0; width: 100%; border: 0; background: rgba(20,28,24,.48); backdrop-filter: blur(2px); }
.sheet-panel { position: relative; z-index: 1; width: 100%; padding: 12px 20px calc(24px + env(safe-area-inset-bottom)); border-radius: 26px 26px 0 0; background: var(--card); box-shadow: 0 -10px 42px rgba(0,0,0,.18); }
.sheet-handle { width: 46px; height: 5px; margin: 0 auto 18px; border-radius: 99px; background: #c8c7c0; }
.sheet-panel h2 { font-size: 1.8rem; }
.sheet-panel p { margin-top: 5px; color: var(--muted); }
.sheet-choice { display: block; margin: 10px 0; border: 1px solid var(--line); border-radius: 16px; padding: 15px 17px; color: var(--forest-dark); background: #fff; font-weight: 800; cursor: pointer; }
.sheet-choice input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.upload-preview { margin: 14px 0; padding: 10px; border: 1px solid var(--line); border-radius: 18px; background: var(--paper); }
.upload-preview-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(88px, 1fr)); gap: 8px; }
.upload-preview-grid img, .upload-preview-grid video { width: 100%; aspect-ratio: 1; border-radius: 11px; object-fit: cover; background: #111; }
.upload-preview-grid.single { grid-template-columns: 1fr; }
.upload-preview-grid.single img, .upload-preview-grid.single video { max-height: 42svh; aspect-ratio: auto; object-fit: contain; }
.upload-preview p { margin: 8px 2px 10px; overflow: hidden; color: var(--muted); font-size: .875rem; text-overflow: ellipsis; white-space: nowrap; }
.upload-preview .button { width: 100%; }
.pwa-help .sheet-panel > .button { width: 100%; margin-top: 12px; }
.rename-album-form { display: grid; gap: 10px; margin-top: 18px; }
.rename-album-form label { font-weight: 750; }
.rename-album-form .editor-actions { margin-top: 6px; }
.share-option-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 18px; }
.share-option {
  display: grid;
  justify-items: center;
  gap: 8px;
  min-height: 104px;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 14px 10px;
  background: #fff;
  color: var(--forest-dark);
  text-align: center;
  text-decoration: none;
  cursor: pointer;
}
.share-option:hover { border-color: rgba(53, 93, 79, .48); background: var(--sage); }
.share-option:focus-visible { outline: 3px solid var(--sunflower); outline-offset: 2px; }
.share-option-icon { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%; background: var(--paper); color: var(--forest-dark); font-size: 1.5rem; font-weight: 800; line-height: 1; }
.share-option-whatsapp { background: #25d366; color: #fff; font-size: .8rem; }
.share-option-telegram { background: #229ed9; color: #fff; font-size: .8rem; }
.share-email-form { display: grid; gap: 9px; margin-top: 18px; }
.share-email-form label { font-weight: 750; }
.share-email-form textarea { min-height: 110px; resize: vertical; }
.share-email-form .editor-actions { margin-top: 7px; }
.share-cancel { display: block; margin: 18px auto 0; }
.processing-overlay {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(246, 243, 236, .94);
  backdrop-filter: blur(5px);
}
.processing-card {
  display: grid;
  justify-items: center;
  gap: 14px;
  width: min(100%, 390px);
  padding: 30px 24px;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: var(--card);
  color: var(--forest-dark);
  box-shadow: var(--shadow);
  text-align: center;
}
.processing-card strong { font: 700 1.18rem Georgia, "Times New Roman", serif; }
.processing-card > span:last-child { color: var(--muted); font-size: .9rem; }
.processing-clock {
  width: 54px;
  height: 54px;
  border: 6px solid var(--sage);
  border-top-color: var(--sunflower);
  border-right-color: var(--forest);
  border-radius: 50%;
  animation: memo-processing-spin .85s linear infinite;
}
@keyframes memo-processing-spin { to { transform: rotate(360deg); } }
.media-jobs { display: grid; gap: 10px; margin: 0 0 18px; }
.media-job { display: flex; align-items: center; gap: 13px; padding: 13px 15px; border: 1px solid #d8d4c8; border-radius: 16px; background: #fffdf8; color: var(--forest-dark); box-shadow: 0 5px 18px rgba(41,44,41,.06); }
.media-job > div { display: grid; min-width: 0; gap: 2px; }
.media-job strong { font-size: .95rem; }
.media-job span:not(.processing-clock) { overflow: hidden; color: var(--muted); font-size: .8rem; text-overflow: ellipsis; white-space: nowrap; }
.media-job small { color: #963b2d; }
.media-job-clock { flex: 0 0 auto; width: 30px; height: 30px; border-width: 4px; }
.media-job-failed { border-color: #e3b9ae; background: #fff7f4; }
.media-job-error-icon { display: grid; flex: 0 0 auto; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: #a94432; color: #fff; font-weight: 900; }
.toast { position: fixed; left: 50%; bottom: calc(22px + env(safe-area-inset-bottom)); z-index: 130; transform: translateX(-50%); width: min(90vw, 440px); padding: 13px 18px; border-radius: 14px; background: var(--forest-dark); color: white; box-shadow: var(--shadow); text-align: center; font-weight: 700; }

.shared-header { padding: 18px max(18px, env(safe-area-inset-left)); }
.shared-main { width: min(100% - 28px, 1040px); margin: 0 auto; padding: 28px 0 90px; }
.shared-main h1 { font-size: clamp(2.3rem, 9vw, 5rem); }
.shared-description { max-width: 760px; margin: 22px 0 36px; color: var(--muted); }
.shared-card > img, .shared-card > video { width: 100%; aspect-ratio: 4/3; object-fit: cover; }
.shared-card > video { object-fit: contain; background: #111; }
.shared-card > p { margin: 0; padding: 14px; }

@media (min-width: 720px) {
  .site-header { padding-inline: 28px; }
  .main-nav { gap: 28px; }
  .main-nav a, .nav-button, .nav-disabled { font-size: .95rem; }
  .auth-shell { grid-template-columns: minmax(0, 1.15fr) minmax(360px, .85fr); gap: 32px; padding: 32px; }
  .auth-story { display: block; }
  .auth-card { padding: 44px; }
  .album-content { padding-top: 3px; }
  .photo-grid { gap: 22px; }
  .photo-card { border-radius: 0; }
  .photo-actions { gap: 8px 18px; padding: 14px 16px 16px; font-size: .94rem; }
  .sheet-panel { width: min(520px, calc(100% - 32px)); margin: 0 auto 20px; border-radius: 26px; }
}

@media (min-width: 1100px) {
  .photo-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .album-hero { height: min(62vh, 620px); max-height: 620px; aspect-ratio: auto; }
}

@media (max-width: 430px) {
  .site-header { gap: 12px; }
  .brand-logo { width: clamp(148px, 43vw, 170px); }
  .photo-actions { gap: 3px 9px; padding: 9px; font-size: .76rem; }
  .photo-actions summary { font-size: .76rem; }
  .album-result { grid-template-columns: 88px 1fr; }
  .album-result img, .result-placeholder { width: 88px; height: 88px; }
}

@media (max-width: 719px) {
  .site-header { justify-content: space-between; }
  .mobile-menu-toggle { display: inline-flex; flex: 0 0 auto; }
  .main-nav {
    position: absolute;
    top: 100%;
    right: 10px;
    left: 10px;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    max-height: 0;
    margin: 0;
    padding: 0 14px;
    overflow: hidden;
    border: 1px solid transparent;
    border-radius: 0 0 20px 20px;
    background: rgba(255, 253, 249, .98);
    box-shadow: 0 18px 34px rgba(36, 72, 61, .16);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    pointer-events: none;
    transition: max-height .24s ease, opacity .18s ease, transform .18s ease, visibility .18s ease, padding .24s ease;
  }
  .main-nav.is-open {
    max-height: 310px;
    padding-block: 8px 12px;
    border-color: var(--line);
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
  }
  .main-nav a, .main-nav .nav-button, .main-nav .nav-disabled {
    width: 100%;
    min-height: 46px;
    padding: 11px 8px;
    border-bottom: 1px solid var(--line);
    font-size: .96rem;
    text-align: left;
  }
  .main-nav > :last-child { border-bottom: 0; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

.nav-form { display: inline-flex; margin: 0; }
.demo-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 10px max(16px, calc((100vw - 1180px) / 2));
  background: var(--forest-dark);
  color: #fff;
  font-size: .9rem;
}
.demo-banner > div, .demo-banner-actions { display: flex; align-items: center; gap: 12px; }
.demo-banner strong { padding: 4px 9px; border-radius: 999px; background: var(--sunflower); color: var(--forest-dark); font-size: .78rem; letter-spacing: .08em; }
.demo-banner form { margin: 0; }
.demo-banner button { border: 1px solid rgba(255,255,255,.48); border-radius: 999px; padding: 5px 10px; background: transparent; color: #fff; cursor: pointer; }
.demo-banner button:hover { background: rgba(255,255,255,.12); }
[data-demo-countdown] { color: #dfe9e4; font-variant-numeric: tabular-nums; white-space: nowrap; }

.demo-landing { width: min(1180px, calc(100% - 28px)); margin: 0 auto; padding: clamp(34px, 7vw, 74px) 0 70px; }
.demo-intro { max-width: 760px; margin-bottom: 34px; }
.demo-intro h1 { max-width: 700px; margin: 0 0 14px; color: var(--forest-dark); font-size: clamp(2rem, 6vw, 4.2rem); }
.demo-intro > p:not(.eyebrow) { max-width: 710px; margin: 0; color: var(--muted); font-size: clamp(1.02rem, 2vw, 1.2rem); }
.demo-intro ul { display: flex; flex-wrap: wrap; gap: 8px 22px; margin: 22px 0 0; padding: 0; color: var(--forest-dark); font-weight: 700; list-style: none; }
.demo-intro li::before { content: '✓'; margin-right: 7px; color: var(--terracotta); }
.demo-album-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 310px), 1fr)); gap: 24px; }
.demo-album-card { overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); box-shadow: var(--shadow); }
.demo-album-card > img, .demo-card-placeholder { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; background: var(--sage); }
.demo-card-placeholder { display: grid; place-items: center; color: var(--forest); font-family: Georgia, serif; font-size: 3rem; }
.demo-card-copy { display: flex; flex-direction: column; align-items: flex-start; min-height: 315px; padding: 24px; }
.demo-card-meta { margin: 0 0 7px; color: var(--terracotta); font-size: .83rem; font-weight: 800; letter-spacing: .04em; }
.demo-card-copy h2 { margin: 0 0 10px; color: var(--forest-dark); font-size: 1.65rem; }
.demo-card-copy > p:last-of-type { margin: 0 0 22px; color: var(--muted); }
.demo-card-copy form { margin-top: auto; }

@media (max-width: 719px) {
  .demo-banner { display: grid; gap: 8px; padding: 10px 14px; font-size: .82rem; }
  .demo-banner > div:first-child { display: block; }
  .demo-banner > div:first-child strong { display: inline-block; margin-right: 6px; }
  .demo-banner > div:first-child span { display: inline; }
  .demo-banner-actions { width: 100%; justify-content: space-between; gap: 8px; }
  .demo-banner-actions button { padding: 3px 8px; }
  .demo-card-copy { min-height: 0; }
}

