/* Stendera 3 — stendera3.lv */
@font-face { font-family: "Playfair Display"; src: url(fonts/playfair-display-latin-400-normal.woff2) format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Playfair Display"; src: url(fonts/playfair-display-latin-400-italic.woff2) format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Playfair Display"; src: url(fonts/playfair-display-latin-700-normal.woff2) format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Princess Sofia"; src: url(fonts/princess-sofia-latin-400-normal.woff2) format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }

:root {
  --side: #1c1c1c;
  --side-text: #c9c9c9;
  --bg: #cec7b5;
  --ink: #3b322b;
  --ink-soft: #5a4e44;
  --line: rgba(59, 50, 43, .18);
  --serif: "Playfair Display", Georgia, "Times New Roman", serif;
  --script: "Princess Sofia", "Playfair Display", Georgia, serif;
  --side-w: 250px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--serif); font-size: 17px; line-height: 1.6; -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-underline-offset: 3px; }
a:focus-visible, button:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
main a:focus-visible, main button:focus-visible, footer a:focus-visible, footer button:focus-visible { outline-color: var(--ink); }
.skip { position: absolute; left: -9999px; top: 8px; z-index: 100; background: #fff; color: #000; padding: 8px 14px; }
.skip:focus { left: 8px; }

/* Sidebar */
.side { position: fixed; inset: 0 auto 0 0; width: var(--side-w); background: var(--side); color: var(--side-text); padding: 44px 40px; z-index: 20; }
.brand { display: flex; flex-direction: column; gap: 34px; text-decoration: none; color: #fff; }
.brand img { width: 40px; height: 35px; object-fit: cover; }
.brand span { font-size: 26px; line-height: 1.2; }
.side nav { margin-top: 50px; display: flex; flex-direction: column; gap: 14px; }
.side nav a { color: var(--side-text); text-decoration: none; font-size: 15px; transition: color .2s; }
.side nav a:hover { color: #fff; }
.side nav a[aria-current="page"] { color: #fff; font-weight: 700; }
.menu-btn { display: none; }

/* Content */
.page { margin-left: var(--side-w); min-height: 100vh; display: flex; flex-direction: column; }
main { flex: 1; width: 100%; max-width: 1130px; padding: 24px 30px 40px; margin: 0 auto; }
.text { padding: 0 8px; }
.text p { margin: 0 0 14px; }
.text p:last-child { margin-bottom: 0; }
.text b { font-weight: 700; }
.text-sm { font-size: 15px; line-height: 1.65; }

/* Hero */
.hero { position: relative; overflow: hidden; aspect-ratio: 2 / 1; background: #6b6253; margin-bottom: 26px; }
.hero picture, .hero img { width: 100%; height: 100%; }
.hero img { object-fit: cover; object-position: 50% 42%; }
.hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,0) 38%, rgba(0,0,0,.18) 62%, rgba(0,0,0,.55) 100%); pointer-events: none; }
.hero-text { position: absolute; z-index: 1; left: 4%; right: 4%; bottom: 5%; display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; color: #fff; font-family: var(--script); text-shadow: 0 2px 14px rgba(0,0,0,.45); }
.hero-text h1 { margin: 0; font-weight: 400; font-size: clamp(30px, 5vw, 62px); line-height: 1.12; }
.hero-text h1 span { display: block; }
.hero-text h1 span + span { padding-left: .9em; }
.price { margin: 0; font-size: clamp(26px, 4.2vw, 52px); line-height: 1.1; white-space: nowrap; }

/* Gallery */
.group { margin-bottom: 44px; }
.grid { display: grid; grid-template-columns: 1fr 2.12fr; gap: 14px; margin-bottom: 30px; }
.grid .stack { display: grid; grid-template-rows: 1fr 1fr; gap: 14px; }
.shot { display: block; position: relative; overflow: hidden; padding: 0; border: 0; background: #b9b1a0; cursor: zoom-in; width: 100%; height: 100%; }
.shot img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s cubic-bezier(.2,.7,.2,1); }
.shot:hover img { transform: scale(1.03); }
.grid .big .shot { aspect-ratio: 4 / 3; }

/* Lightbox */
.lb { position: fixed; inset: 0; z-index: 90; background: rgba(15,13,11,.94); display: none; align-items: center; justify-content: center; }
.lb.open { display: flex; }
.lb img { max-width: 92vw; max-height: 86vh; width: auto; height: auto; box-shadow: 0 20px 60px rgba(0,0,0,.5); user-select: none; -webkit-user-drag: none; }
.lb button { position: absolute; width: 48px; height: 48px; border-radius: 50%; border: 1px solid rgba(255,255,255,.35); background: rgba(0,0,0,.35); color: #fff; cursor: pointer; display: grid; place-items: center; transition: background-color .2s, border-color .2s; }
.lb button:hover { background: rgba(255,255,255,.12); border-color: #fff; }
.lb button svg { width: 20px; height: 20px; }
.lb .lb-close { top: 18px; right: 18px; }
.lb .lb-prev { left: 18px; top: 50%; margin-top: -24px; }
.lb .lb-next { right: 18px; top: 50%; margin-top: -24px; }
.lb .lb-count { position: absolute; bottom: 18px; left: 0; right: 0; text-align: center; color: rgba(255,255,255,.7); font-size: 14px; }
body.lb-open { overflow: hidden; }

/* Map */
.map { position: relative; aspect-ratio: 3 / 2; max-height: 72vh; width: 100%; background: #e9e4d8; display: grid; place-items: center; text-align: center; overflow: hidden; }
.map iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.map-card { padding: 30px; max-width: 460px; }
.map-card h1 { margin: 0 0 6px; font-weight: 400; font-size: 30px; }
.map-card p { margin: 0 0 22px; color: var(--ink-soft); }
.map-actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.btn { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 20px; border-radius: 999px; font: 15px var(--serif); text-decoration: none; cursor: pointer; border: 1px solid var(--ink); transition: background-color .2s, color .2s; }
.btn.solid { background: var(--side); color: #fff; border-color: var(--side); }
.btn.solid:hover { background: #000; }
.btn.line { background: transparent; color: var(--ink); }
.btn.line:hover { background: var(--ink); color: #fff; }
.btn svg { width: 16px; height: 16px; }
.map-note { margin: 14px 0 0; font-size: 13px; color: var(--ink-soft); }

/* Footer */
footer { padding: 18px 30px 26px; text-align: center; font-size: 12px; color: var(--ink-soft); }
footer a { color: var(--ink); }
footer .dot { margin: 0 .45em; }

/* Consent bar */
.cookie { position: fixed; z-index: 60; left: calc(var(--side-w) + 20px); right: 20px; bottom: 20px; max-width: 720px; margin: auto; background: rgba(28,28,28,.95); color: #f1efee; border-radius: 14px; padding: 16px 20px; display: flex; align-items: center; gap: 22px; box-shadow: 0 18px 50px rgba(0,0,0,.3); font-size: 14px; line-height: 1.5; }
.cookie[hidden] { display: none; }
.cookie strong { font-weight: 700; }
.cookie p { margin: 2px 0 0; color: #c9c9c9; }
.cookie p a { color: #fff; }
.cookie-actions { margin-left: auto; display: flex; gap: 10px; white-space: nowrap; }
.cookie button { appearance: none; cursor: pointer; font: 700 14px/1 var(--serif); padding: 12px 16px; min-height: 44px; border-radius: 999px; border: 1.5px solid #f1efee; background: #f1efee; color: #1c1c1c; }
.cookie button.ghost { background: transparent; color: #f1efee; }
.cookie button.ghost:hover { background: rgba(255,255,255,.1); }

/* Privacy dialog */
body.modal-open { overflow: hidden; }
.modal { position: fixed; inset: 0; z-index: 80; display: none; padding: 24px; }
.modal.open { display: grid; place-items: center; }
.modal-bg { position: absolute; inset: 0; background: rgba(15,13,11,.6); }
.modal-box { position: relative; width: 100%; max-width: 760px; height: min(86vh, 860px); background: #f4f1ea; border-radius: 16px; overflow: hidden; box-shadow: 0 30px 80px rgba(0,0,0,.35); }
.modal-scroll { height: 100%; overflow-y: auto; -webkit-overflow-scrolling: touch; }
.modal-close { position: absolute; z-index: 2; right: 14px; top: 12px; width: 44px; height: 44px; border: 0; border-radius: 50%; background: var(--side); color: #fff; cursor: pointer; display: grid; place-items: center; }
.modal-close svg { width: 18px; height: 18px; }
.legal { max-width: 620px; margin: 0 auto; padding: 54px 28px 44px; font-size: 16px; line-height: 1.65; }
.legal .kicker { margin: 0; font-size: 12px; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-soft); }
.legal h2 { margin: 10px 0 4px; font-weight: 400; font-size: 36px; line-height: 1.15; }
.legal .updated { margin: 0 0 8px; font-size: 14px; color: var(--ink-soft); }
.legal h3 { margin: 28px 0 6px; font-size: 18px; }
.legal p { margin: 0 0 10px; }
.legal a { color: var(--ink); }
.setting { margin: 16px 0 6px; padding: 14px 18px; border: 1px solid var(--line); border-radius: 12px; background: #fff; display: flex; align-items: center; justify-content: space-between; gap: 18px; }
.setting strong { display: block; }
.setting small { color: var(--ink-soft); font-size: 13px; }
.switch { position: relative; width: 52px; height: 30px; flex: none; }
.switch input { position: absolute; inset: 0; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; z-index: 1; }
.switch span { position: absolute; inset: 0; background: #bdb5a4; border-radius: 999px; transition: background-color .2s; }
.switch span::after { content: ""; position: absolute; left: 3px; top: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.2); transition: transform .2s; }
.switch input:checked + span { background: var(--side); }
.switch input:checked + span::after { transform: translateX(22px); }
.switch input:focus-visible + span { outline: 2px solid var(--ink); outline-offset: 3px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Mobile */
@media (max-width: 900px) {
  :root { --side-w: 0px; }
  .side { position: sticky; top: 0; inset: auto; width: auto; height: 60px; padding: 0 16px 0 18px; display: flex; align-items: center; justify-content: space-between; }
  .brand { flex-direction: row; align-items: center; gap: 12px; }
  .brand img { width: 32px; height: 28px; }
  .brand span { font-size: 21px; }
  .menu-btn { display: inline-flex; width: 44px; height: 44px; padding: 0; border-radius: 50%; border: 1px solid rgba(255,255,255,.3); background: transparent; color: #fff; align-items: center; justify-content: center; cursor: pointer; }
  .menu-btn span, .menu-btn span::before, .menu-btn span::after { display: block; width: 18px; height: 1.5px; border-radius: 2px; background: currentColor; }
  .menu-btn span { position: relative; transition: background-color .2s; }
  .menu-btn span::before, .menu-btn span::after { content: ""; position: absolute; left: 0; transition: transform .3s cubic-bezier(.2,.7,.2,1); }
  .menu-btn span::before { top: -6px; }
  .menu-btn span::after { top: 6px; }
  .menu-btn[aria-expanded="true"] span { background: transparent; }
  .menu-btn[aria-expanded="true"] span::before { transform: translateY(6px) rotate(45deg); }
  .menu-btn[aria-expanded="true"] span::after { transform: translateY(-6px) rotate(-45deg); }
  .side nav { position: absolute; left: 0; right: 0; top: 100%; margin: 0; gap: 0; padding: 0 18px; background: var(--side); max-height: 0; overflow: hidden; visibility: hidden; transition: max-height .35s cubic-bezier(.2,.7,.2,1), visibility 0s linear .35s; box-shadow: 0 20px 30px -20px rgba(0,0,0,.5); }
  .side.menu-open nav { max-height: 260px; visibility: visible; transition: max-height .35s cubic-bezier(.2,.7,.2,1); }
  .side nav a { padding: 15px 0; border-top: 1px solid rgba(255,255,255,.1); font-size: 20px; }
  .side nav a:last-child { padding-bottom: 20px; }
  .page { margin-left: 0; }
  main { padding: 16px 16px 30px; }
  .text { padding: 0; }
  .hero { aspect-ratio: 4 / 3; margin-bottom: 20px; }
  .hero-text { flex-direction: column; align-items: flex-start; gap: 6px; bottom: 6%; }
  .hero-text h1 span + span { padding-left: .6em; }
  .grid { grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 22px; }
  .grid .stack { grid-column: 1 / -1; grid-template-rows: none; grid-template-columns: 1fr 1fr; gap: 10px; order: 2; }
  .grid .stack .shot { aspect-ratio: 4 / 3; }
  .grid .big { grid-column: 1 / -1; order: 1; }
  .group { margin-bottom: 34px; }
  .map { aspect-ratio: auto; min-height: 420px; }
  .cookie { left: 12px; right: 12px; bottom: 12px; display: block; }
  .cookie-actions { margin-top: 12px; }
  .lb .lb-prev, .lb .lb-next { top: auto; bottom: 14px; margin: 0; }
  .lb .lb-count { bottom: 28px; }
  .modal { padding: 10px; }
  .modal-box { height: calc(100vh - 20px); height: calc(100dvh - 20px); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .shot img, .shot:hover img { transition: none; transform: none; }
}
@media print {
  .side nav, .menu-btn, .cookie, .modal, .lb { display: none !important; }
  .side { position: static; height: auto; }
  .page { margin-left: 0; }
}
