:root {
    --bg: #f6f8fb;
    --bg-alt: #eef2f7;
    --surface: #ffffff;
    --text: #1a2332;
    --text-muted: #5c6b7f;
    --primary: #0d7a4e;
    --primary-dark: #065a38;
    --primary-light: #e8f5ef;
    --accent: #1a6fd4;
    --border: #d8e0ea;
    --shadow: 0 4px 24px rgba(26, 35, 50, 0.08);
    --radius: 12px;
    --font: system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --font-display: Georgia, 'Times New Roman', 'Source Serif 4', serif;
    --container: 1140px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    font-family: var(--font);
    font-size: 1rem;
    line-height: 1.6;
    color: var(--text);
    background: var(--bg);
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
.container { width: min(100% - 2rem, var(--container)); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }
.skip-link { position: absolute; left: -9999px; top: 0; background: var(--primary); color: #fff; padding: .5rem 1rem; z-index: 999; }
.skip-link:focus { left: 1rem; }

/* Header */
.site-header {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    position: sticky; top: 0; z-index: 100;
}
.header-inner {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    padding: .65rem 0;
}
.header-bar {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}
.logo {
    display: flex; align-items: center; gap: .65rem;
    text-decoration: none; color: inherit; min-width: 0;
}
.logo:hover { text-decoration: none; }
.logo img { flex-shrink: 0; width: 36px; height: 36px; aspect-ratio: 1; }
.logo-text {
    display: flex; flex-direction: column; line-height: 1.2; min-width: 0;
}
.logo-text strong {
    font-size: 1rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.logo-tagline {
    font-size: .72rem; color: var(--text-muted);
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.header-panel {
    display: flex;
    align-items: center;
    flex: 1;
    gap: 1rem;
    min-width: 0;
}
.site-nav {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex: 1;
    gap: .85rem 1rem;
    flex-wrap: wrap;
    min-width: 0;
}
.site-nav a {
    display: inline-flex;
    align-items: center;
    color: var(--text); font-size: .88rem; font-weight: 500;
    line-height: 1.25;
    text-decoration: none; white-space: nowrap;
}
.site-nav a:hover { color: var(--primary); }

/* Nav dropdown — Kategorie */
.nav-dropdown {
    position: relative;
    display: inline-flex;
    align-items: center;
}
.nav-dropdown::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    height: .6rem;
}
.nav-dropdown-toggle {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    margin: 0;
    padding: 0;
    border: none;
    background: none;
    color: var(--text);
    font-family: inherit;
    font-size: .88rem;
    font-weight: 500;
    line-height: 1.25;
    cursor: pointer;
    white-space: nowrap;
    appearance: none;
    -webkit-appearance: none;
}
.nav-dropdown-toggle:hover,
.nav-dropdown.is-open .nav-dropdown-toggle { color: var(--primary); }
.nav-dropdown-chevron {
    display: inline-block;
    flex-shrink: 0;
    width: .45rem;
    height: .45rem;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(45deg);
    transition: transform .15s ease;
}
.nav-dropdown.is-open .nav-dropdown-chevron { transform: rotate(225deg); }
.nav-dropdown-menu {
    display: none;
    position: absolute;
    top: calc(100% + .5rem);
    left: 50%;
    transform: translateX(-50%);
    min-width: 15rem;
    margin: 0;
    padding: .35rem 0;
    list-style: none;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 10px;
    box-shadow: var(--shadow);
    z-index: 200;
}
.nav-dropdown-menu a {
    display: block;
    padding: .55rem 1rem;
    color: var(--text);
    font-size: .88rem;
    font-weight: 500;
    text-decoration: none;
    white-space: normal;
    line-height: 1.35;
}
.nav-dropdown-menu a:hover {
    background: var(--bg-alt);
    color: var(--primary);
}
@media (hover: hover) and (pointer: fine) {
    .nav-dropdown:hover .nav-dropdown-menu,
    .nav-dropdown:focus-within .nav-dropdown-menu { display: block; }
}
.nav-dropdown.is-open .nav-dropdown-menu { display: block; }

.header-search {
    display: flex;
    gap: .25rem;
    flex-shrink: 0;
}
.header-search input {
    border: 1px solid var(--border); border-radius: 8px;
    padding: .4rem .65rem; font: inherit; width: 11rem; max-width: 100%;
}
.header-search button {
    border: none; background: var(--primary); color: #fff;
    border-radius: 8px; padding: 0 .65rem; cursor: pointer; font-size: 1.05rem;
    flex-shrink: 0;
}
.nav-toggle {
    display: none; flex-direction: column; justify-content: center; gap: 5px;
    background: none; border: none; padding: .45rem; cursor: pointer;
    flex-shrink: 0; width: 40px; height: 40px;
    border-radius: 8px;
}
.nav-toggle:hover { background: var(--bg-alt); }
.nav-toggle span { display: block; width: 22px; height: 2px; background: var(--text); margin: 0 auto; }

/* Breadcrumb */
.breadcrumb { background: var(--bg-alt); border-bottom: 1px solid var(--border); font-size: .85rem; }
.breadcrumb ol { display: flex; flex-wrap: wrap; gap: .35rem; list-style: none; margin: 0; padding: .6rem 0; }
.breadcrumb li:not(:last-child)::after { content: '›'; margin-left: .35rem; color: var(--text-muted); }
.breadcrumb a { color: var(--text-muted); }

/* Hero */
.hero { background: linear-gradient(135deg, #0d7a4e 0%, #0a5c3a 50%, #1a4d6e 100%); color: #fff; padding: 3rem 0; }
.hero-inner { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; align-items: center; }
.hero h1 { font-family: var(--font-display); font-size: clamp(1.8rem, 4vw, 2.6rem); margin: .5rem 0 1rem; line-height: 1.15; }
.hero .lead { font-size: 1.1rem; opacity: .92; margin-bottom: 1.5rem; }
.badge { display: inline-block; background: rgba(255,255,255,.15); padding: .25rem .75rem; border-radius: 999px; font-size: .8rem; font-weight: 600; }
.hero-actions { display: flex; gap: .75rem; flex-wrap: wrap; margin-bottom: 1.5rem; }
.hero-stats { display: flex; gap: 1.5rem; list-style: none; padding: 0; margin: 0; font-size: .9rem; opacity: .9; }
.hero-stats strong { display: block; font-size: 1.2rem; }
.hero-visual { display: flex; justify-content: center; align-items: center; }
.hero-showcase {
    width: 100%;
    max-width: 440px;
    height: auto;
    aspect-ratio: 520 / 340;
    display: block;
    border-radius: var(--radius);
}
.sheet-mock { background: var(--surface); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.sheet-toolbar { height: 28px; background: #e8ecf0; border-bottom: 1px solid var(--border); }
.sheet-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2px; padding: 8px; background: #f0f4f8; }
.sheet-grid span { height: 36px; background: #fff; border-radius: 4px; }
.sheet-grid .accent { background: #c8e6d9; }
.sheet-grid-compact {
    min-height: 116px;
    background-color: #f0f4f8;
    background-image:
        linear-gradient(#fff, #fff) 8px 8px / calc(25% - 6px) 36px no-repeat,
        linear-gradient(#fff, #fff) calc(25% + 2px) 8px / calc(25% - 6px) 36px no-repeat,
        linear-gradient(#c8e6d9, #c8e6d9) calc(50% + 2px) 8px / calc(25% - 6px) 36px no-repeat,
        linear-gradient(#fff, #fff) calc(75% - 2px) 8px / calc(25% - 6px) 36px no-repeat,
        linear-gradient(#fff, #fff) 8px 52px / calc(25% - 6px) 36px no-repeat,
        linear-gradient(#c8e6d9, #c8e6d9) calc(25% + 2px) 52px / calc(25% - 6px) 36px no-repeat,
        linear-gradient(#c8e6d9, #c8e6d9) calc(50% + 2px) 52px / calc(25% - 6px) 36px no-repeat,
        linear-gradient(#fff, #fff) calc(75% - 2px) 52px / calc(25% - 6px) 36px no-repeat;
}

/* Buttons */
.btn {
    display: inline-flex; align-items: center; gap: .35rem;
    padding: .6rem 1.2rem; border-radius: 8px; font-weight: 600;
    font-size: .95rem; text-decoration: none; border: 2px solid transparent; cursor: pointer;
}
.btn:hover { text-decoration: none; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); color: #fff; }
.btn-secondary { background: #fff; color: var(--primary); border-color: var(--primary); }
.btn-secondary:hover { background: var(--primary-light); }
.btn-ghost { background: transparent; color: var(--text-muted); border-color: var(--border); }
.btn-lg { padding: .85rem 1.5rem; font-size: 1rem; }
.btn-sm { padding: .4rem .85rem; font-size: .85rem; }
.hero .btn-primary { background: #fff; color: var(--primary); }
.hero .btn-primary:hover { background: var(--primary-light); }
.hero .btn-secondary { background: transparent; color: #fff; border-color: rgba(255,255,255,.5); }

/* Sections */
.section { padding: 3rem 0; }
.section-alt { background: var(--bg-alt); }
.section-header { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 1.5rem; flex-wrap: wrap; gap: .5rem; }
.section-header h2 { font-family: var(--font-display); margin: 0; font-size: 1.6rem; }
.link-more { font-weight: 600; font-size: .95rem; }

/* Category grid */
.category-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1.25rem; }
.guide-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 1.5rem; margin: 2rem 0; }
.guide-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.5rem; }
.guide-card h2 { font-size: 1.15rem; margin: 0 0 .75rem; }
.guide-card h2 a { color: inherit; text-decoration: none; }
.guide-card h2 a:hover { color: var(--primary); }
.guide-card-meta { font-size: .85rem; color: var(--text-muted); margin: .75rem 0 0; }
.category-seo-footer { margin-top: 2.5rem; padding-top: 2rem; border-top: 1px solid var(--border); }
.guide-downloads { margin-top: 2rem; padding: 1.25rem; background: var(--primary-light); border-radius: var(--radius); }
.category-card {
    background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
    padding: 1.5rem; text-decoration: none; color: inherit;
    transition: box-shadow .2s ease, transform .2s ease;
    will-change: transform;
}
.category-card:hover {
    box-shadow: var(--shadow), 0 0 0 1px var(--primary);
    transform: translateY(-2px);
    text-decoration: none;
}
.category-card h3 { margin: .75rem 0 .5rem; font-size: 1.1rem; }
.category-card p { color: var(--text-muted); font-size: .9rem; margin: 0 0 .75rem; }
.category-count { font-size: .8rem; font-weight: 600; color: var(--primary); }
.category-icon { display: block; width: 40px; height: 40px; border-radius: 10px; background: var(--primary-light); }

/* Template cards */
.template-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1.25rem; }
.template-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; transition: box-shadow .2s; }
.template-card:hover { box-shadow: var(--shadow); }
.template-card-link { display: block; text-decoration: none; color: inherit; }
.template-card-link:hover { text-decoration: none; }
.template-card-image { position: relative; background: var(--bg-alt); aspect-ratio: 16/10; }
.template-card-image img { width: 100%; height: 100%; object-fit: cover; }
.template-card-badge { position: absolute; top: .5rem; right: .5rem; background: var(--primary); color: #fff; font-size: .7rem; font-weight: 700; padding: .2rem .5rem; border-radius: 4px; }
.template-card-body { padding: 1rem 1.15rem 1.25rem; }
.template-card-cat { font-size: .75rem; color: var(--primary); font-weight: 600; text-transform: uppercase; letter-spacing: .03em; }
.template-card-body h3 { margin: .35rem 0 .5rem; font-size: 1.05rem; }
.template-card-body p { color: var(--text-muted); font-size: .88rem; margin: 0 0 .75rem; line-height: 1.45; }
.template-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .75rem;
}
.template-card-stats {
    display: inline-flex;
    align-items: center;
    gap: .25rem;
    font-size: .82rem;
    font-weight: 600;
    color: var(--text-muted);
    min-width: 3.5rem;
}
.template-card-stats-icon { font-size: .75rem; opacity: .85; }
[data-card-stat-total], [data-stat-total] {
    display: inline-block;
    min-width: 2.5ch;
    font-variant-numeric: tabular-nums;
}
.template-card-cta { font-weight: 600; font-size: .9rem; color: var(--primary); }

/* Listing toolbar */
.listing-toolbar {
    margin-bottom: 1.25rem;
    padding: 1rem 1.15rem;
    background: var(--bg-alt);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}
.listing-search {
    display: flex;
    gap: .35rem;
    margin-bottom: 1rem;
}
.listing-search input {
    flex: 1;
    min-width: 0;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: .55rem .75rem;
    font: inherit;
    background: var(--surface);
}
.listing-search button {
    border: none;
    background: var(--primary);
    color: #fff;
    border-radius: 8px;
    padding: 0 .85rem;
    cursor: pointer;
    font-size: 1.05rem;
    flex-shrink: 0;
}
.listing-filters {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
    margin-bottom: .75rem;
}
.listing-pill {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    padding: .4rem .75rem;
    border: 1px solid var(--border);
    border-radius: 999px;
    background: var(--surface);
    color: var(--text);
    font: inherit;
    font-size: .82rem;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: border-color .15s, background .15s, color .15s;
    line-height: 1.3;
}
.listing-pill:hover {
    border-color: var(--primary);
    color: var(--primary);
    text-decoration: none;
}
.listing-pill.is-active {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}
.listing-pill.is-active:hover { color: #fff; background: var(--primary-dark); }
.listing-pill-count {
    display: inline-block;
    min-width: 1.25rem;
    padding: .05rem .35rem;
    border-radius: 999px;
    background: rgba(0, 0, 0, .08);
    font-size: .75rem;
    font-weight: 700;
    text-align: center;
}
.listing-pill.is-active .listing-pill-count { background: rgba(255, 255, 255, .22); }
.listing-results-meta {
    margin: 0;
    font-size: .88rem;
    color: var(--text-muted);
    font-weight: 500;
}
.listing-results-meta [data-listing-count] {
    font-weight: 700;
    color: var(--text);
}
.listing-empty-filter {
    margin: 0 0 1rem;
    padding: .75rem 1rem;
    background: var(--surface);
    border: 1px dashed var(--border);
    border-radius: 8px;
    color: var(--text-muted);
    font-size: .9rem;
}
.template-card.is-filtered-out { display: none; }

/* Layout sidebar */
.layout-with-sidebar { display: grid; grid-template-columns: 1fr 300px; gap: 2rem; padding: 2rem 0 3rem; align-items: start; }
.main-column { min-width: 0; }
.sidebar { position: sticky; top: 5rem; }

/* Template detail */
.template-hero { background: var(--surface); border-bottom: 1px solid var(--border); padding: 2rem 0; }
.template-hero-inner { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; align-items: center; }
.template-hero h1 { font-family: var(--font-display); font-size: clamp(1.5rem, 3vw, 2.2rem); margin: .5rem 0; }
.template-meta { display: flex; flex-wrap: wrap; gap: .5rem; margin: 1rem 0; }
.meta-pill { font-size: .78rem; background: var(--bg-alt); padding: .25rem .6rem; border-radius: 999px; color: var(--text-muted); }
.meta-free { background: var(--primary-light); color: var(--primary); font-weight: 600; }
.download-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1rem; }
.template-preview { margin: 0; text-align: center; }
.template-preview img { border-radius: var(--radius); border: 1px solid var(--border); box-shadow: var(--shadow); margin: 0 auto; }
.template-preview figcaption { font-size: .8rem; color: var(--text-muted); margin-top: .5rem; }
.download-box { background: var(--primary-light); border: 1px solid #b8dcc8; border-radius: var(--radius); padding: 1.5rem; margin: 2rem 0; }

/* Page header */
.page-header { background: var(--surface); border-bottom: 1px solid var(--border); padding: 2rem 0; }
.page-header h1 { font-family: var(--font-display); margin: 0 0 .5rem; }
.page-header p { color: var(--text-muted); margin: 0; }

/* Prose */
.prose h2 { font-family: var(--font-display); margin-top: 2rem; }
.prose h3 { margin-top: 1.5rem; }
.prose ul, .prose ol { padding-left: 1.25rem; }
.prose li { margin-bottom: .35rem; }
.intro { font-size: 1.05rem; }
.intro p { margin: 0 0 1rem; }
.listing-intro { margin-bottom: 1.25rem; }
.seo-content-block { max-width: 72ch; }
.keyword-tag {
    display: inline-block; font-size: .78rem; padding: .2rem .55rem; margin: 0 .35rem .35rem 0;
    background: var(--accent-soft); color: var(--accent); border-radius: 999px;
}
.template-keywords { margin-bottom: 1rem; }
.template-byline { margin-top: 2rem; padding-top: 1rem; border-top: 1px solid var(--border); color: var(--text-muted); }
.template-byline a { color: var(--accent); }

/* FAQ */
.faq-list { display: flex; flex-direction: column; gap: .5rem; }
.faq-item { background: var(--surface); border: 1px solid var(--border); border-radius: 8px; padding: 0 1rem; }
.faq-item summary { cursor: pointer; font-weight: 600; padding: .85rem 0; list-style: none; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item p { margin: 0 0 1rem; color: var(--text-muted); font-size: .95rem; }

/* Sidebar boxes */
.sidebar-box, .trust-box { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.25rem; margin-bottom: 1rem; }
.sidebar-box h3, .trust-box h3 { margin: 0 0 .75rem; font-size: 1rem; }
.sidebar-links { list-style: none; padding: 0; margin: 0; }
.sidebar-links li { margin-bottom: .4rem; }
.sidebar-links a { font-size: .9rem; }
.trust-box ul { margin: 0; padding-left: 1.1rem; font-size: .9rem; color: var(--text-muted); }

/* Ads */
.ad-slot { margin: 1.5rem 0; }
.ad-placeholder {
    min-height: 120px; background: repeating-linear-gradient(-45deg, #f0f4f8, #f0f4f8 8px, #e8ecf0 8px, #e8ecf0 16px);
    border: 2px dashed var(--border); border-radius: 8px;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    color: var(--text-muted); font-size: .8rem; gap: .25rem;
}
.ad-in_content .ad-placeholder, .ad-in_content { min-height: 280px; }
.ad-detail_mid .ad-placeholder, .ad-detail_mid { min-height: 280px; }
.ad-sidebar .ad-placeholder, .ad-sidebar { min-height: 250px; }
.ad-listing_end .ad-placeholder, .ad-listing_end { min-height: 200px; }

/* Search */
.search-form { display: flex; gap: .5rem; margin-top: 1rem; max-width: 520px; }
.search-form input { flex: 1; padding: .65rem 1rem; border: 1px solid var(--border); border-radius: 8px; font: inherit; }
.search-count { color: var(--text-muted); margin-bottom: 1.5rem; }
.empty-state { padding: 2rem; text-align: center; color: var(--text-muted); }

/* Footer */
.site-footer { background: #1a2332; color: #c8d0dc; margin-top: 3rem; padding: 3rem 0 0; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 2rem; padding-bottom: 2rem; }
.footer-brand img { width: 36px; height: 36px; aspect-ratio: 1; }
.site-footer h3 { color: #fff; font-size: .95rem; margin: 0 0 .75rem; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: .4rem; }
.site-footer a { color: #a8b8cc; text-decoration: none; font-size: .9rem; }
.site-footer a:hover { color: #fff; }
.footer-eeat { font-size: .85rem; line-height: 1.5; }
.footer-meta { font-size: .8rem; opacity: .7; }
.footer-bottom { border-top: 1px solid #2d3a4d; padding: 1rem 0; font-size: .85rem; text-align: center; }

/* Download gate modal */
body.download-gate-open { overflow: hidden; }
.download-gate { position: fixed; inset: 0; z-index: 1000; display: flex; align-items: center; justify-content: center; padding: 1rem; }
.download-gate[hidden] { display: none !important; }
.download-gate-backdrop { position: absolute; inset: 0; background: rgba(26, 35, 50, 0.72); backdrop-filter: blur(4px); }
.download-gate-panel {
    position: relative; z-index: 1; width: min(100%, 480px);
    background: var(--surface); border-radius: 16px; padding: 1.75rem 1.75rem 1.5rem;
    box-shadow: 0 24px 64px rgba(0,0,0,.25); text-align: center;
    animation: gateIn .25s ease-out;
}
@keyframes gateIn { from { opacity: 0; transform: scale(.95) translateY(8px); } to { opacity: 1; transform: none; } }
.download-gate-close {
    position: absolute; top: .75rem; right: .75rem; width: 36px; height: 36px;
    border: none; background: var(--bg-alt); border-radius: 50%; font-size: 1.4rem;
    line-height: 1; cursor: pointer; color: var(--text-muted);
}
.download-gate-title { font-family: var(--font-display); margin: 0 0 .35rem; font-size: 1.35rem; }
.download-gate-name { color: var(--text-muted); font-size: .95rem; margin: 0 0 1rem; }
.download-gate-ad { margin: 0 0 1.25rem; min-height: 250px; }
.download-gate-ad .ad-placeholder { min-height: 250px; }
.download-gate-countdown {
    font-size: 3.5rem; font-weight: 700; line-height: 1; color: var(--primary);
    font-variant-numeric: tabular-nums; margin-bottom: .25rem;
}
.download-gate-wait { margin: 0; color: var(--text-muted); font-size: 1rem; }
.download-gate-wait strong { color: var(--primary); font-size: 1.15rem; }
.download-gate-ready { font-weight: 700; color: var(--primary); font-size: 1.1rem; margin: 0 0 .5rem; }
.download-gate-funding { font-size: .82rem; color: var(--text-muted); margin: 1rem 0; line-height: 1.45; }
.download-gate-actions { display: flex; flex-direction: column; gap: .5rem; align-items: center; }
.download-gate-actions [data-gate-download].is-gate-locked,
.download-gate-actions [data-gate-download]:disabled {
    opacity: .65;
    cursor: not-allowed;
    filter: grayscale(.25);
    box-shadow: none;
    transform: none;
}
.download-gate-actions [data-gate-download]:not(:disabled):not(.is-gate-locked) {
    animation: gateReady .35s ease-out;
}
@keyframes gateReady { from { transform: scale(.96); } to { transform: scale(1); } }

.download-specs {
    background: var(--bg-alt); border: 1px solid var(--border); border-radius: var(--radius);
    padding: 1.25rem 1.35rem; margin-bottom: 2rem;
}
.download-specs h2 { margin-top: 0; font-size: 1.15rem; }
.download-specs-intro { margin: 0 0 1rem; font-size: .92rem; color: var(--text-muted); }
.download-format-note {
    margin: 0 0 1rem;
    padding: .75rem 1rem;
    font-size: .9rem;
    line-height: 1.5;
    background: var(--surface);
    border-left: 3px solid var(--accent, #2563eb);
    border-radius: 0 6px 6px 0;
    color: var(--text);
}
.download-format-note strong { font-weight: 600; }
.download-specs-grid { display: grid; gap: 1rem; margin: 0; }
@media (min-width: 640px) { .download-specs-grid { grid-template-columns: 1fr 1fr; } }
.download-specs-item { margin: 0; }
.download-specs-item dt { font-weight: 600; font-size: .82rem; text-transform: uppercase; letter-spacing: .03em; color: var(--text-muted); margin-bottom: .25rem; }
.download-specs-item dd { margin: 0; font-size: .95rem; }
.download-specs-item code { font-size: .85em; background: var(--surface); padding: .1rem .35rem; border-radius: 4px; }
.download-specs-meta { display: block; font-size: .85rem; color: var(--text-muted); margin-top: .2rem; }
.compat-list { margin: 0; padding-left: 1.1rem; font-size: .9rem; color: var(--text-muted); }
.compat-list li { margin-bottom: .15rem; }
.template-hero-eyebrow { margin: 0 0 .5rem; font-size: .88rem; }
.template-hero-eyebrow a { color: var(--primary); font-weight: 600; text-decoration: none; }
.template-hero-eyebrow a:hover { text-decoration: underline; }
.related-inline-list { margin: 0; padding-left: 1.25rem; }
.related-inline-list li { margin-bottom: .35rem; }
.sidebar-heading { margin: 0 0 .75rem; font-size: 1rem; font-family: inherit; font-weight: 600; }
.sidebar-download-link {
    background: none; border: none; padding: 0; font: inherit; color: var(--primary);
    cursor: pointer; text-align: left;
}
.sidebar-download-link:hover { text-decoration: underline; }

.template-rating {
    margin: 1.75rem 0 2rem;
    padding: 1.25rem 1.35rem;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--bg-alt);
}
.template-rating h2 { margin: 0 0 .35rem; font-size: 1.15rem; }
.template-rating-intro { margin: 0 0 1rem; color: var(--text-muted); font-size: .92rem; }
.template-rating-summary {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem 1.5rem;
    align-items: center;
    margin-bottom: 1.1rem;
}
.template-rating-scoreboard { display: flex; align-items: baseline; gap: .2rem; }
.template-rating-average { font-size: 2rem; font-weight: 700; line-height: 1; color: var(--text); }
.template-rating-average-max { font-size: 1rem; color: var(--text-muted); }
.template-rating-meta p { margin: .35rem 0 0; font-size: .9rem; color: var(--text-muted); }
.template-rating-empty { margin: .35rem 0 0; font-size: .9rem; color: var(--text-muted); }
.template-rating-vote {
    padding-top: 1rem;
    border-top: 1px solid var(--border);
}
.template-rating-vote-label { margin: 0 0 .5rem; font-size: .92rem; }
.template-rating-input { display: flex; gap: .25rem; flex-wrap: wrap; }
.template-rating-star-btn {
    background: none;
    border: none;
    padding: .15rem;
    font-size: 1.85rem;
    line-height: 1;
    cursor: pointer;
    color: #d1d5db;
    transition: color .15s ease, transform .1s ease;
}
.template-rating-star-btn:hover,
.template-rating-star-btn.is-active,
.template-rating-star-btn.is-hover {
    color: #f59e0b;
    transform: scale(1.05);
}
.template-rating-star-btn:disabled { cursor: wait; opacity: .65; }
.template-rating-message { min-height: 1.25rem; margin: .55rem 0 0; font-size: .88rem; color: var(--primary); }
.template-rating-message.is-error { color: #b91c1c; }
.template-stars { display: inline-flex; gap: .12rem; line-height: 1; vertical-align: middle; }
.template-stars-lg .template-star { font-size: 1.5rem; }
.template-stars-md .template-star { font-size: 1.1rem; }
.template-star-full, .template-star-half { color: #f59e0b; }
.template-star-empty { color: #d1d5db; }
.meta-pill.meta-rating { color: #b45309; background: #fffbeb; }
.guide-header-rating { display: inline-block; margin-top: .75rem; }
.hidden { display: none !important; }
.hp-field {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

/* Responsive */
@media (max-width: 1100px) {
    .site-nav a { font-size: .82rem; }
    .header-search input { width: 9rem; }
}

@media (max-width: 900px) {
    .hero-inner, .template-hero-inner, .layout-with-sidebar { grid-template-columns: 1fr; }
    .sidebar { position: static; }

    .header-inner {
        display: block;
        padding: .5rem 0;
    }
    .header-bar {
        display: flex;
        align-items: center;
        gap: .5rem;
    }
    .logo { flex: 1; min-width: 0; }
    .logo-tagline { display: none; }
    .nav-toggle {
        display: flex;
        margin-left: auto;
    }

    .header-panel {
        display: none;
        flex: none;
        flex-direction: column;
        align-items: stretch;
        padding-top: .5rem;
    }
    .header-panel.is-open {
        display: flex;
        border-top: 1px solid var(--border);
        margin-top: .5rem;
        padding-top: .75rem;
    }
    .site-nav {
        flex: none;
        flex-direction: column;
        align-items: stretch;
        justify-content: flex-start;
        gap: 0;
    }
    .site-nav a {
        padding: .65rem 0;
        border-bottom: 1px solid var(--border);
        white-space: normal;
    }
    .nav-dropdown {
        width: 100%;
        display: flex;
        flex-direction: column;
        align-items: stretch;
    }
    .nav-dropdown::after { display: none; }
    .nav-dropdown:hover .nav-dropdown-menu,
    .nav-dropdown:focus-within .nav-dropdown-menu { display: none; }
    .nav-dropdown-toggle {
        width: 100%;
        justify-content: space-between;
        padding: .65rem 0;
        border-bottom: 1px solid var(--border);
        text-align: left;
    }
    .nav-dropdown-menu {
        position: static;
        transform: none;
        display: none;
        width: 100%;
        min-width: 0;
        margin: 0;
        padding: 0 0 .35rem;
        border: none;
        border-radius: 0;
        box-shadow: none;
        background: transparent;
    }
    .nav-dropdown.is-open .nav-dropdown-menu { display: block; }
    .nav-dropdown-menu li { border-bottom: 1px solid var(--border); }
    .nav-dropdown-menu li:last-child { border-bottom: none; }
    .nav-dropdown-menu a {
        padding: .55rem 0 .55rem 1rem;
        font-size: .9rem;
        font-weight: 400;
        color: var(--text-muted);
    }
    .nav-dropdown-menu a:hover { background: transparent; }
    .site-nav > a:last-child { border-bottom: none; }
    .header-search {
        width: 100%;
        margin-top: .75rem;
    }
    .header-search input { flex: 1; width: auto; min-width: 0; }
}

/* Cookie consent (RODO / Consent Mode v2) */
html.cookie-consent-open { overflow: hidden; }
.cookie-consent {
    position: fixed;
    inset: 0;
    z-index: 1100;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}
.cookie-consent[hidden] { display: none !important; }
.cookie-consent-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(26, 35, 50, 0.55);
}
.cookie-consent-panel {
    position: relative;
    width: min(100%, 42rem);
    max-height: min(90vh, 34rem);
    overflow: auto;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 1.25rem 1.35rem 1.35rem;
}
.cookie-consent-title {
    margin: 0 0 .5rem;
    font-family: var(--font-display);
    font-size: 1.2rem;
}
.cookie-consent-intro {
    margin: 0 0 1rem;
    color: var(--text-muted);
    font-size: .92rem;
    line-height: 1.55;
}
.cookie-consent-intro a { font-weight: 600; }
.cookie-consent-settings {
    flex-direction: column;
    gap: .75rem;
    margin-bottom: 1rem;
    padding: .85rem .9rem;
    background: var(--bg-alt);
    border-radius: 10px;
}
.cookie-consent-settings:not([hidden]) {
    display: flex;
}
.cookie-consent-settings[hidden] {
    display: none !important;
}
.cookie-consent-option {
    display: flex;
    gap: .65rem;
    align-items: flex-start;
    cursor: pointer;
    font-size: .9rem;
}
.cookie-consent-option input { margin-top: .2rem; flex-shrink: 0; }
.cookie-consent-option strong { display: block; margin-bottom: .15rem; }
.cookie-consent-option small {
    display: block;
    color: var(--text-muted);
    font-size: .82rem;
    line-height: 1.4;
}
.cookie-consent-actions {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
    justify-content: flex-end;
}
.cookie-consent-btn { min-width: 7.5rem; }
@media (max-width: 540px) {
    .cookie-consent { padding: .75rem; }
    .cookie-consent-actions { flex-direction: column; }
    .cookie-consent-btn { width: 100%; min-width: 0; }
}
