/* SV.JOZEF-R — professional site styles */
:root {
  --color-bg: #faf8f5;
  --color-bg-elevated: #ffffff;
  --color-ink: #1a1814;
  --color-ink-muted: #5c564c;
  --color-accent: #2d4a3e;
  --color-accent-hover: #1f342b;
  --color-wood: #8b6914;
  --color-border: #e8e4dc;
  --font-sans: "Source Sans 3", system-ui, sans-serif;
  --radius: 12px;
  --shadow: 0 4px 24px rgba(26, 24, 20, 0.06);
  --shadow-hover: 0 12px 40px rgba(26, 24, 20, 0.1);
  --max-width: 1120px;
  --header-h: 72px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 12px);
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--color-ink);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
}

button,
input,
select,
textarea {
  font-family: inherit;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--color-accent);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--color-accent-hover);
}

.container {
  width: min(100% - 2rem, var(--max-width));
  margin-inline: auto;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(250, 248, 245, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--color-border);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: var(--header-h);
  gap: 1rem;
}

.logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: center;
  line-height: 0;
}

.logo:hover .logo__img {
  opacity: 0.88;
}

.logo__img {
  height: 36px;
  width: auto;
  display: block;
}

@media (min-width: 480px) {
  .logo__img {
    height: 42px;
  }
}

.nav {
  display: flex;
  align-items: center;
  align-self: center;
  gap: 0.25rem;
}

.nav a {
  padding: 0.5rem 1rem;
  border-radius: 8px;
  color: var(--color-ink-muted);
  font-weight: 600;
  font-size: 0.9375rem;
}

.nav a:hover,
.nav a[aria-current="page"] {
  color: var(--color-accent);
  background: rgba(45, 74, 62, 0.08);
}

.nav-toggle {
  display: none;
  align-self: center;
  position: relative;
  box-sizing: border-box;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  border: 1px solid var(--color-border);
  background: var(--color-bg-elevated);
  border-radius: 10px;
  cursor: pointer;
  color: var(--color-ink);
  align-items: center;
  justify-content: center;
}

.nav-toggle:hover {
  background: rgba(45, 74, 62, 0.06);
  border-color: rgba(45, 74, 62, 0.2);
}

.nav-toggle:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

.nav-toggle__icon,
.nav-toggle__icon::before,
.nav-toggle__icon::after {
  display: block;
  width: 1.25rem;
  height: 2px;
  border-radius: 1px;
  background: currentColor;
}

.nav-toggle__icon {
  position: relative;
  transition: background 0.2s ease;
}

.nav-toggle__icon::before,
.nav-toggle__icon::after {
  content: "";
  position: absolute;
  left: 0;
  transition: transform 0.25s ease, top 0.25s ease;
}

.nav-toggle__icon::before {
  top: -6px;
}

.nav-toggle__icon::after {
  top: 6px;
}

.nav-toggle.is-open .nav-toggle__icon {
  background: transparent;
}

.nav-toggle.is-open .nav-toggle__icon::before {
  top: 0;
  transform: rotate(45deg);
}

.nav-toggle.is-open .nav-toggle__icon::after {
  top: 0;
  transform: rotate(-45deg);
}

@media (prefers-reduced-motion: reduce) {
  .nav-toggle__icon,
  .nav-toggle__icon::before,
  .nav-toggle__icon::after {
    transition: none;
  }
}

@media (max-width: 720px) {
  .nav-toggle {
    display: inline-flex;
  }

  .nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    padding: 1rem;
    background: var(--color-bg-elevated);
    border-bottom: 1px solid var(--color-border);
    box-shadow: var(--shadow);
    display: none;
  }

  .nav.is-open {
    display: flex;
  }

  .site-header {
    position: relative;
  }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  font-family: inherit;
  font-weight: 600;
  font-size: 1rem;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:active {
  transform: scale(0.98);
}

.btn--primary {
  background: var(--color-accent);
  color: #fff;
  box-shadow: 0 2px 12px rgba(45, 74, 62, 0.25);
}

.btn--primary:hover {
  background: var(--color-accent-hover);
  color: #fff;
  box-shadow: 0 4px 20px rgba(45, 74, 62, 0.35);
}

.btn--ghost {
  background: transparent;
  color: var(--color-accent);
  border: 2px solid rgba(45, 74, 62, 0.42);
  border: 2px solid color-mix(in srgb, var(--color-accent) 48%, var(--color-ink-muted));
}

.btn--ghost:hover {
  border-color: var(--color-accent);
  color: var(--color-accent-hover);
}

/* Hero — full-bleed photo + readable text column */
.hero {
  position: relative;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: clamp(28rem, 78vh, 52rem);
  padding: clamp(3.5rem, 10vw, 6.5rem) 0 clamp(4rem, 8vw, 5.5rem);
  border-bottom: 1px solid var(--color-border);
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background: url("../images/bg/1.jpg") center 42% / cover no-repeat;
  background-color: var(--color-border);
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background: linear-gradient(
      105deg,
      rgba(250, 248, 245, 0.97) 0%,
      rgba(250, 248, 245, 0.9) 26%,
      rgba(250, 248, 245, 0.5) 48%,
      rgba(26, 24, 20, 0.12) 100%
    ),
    linear-gradient(
      to bottom,
      rgba(26, 24, 20, 0.18) 0%,
      transparent 22%,
      transparent 70%,
      rgba(26, 24, 20, 0.4) 100%
    );
}

.hero > .container {
  position: relative;
  z-index: 2;
}

.hero__inner {
  max-width: 36rem;
}

@media (max-width: 640px) {
  .hero::after {
    background: linear-gradient(
        180deg,
        rgba(250, 248, 245, 0.96) 0%,
        rgba(250, 248, 245, 0.82) 42%,
        rgba(250, 248, 245, 0.62) 100%
      ),
      linear-gradient(
        to bottom,
        transparent 0%,
        transparent 55%,
        rgba(26, 24, 20, 0.35) 100%
      );
  }

  .hero__inner {
    max-width: none;
  }
}


.hero__eyebrow {
  font-size: 0.8125rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--color-wood);
  margin: 0 0 1rem;
}

.hero h1 {
  font-size: clamp(2rem, 4.5vw, 2.85rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 1.25rem;
  color: var(--color-ink);
}

.hero__lead {
  font-size: 1.1875rem;
  color: var(--color-ink-muted);
  margin: 0 0 1.75rem;
  max-width: 36ch;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.hero__tagline {
  margin: clamp(1.75rem, 4vw, 2.75rem) 0 0;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(26, 24, 20, 0.1);
}

.hero__tagline strong {
  display: block;
  font-size: 1.125rem;
  font-weight: 700;
  margin-bottom: 0.35rem;
  color: var(--color-ink);
}

.hero__tagline span {
  display: block;
  font-size: 0.9375rem;
  color: var(--color-ink-muted);
}

/* Sections */
.section {
  padding: clamp(3.5rem, 7vw, 5rem) 0;
}

.section--alt {
  background: var(--color-bg-elevated);
  border-block: 1px solid var(--color-border);
}

.section__head {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 2.75rem;
}

.section__head h2 {
  font-size: clamp(1.65rem, 3vw, 2.1rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 0.75rem;
}

.section__head p {
  margin: 0;
  color: var(--color-ink-muted);
  font-size: 1.0625rem;
}

/* Features grid */
.features {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 640px) {
  .features--four {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1040px) {
  .features--four {
    grid-template-columns: repeat(4, 1fr);
  }
}

.feature-card {
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 1.75rem;
  box-shadow: var(--shadow);
  transition: box-shadow 0.25s ease, border-color 0.25s ease;
}

.feature-card:hover {
  box-shadow: var(--shadow-hover);
  border-color: rgba(45, 74, 62, 0.2);
}

.feature-card__icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: rgba(45, 74, 62, 0.1);
  color: var(--color-accent);
  display: grid;
  place-items: center;
  font-size: 1.25rem;
  margin-bottom: 1rem;
}

.feature-card h3 {
  font-size: 1.125rem;
  font-weight: 700;
  margin: 0 0 0.5rem;
}

.feature-card__link {
  color: inherit;
  text-decoration: none;
}

.feature-card__link:hover {
  color: var(--color-accent);
}

.feature-card p {
  margin: 0;
  color: var(--color-ink-muted);
  font-size: 0.9375rem;
}

/* Product preview cards */
.product-preview {
  display: grid;
  gap: 1.25rem;
}

@media (min-width: 700px) {
  .product-preview:not(.product-preview--four) {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 640px) {
  .product-preview--four {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1100px) {
  .product-preview--four {
    grid-template-columns: repeat(4, 1fr);
  }
}

.product-preview__card {
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.product-preview__media {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--color-border);
}

.product-preview__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-preview__body {
  padding: 1.5rem 1.5rem 1.75rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.product-preview__card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
}

.product-preview__body h3 {
  font-size: 1.35rem;
  font-weight: 700;
  margin: 0 0 0.5rem;
  color: var(--color-accent);
}

.product-preview__body p {
  margin: 0 0 1rem;
  flex: 1;
  color: var(--color-ink-muted);
  font-size: 0.9375rem;
}

.product-preview__body .link-arrow {
  font-weight: 700;
  font-size: 0.9375rem;
}

/* Galéria realizácií */
.gallery-grid {
  display: grid;
  gap: 1.35rem;
}

@media (min-width: 640px) {
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 960px) {
  .gallery-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.gallery-item {
  margin: 0;
}

.gallery-item__frame {
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 16 / 10;
  background: var(--color-border);
  box-shadow: var(--shadow);
}

.gallery-item__frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery-item__cap {
  margin: 0.75rem 0 0;
  text-align: center;
}

.gallery-item__title {
  display: block;
  font-weight: 700;
  font-size: 1rem;
  color: var(--color-ink);
}

.gallery-item__loc {
  display: block;
  margin-top: 0.2rem;
  font-size: 0.875rem;
  color: var(--color-ink-muted);
}

/* Product detail (products page) */
.product-detail {
  margin-bottom: 2.5rem;
  padding: 2rem;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.product-detail h2 {
  font-size: 1.65rem;
  font-weight: 700;
  margin: 0 0 1rem;
  color: var(--color-accent);
}

.product-detail--with-media .product-detail__body h2 {
  margin-top: 0;
}

.product-detail__body > p {
  margin: 0;
  color: var(--color-ink-muted);
}

.product-detail__media {
  border-radius: 10px;
  overflow: hidden;
  background: var(--color-border);
  box-shadow: var(--shadow);
}

.product-detail__media img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  display: block;
}

@media (min-width: 720px) {
  .product-detail--with-media {
    display: grid;
    grid-template-columns: minmax(200px, 320px) 1fr;
    gap: 2rem;
    align-items: start;
  }

  .product-detail--with-media .product-detail__media img {
    aspect-ratio: 4 / 3;
  }
}

.product-detail ul {
  margin: 0;
  padding-left: 1.25rem;
  color: var(--color-ink-muted);
}

.product-detail li {
  margin-bottom: 0.5rem;
}

.product-detail li:last-child {
  margin-bottom: 0;
}

/* Stránka Služby (obsah z pôvodného project.html) */
.service-detail h2 {
  margin-bottom: 0.35rem;
}

.service-detail__lead {
  margin: 0 0 1rem;
  font-size: 1.0625rem;
  font-weight: 600;
  color: var(--color-accent);
  line-height: 1.45;
}

.service-detail > p:not(.service-detail__lead) {
  margin: 0;
  color: var(--color-ink-muted);
}

.cta-strip {
  margin-top: 0.5rem;
  margin-bottom: 0;
  padding: 2rem 1.5rem;
  text-align: center;
  background: rgba(45, 74, 62, 0.06);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
}

.cta-strip p {
  margin: 0 0 1.25rem;
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--color-ink);
}

.section__cta {
  margin: 2rem 0 0;
  text-align: center;
}

.sluzby-uvod-detail,
.produkty-uvod-detail,
.galeria-uvod-detail {
  margin-top: 0.25rem;
}

.sluzby-uvod-detail__footer,
.produkty-uvod-detail__footer,
.galeria-uvod-detail__footer {
  margin-top: 0.5rem;
  margin-bottom: 0;
}

.note-box {
  margin-top: 2rem;
  padding: 1.5rem;
  background: rgba(45, 74, 62, 0.06);
  border-radius: var(--radius);
  border-left: 4px solid var(--color-accent);
}

.note-box h3 {
  margin: 0 0 0.5rem;
  font-size: 1.125rem;
}

.note-box p {
  margin: 0;
  color: var(--color-ink-muted);
}

/* Contact — section + section--alt: rovnaký „pás“ ako Produktové rady */
.contact-section {
  padding: clamp(3.5rem, 7vw, 5rem) 0;
}

/* Odkazy sa doplnia z JS (bez mailto:/tel: v surovom HTML) */
a.contact-protected:empty {
  min-width: 10ch;
  min-height: 1.35em;
  vertical-align: bottom;
}

.contact-noscript {
  margin: 1rem 0 0;
  font-size: 0.9375rem;
  color: var(--color-ink-muted);
}

.contact-grid {
  display: grid;
  gap: 2rem;
}

@media (min-width: 800px) {
  .contact-grid {
    grid-template-columns: 1fr 1fr;
    align-items: stretch;
  }
}

.contact-card__lead {
  margin: 0 0 1rem;
  color: var(--color-ink-muted);
}

.contact-map-block {
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--color-border);
}

.contact-map-block__title {
  margin: 0 0 0.5rem;
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--color-ink);
}

.contact-map-block__note {
  margin: 0 0 1.25rem;
  max-width: 42rem;
  color: var(--color-ink-muted);
  font-size: 1rem;
  line-height: 1.55;
}

.contact-map-frame {
  position: relative;
  width: 100%;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-hover);
  border: 1px solid var(--color-border);
  background: var(--color-border);
  aspect-ratio: 16 / 9;
  max-height: 420px;
}

.contact-map-frame__embed {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.contact-map-block__actions {
  margin: 1rem 0 0;
  text-align: center;
}

.contact-card {
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  min-height: 100%;
}

/* Na section--alt pás: karty ako produktové náhľady (teplšia plocha na bielom pruhu) */
.contact-section.section--alt .contact-card {
  background: var(--color-bg);
}

.contact-card .btn {
  margin-top: auto;
  align-self: flex-start;
}

.contact-card__title {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 0 1.25rem;
  line-height: 1.2;
}

.contact-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.contact-list li {
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--color-border);
}

.contact-list li:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.contact-list dt {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-ink-muted);
  margin-bottom: 0.25rem;
}

.contact-list dd {
  margin: 0;
  font-size: 1.0625rem;
}

.contact-list a {
  font-weight: 600;
}

/* Footer */
.site-footer {
  background: var(--color-ink);
  color: rgba(255, 255, 255, 0.75);
  padding: 2.5rem 0;
  margin-top: auto;
}

.site-footer a {
  color: #fff;
}

.site-footer a:hover {
  color: rgba(255, 255, 255, 0.85);
}

.site-footer__inner {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: center;
  text-align: center;
}

@media (min-width: 640px) {
  .site-footer__inner {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
    align-items: center;
  }
}

.site-footer__side {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  align-items: center;
}

@media (min-width: 640px) {
  .site-footer__side {
    align-items: flex-end;
    text-align: right;
  }
}

.site-footer__legal {
  font-size: 0.875rem;
  margin: 0;
}

.site-footer__legal a {
  font-weight: 600;
}

.site-footer__brand {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: #fff;
  text-decoration: none;
}

.site-footer__brand:hover {
  color: #fff;
  opacity: 0.9;
}

.site-footer__brand img {
  width: 20px;
  height: 20px;
  object-fit: contain;
  flex-shrink: 0;
}

.site-footer__copy {
  font-size: 0.875rem;
  margin: 0;
}

/* Extra scroll space when cookie bar is visible */
body:has(#cookie-consent:not([hidden])) {
  padding-bottom: clamp(5.5rem, 22vw, 9rem);
}

/* Cookie consent bar — viewport-fixed (direct child of body, above page content) */
.cookie-consent {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  top: auto;
  width: 100%;
  z-index: 200;
  margin: 0;
  padding: 1rem 0 calc(1.25rem + env(safe-area-inset-bottom, 0px));
  background: var(--color-bg-elevated);
  border-top: 1px solid var(--color-border);
  box-shadow: 0 -8px 32px rgba(26, 24, 20, 0.1);
  /* Own compositing layer — avoids fixed bar scrolling with content on some mobile WebViews */
  transform: translateZ(0);
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}

.cookie-consent[hidden] {
  display: none !important;
}

.cookie-consent__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem 1.5rem;
}

.cookie-consent__title {
  font-size: 1.0625rem;
  font-weight: 700;
  margin: 0 0 0.35rem;
  color: var(--color-ink);
}

.cookie-consent__text p {
  margin: 0;
  font-size: 0.9375rem;
  line-height: 1.55;
  color: var(--color-ink-muted);
  max-width: 46rem;
}

.cookie-consent__text a {
  color: var(--color-accent);
  font-weight: 600;
}

.cookie-consent__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  flex-shrink: 0;
}

.cookie-consent__btn {
  padding: 0.6rem 1.1rem;
  font-size: 0.875rem;
}

.contact-map-frame__fallback {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 1.25rem 1.5rem;
  text-align: center;
  background: var(--color-bg);
}

.contact-map-frame__fallback[hidden] {
  display: none !important;
}

.contact-map-frame__fallback p {
  margin: 0;
  font-size: 0.9375rem;
  line-height: 1.55;
  color: var(--color-ink-muted);
  max-width: 26rem;
}

.contact-map-frame__embed[hidden] {
  display: none !important;
}

.legal-prose {
  max-width: 42rem;
  font-size: 1rem;
  line-height: 1.65;
  color: var(--color-ink-muted);
}

.legal-prose h3 {
  margin: 1.75rem 0 0.5rem;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--color-ink);
}

.legal-prose h3:first-child {
  margin-top: 0;
}

.legal-prose p {
  margin: 0 0 0.75rem;
}

.legal-prose ul {
  margin: 0 0 0.75rem;
  padding-left: 1.25rem;
}

.legal-prose li {
  margin-bottom: 0.5rem;
}

.legal-prose a {
  color: var(--color-accent);
  font-weight: 600;
}

/* Privacy / GDPR modal */
.privacy-modal[hidden] {
  display: none !important;
}

.privacy-modal {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 0;
}

@media (min-width: 640px) {
  .privacy-modal {
    align-items: center;
    padding: 1.5rem;
  }
}

.privacy-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(26, 24, 20, 0.45);
  backdrop-filter: blur(4px);
}

.privacy-modal__panel {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 36rem;
  max-height: min(90vh, 720px);
  margin: 0;
  background: var(--color-bg-elevated);
  border: 1px solid var(--color-border);
  border-radius: var(--radius) var(--radius) 0 0;
  box-shadow: var(--shadow-hover);
  display: flex;
  flex-direction: column;
}

@media (min-width: 640px) {
  .privacy-modal__panel {
    border-radius: var(--radius);
    max-height: min(85vh, 680px);
  }
}

.privacy-modal__close {
  position: absolute;
  top: 0.65rem;
  right: 0.65rem;
  z-index: 2;
  width: 2.25rem;
  height: 2.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  background: var(--color-bg);
  color: var(--color-ink);
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
  font-family: inherit;
}

.privacy-modal__close:hover {
  background: rgba(45, 74, 62, 0.08);
  border-color: rgba(45, 74, 62, 0.2);
}

.privacy-modal__close:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

.privacy-modal__scroll {
  overflow-y: auto;
  padding: 1.75rem 1.5rem 1.5rem;
  -webkit-overflow-scrolling: touch;
}

@media (min-width: 640px) {
  .privacy-modal__scroll {
    padding: 2rem 2.25rem 1.75rem;
  }
}

.privacy-modal__title {
  margin: 0 2.25rem 0.75rem 0;
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1.25;
  color: var(--color-ink);
}

.privacy-modal__lead {
  margin: 0 0 1rem;
  font-size: 0.9375rem;
  line-height: 1.55;
  color: var(--color-ink-muted);
}

.privacy-modal .legal-prose {
  max-width: none;
}

/* Page layout */
.page-wrap {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1;
}

.page-title {
  padding: 2.5rem 0 1rem;
  border-bottom: 1px solid var(--color-border);
  background: var(--color-bg-elevated);
}

.page-title h1 {
  font-size: clamp(1.75rem, 3.5vw, 2.25rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 0.5rem;
}

.page-title p {
  margin: 0;
  color: var(--color-ink-muted);
  max-width: 50ch;
}

.page-back {
  margin: 0;
  margin-top: 0.5rem;
  text-align: center;
}
