/* === ALDO sušáky – design (červená + tmavě šedá + bílá podle loga) === */
:root {
    --primary: #e1141f;        /* červená z loga */
    --primary-dark: #b51019;   /* tmavší červená */
    --secondary: #3f4044;      /* tmavě šedá z loga */
    --accent: #e1141f;         /* CTA - stejná červená */
    --accent-dark: #b51019;
    --bg: #fafafa;
    --bg-light: #f5f5f5;
    --border: #e5e7eb;
    --text: #1a1a1a;
    --text-muted: #64748b;
    --green: #16a34a;
    --red: #e1141f;
}

*, *::before, *::after { box-sizing: border-box; }
body { margin:0; font-family: 'Inter', system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif; color:var(--text); background:var(--bg); line-height:1.5; }
img { max-width:100%; height:auto; display:block; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }

.container { max-width: 1280px; margin: 0 auto; padding: 0 16px; }

/* === HEADER === */
.topbar { background:#fff; border-bottom: 3px solid var(--primary); position: sticky; top: 0; z-index: 100; box-shadow: 0 2px 6px rgba(0,0,0,.04); }
.topbar-inner { display:grid; grid-template-columns: auto 1fr auto; align-items:center; gap: 24px; padding: 14px 16px; }
.brand { display:flex; align-items:center; line-height:1; text-decoration:none; }
.brand img,
.brand .brand-logo { height: 56px; width: 170px; max-width: 220px; display: block; }
@media (max-width: 800px) {
    .brand img,
    .brand .brand-logo { height: 42px; width: 126px; max-width: 150px; }
}
.search { display: flex; align-items: stretch; }
.search input[type=search] { flex: 1; padding: 10px 14px; border: 2px solid var(--border); border-right: 0; border-radius: 4px 0 0 4px; font: inherit; background:#fff; min-width: 200px; }
.search input[type=search]:focus { outline: 0; border-color: var(--primary); }
.search button { display: flex; align-items: center; justify-content: center; padding: 0 18px; background: var(--accent); border: 2px solid var(--accent); color: #fff; cursor: pointer; border-radius: 0 4px 4px 0; }
.search button:hover { background: var(--accent-dark); border-color: var(--accent-dark); }
.search button svg { display: block; }
.topbar-actions { display: flex; align-items: center; gap: 10px; }
.cart-link { display: flex; align-items: center; gap: 8px; padding: 10px 16px; background: var(--accent); color: #fff !important; border-radius: 4px; font-weight: 600; text-decoration: none; }
.cart-link:hover { background: var(--accent-dark); text-decoration: none; }
.cart-link svg { flex-shrink: 0; }
.hamburger svg { display: block; }
.cart-text { display: inline; }
.cart-badge { display:inline-flex; align-items:center; justify-content:center; min-width:22px; height:22px; padding: 0 6px; background:#fff; color: var(--accent); border-radius: 50%; font-size: .82rem; font-weight: 700; }
.hamburger { display: none; background:none; border:0; font-size:1.6rem; cursor:pointer; color: var(--secondary); padding: 6px 10px; }

/* === MAIN NAV === */
.mainnav { background: var(--primary); }
.mainnav .container { display: flex; gap: 0; flex-wrap: wrap; }
.mainnav a { color: #fff; text-decoration: none; padding: 12px 18px; font-weight: 500; text-transform: uppercase; font-size: .9rem; letter-spacing: .5px; transition: background .15s; }
.mainnav a:hover { background: var(--primary-dark); text-decoration: none; }

@media (max-width: 800px) {
    .topbar-inner { grid-template-columns: auto 1fr auto; gap: 10px; }
    .brand { font-size: 1.2rem; }
    .brand-sub { display: none; }
    .search { display: none; }
    .cart-text { display: none; }
    .hamburger { display: block; }
    /* .mainnav je na mobilu schované – navigace je v slide-out draweru zleva */
    .mainnav { display: none; }
}

/* === MOBILE DRAWER (slide-out kategorie zleva) === */
.mobile-drawer { display: none; }
.mobile-drawer-backdrop { display: none; }
@media (max-width: 800px) {
    .mobile-drawer {
        display: block;
        position: fixed;
        top: 0; left: 0;
        width: min(320px, 85vw);
        height: 100vh;
        background: #fff;
        z-index: 1000;
        transform: translateX(-100%);
        transition: transform .25s ease;
        overflow-y: auto;
        box-shadow: 4px 0 16px rgba(0,0,0,.15);
        display: flex;
        flex-direction: column;
    }
    .mobile-drawer.is-open { transform: translateX(0); }
    .mobile-drawer-head {
        display: flex; align-items: center; justify-content: space-between;
        padding: 14px 16px;
        border-bottom: 2px solid var(--primary);
        position: sticky; top: 0; background: #fff; z-index: 1;
    }
    .mobile-drawer-head strong { font-size: .82rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: .08em; }
    .mobile-drawer-close { background: none; border: 0; font-size: 1.8rem; line-height: 1; cursor: pointer; color: var(--secondary); padding: 0 6px; }
    .mobile-drawer-nav { padding: 4px 0; flex: 1; }
    .mobile-drawer-nav ul { list-style: none; margin: 0; padding: 0; }
    .mobile-drawer-nav a {
        display: block;
        padding: 12px 16px;
        color: var(--secondary);
        text-decoration: none;
        font-size: .95rem;
        border-bottom: 1px solid #f1f5f9;
    }
    .mobile-drawer-nav > ul > li > a {
        font-weight: 700;
        text-transform: uppercase;
        font-size: .85rem;
        letter-spacing: .04em;
    }
    .mobile-drawer-nav li li a {
        padding-left: 32px;
        font-weight: 400;
        text-transform: none;
        letter-spacing: 0;
        color: var(--text);
    }
    .mobile-drawer-nav li li li a { padding-left: 48px; font-size: .88rem; }
    .mobile-drawer-nav a:hover,
    .mobile-drawer-nav a.is-current { background: #fef2f2; color: var(--primary); }
    .mobile-drawer-cta {
        padding: 14px 16px;
        border-top: 1px solid var(--border);
        background: #fafafa;
    }
    .mobile-drawer-cta a {
        display: flex; align-items: center; gap: 10px;
        padding: 10px 12px;
        color: var(--secondary); text-decoration: none;
        border-radius: 6px;
    }
    .mobile-drawer-cta a:hover { background: #fff; }

    .mobile-drawer-backdrop {
        display: block;
        position: fixed; inset: 0;
        background: rgba(0,0,0,.45);
        opacity: 0;
        pointer-events: none;
        transition: opacity .25s ease;
        z-index: 999;
    }
    .mobile-drawer-backdrop.is-open { opacity: 1; pointer-events: auto; }
    body.has-drawer-open { overflow: hidden; }
}

/* === HERO === */
.hero {
    margin: 0 auto;
    background: linear-gradient(rgba(30,58,138,.65), rgba(17,24,39,.55)), url('/img/hero-default.jpg') center/cover no-repeat;
    background-color: var(--primary);
    padding: 80px 16px;
    text-align: center;
    color: #fff;
}
.hero-overlay { max-width: 800px; margin: 0 auto; }
.hero h1, .hero-slide h1 { margin: 0 0 12px; font-size: clamp(1.8rem, 4vw, 3rem); font-weight: 800; line-height: 1.15; }
.hero p, .hero-slide p { margin: 0 0 24px; font-size: clamp(1rem, 2vw, 1.25rem); opacity: .95; }

/* === HERO CAROUSEL === */
.hero-carousel { position: relative; overflow: hidden; border-radius: 8px; margin-bottom: 24px; background: #fff; }
.hero-track { position: relative; aspect-ratio: 3 / 1; min-height: 240px; max-height: 600px; }
.hero-slide { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; opacity: 0; transition: opacity .6s ease; pointer-events: none; background-color: #fff; }
.hero-slide.is-active { opacity: 1; pointer-events: auto; }

/* Slide s textovým overlayem (background-image cover + tmavý gradient + text shadow) */
.hero-slide:not(.is-image-only) {
    padding: 60px 40px;
    text-align: center;
    color: #fff;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}
.hero-slide:not(.is-image-only)::before {
    content: ""; position: absolute; inset: 0;
    background: linear-gradient(180deg, rgba(0,0,0,.18) 0%, rgba(0,0,0,.10) 40%, rgba(0,0,0,.30) 100%);
    pointer-events: none;
}
.hero-slide:not(.is-image-only) .hero-overlay { position: relative; z-index: 1; }
.hero-slide:not(.is-image-only) h1,
.hero-slide:not(.is-image-only) p { text-shadow: 0 2px 10px rgba(0,0,0,.55), 0 1px 2px rgba(0,0,0,.4); }

/* Image-only slide: celý obrázek bez ořezu, bez overlaye */
.hero-slide.is-image-only { padding: 0; }
.hero-img { width: 100%; height: 100%; object-fit: contain; display: block; }
.hero-img-link { display: block; width: 100%; height: 100%; }
.hero-nav { position: absolute; top: 50%; transform: translateY(-50%); width: 44px; height: 44px; border-radius: 50%; border: 0; background: rgba(255,255,255,.85); color: var(--secondary); font-size: 1.6rem; cursor: pointer; z-index: 5; display: flex; align-items: center; justify-content: center; transition: background .15s; }
.hero-nav:hover { background: #fff; }
.hero-prev { left: 16px; }
.hero-next { right: 16px; }
.hero-dots { position: absolute; bottom: 16px; left: 50%; transform: translateX(-50%); display: flex; gap: 8px; z-index: 5; }
.hero-dot { width: 12px; height: 12px; border-radius: 50%; border: 2px solid rgba(255,255,255,.7); background: transparent; cursor: pointer; padding: 0; transition: background .15s, border-color .15s; box-shadow: 0 1px 3px rgba(0,0,0,.4); }
.hero-dot:hover { border-color: #fff; }
.hero-dot.is-active { background: #fff; border-color: #fff; }
@media (max-width: 600px) {
    /* Banner je obvykle ~3:1, proto necháme i na mobilu wide aspect — žádné prázdné pruhy. */
    .hero-track { aspect-ratio: 3 / 1; min-height: 0; }
    .hero-slide { padding: 30px 16px; }
    .hero-nav { width: 32px; height: 32px; font-size: 1.2rem; }
    .hero-prev { left: 6px; }
    .hero-next { right: 6px; }
    .hero-carousel { margin-bottom: 14px; border-radius: 6px; }
    /* Pokud má slide text (overlay), 3:1 je málo — zvětšíme zpátky na 4:3 jen pro overlay sliduy */
    .hero-slide:not(.is-image-only) { aspect-ratio: 4 / 3; }
}

/* === USP BAR === */
.usp-bar { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; padding: 22px 18px; background: #fff; border-bottom: 1px solid var(--border); }
.usp-item { display: flex; align-items: center; gap: 14px; padding: 14px 16px; background: var(--bg-light); border-radius: 8px; transition: background .12s; }
.usp-item:hover { background: #f0f0f0; }
.usp-icon { flex-shrink: 0; width: 48px; height: 48px; display: flex; align-items: center; justify-content: center; font-size: 1.7rem; line-height: 1; background: #fff; border-radius: 10px; box-shadow: 0 1px 3px rgba(0,0,0,.06); color: var(--primary, #0a66c2); }
.usp-icon svg { width: 28px; height: 28px; display: block; }
.usp-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.usp-text strong { color: var(--secondary); font-size: .92rem; font-weight: 700; line-height: 1.25; }
.usp-text span { color: var(--text-muted); font-size: .82rem; line-height: 1.3; }
@media (max-width: 900px) {
    .usp-bar { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 500px) {
    .usp-bar { grid-template-columns: 1fr; }
}

/* === SECTIONS === */
.section-title { text-align: center; margin: 40px 0 24px; font-size: 1.8rem; font-weight: 700; color: var(--secondary); }
.section-title .accent { color: var(--accent); }
.categories-section, .products-section { padding: 16px 0; }

/* === CATEGORY GRID === */
.cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
@media (max-width: 800px) {
    .cat-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
}

/* Default tile (bez obrázku) */
.cat-tile {
    position: relative;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    aspect-ratio: 1 / 1;
    background: #fff;
    border: 2px solid var(--border);
    border-radius: 8px;
    overflow: hidden;
    text-decoration: none;
    transition: transform .15s, box-shadow .15s, border-color .15s;
}
.cat-tile:hover {
    border-color: var(--primary);
    box-shadow: 0 6px 20px rgba(0,0,0,.12);
    transform: translateY(-2px);
    text-decoration: none;
}
.cat-tile h3 {
    position: relative;
    z-index: 2;
    width: 100%;
    margin: 0;
    padding: 16px 14px;
    text-align: center;
    color: var(--secondary);
    font-size: .95rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .04em;
}

/* S obrázkem (background) */
.cat-tile.has-image {
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border: 0;
}
.cat-tile.has-image::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 40%, rgba(0,0,0,.65) 100%);
    z-index: 1;
}
.cat-tile.has-image h3 {
    color: #fff;
    text-shadow: 0 2px 6px rgba(0,0,0,.5);
}
.cat-tile.has-image:hover {
    box-shadow: 0 8px 24px rgba(0,0,0,.18);
}
.cat-tile.has-image:hover::before {
    background: linear-gradient(180deg, transparent 30%, rgba(0,0,0,.75) 100%);
}

/* === PRODUCT CARDS === */
.grid { display:grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 18px; }
@media (max-width: 800px) {
    /* Vynutit 2 sloupce na tabletu/mobilu — bez auto-fill kolapsu na 1 sloupec */
    .grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
}
@media (max-width: 800px) {
    /* Kompaktní karty na mobilu */
    .card-body { padding: 10px; gap: 4px; }
    .card-title { font-size: .88rem; min-height: 2.4em; }
    .card-sku { font-size: .72rem; }
    .card-price { font-size: 1.15rem; margin-bottom: 6px; }
    .card-img img { padding: 6px; }
}
.card { background:#fff; border:1px solid var(--border); border-radius:8px; overflow:hidden; display:flex; flex-direction:column; transition: box-shadow .15s, transform .15s; }
.card:hover { box-shadow: 0 4px 16px rgba(0,0,0,.08); transform: translateY(-2px); }
.card-img, .card-img-placeholder { display:flex; aspect-ratio:1/1; background:#f3f3f3; align-items:center; justify-content:center; color:#aaa; overflow: hidden; }
.card-img img { width:100%; height:100%; object-fit:contain; padding: 10px; transition: transform .35s ease; }
.card:hover .card-img img { transform: scale(1.08); }
.card-body { padding:14px; display:flex; flex-direction:column; gap:6px; flex:1; }
.card-title { margin:0; font-size:.98rem; line-height:1.3; min-height: 2.6em; }
.card-title a { color: var(--secondary); text-decoration: none; }
.card-title a:hover { color: var(--primary); }
.card-sku { margin:0; color: var(--text-muted); font-size:.78rem; }
.card-price { margin: auto 0 8px; font-weight: 800; font-size: 1.4rem; color: var(--primary); line-height: 1; }
.card-price small { color: var(--text-muted); font-weight: 400; font-size: .72rem; vertical-align: super; }

/* === BUTTONS === */
.btn { display:inline-block; padding: 10px 18px; border-radius: 4px; border: 2px solid var(--border); background: #fff; color: var(--secondary); cursor: pointer; font: inherit; font-weight: 500; text-decoration: none; transition: all .15s; }
.btn:hover { background: var(--bg-light); text-decoration: none; }
.btn-primary { background: var(--primary); border-color: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); color: #fff; }
.btn-accent { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn-accent:hover { background: var(--accent-dark); border-color: var(--accent-dark); color: #fff; }
.btn-add, .btn-fast { display: inline-flex; align-items: center; justify-content: center; gap: 8px; }
.btn-add svg, .btn-fast svg { flex-shrink: 0; }
.btn-add { background: var(--secondary); border-color: var(--secondary); color: #fff; padding: 9px 14px; font-size: .9rem; font-weight: 600; }
.btn-add:hover { background: #000; border-color: #000; color: #fff; }
.btn-fast { background: var(--primary); border-color: var(--primary); color: #fff; padding: 9px 14px; font-size: .9rem; font-weight: 700; }
.btn-fast:hover { background: var(--primary-dark); border-color: var(--primary-dark); color: #fff; }
.btn-fast:disabled { opacity: .7; cursor: wait; }
.btn-remove { padding: 4px 10px; background: var(--red); border-color: var(--red); color: #fff; }
.btn-large { padding: 14px 28px; font-size: 1.1rem; font-weight: 600; }
.btn-block { display: block; width: 100%; }
.card-actions { display: grid; grid-template-columns: 1fr; gap: 6px; margin-top: auto; }

/* === BREADCRUMBS === */
.breadcrumbs { margin: 0 0 16px; font-size: .88rem; color: var(--text-muted); }
.breadcrumbs ol { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 0; }
.breadcrumbs li { display: flex; align-items: center; }
.breadcrumbs li + li::before { content: "›"; margin: 0 8px; color: var(--border); font-weight: 700; }
.breadcrumbs a { color: var(--text-muted); text-decoration: none; }
.breadcrumbs a:hover { color: var(--primary); text-decoration: underline; }
.breadcrumbs .is-current span { color: var(--secondary); font-weight: 600; }

/* === SIDEBAR (catalog) === */
main.container { display:grid; grid-template-columns:1fr; gap:24px; padding:24px 16px; }
@media(min-width:900px) { main.container:has(.sidebar){grid-template-columns: 260px 1fr;} }
.sidebar { background: #fff; border: 1px solid var(--border); border-radius: 8px; padding: 8px; height: max-content; box-shadow: 0 1px 3px rgba(0,0,0,.04); }
/* Na mobilu kategorie sidebar skryjeme — používá se slide-out drawer ze sandwiče */
@media (max-width: 800px) {
    .sidebar { display: none; }
    main.container { padding: 14px 12px; gap: 14px; }
}
.sidebar h3 { margin: 0; padding: 14px 14px 10px; font-size: .82rem; color: var(--text-muted); font-weight: 700; text-transform: uppercase; letter-spacing: .08em; border-bottom: 1px solid var(--border); }
.sidebar ul { list-style: none; padding: 0; margin: 0; }
.sidebar > h3 + ul,
.sidebar > ul { padding: 6px 0; }
.sidebar > ul + h3 { margin-top: 10px; padding-top: 14px; border-top: 1px solid var(--border); }

/* Cat tree — moderní pill-like řádky s hover bg, červený active */
.cat-tree { padding: 0 !important; }
.cat-tree li { border: 0 !important; position: relative; }
.cat-tree li a {
    display: flex; align-items: center; gap: 8px;
    padding: 9px 12px; margin: 1px 4px;
    color: var(--secondary); font-size: .94rem; font-weight: 500;
    border-radius: 6px;
    transition: background .12s, color .12s, padding-left .12s;
}
.cat-tree li a:hover { background: var(--bg-light); color: var(--primary); text-decoration: none; padding-left: 14px; }

/* Top-level (přímý potomek .sidebar) – výraznější */
.sidebar > .cat-tree > li > a { font-weight: 700; text-transform: uppercase; font-size: .82rem; letter-spacing: .04em; color: var(--secondary); }

/* Nested úrovně */
.cat-tree .cat-tree { padding: 2px 0 4px 12px !important; margin: 0; border-left: 0; }
.cat-tree .cat-tree li a { font-weight: 500; text-transform: none; font-size: .92rem; letter-spacing: 0; padding: 7px 12px; color: var(--text-muted); }
.cat-tree .cat-tree .cat-tree li a { font-size: .88rem; }

/* Active: červené pozadí + bílý text */
.cat-tree li.is-active > a { background: var(--primary); color: #fff; padding-left: 12px; }
.cat-tree li.is-active > a:hover { background: var(--primary-dark); color: #fff; padding-left: 12px; }

/* Has-children: chevron */
.cat-tree li.has-children > a::after {
    content: ""; margin-left: auto; flex-shrink: 0;
    width: 8px; height: 8px;
    border-right: 2px solid currentColor; border-bottom: 2px solid currentColor;
    transform: rotate(-45deg);
    opacity: .5;
}
.cat-tree li.has-children.is-active > a::after,
.cat-tree li.has-children > a:hover::after { opacity: 1; }

/* === Filter (sidebar) === */
.filter-form { padding: 8px 4px 4px; }
.filter-form .filter-group { margin: 0 0 14px; padding: 0 10px 14px; border-bottom: 1px solid var(--border); }
.filter-form .filter-group:last-child { border-bottom: 0; }
.filter-label { display: block; font-weight: 600; margin-bottom: 8px; color: var(--secondary); font-size: .9rem; }
.filter-form .grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.filter-form input[type=number] { padding: 7px 9px; border: 1px solid var(--border); border-radius: 4px; font-size: .9rem; width: 100%; box-sizing: border-box; }
.filter-form input[type=number]:focus { outline: none; border-color: var(--primary); }

/* === Dual-range slider === */
.range-slider { padding: 4px 6px 8px; }
.range-values { display: flex; justify-content: space-between; font-size: .85rem; font-weight: 600; color: var(--secondary); margin-bottom: 6px; }
.range-track { position: relative; height: 28px; display: flex; align-items: center; }
.range-track::before {
    content: ""; position: absolute; left: 0; right: 0; top: 50%; transform: translateY(-50%);
    height: 4px; background: #e2e8f0; border-radius: 2px;
}
.range-fill {
    position: absolute; top: 50%; transform: translateY(-50%);
    height: 4px; background: var(--primary); border-radius: 2px;
    pointer-events: none;
}
.range-input {
    position: absolute; left: 0; right: 0; width: 100%; height: 28px;
    -webkit-appearance: none; appearance: none; background: transparent;
    pointer-events: none; margin: 0;
}
.range-input::-webkit-slider-thumb {
    -webkit-appearance: none; appearance: none;
    pointer-events: auto;
    width: 18px; height: 18px; border-radius: 50%;
    background: #fff; border: 2px solid var(--primary); cursor: pointer;
    box-shadow: 0 1px 3px rgba(0,0,0,.2);
    transition: transform .1s;
}
.range-input::-webkit-slider-thumb:hover,
.range-input::-webkit-slider-thumb:active { transform: scale(1.15); }
.range-input::-moz-range-thumb {
    pointer-events: auto;
    width: 18px; height: 18px; border-radius: 50%;
    background: #fff; border: 2px solid var(--primary); cursor: pointer;
    box-shadow: 0 1px 3px rgba(0,0,0,.2);
}
.range-input::-webkit-slider-runnable-track { background: transparent; height: 28px; }
.range-input::-moz-range-track { background: transparent; height: 28px; }
.range-input:focus { outline: none; }
.range-input:focus::-webkit-slider-thumb { box-shadow: 0 0 0 4px rgba(225,20,31,.2); }

/* Loading state pro grid při filtraci */
.catalog .grid.is-loading { opacity: .55; transition: opacity .15s; pointer-events: none; }
.filter-check { display: flex; align-items: center; gap: 8px; padding: 4px 0; font-size: .9rem; cursor: pointer; color: var(--secondary); }
.filter-check:hover { color: var(--primary); }
.filter-check input { margin: 0; }

/* === PRODUCT DETAIL === */
.product-detail {
    display: grid; gap: 30px; padding: 16px 0;
    grid-template-columns: 1fr;
    grid-template-areas: "gallery" "info" "description";
}
.product-detail .gallery { grid-area: gallery; }
.product-detail .info { grid-area: info; }
.product-detail .description { grid-area: description; margin-top: 0; padding-top: 24px; border-top: 1px solid var(--border); }

/* === Technické parametry === */
.product-params { grid-column: 1 / -1; padding: 18px 0 24px; border-top: 1px solid var(--border); }
.product-params h2 { margin: 0 0 14px; color: var(--secondary); font-size: 1.2rem; }
.params-list { display: grid; grid-template-columns: 1fr 1fr; gap: 0; margin: 0; padding: 0; border: 1px solid var(--border); border-radius: 6px; overflow: hidden; }
.params-row { display: contents; }
.params-row dt { padding: 10px 14px; background: var(--bg-light); color: var(--secondary); font-weight: 600; font-size: .92rem; border-bottom: 1px solid var(--border); border-right: 1px solid var(--border); margin: 0; }
.params-row dd { padding: 10px 14px; color: var(--text); margin: 0; border-bottom: 1px solid var(--border); font-size: .95rem; }
.params-row:last-child dt,
.params-row:last-child dd { border-bottom: 0; }
.params-row:nth-child(even) dt { background: #fafafa; }
.params-row:nth-child(even) dd { background: #fafafa; }
@media (max-width: 600px) {
    .params-list { grid-template-columns: 1fr; }
    .params-row dt { border-right: 0; padding-bottom: 4px; background: #fff !important; }
    .params-row dd { padding-top: 4px; padding-bottom: 12px; }
}
@media(min-width:780px){
    .product-detail {
        grid-template-columns: 1fr 1fr;
        grid-template-areas:
            "gallery info"
            "params params"
            "description description";
    }
    .product-detail .product-params { grid-area: params; }
}
.gallery img { border: 1px solid var(--border); border-radius: 8px; background: #fff; }
.gallery-main { position: relative; padding: 0; border: 0; background: transparent; cursor: zoom-in; display: block; width: 100%; }
.gallery-main img { width: 100%; transition: transform .3s; }
.gallery-main:hover img { transform: scale(1.02); }
.gallery-zoom-hint { position: absolute; right: 14px; bottom: 14px; width: 38px; height: 38px; border-radius: 50%; background: rgba(255,255,255,.9); color: var(--primary); display: flex; align-items: center; justify-content: center; box-shadow: 0 2px 6px rgba(0,0,0,.15); pointer-events: none; opacity: 0; transition: opacity .2s; }
.gallery-main:hover .gallery-zoom-hint { opacity: 1; }
.thumbs { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.thumb { width: 72px; height: 72px; object-fit: cover; border-radius: 4px; border: 2px solid var(--border); cursor: pointer; transition: border-color .15s, transform .15s; }
.thumb:hover { border-color: var(--primary); transform: scale(1.05); }
.thumb.is-active { border-color: var(--primary); }

/* === LIGHTBOX === */
.lightbox-overlay { position: fixed; inset: 0; background: rgba(15,23,42,.92); z-index: 2000; display: flex; align-items: center; justify-content: center; padding: 20px; animation: lb-fade-in .2s ease-out; }
@keyframes lb-fade-in { from { opacity: 0; } to { opacity: 1; } }
.lightbox-img { max-width: 92vw; max-height: 88vh; object-fit: contain; border-radius: 6px; box-shadow: 0 6px 30px rgba(0,0,0,.5); background: #fff; }
.lightbox-btn { position: absolute; background: rgba(255,255,255,.92); border: 0; width: 50px; height: 50px; border-radius: 50%; cursor: pointer; color: var(--secondary); display: flex; align-items: center; justify-content: center; font-size: 1.6rem; transition: background .15s, transform .15s; }
.lightbox-btn:hover { background: #fff; transform: scale(1.05); }
.lightbox-close { top: 20px; right: 20px; }
.lightbox-prev { left: 20px; top: 50%; transform: translateY(-50%); }
.lightbox-prev:hover { transform: translateY(-50%) scale(1.05); }
.lightbox-next { right: 20px; top: 50%; transform: translateY(-50%); }
.lightbox-next:hover { transform: translateY(-50%) scale(1.05); }
.lightbox-counter { position: absolute; bottom: 20px; left: 50%; transform: translateX(-50%); color: rgba(255,255,255,.85); font-size: .9rem; background: rgba(0,0,0,.4); padding: 6px 14px; border-radius: 14px; }
@media(max-width: 600px) {
    .lightbox-btn { width: 42px; height: 42px; font-size: 1.4rem; }
    .lightbox-prev { left: 8px; }
    .lightbox-next { right: 8px; }
    .lightbox-close { top: 8px; right: 8px; }
}
.info h1 { margin-top: 0; color: var(--secondary); }
.price strong { font-size: 2.2rem; color: var(--primary); font-weight: 800; }
.price small { color: var(--text-muted); font-weight: 400; font-size: .85rem; }
.qty-input { width: 64px; padding: 8px; border: 1px solid var(--border); border-radius: 4px; text-align: center; font: inherit; }
.qty-input::-webkit-inner-spin-button,
.qty-input::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.add-to-cart { display: grid; grid-template-columns: auto 1fr; gap: 10px; align-items: center; margin: 20px 0 12px; }
.add-to-cart-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.add-to-cart-actions .btn { padding: 10px 12px; font-size: .92rem; font-weight: 600; }
.btn-details { display: inline-flex; align-items: center; justify-content: center; gap: 8px; width: 100%; padding: 10px 14px; background: #e2e8f0; color: var(--secondary); border: 1px solid #cbd5e1; border-radius: 4px; font-size: .92rem; font-weight: 600; text-decoration: none; transition: background .15s, color .15s; }
.btn-details:hover { background: #cbd5e1; color: var(--primary); text-decoration: none; }
@media(max-width: 480px) {
    .add-to-cart { grid-template-columns: 1fr; }
    .add-to-cart-actions { grid-template-columns: 1fr 1fr; }
}

/* Smooth scroll + offset za sticky topbar */
html { scroll-behavior: smooth; }
#parametry, #popis { scroll-margin-top: 100px; }

/* Quantity stepper (− 1 +) - hranatý jako tlačítka */
.qty-stepper { display: inline-flex; align-items: stretch; border: 1px solid var(--border); border-radius: 4px; overflow: hidden; background: #fff; }
.qty-stepper .qty-input { width: 44px; border: 0; border-radius: 0; padding: 8px 4px; background: transparent; border-left: 1px solid var(--border); border-right: 1px solid var(--border); }
.qty-btn { background: var(--bg-light); border: 0; padding: 0 12px; font-size: 1.1rem; font-weight: 600; color: var(--secondary); cursor: pointer; line-height: 1; min-width: 32px; }
.qty-btn:hover { background: var(--border); color: var(--primary); }
.qty-stepper-cart { display: inline-flex; }
.qty-stepper-card-sm { display: inline-flex; }
.qty-stepper-card-sm .qty-btn { padding: 0 10px; font-size: 1rem; min-width: 28px; }
.qty-stepper-card-sm .qty-input { width: 38px; padding: 4px 2px; font-size: .9rem; }

/* Cena + qty na jednom radku */
.price-qty-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 8px 0; }
.price-qty-row .card-price { margin: 0; }

/* === CART === */
.cart-table { width:100%; border-collapse:collapse; background:#fff; border: 1px solid var(--border); border-radius: 8px; overflow: hidden; }
.cart-table th, .cart-table td { padding: 12px 10px; border-bottom: 1px solid var(--border); text-align: left; vertical-align: middle; }
.cart-table th { background: var(--bg-light); font-size: .9rem; }
.thumb-mini { width:48px; height:48px; object-fit:cover; float:left; margin-right:10px; border-radius:4px; }

/* === Cart table — mobil: tabulka se rozpadne na karty === */
@media (max-width: 700px) {
    .cart-table { display: block; border: 0; background: transparent; }
    .cart-table thead { display: none; }
    .cart-table tbody, .cart-table tfoot { display: block; }
    .cart-table tbody tr {
        display: grid;
        grid-template-columns: 1fr auto;
        gap: 8px 12px;
        background: #fff;
        border: 1px solid var(--border);
        border-radius: 8px;
        padding: 10px 12px;
        margin-bottom: 10px;
    }
    .cart-table tbody td {
        border: 0;
        padding: 0;
    }
    /* Produkt – celý horní řádek */
    .cart-table tbody td:nth-child(1) {
        grid-column: 1 / -1;
        font-size: .92rem;
        line-height: 1.35;
    }
    .cart-table tbody td:nth-child(1) small { color: var(--text-muted); }
    /* Cena/ks – pod produktem, vlevo */
    .cart-table tbody td:nth-child(2) {
        grid-column: 1;
        font-size: .82rem;
        color: var(--text-muted);
        align-self: center;
    }
    .cart-table tbody td:nth-child(2)::before {
        content: "Cena/ks: ";
    }
    /* Stepper – vpravo, vedle ceny/ks */
    .cart-table tbody td:nth-child(3) {
        grid-column: 2;
        grid-row: 2;
        justify-self: end;
        align-self: center;
    }
    /* Celkem – vlevo dole */
    .cart-table tbody td:nth-child(4) {
        grid-column: 1;
        grid-row: 3;
        font-weight: 800;
        color: var(--primary);
        font-size: 1.1rem;
        align-self: center;
    }
    .cart-table tbody td:nth-child(4)::before {
        content: "Celkem: ";
        font-weight: 400;
        color: var(--text-muted);
        font-size: .82rem;
    }
    /* Mazací × – vpravo dole */
    .cart-table tbody td:nth-child(5) {
        grid-column: 2;
        grid-row: 3;
        justify-self: end;
        align-self: center;
    }
    .cart-table tbody td:nth-child(5) .btn-remove {
        padding: 6px 12px; font-size: 1rem;
    }
    /* Footer – Celkem zboží + váha jako prosté řádky */
    .cart-table tfoot tr {
        display: flex;
        justify-content: space-between;
        padding: 8px 12px;
        background: #f9fafb;
        border: 1px solid var(--border);
        border-radius: 6px;
        margin-top: 4px;
    }
    .cart-table tfoot td { display: inline-block; padding: 0; border: 0; }
    .cart-actions { flex-direction: column; gap: 8px; }
    .cart-actions .btn { width: 100%; text-align: center; }
}
.qty-edit { width:64px; padding:6px; border: 1px solid var(--border); border-radius: 4px; }
.cart-actions { display:flex; justify-content:space-between; margin-top:18px; gap: 10px; }

/* === CMS PAGE === */
.cms-page { background: #fff; padding: 22px 26px; border: 1px solid var(--border); border-radius: 8px; min-width: 0; }
.cms-page h1 { color: var(--secondary); margin: 8px 0 14px; font-size: 1.4rem; font-weight: 700; }
.cms-content { font-size: .88rem; line-height: 1.6; word-wrap: break-word; overflow-wrap: anywhere; color: var(--text); }
.cms-content h1 { font-size: 1.25rem; font-weight: 700; color: var(--secondary); margin: 16px 0 8px; }
.cms-content h2 { font-size: 1.05rem; font-weight: 700; color: var(--secondary); margin: 18px 0 6px; }
.cms-content h3 { font-size: .95rem; font-weight: 700; color: var(--secondary); margin: 14px 0 4px; }
.cms-content h4, .cms-content h5, .cms-content h6 { font-size: .9rem; font-weight: 600; color: var(--secondary); margin: 12px 0 3px; }
.cms-content p, .cms-content div { font-weight: 400; margin: 0 0 8px; font-size: .88rem; }
.cms-content strong, .cms-content b { font-weight: 600; }
.cms-content ul, .cms-content ol { margin: 4px 0 10px; padding-left: 22px; font-size: .88rem; }
.cms-content li { margin: 2px 0; }
.cms-content a { color: var(--primary); word-break: break-all; }
.cms-content img { max-width: 100%; height: auto; }
.cms-content table { max-width: 100%; display: block; overflow-x: auto; }
.cms-content pre, .cms-content code { white-space: pre-wrap; word-wrap: break-word; }
@media (max-width: 700px) {
    .cms-page { padding: 16px 14px; border-radius: 6px; }
    .cms-page h1 { font-size: 1.35rem; margin: 4px 0 12px; }
    .cms-content { font-size: .95rem; line-height: 1.6; }
}
.cms-page-nav { display: flex; flex-wrap: wrap; gap: 4px; margin: 0 0 18px; padding: 6px; background: var(--bg-light); border-radius: 6px; }
.cms-page-nav a { padding: 7px 12px; border-radius: 4px; color: var(--secondary); font-size: .9rem; font-weight: 500; text-decoration: none; transition: background .15s, color .15s; }
.cms-page-nav a:hover { background: #fff; color: var(--primary); }
.cms-page-nav a.is-active { background: var(--primary); color: #fff; }

/* === FLASHES === */
.flashes { padding: 8px 0; }
.flash { padding: 12px 16px; border-radius: 4px; margin-bottom: 6px; }
.flash-success { background:#e6ffed; border:1px solid #aee9bf; color: #0f5132; }
.flash-error { background:#ffeaea; border:1px solid #f5b5b5; color: #842029; }
.flash-info { background:#eaf3ff; border:1px solid #b6cff0; color: #054387; }

/* === FOOTER === */
.footer { margin-top: 60px; padding: 50px 16px 20px; background: var(--secondary); color: #cbd5e1; }
.footer a { color: #cbd5e1; }
.footer a:hover { color: #fff; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 40px; padding-bottom: 30px; border-bottom: 1px solid #374151; }
.footer-col h4 { margin: 0 0 16px; color: #fff; font-size: .95rem; font-weight: 700; letter-spacing: .5px; }
.footer-col p, .footer-col ul { margin: 6px 0; font-size: .88rem; color: #cbd5e1; }
.footer-col ul.footer-links { list-style: none; padding: 0; }
.footer-col ul.footer-links li { padding: 5px 0; }
.footer-col ul.footer-links a { color: #cbd5e1; }
.footer-col ul.footer-links a:hover { color: var(--primary); }
.footer-html { font-size: .88rem; line-height: 1.6; }
.footer-html p { margin: 8px 0; color: #cbd5e1; }
.footer-html strong { color: #fff; }
.footer-html em { color: #94a3b8; font-style: italic; }
.footer-html a { color: #cbd5e1; }
.footer-html a:hover { color: var(--primary); }
.footer-bottom { padding-top: 20px; text-align: center; color: #94a3b8; font-size: .82rem; }
.footer-bottom p { margin: 4px 0; }
.footer-credit { font-size: .75rem; color: #94a3b8; }
.footer-credit a { color: #cbd5e1; text-decoration: none; font-weight: 500; }
.footer-credit a:hover { color: #fff; text-decoration: underline; }
.footer .muted { color: #94a3b8; }
.trust { font-size: .9rem; }

/* === MISC === */
.empty { padding: 30px; background: #fff; border: 1px dashed var(--border); border-radius: 8px; text-align: center; color: var(--text-muted); }
.muted { color: var(--text-muted); }
.btn-link { display: block; text-align: center; font-size: .9rem; color: var(--text-muted); margin-top: 8px; }

/* === ADD-TO-CART MODAL === */
.addmodal-overlay { position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 1000; display: flex; align-items: center; justify-content: center; padding: 20px; animation: fadeIn .15s ease; }
.addmodal { background: #fff; border-radius: 8px; max-width: 560px; width: 100%; box-shadow: 0 10px 40px rgba(0,0,0,.3); overflow: hidden; }
.addmodal-head { display: flex; align-items: center; gap: 10px; padding: 16px 20px; border-bottom: 1px solid var(--border); background: #f9fafb; }
.addmodal-head svg { flex-shrink: 0; }
.addmodal-head strong { flex: 1; color: var(--secondary); }
.addmodal-close { background: none; border: 0; font-size: 1.6rem; cursor: pointer; color: var(--text-muted); padding: 0 6px; line-height: 1; }
.addmodal-close:hover { color: var(--primary); }
.addmodal-body { padding: 18px 20px; }
.addmodal-body p { margin: 4px 0; }
.addmodal-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 14px 20px 20px; }
.addmodal-actions .btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 11px 14px; font-size: .95rem; font-weight: 600; }
.addmodal-actions .btn-primary { background: var(--primary); border-color: var(--primary); color: #fff; }
.addmodal-actions .btn-primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); }
@media(max-width:500px){ .addmodal-actions { grid-template-columns: 1fr; } }
@keyframes fadeIn { from {opacity:0;} to {opacity:1;} }

/* === Trix content rendering === */
.cms-content img { border-radius: 4px; margin: 10px 0; }
.cms-content blockquote { border-left: 3px solid var(--primary); padding-left: 16px; color: var(--text-muted); }

/* === Checkout (z předchozí etapy) === */
.checkout h1 { margin-bottom: 16px; color: var(--secondary); }
.checkout-grid { display:grid; grid-template-columns: 1fr 340px; gap: 24px; align-items: start; }
@media(max-width:900px){ .checkout-grid { grid-template-columns: 1fr; } }
.ship-pay-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media(max-width:700px){ .ship-pay-grid { grid-template-columns: 1fr; } }
.ship-pay-grid .block { margin-bottom: 0; }
/* Volby dopravy/platby v 2 sloupcích na desktopu (méně vertikálního prostoru) */
#shipping-options, #payment-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
@media(max-width:900px){ #shipping-options, #payment-options { grid-template-columns: 1fr; } }
.checkout-main .block { background:#fff; border:1px solid var(--border); border-radius:8px; padding:18px; margin-bottom:14px; }
.checkout-main h2 { margin: 0 0 12px; font-size: 1.1rem; color: var(--secondary); }
.checkout-main label { display: flex; flex-direction: column; gap: 4px; margin: 0 0 10px; font-size: .9rem; color: var(--text-muted); }
.checkout-main input[type=text], .checkout-main input[type=email], .checkout-main input[type=tel], .checkout-main input[type=password],
.checkout-main select, .checkout-main textarea { padding: 9px 10px; border: 1px solid var(--border); border-radius: 4px; font: inherit; font-size: .95rem; color: var(--text); width: 100%; box-sizing: border-box; }
.checkout-main input:focus, .checkout-main select:focus, .checkout-main textarea:focus { outline: none; border-color: var(--primary); }
.checkout-main .register-box { display: grid; gap: 12px; margin-top: 10px; padding: 14px; background: #f9fafb; border: 1px solid var(--border); border-radius: 6px; }
.checkout-main .register-box[hidden] { display: none; }
.checkout-main .grid-2 { display:grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.checkout-main .grid-3 { display:grid; grid-template-columns: 2fr 1fr 1fr; gap: 12px; }
@media(max-width:600px){ .checkout-main .grid-2, .checkout-main .grid-3 { grid-template-columns: 1fr; } }
.checkout-main .checkbox { flex-direction: row; align-items: center; gap: 8px; cursor: pointer; color: var(--text); }
.checkout-main .checkbox input { width: auto; }
.checkout-main .err { color: var(--red); font-size: .85rem; margin-top: 2px; display: block; }
.terms-checkbox { font-size: .95rem !important; color: var(--text) !important; }
.ship-option, .pay-option {
    display: grid;
    grid-template-columns: 24px 1fr auto;
    align-items: center;
    gap: 14px;
    padding: 12px 14px;
    border: 1px solid var(--border);
    border-radius: 6px;
    cursor: pointer;
    margin-bottom: 0;
    background: #fff;
    transition: all .15s;
}
/* Atribut hidden musí přebít display: grid (jinak by se zobrazovaly i nepovolené kombinace) */
.ship-option[hidden], .pay-option[hidden] { display: none !important; }
.ship-option:hover, .pay-option:hover { border-color: var(--primary); background: #fff5f5; }
.ship-option:has(input:checked), .pay-option:has(input:checked) { border-color: var(--primary); background: #fff5f5; box-shadow: inset 0 0 0 1px var(--primary); }
.ship-option > input[type=radio], .pay-option > input[type=radio] { margin: 0; }
.ship-info, .pay-info { text-align: left; }
.ship-info strong, .pay-info strong { display: block; color: var(--secondary); font-size: .98rem; }
.ship-info small, .pay-info small { color: var(--text-muted); font-size: .82rem; }
.ship-price, .pay-price { font-weight: 700; color: var(--primary); text-align: right; white-space: nowrap; font-size: 1.05rem; }
.ship-price em { color: var(--green); font-style: normal; font-weight: 700; }
.ship-price small { display: block; color: var(--text-muted); font-weight: 400; font-size: .72rem; margin-top: 2px; white-space: nowrap; }
.pickup-section { margin-top: 12px; padding: 14px; background: #f7fbff; border: 2px dashed var(--primary); border-radius: 6px; }
.pickup-section .btn { margin-bottom: 0; }
#pickup-selected { margin: 0; }
#pickup-selected p { margin: 4px 0; }
#pickup-selected-info { padding: 10px; background: #fff; border-radius: 4px; border: 1px solid var(--border); }
.checkout-summary { background: #fff; border: 1px solid var(--border); border-radius: 8px; padding: 18px; position: sticky; top: 110px; }
.checkout-summary h3 { margin: 0 0 12px; color: var(--secondary); }
.sum-items { list-style: none; padding: 0; margin: 0 0 12px; border-bottom: 1px solid var(--border); padding-bottom: 10px; }
.sum-items li { display: flex; justify-content: space-between; padding: 4px 0; font-size: .9rem; gap: 10px; }
.sum-name { color: var(--text); flex: 1; }
.sum-price { color: var(--secondary); white-space: nowrap; }
.sum-row { display: flex; justify-content: space-between; padding: 6px 0; font-size: .95rem; }
.sum-total { font-size: 1.2rem; border-top: 2px solid var(--secondary); margin-top: 10px; padding-top: 10px; font-weight: 700; color: var(--secondary); }

/* === CHECKOUT login banner === */
.checkout-login-banner { background: #fff3d6; border: 1px solid #f5d690; border-radius: 6px; padding: 12px 16px; margin: 0 0 16px; font-size: .95rem; color: #5b4112; }
.checkout-login-banner a { color: var(--primary); font-weight: 700; }

/* Pickup toggle (Chci vyzvednout osobně) */
.checkout-main .pickup-toggle-block { background: #f9fafb; border: 1px dashed var(--border); padding: 14px 18px; }
.checkout-main .pickup-toggle-block:has(.pickup-toggle input:checked) { background: #fff5f5; border-color: var(--primary); border-style: solid; }
.checkout-main .pickup-toggle { display: flex; align-items: center; gap: 12px; margin: 0; cursor: pointer; font-size: 1rem; font-weight: 600; color: var(--secondary); }
.checkout-main .pickup-toggle input[type=checkbox] { width: 20px; height: 20px; flex-shrink: 0; cursor: pointer; accent-color: var(--primary); }
.checkout-main .pickup-toggle-icon { font-size: 1.2rem; flex-shrink: 0; }
.checkout-main .pickup-toggle-text { flex: 1; }
.checkout-main .pickup-toggle-hint { margin: 8px 0 0 32px; color: var(--text-muted); font-size: .85rem; }

/* === AUTH (login / register / password reset) === */
.auth-section { max-width: 720px; margin: 24px auto; padding: 16px 0; }
.auth-card { background: #fff; border: 1px solid var(--border); border-radius: 8px; padding: 28px 30px; max-width: 460px; margin: 0 auto; box-shadow: 0 2px 8px rgba(0,0,0,.04); }
.auth-card-wide { max-width: 640px; }
.auth-card h1 { margin: 0 0 8px; color: var(--secondary); font-size: 1.6rem; }
.auth-card .form-stack { display: grid; gap: 14px; margin-top: 18px; }
.form-stack label { display: grid; gap: 4px; font-weight: 600; color: var(--secondary); font-size: .92rem; }
.form-stack input[type=text],
.form-stack input[type=email],
.form-stack input[type=tel],
.form-stack input[type=password],
.form-stack select { width: 100%; padding: 10px 12px; border: 2px solid var(--border); border-radius: 4px; font: inherit; background: #fff; }
.form-stack input:focus,
.form-stack select:focus { outline: none; border-color: var(--primary); }
.form-row { display: grid; gap: 14px; }
.form-row-2 { grid-template-columns: 1fr 1fr; }
.form-row-3 { grid-template-columns: 2fr 1fr 1fr; }
@media (max-width: 600px) {
    .form-row-2, .form-row-3 { grid-template-columns: 1fr; }
}
.form-stack label.checkbox-line { display: flex; align-items: flex-start; gap: 8px; font-weight: 400; color: var(--text); font-size: .92rem; line-height: 1.5; flex-wrap: wrap; }
.form-stack label.checkbox-line input[type=checkbox] { width: auto; margin-top: 3px; flex-shrink: 0; }
.field-error { color: var(--red); font-size: .82rem; font-weight: 500; }
.text-center { text-align: center; }
.btn-lg { padding: 12px 18px; font-size: 1rem; }

/* === ACCOUNT (Můj účet) === */
.account-page { display: grid; grid-template-columns: 240px 1fr; gap: 28px; padding: 18px 0; }
.account-sidebar { background: #fff; border: 1px solid var(--border); border-radius: 8px; padding: 18px; height: max-content; position: sticky; top: 110px; }
.account-sidebar h3 { margin: 0 0 12px; color: var(--secondary); font-size: 1rem; text-transform: uppercase; letter-spacing: .04em; }
.account-nav { display: grid; gap: 4px; }
.account-nav a { padding: 9px 12px; border-radius: 4px; color: var(--secondary); font-weight: 500; }
.account-nav a:hover { background: var(--bg-light); text-decoration: none; }
.account-nav a.is-active { background: var(--primary); color: #fff; }
.account-nav a.account-logout { margin-top: 14px; border-top: 1px solid var(--border); padding-top: 14px; color: var(--text-muted); }
.account-main { background: #fff; border: 1px solid var(--border); border-radius: 8px; padding: 24px 28px; }
.account-main h1 { margin: 0 0 6px; color: var(--secondary); font-size: 1.5rem; }
.account-main h2 { margin: 24px 0 10px; font-size: 1.1rem; color: var(--secondary); }
.account-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 18px 0 24px; }
.account-card { background: var(--bg-light); border: 1px solid var(--border); border-radius: 8px; padding: 18px; }
.account-card h3 { margin: 0 0 6px; font-size: .95rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: .04em; }
.account-card .big-number { font-size: 2.2rem; font-weight: 700; color: var(--primary); margin: 8px 0 14px; }
.account-orders { width: 100%; border-collapse: collapse; margin: 12px 0; }
.account-orders th, .account-orders td { padding: 10px 8px; text-align: left; border-bottom: 1px solid var(--border); }
.account-orders th { background: var(--bg-light); font-weight: 600; color: var(--secondary); font-size: .88rem; }
.account-orders td.num, .account-orders th.num { text-align: right; }
.account-orders .total-row td { border-top: 2px solid var(--secondary); font-size: 1.05rem; }
.status { display: inline-block; padding: 2px 10px; border-radius: 12px; font-size: .82rem; font-weight: 500; }
.status-new { background: #fff7d6; color: #92660d; }
.status-paid { background: #e6ffed; color: #15803d; }
.status-shipped { background: #dbeafe; color: #1e40af; }
.status-cancelled { background: #fee2e2; color: #991b1b; }
.status-refunded { background: #f3e8ff; color: #6b21a8; }
.order-header { display: flex; justify-content: space-between; align-items: flex-start; padding: 14px 0; border-bottom: 1px solid var(--border); margin-bottom: 18px; }
.order-total-big { font-size: 1.6rem; font-weight: 700; color: var(--primary); text-align: right; }
.order-total-big .small { display: block; font-size: .8rem; font-weight: 400; }
.order-addresses { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-top: 24px; }
.order-addresses h3 { margin: 0 0 6px; font-size: .95rem; }

@media (max-width: 800px) {
    .account-page { grid-template-columns: 1fr; }
    .account-sidebar { position: static; }
    .account-cards, .order-addresses { grid-template-columns: 1fr; }
}

/* Account link in topbar */
.account-link { color: var(--secondary); font-weight: 600; padding: 8px 12px; border: 2px solid var(--border); border-radius: 4px; display: inline-flex; align-items: center; gap: 6px; }
.account-link:hover { border-color: var(--primary); color: var(--primary); text-decoration: none; }

/* === THANKYOU === */
.thankyou { max-width: 760px; margin: 0 auto; padding: 16px 0; }
.ty-banner { background: #e6ffed; border: 1px solid #aee9bf; padding: 30px; border-radius: 8px; text-align: center; margin-bottom: 18px; }
.ty-banner h1 { margin: 0 0 6px; color: #15803d; }
.ty-number { font-size: 1.1rem; margin-top: 10px; }
.ty-info { background: #fff; border: 1px solid var(--border); padding: 18px; border-radius: 8px; margin-bottom: 18px; }
.payment-info { display: flex; gap: 24px; align-items: flex-start; flex-wrap: wrap; margin: 14px 0; padding: 14px; background: var(--bg-light); border-radius: 6px; }
.payment-info-text { flex: 1; min-width: 240px; }
.payment-info-text ul { margin: 0; padding-left: 20px; line-height: 1.8; }
.payment-qr { flex-shrink: 0; }
@media (max-width: 600px) {
    .payment-info { flex-direction: column-reverse; align-items: center; }
}
.ty-recap { background: #fff; border: 1px solid var(--border); padding: 18px; border-radius: 8px; margin-bottom: 18px; }
.ty-recap .total-row { border-top: 2px solid var(--secondary); }
.ty-actions { text-align: center; }

/* === Dostupnost produktu (Skladem / Na dotaz) === */
.avail-line { margin: .35rem 0 0; }
.avail-badge { display: inline-block; padding: 3px 12px; border-radius: 999px; font-size: .85rem; font-weight: 800; }
.avail-badge.avail-in, .card-avail.avail-in { background: #ecfdf5; color: #047857; }
.avail-badge.avail-req, .card-avail.avail-req { background: #fef3c7; color: #92400e; }
.card-avail { display: inline-block; margin: 6px 0; padding: 2px 10px; border-radius: 999px; font-size: .78rem; font-weight: 700; }
.product-inquiry { margin-top: 18px; padding-top: 18px; }
.product-inquiry-primary { background: #fffbeb; border: 1px solid #fde68a; border-radius: 12px; padding: 14px 16px; }
.product-inquiry-primary p { margin: 0; color: #92400e; font-weight: 600; }
.btn-block { width: 100%; }
