/* Pražský Čajový Ateliér — design system */
:root {
  --forest: #426755;
  --gold: #D1A85E;
  --cream: #F7F1E7;
  --sage: #7F9A83;
  --graphite: #302D2A;
  --white: #FFFFFF;
  --beige: #E7DFD1;
  --font-display: "Playfair Display", Georgia, "Times New Roman", serif;
  --font-body: Inter, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  --radius: 14px;
  --shadow-paper: 0 10px 30px -10px rgba(48,45,42,.25), 0 2px 6px rgba(48,45,42,.08);
  --measure: 68ch;
}
@font-face { font-family: "Playfair Display"; src: local("Playfair Display"); }

* { box-sizing: border-box; }
html, body { overflow-x: clip; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--graphite);
  background: var(--cream);
  line-height: 1.55;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { font-family: var(--font-display); margin: 0 0 .5em; line-height: 1.15; }
p { margin: 0 0 1em; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }
.icon { width: 22px; height: 22px; fill: none; stroke: currentColor; }
.icon-sm { width: 16px; height: 16px; vertical-align: -3px; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; border-radius: 4px; }

/* grain overlay */
.grain { position: fixed; inset: 0; width: 100vw; height: 100vh; pointer-events: none; z-index: 2; mix-blend-mode: multiply; opacity: .5; }
.grain svg { width: 100%; height: 100%; }

/* layout helpers */
.wrap { max-width: 1180px; margin: 0 auto; padding: 0 20px; }
.section { padding: clamp(48px, 8vw, 96px) 0; }
.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 900px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 580px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } }
.mt-0 { margin-top: 0 } .mb-0 { margin-bottom: 0 }
.center { text-align: center; }

/* reveal animation */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in-view { opacity: 1; transform: none; }
.reveal.stagger > * { transition-delay: calc(var(--i, 0) * 90ms); }
@media (prefers-reduced-motion: reduce) {
  .reveal, html { transition: none !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}

/* buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 14px 26px; border-radius: 999px; border: 1px solid transparent;
  font-family: var(--font-body); font-weight: 600; font-size: .95rem; cursor: pointer;
  position: relative; overflow: hidden; isolation: isolate; min-height: 44px;
  transition: color .3s ease, border-color .3s ease, transform .2s ease;
}
.btn::before {
  content: ""; position: absolute; inset: 0; left: -100%; width: 100%;
  background: var(--forest); z-index: -1; transition: left .35s ease;
}
.btn:hover::before { left: 0; }
.btn:active { transform: scale(.97); }
.btn-gold { background: var(--gold); color: var(--graphite); }
.btn-gold::before { background: var(--forest); }
.btn-gold:hover { color: var(--white); }
.btn-forest { background: var(--forest); color: var(--white); }
.btn-forest::before { background: var(--gold); }
.btn-forest:hover { color: var(--graphite); }
.btn-outline { background: transparent; color: var(--graphite); border-color: var(--graphite); }
.btn-outline::before { background: var(--graphite); }
.btn-outline:hover { color: var(--white); }
.btn-outline-dark { background: transparent; color: var(--cream); border-color: var(--cream); }
.btn-outline-dark::before { background: var(--cream); }
.btn-outline-dark:hover { color: var(--graphite); }
.btn-ghost-dark { background: transparent; color: var(--cream); border: 1px solid rgba(247,241,231,.4); }
.btn-ghost-dark::before { background: rgba(247,241,231,.15); }
.btn-ghost-dark:hover { color: var(--cream); }
.btn-sm { padding: 9px 18px; font-size: .85rem; min-height: 38px; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }

/* header */
.site-header { position: sticky; top: 0; z-index: 50; background: var(--cream); border-bottom: 1px solid var(--beige); }
.header-inner { max-width: 1180px; margin: 0 auto; padding: 12px 20px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.logo-mark { width: 180px; height: 38px; }
.main-nav { display: flex; align-items: center; gap: 22px; }
.main-nav a { font-size: .92rem; font-weight: 500; position: relative; padding: 4px 0; }
.main-nav a::after { content: ""; position: absolute; left: 0; bottom: -2px; width: 0; height: 2px; background: var(--gold); transition: width .3s ease; }
.main-nav a:hover::after, .main-nav a.active::after { width: 100%; }
.main-nav a.active { color: var(--forest); }
.nav-close { display: none; }
.header-actions { display: flex; align-items: center; gap: 10px; }
.icon-btn { position: relative; display: inline-flex; width: 44px; height: 44px; align-items: center; justify-content: center; border-radius: 50%; color: var(--graphite); }
.icon-btn:hover { background: var(--beige); }
.cart-count { position: absolute; top: 2px; right: 2px; background: var(--forest); color: var(--white); font-size: .65rem; min-width: 16px; height: 16px; border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.cart-link.bump .cart-count { animation: bump .4s ease; }
@keyframes bump { 0%{transform:scale(1)} 40%{transform:scale(1.5)} 100%{transform:scale(1)} }
.nav-toggle { display: none; }
.nav-overlay { position: fixed; inset: 0; background: rgba(48,45,42,.5); opacity: 0; visibility: hidden; transition: opacity .3s ease; z-index: 59; }
.nav-overlay.open { opacity: 1; visibility: visible; }

@media (max-width: 860px) {
  .main-nav {
    position: fixed; top: 0; right: 0; height: 100vh; width: min(320px, 85vw);
    background: var(--graphite); color: var(--cream); flex-direction: column; align-items: flex-start;
    padding: 90px 28px 28px; gap: 20px; transform: translateX(100%); visibility: hidden; transition: transform .35s ease, visibility .35s ease; z-index: 60;
  }
  .main-nav.open { transform: translateX(0); visibility: visible; }
  .main-nav a { color: var(--cream); font-size: 1.05rem; }
  .nav-close { display: inline-flex; position: absolute; top: 20px; right: 20px; color: var(--cream); background: none; border: none; width: 44px; height: 44px; }
  .nav-toggle { display: inline-flex; }
}

/* footer */
.site-footer { background: var(--graphite); color: var(--beige); position: relative; }
.footer-divider { width: 100%; height: 40px; display: block; }
.footer-inner { max-width: 1180px; margin: 0 auto; padding: 0 20px 40px; display: grid; grid-template-columns: 1.3fr 2fr 1.3fr; gap: 32px; }
@media (max-width: 860px) { .footer-inner { grid-template-columns: 1fr; } }
.footer-mark { width: 44px; height: 44px; margin-bottom: 10px; }
.footer-legal { font-size: .82rem; opacity: .75; }
.footer-cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
@media (max-width: 560px) { .footer-cols { grid-template-columns: 1fr; } }
.footer-cols h3 { font-family: var(--font-body); font-size: .85rem; text-transform: uppercase; letter-spacing: .08em; color: var(--gold); margin-bottom: 10px; }
.footer-cols a { display: block; padding: 4px 0; font-size: .92rem; color: var(--beige); }
.footer-cols a:hover { color: var(--gold); }
.newsletter-form { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0; }
.newsletter-form input[type=email] { flex: 1; min-width: 160px; padding: 11px 14px; border-radius: 999px; border: 1px solid rgba(247,241,231,.3); background: rgba(247,241,231,.08); color: var(--cream); }
.newsletter-form .hp { position: absolute; left: -9999px; }
.footer-email { display: flex; align-items: center; gap: 8px; font-size: .9rem; }
.form-msg { width: 100%; font-size: .85rem; margin: 4px 0 0; }
.form-msg.success { color: var(--sage); }
.form-msg.error { color: #e2a0a0; }
.footer-bottom { text-align: center; padding: 16px; font-size: .78rem; opacity: .6; border-top: 1px solid rgba(247,241,231,.1); }

/* cookie banner */
.cookie-banner { position: fixed; bottom: 16px; left: 16px; right: 16px; z-index: 80; background: var(--graphite); color: var(--cream); border-radius: var(--radius); padding: 18px 22px; display: flex; flex-wrap: wrap; align-items: center; gap: 16px; justify-content: space-between; box-shadow: var(--shadow-paper); }
.cookie-banner a { color: var(--gold); text-decoration: underline; }
.cookie-actions { display: flex; gap: 10px; flex-wrap: wrap; }

/* hero */
.hero { position: relative; padding: clamp(60px,10vw,120px) 0 80px; overflow: hidden; }
.hero-inner { max-width: 1180px; margin: 0 auto; padding: 0 20px; display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; }
@media (max-width: 860px) { .hero-inner { grid-template-columns: 1fr; } }
.hero-kicker { color: var(--forest); font-weight: 600; letter-spacing: .08em; text-transform: uppercase; font-size: .8rem; }
.hero-title { font-size: clamp(2.4rem, 6vw, 4.2rem); color: var(--graphite); }
.hero-sub { font-size: 1.1rem; max-width: 42ch; color: #51493f; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 10px; }
.hero-art { position: relative; aspect-ratio: 1/1; }
.hero-art svg { width: 100%; height: 100%; }
.hero-art .piece { opacity: 0; transform: translateY(40px) rotate(-6deg); animation: assemble .9s cubic-bezier(.2,.8,.2,1) forwards; }
.hero-art .piece:nth-child(2) { animation-delay: .12s; }
.hero-art .piece:nth-child(3) { animation-delay: .24s; }
.hero-art .piece:nth-child(4) { animation-delay: .36s; }
.hero-art .piece:nth-child(5) { animation-delay: .48s; }
@keyframes assemble { to { opacity: 1; transform: translateY(0) rotate(0); } }
@media (prefers-reduced-motion: reduce) { .hero-art .piece { opacity: 1; transform: none; animation: none; } }
.float-steam { animation: steam 6s ease-in-out infinite; }
@keyframes steam { 0%,100% { transform: translateY(0); opacity:.5 } 50% { transform: translateY(-10px); opacity:.9 } }
@media (prefers-reduced-motion: reduce) { .float-steam { animation: none; } }

/* section index (magazine cover) */
.index-list { counter-reset: sec; list-style: none; margin: 0; padding: 0; display: grid; gap: 0; border-top: 1px solid var(--beige); }
.index-item { counter-increment: sec; display: grid; grid-template-columns: 70px 1fr auto; align-items: baseline; gap: 18px; padding: 18px 0; border-bottom: 1px solid var(--beige); }
.index-item::before { content: counter(sec, decimal-leading-zero); font-family: var(--font-display); font-size: 1.4rem; color: var(--gold); }
.index-item h3 { margin: 0; font-size: 1.2rem; }
.index-item a { display: contents; }
.index-item .arrow { font-size: 1.3rem; color: var(--forest); transition: transform .3s ease; }
.index-item:hover .arrow { transform: translateX(6px); }

/* cards */
.card { background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow-paper); overflow: hidden; transition: transform .35s ease, box-shadow .35s ease; }
.card:hover { transform: translateY(-6px); }
.card-media { aspect-ratio: 4/3; overflow: hidden; }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.card:hover .card-media img { transform: scale(1.08); }
.card-body { padding: 18px 20px 22px; }
.card-body h3 { font-size: 1.05rem; margin-bottom: 6px; }
.card-tag { font-size: .72rem; text-transform: uppercase; letter-spacing: .07em; color: var(--sage); }
.card-price { font-weight: 700; color: var(--forest); font-size: 1.1rem; margin: 8px 0; }
.card-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; }

/* product strip (scroll-snap on mobile) */
.product-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
@media (max-width: 900px) {
  .product-strip { grid-template-columns: unset; grid-auto-flow: column; grid-auto-columns: 78%; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 8px; }
  .product-strip .card { scroll-snap-align: start; }
}

/* badge / divider svgs */
.badge-seal { width: 110px; height: 110px; }
.divider-wave { width: 100%; height: 48px; display: block; }

/* tea finder feature */
.finder { background: var(--forest); color: var(--cream); border-radius: 24px; padding: clamp(28px,5vw,56px); position: relative; overflow: hidden; }
.finder h2 { color: var(--cream); }
.finder-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px,1fr)); gap: 14px; margin: 24px 0; }
.finder-opt { background: rgba(247,241,231,.08); border: 1px solid rgba(247,241,231,.25); border-radius: 12px; padding: 14px; cursor: pointer; transition: background .25s ease, border-color .25s ease; }
.finder-opt:hover, .finder-opt.selected { background: var(--gold); color: var(--graphite); border-color: var(--gold); }
.finder-opt input { accent-color: var(--gold); margin-right: 8px; }
.finder-result { margin-top: 20px; background: var(--cream); color: var(--graphite); border-radius: 14px; padding: 20px; min-height: 60px; }

/* page hero for inner pages */
.page-hero { background: var(--beige); padding: 48px 0 40px; }
.page-hero h1 { font-size: clamp(2rem, 4vw, 2.8rem); }
.breadcrumbs { font-size: .85rem; color: #6b6356; display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; }
.breadcrumbs a { text-decoration: underline; }
.breadcrumbs span { opacity: .6; }

/* prose (legal pages) */
.prose { max-width: var(--measure); margin: 0 auto; }
.prose h2 { margin-top: 1.6em; font-size: 1.4rem; }
.prose h3 { font-size: 1.1rem; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li { margin-bottom: .4em; }
.legal-toc { background: var(--white); border-radius: var(--radius); padding: 20px 24px; margin-bottom: 30px; }
.legal-toc h2 { font-size: 1rem; text-transform: uppercase; letter-spacing: .06em; }
.legal-toc ol { columns: 2; padding-left: 1.2em; }
@media (max-width: 600px) { .legal-toc ol { columns: 1; } }

/* notice */
.notice { border-radius: 12px; padding: 16px 20px; background: var(--beige); border-left: 4px solid var(--gold); font-size: .92rem; margin: 20px 0; }
.notice-warning { border-left-color: #b5693a; background: #f3e4d8; }

/* forms */
.form-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr; } }
.field { display: flex; flex-direction: column; gap: 6px; }
.field.full { grid-column: 1 / -1; }
.field label { font-size: .85rem; font-weight: 600; }
.field input, .field select, .field textarea {
  padding: 12px 14px; border-radius: 10px; border: 1px solid var(--beige); background: var(--white);
  font-family: var(--font-body); font-size: .95rem; accent-color: var(--forest);
}
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--forest); }
.field-error { color: #a0423a; font-size: .8rem; min-height: 1em; }
.field textarea { resize: vertical; min-height: 110px; }

/* product detail */
.product-detail { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
@media (max-width: 800px) { .product-detail { grid-template-columns: 1fr; } }
.product-gallery img { border-radius: var(--radius); aspect-ratio: 1/1; object-fit: cover; }
.product-info .price { font-size: 1.6rem; color: var(--forest); font-weight: 700; }
.qty-row { display: flex; align-items: center; gap: 12px; margin: 16px 0; }
.qty-row input { width: 64px; padding: 10px; border-radius: 8px; border: 1px solid var(--beige); text-align: center; }
.spec-table { width: 100%; border-collapse: collapse; margin: 20px 0; font-size: .92rem; }
.spec-table th { text-align: left; color: #6b6356; width: 40%; padding: 8px 0; vertical-align: top; }
.spec-table td { padding: 8px 0; }

/* cart */
.cart-table { width: 100%; border-collapse: collapse; }
.cart-table th { text-align: left; font-size: .8rem; text-transform: uppercase; letter-spacing: .05em; color: #6b6356; padding: 10px; border-bottom: 2px solid var(--beige); }
.cart-table td { padding: 14px 10px; border-bottom: 1px solid var(--beige); vertical-align: middle; }
.cart-row-product { display: flex; align-items: center; gap: 12px; }
.cart-row-product img { width: 64px; height: 64px; object-fit: cover; border-radius: 8px; }
.cart-summary { background: var(--white); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow-paper); }
.cart-summary dl { display: grid; grid-template-columns: 1fr auto; gap: 8px 12px; margin: 0 0 16px; }
.cart-summary dt { color: #6b6356; }
.cart-summary .total { font-weight: 700; font-size: 1.2rem; color: var(--forest); }
.cart-empty { text-align: center; padding: 60px 20px; }

/* contact layout */
.contact-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
@media (max-width: 800px) { .contact-layout { grid-template-columns: 1fr; } }
.contact-card { background: var(--white); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow-paper); }
.contact-card dl { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; font-size: .92rem; }
.contact-card dt { color: #6b6356; }

/* faq */
.faq-item { border-bottom: 1px solid var(--beige); padding: 6px 0; }
.faq-item summary { cursor: pointer; font-weight: 600; padding: 14px 0; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; font-size: 1.4rem; color: var(--gold); transition: transform .3s ease; }
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item p { padding-bottom: 16px; color: #51493f; }

/* image frame used across site */
.img-frame { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-paper); }
.img-frame img { width: 100%; height: 100%; object-fit: cover; }

/* 404 */
.page-404 { text-align: center; padding: clamp(60px,10vw,120px) 0; }
.page-404 .logo-mark { width: 240px; height: 50px; margin: 0 auto 30px; }

/* COMPONENTS:
.wrap - centered max-width content container
.section - vertical page section spacing
.grid / .grid-2 / .grid-3 / .grid-4 - responsive grid helpers
.reveal - scroll-reveal animation hook (add .in-view via JS)
.btn / .btn-gold / .btn-forest / .btn-outline / .btn-outline-dark / .btn-ghost-dark / .btn-sm - button variants with fill-sweep hover
.site-header / .main-nav / .header-actions / .icon-btn / .cart-count - header & nav
.site-footer / .footer-inner / .footer-cols / .newsletter-form - footer
.cookie-banner / .cookie-actions - cookie consent UI
.hero / .hero-inner / .hero-title / .hero-art - home hero with assembling SVG motion
.index-list / .index-item - magazine-style numbered section index
.card / .card-media / .card-body / .card-price - product/content card
.product-strip - horizontal scroll-snap product row on mobile
.finder / .finder-grid / .finder-opt / .finder-result - signature tea-finder feature
.page-hero - inner page header band
.breadcrumbs - breadcrumb trail
.prose - readable long-form legal/article text
.legal-toc - table of contents box for legal pages
.notice / .notice-warning - callout boxes
.form-grid / .field / .field-error - form layout system
.product-detail / .product-gallery / .product-info / .spec-table / .qty-row - product page layout
.cart-table / .cart-summary / .cart-row-product / .cart-empty - cart page layout
.contact-layout / .contact-card - contact page layout
.faq-item - accordion FAQ entry (details/summary)
.img-frame - framed photo with shadow
.badge-seal / .divider-wave - decorative bespoke SVGs
.page-404 - not-found page layout
*/
/* Footer brand logo */
.footer-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.footer-brand svg {
  width: 48px;
  height: 48px;
  color: var(--gold);
}

/* Footer newsletter signup */
.footer-newsletter {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-newsletter input {
  padding: 10px 14px;
  border: 1px solid var(--beige);
  border-radius: 6px;
  background: var(--white);
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--graphite);
}

.footer-newsletter input::placeholder {
  color: var(--sage);
}

/* Header logo link */
.logo {
  display: flex;
  align-items: center;
  padding: 4px;
  transition: opacity .2s ease;
}

.logo svg {
  width: 28px;
  height: 28px;
  color: var(--forest);
}

.logo:hover {
  opacity: 0.85;
}

/* Cart quantity input */
.qty-input {
  width: 60px;
  padding: 6px 10px;
  border: 1px solid var(--beige);
  border-radius: 6px;
  background: var(--white);
  font-family: var(--font-body);
  font-size: 14px;
  text-align: center;
  color: var(--graphite);
}

.qty-input:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 2px rgba(209, 168, 94, 0.1);
}

/* Cart remove button */
.remove-item {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 1px solid var(--beige);
  border-radius: 6px;
  background: var(--white);
  color: var(--graphite);
  font-size: 18px;
  font-weight: 300;
  cursor: pointer;
  transition: all .2s ease;
}

.remove-item:hover {
  background: var(--cream);
  border-color: var(--sage);
}

@media (max-width: 580px) {
  .qty-input {
    width: 50px;
    font-size: 13px;
    padding: 5px 8px;
  }
  
  .remove-item {
    width: 28px;
    height: 28px;
    font-size: 16px;
  }
}
