:root {
  --ink: #0b4a8f;
  --berry: #c93a2d;
  --leaf: #3f7a45;
  --paper: #f6eedc;
  --paper-deep: #ead8b5;
  --porcelain: #fffaf0;
  --mist: #edf5ef;
  --charcoal: #1e1e1a;
  --sun: #f4b63f;
  --line: rgba(30, 30, 26, 0.18);
  --shadow: 0 24px 70px rgba(18, 32, 43, 0.18);
}

@font-face {
  font-family: "Quicksand";
  src: url("/assets/fonts/Quicksand_400Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Quicksand";
  src: url("/assets/fonts/Quicksand_500Medium.ttf") format("truetype");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Quicksand";
  src: url("/assets/fonts/Quicksand_600SemiBold.ttf") format("truetype");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Quicksand";
  src: url("/assets/fonts/Quicksand_700Bold.ttf") format("truetype");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Quicksand", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--charcoal);
  background-color: var(--paper);
  background-image:
    linear-gradient(rgba(246, 238, 220, 0.84), rgba(246, 238, 220, 0.84)),
    url("/assets/brand/davio-pattern-discovery-confetti-tile.png");
  background-size: auto, 430px 430px;
  background-attachment: fixed;
}

a {
  color: inherit;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 16px clamp(18px, 4vw, 56px);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 250, 240, 0.9);
  backdrop-filter: blur(12px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  font-size: 1.15rem;
  text-decoration: none;
}

.brand-logo {
  display: block;
  width: min(158px, 44vw);
  height: auto;
}

.brand-suffix {
  padding: 4px 8px;
  border: 1px solid rgba(11, 74, 143, 0.2);
  border-radius: 8px;
  color: var(--ink);
  background: rgba(255, 248, 232, 0.72);
  font-size: 0.88rem;
  line-height: 1;
}

.brand-mark {
  width: 34px;
  height: 34px;
  border-radius: 9px;
  object-fit: cover;
  box-shadow: 0 0 0 2px rgba(11, 74, 143, 0.22);
}

nav {
  display: flex;
  gap: clamp(12px, 3vw, 28px);
  font-size: 0.96rem;
  font-weight: 700;
}

nav a {
  text-decoration: none;
}

.hero {
  min-height: min(680px, calc(100svh - 120px));
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(300px, 0.78fr);
  align-items: center;
  gap: clamp(22px, 5vw, 70px);
  padding: clamp(28px, 5vw, 64px) clamp(18px, 5vw, 72px) clamp(36px, 6vw, 80px);
  overflow: hidden;
}

.hero-copy {
  max-width: 760px;
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--berry);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.78rem;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1 {
  margin: 0;
  font-size: clamp(3.7rem, 10vw, 8.6rem);
  line-height: 0.88;
  letter-spacing: 0;
  color: var(--ink);
}

h2 {
  margin: 0;
  font-size: clamp(2rem, 4vw, 4.2rem);
  line-height: 1;
  letter-spacing: 0;
  color: var(--ink);
}

h3 {
  margin: 12px 0 8px;
  font-size: 1.18rem;
  letter-spacing: 0;
}

.lead {
  max-width: 640px;
  margin: 22px 0 0;
  font-size: clamp(1.08rem, 2vw, 1.35rem);
  line-height: 1.55;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.hero-note {
  max-width: 560px;
  margin: 18px 0 0;
  color: rgba(30, 30, 26, 0.72);
  font-weight: 800;
}

.button {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 13px 20px;
  border-radius: 8px;
  border: 2px solid var(--ink);
  font-weight: 900;
  text-decoration: none;
  cursor: pointer;
}

.button.primary {
  color: white;
  background: var(--ink);
}

.button.secondary {
  color: var(--ink);
  background: #fff8e8;
}

.poster-stack {
  position: relative;
  min-height: min(64vh, 560px);
}

.poster {
  position: absolute;
  width: min(54vw, 360px);
  height: auto;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  background: linear-gradient(180deg, #fff8e8, #ead8b5);
  border: 8px solid #fff8e8;
  box-shadow: var(--shadow);
}

.poster-main {
  right: 4%;
  top: 5%;
  transform: rotate(2deg);
  z-index: 3;
}

.poster-back {
  opacity: 0.82;
}

.poster-one {
  right: 32%;
  top: 20%;
  transform: rotate(-8deg) scale(0.84);
  z-index: 2;
}

.poster-two {
  right: -4%;
  top: 24%;
  transform: rotate(8deg) scale(0.82);
  z-index: 1;
}

.band,
.split,
.poster-showcase,
.gallery-preview,
.install {
  padding: clamp(56px, 8vw, 110px) clamp(18px, 5vw, 72px);
}

.band {
  background: var(--porcelain);
  border-block: 1px solid var(--line);
}

.section-heading {
  max-width: 840px;
  margin-bottom: 36px;
}

.steps,
.category-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.steps article,
.category-card,
.signup {
  border: 2px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  padding: 22px;
}

.steps article {
  background: var(--paper);
}

.steps span {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--sun);
  color: var(--charcoal);
  font-weight: 950;
}

.steps p,
.category-card p,
.feature-list p,
.gallery-copy p,
.install p {
  margin: 0;
  line-height: 1.6;
  font-size: 1rem;
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1fr);
  gap: clamp(28px, 6vw, 70px);
  align-items: start;
}

.feature-list {
  display: grid;
  gap: 18px;
  font-size: 1.08rem;
}

.categories {
  background: #f0e2c3;
}

.category-grid {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.category-card {
  display: grid;
  gap: 10px;
  min-height: 160px;
}

.category-card.planned {
  opacity: 0.72;
  background: rgba(246, 238, 220, 0.72);
}

.category-card strong {
  color: var(--ink);
  font-size: 1.03rem;
}

.category-card small {
  color: var(--leaf);
  font-weight: 900;
}

.category-card span {
  color: var(--berry);
  font-weight: 900;
}

.poster-showcase {
  background: var(--mist);
  border-block: 1px solid var(--line);
}

.showcase-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 14px;
}

.showcase-grid figure {
  margin: 0;
  min-width: 0;
  cursor: zoom-in;
}

.showcase-grid img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  background: linear-gradient(180deg, #fff8e8, #ead8b5);
  border: 6px solid var(--porcelain);
  box-shadow: 0 18px 42px rgba(30, 30, 26, 0.13);
}

.poster-trigger {
  cursor: zoom-in;
}

.poster-trigger img,
img.poster-trigger:not(.poster) {
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.poster-trigger:hover img,
.poster-trigger:focus-visible img,
img.poster-trigger:not(.poster):hover,
img.poster-trigger:not(.poster):focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 22px 52px rgba(30, 30, 26, 0.18);
}

.poster.poster-trigger {
  transition: box-shadow 160ms ease, filter 160ms ease;
}

.poster.poster-trigger:hover,
.poster.poster-trigger:focus-visible {
  filter: brightness(1.03);
  box-shadow: 0 26px 64px rgba(30, 30, 26, 0.2);
}

.poster-trigger:focus-visible {
  outline: 3px solid var(--sun);
  outline-offset: 5px;
}

.showcase-grid figcaption {
  margin-top: 10px;
  color: var(--ink);
  font-weight: 900;
  line-height: 1.25;
}

.gallery-preview {
  display: grid;
  grid-template-columns: minmax(0, 0.72fr) minmax(0, 1fr);
  gap: clamp(28px, 6vw, 72px);
  align-items: center;
}

.gallery-copy {
  display: grid;
  gap: 18px;
}

.mini-gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.mini-gallery img {
  width: 100%;
  height: auto;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  background: linear-gradient(180deg, #fff8e8, #ead8b5);
  border: 6px solid #fff8e8;
  box-shadow: 0 18px 40px rgba(30, 30, 26, 0.12);
}

.install {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(320px, 0.68fr);
  gap: clamp(28px, 6vw, 72px);
  align-items: start;
  background: var(--ink);
  color: white;
}

.install h2,
.install .eyebrow {
  color: white;
}

.install-copy {
  display: grid;
  gap: 18px;
}

.install-card {
  display: grid;
  gap: 18px;
  background: var(--porcelain);
  color: var(--charcoal);
  border: 2px solid transparent;
  border-radius: 8px;
  padding: clamp(18px, 4vw, 28px);
  box-shadow: 0 20px 56px rgba(8, 29, 55, 0.22);
}

.install-qr {
  width: min(100%, 320px);
  height: auto;
  justify-self: center;
  border: 8px solid white;
  border-radius: 8px;
  box-shadow: 0 12px 28px rgba(30, 30, 26, 0.12);
}

.store-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.store-button {
  min-height: 72px;
  display: grid;
  align-content: center;
  gap: 4px;
  padding: 12px 14px;
  border: 2px solid var(--ink);
  border-radius: 8px;
  color: var(--ink);
  background: #fff8e8;
  text-decoration: none;
}

.store-button span {
  font-size: 0.86rem;
  font-weight: 900;
}

.store-button strong {
  font-size: 0.96rem;
  line-height: 1.18;
}

.store-button.unavailable {
  border-color: rgba(11, 74, 143, 0.24);
  color: rgba(11, 74, 143, 0.68);
}

label {
  display: grid;
  gap: 7px;
  font-weight: 900;
}

input,
select {
  width: 100%;
  min-height: 46px;
  border: 2px solid rgba(11, 74, 143, 0.25);
  border-radius: 8px;
  padding: 10px 12px;
  font: inherit;
  background: white;
}

code {
  padding: 0.1em 0.35em;
  border-radius: 5px;
  background: rgba(11, 74, 143, 0.09);
  color: var(--ink);
  font-size: 0.95em;
}

.button:hover,
.button:focus-visible {
  transform: translateY(-1px);
  box-shadow: 0 10px 20px rgba(11, 74, 143, 0.15);
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.58;
}

.form-message {
  min-height: 24px;
  color: var(--leaf);
  font-weight: 800;
}

body.lightbox-open {
  overflow: hidden;
}

.poster-lightbox[hidden] {
  display: none;
}

.poster-lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-items: center;
  padding: clamp(18px, 4vw, 44px);
  background: rgba(8, 29, 55, 0.78);
  backdrop-filter: blur(10px);
}

.poster-lightbox figure {
  margin: 0;
  display: grid;
  gap: 12px;
  justify-items: center;
  width: min(100%, 760px);
}

.poster-lightbox img {
  max-width: min(100%, 72vh);
  max-height: 82vh;
  width: auto;
  height: auto;
  aspect-ratio: 2 / 3;
  object-fit: contain;
  border: 10px solid var(--porcelain);
  background: var(--porcelain);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.32);
}

.poster-lightbox figcaption {
  color: white;
  font-weight: 900;
  text-align: center;
}

.lightbox-close {
  position: absolute;
  top: clamp(14px, 3vw, 28px);
  right: clamp(14px, 3vw, 28px);
  width: 44px;
  height: 44px;
  border: 2px solid white;
  border-radius: 50%;
  color: white;
  background: rgba(8, 29, 55, 0.36);
  font: inherit;
  font-size: 1.65rem;
  line-height: 1;
  cursor: pointer;
}

footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 22px clamp(18px, 5vw, 72px);
  background: #fff8e8;
  font-weight: 900;
}

.footer-logo {
  display: block;
  width: 128px;
  height: auto;
}

.legal-page {
  max-width: 920px;
  padding: clamp(46px, 7vw, 92px) clamp(18px, 5vw, 72px);
}

.legal-page h1 {
  font-size: clamp(2.7rem, 7vw, 6rem);
}

.legal-page section {
  margin-top: 34px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.legal-page section h2 {
  font-size: clamp(1.5rem, 3vw, 2.4rem);
  margin-bottom: 12px;
}

.legal-page section p {
  font-size: 1.08rem;
  line-height: 1.7;
}

.admin-body {
  background-color: #fff8e8;
}

.admin-page {
  padding: clamp(32px, 6vw, 72px) clamp(18px, 5vw, 72px);
}

.admin-hero {
  max-width: 960px;
  margin-bottom: 30px;
}

.admin-hero h1 {
  font-size: clamp(2.6rem, 6vw, 5.8rem);
}

.admin-panel,
.admin-stats,
.admin-results {
  border: 2px solid var(--line);
  border-radius: 8px;
  background: var(--paper);
  box-shadow: 0 14px 38px rgba(30, 30, 26, 0.08);
}

.admin-panel {
  display: grid;
  grid-template-columns: minmax(220px, 1.1fr) minmax(180px, 0.7fr) auto;
  gap: 16px;
  align-items: end;
  padding: 18px;
}

.admin-actions {
  display: flex;
  gap: 10px;
}

.admin-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  margin-top: 18px;
  overflow: hidden;
  background: var(--line);
}

.admin-stats article {
  display: grid;
  gap: 8px;
  min-height: 118px;
  padding: 18px;
  background: var(--paper);
}

.admin-stats span {
  color: var(--leaf);
  font-weight: 900;
}

.admin-stats strong {
  color: var(--ink);
  font-size: clamp(1.35rem, 3vw, 2.3rem);
  line-height: 1.05;
}

.admin-results {
  margin-top: 18px;
  padding: 20px;
}

.admin-results-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: start;
  margin-bottom: 16px;
}

.admin-results h2 {
  font-size: clamp(1.6rem, 3vw, 2.6rem);
}

.insight-list {
  margin-bottom: 18px;
}

.insight-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.insight-tags span {
  padding: 8px 10px;
  border: 1px solid rgba(11, 74, 143, 0.18);
  border-radius: 8px;
  background: #fff8e8;
}

.summary-blocks {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 18px;
}

.summary-block {
  border: 1px solid rgba(11, 74, 143, 0.18);
  border-radius: 8px;
  padding: 14px;
  background: #fff8e8;
}

.summary-block h3 {
  margin-bottom: 10px;
  color: var(--ink);
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 760px;
  background: #fff8e8;
}

th,
td {
  padding: 12px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
}

th {
  color: var(--ink);
  font-size: 0.82rem;
  text-transform: uppercase;
}

td {
  line-height: 1.45;
}

@media (max-width: 900px) {
  .topbar {
    align-items: flex-start;
    flex-direction: column;
  }

  nav {
    width: 100%;
    overflow-x: auto;
    padding-bottom: 4px;
  }

  .hero,
  .split,
  .gallery-preview,
  .install {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
  }

  .poster-stack {
    min-height: 430px;
  }

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

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

  .admin-panel,
  .admin-stats,
  .summary-blocks {
    grid-template-columns: 1fr;
  }

  .admin-actions,
  .admin-results-head {
    flex-direction: column;
  }

  .admin-actions .button {
    width: 100%;
  }

  .store-actions {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .topbar {
    gap: 12px;
    padding-block: 12px;
  }

  nav {
    flex-wrap: wrap;
    gap: 8px 16px;
    overflow-x: visible;
    padding-bottom: 0;
    font-size: 0.88rem;
    line-height: 1.1;
  }

  .hero {
    padding-top: 24px;
    padding-bottom: 24px;
    gap: 18px;
  }

  .hero-actions {
    margin-top: 20px;
  }

  .hero-actions .button.secondary {
    display: none;
  }

  .hero-note {
    margin-top: 12px;
    font-size: 0.95rem;
  }

  footer {
    flex-direction: column;
  }

  .button {
    width: 100%;
  }

  .poster-stack {
    min-height: 290px;
  }

  .poster {
    width: min(48vw, 190px);
    border-width: 6px;
  }

  .poster-one,
  .poster-two {
    display: none;
  }

  .poster-main {
    left: 50%;
    right: auto;
    top: 0;
    transform: translateX(-50%) rotate(2deg);
  }

  .steps,
  .category-grid,
  .showcase-grid,
  .mini-gallery {
    grid-template-columns: 1fr;
  }

  .poster-lightbox img {
    max-width: 96vw;
    max-height: 78vh;
    border-width: 6px;
  }
}
