/* Simplyo – veřejný web. Hodnoty odpovídají prototypu (simplyo.cz – úvodní stránka).
   --brand a --accent se nastavují v administraci (Nastavení → Vzhled). */

:root {
    --brand: #14233C;
    --accent: #0B7A7A;
    --ink: #14233C;
    --text: #3F4B5C;
    --muted: #5A6575;
    --line: #E2E7EE;
    --line-strong: #D5DBE4;
    --input: #C3CBD6;
    --light: #F3F5F8;
    --on-brand-muted: #C9D3E1;
    --on-brand-accent: #5CD6CF;
    --label: #8A3B12;
    --danger: #B42318;
    --footer: #0E1A2D;
}

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

html { scroll-behavior: smooth; }

body {
    margin: 0;
    font-family: 'Sora', system-ui, sans-serif;
    color: var(--ink);
    background: #FFFFFF;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

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

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

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

[id] { scroll-margin-top: 16px; }

.visually-hidden {
    position: absolute !important;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0, 0, 0, 0);
    white-space: nowrap; border: 0;
}

.skip-link {
    position: absolute; left: 16px; top: -48px;
    background: var(--brand); color: #FFFFFF;
    padding: 10px 16px; border-radius: 10px; z-index: 10;
}
.skip-link:focus { top: 12px; color: #FFFFFF; }

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding-left: 24px;
    padding-right: 24px;
}

.muted { color: var(--muted); }

/* ---------- Tlačítka ---------- */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 52px;
    padding: 0 26px;
    border-radius: 12px;
    border: none;
    font: inherit;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: filter .15s ease, background-color .15s ease;
}
.btn:hover { filter: brightness(1.15); }
.btn:disabled { opacity: .6; cursor: default; }
.btn-sm { min-height: 44px; padding: 0 20px; border-radius: 10px; }

.btn-primary, .btn-primary:hover { background: var(--brand); color: #FFFFFF; }
.btn-accent, .btn-accent:hover { background: var(--accent); color: #FFFFFF; font-weight: 700; }
.btn-outline, .btn-outline:hover { border: 1.5px solid var(--ink); color: var(--ink); background: transparent; }
.btn-outline:hover { background: rgba(20, 35, 60, .05); filter: none; }

.bg-brand .btn-primary { background: var(--accent); }
.bg-brand .btn-outline { border-color: #FFFFFF; color: #FFFFFF; }

.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

.text-link { font-weight: 600; }
.bg-brand .text-link { color: var(--on-brand-accent); }

/* ---------- Hlavička ---------- */

.site-header { border-bottom: 1px solid var(--line); background: #FFFFFF; }
.site-header .container {
    padding-top: 18px;
    padding-bottom: 18px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.logo {
    display: flex;
    align-items: baseline;
    font-size: 30px;
    font-weight: 700;
    letter-spacing: -0.03em;
    line-height: 1;
    color: var(--ink);
    text-decoration: none;
}
.logo:hover { color: var(--ink); }
.logo svg { margin-right: 1px; }
.logo .logo-o { color: var(--accent); }
.logo-img { max-height: 40px; width: auto; display: block; }

.main-nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 28px;
    font-size: 15px;
}
.main-nav a:not(.btn) { color: var(--ink); text-decoration: none; }
.main-nav a:not(.btn):hover { color: var(--accent); }

.nav-toggle {
    display: none;
    width: 44px; height: 44px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #FFFFFF;
    cursor: pointer;
    align-items: center;
    justify-content: center;
}
.nav-toggle-bar, .nav-toggle-bar::before, .nav-toggle-bar::after {
    display: block;
    width: 20px; height: 2px;
    background: var(--ink);
    border-radius: 2px;
    position: relative;
}
.nav-toggle-bar::before, .nav-toggle-bar::after { content: ""; position: absolute; left: 0; }
.nav-toggle-bar::before { top: -6px; }
.nav-toggle-bar::after { top: 6px; }

/* ---------- Sekce ---------- */

.section { padding: 96px 0; }
.section-compact { padding: 72px 0; }
.bg-white { background: #FFFFFF; }
.bg-light { background: var(--light); }
.bg-brand { background: var(--brand); color: #FFFFFF; }

.section-stack { display: flex; flex-direction: column; gap: 40px; }

.section-head { display: flex; flex-direction: column; gap: 12px; max-width: 720px; }

.eyebrow {
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--accent);
}
.bg-brand .eyebrow { color: var(--on-brand-accent); }

.section-title {
    margin: 0;
    font-size: 38px;
    line-height: 1.15;
    letter-spacing: -0.02em;
}

.lead { margin: 0; font-size: 18px; color: var(--text); }
.bg-brand .lead { color: var(--on-brand-muted); }

.grid { display: grid; gap: 20px; }
.grid-280 { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.grid-300 { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }

/* Hero */

.hero .container {
    padding-top: 88px;
    padding-bottom: 96px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 56px;
}
.hero-text { flex: 1 1 480px; min-width: 0; display: flex; flex-direction: column; gap: 24px; }
.hero h1 {
    margin: 0;
    font-size: 56px;
    line-height: 1.08;
    letter-spacing: -0.03em;
    font-weight: 700;
}
.hero-lead { margin: 0; font-size: 19px; color: var(--text); max-width: 560px; }
.bg-brand .hero-lead { color: var(--on-brand-muted); }

.flow-card {
    flex: 1 1 420px;
    min-width: 0;
    background: #FFFFFF;
    color: var(--ink);
    border-radius: 20px;
    padding: 32px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    border: 1px solid var(--line);
}
.flow-card-title {
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--muted);
}
.flow { display: flex; flex-wrap: wrap; align-items: stretch; gap: 12px; }
.flow-box {
    flex: 1 1 140px;
    border-radius: 14px;
    background: var(--light);
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.flow-box.is-target { background: var(--brand); color: #FFFFFF; }
.flow-box-title { font-size: 18px; font-weight: 700; }
.flow-box-text { font-size: 14px; color: var(--muted); }
.flow-box.is-target .flow-box-text { color: var(--on-brand-muted); }
.flow-lines {
    flex: 1 1 120px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 8px;
    font-size: 13px;
    color: var(--text);
}
.flow-line { display: flex; align-items: center; gap: 8px; }
.flow-line .bar { flex-grow: 1; height: 3px; border-radius: 2px; background: var(--brand); }
.flow-line.forward .bar { background: var(--accent); }
.flow-note { font-size: 14px; color: var(--muted); }

/* Karty problém → řešení */

.card {
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 28px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    background: #FFFFFF;
    color: var(--ink);
}
.card-label { font-size: 14px; font-weight: 600; color: var(--label); }
.card-title { font-size: 20px; font-weight: 700; }
.card-text { font-size: 15px; color: var(--text); }
.card-text strong { color: var(--accent); }

/* Dlaždice s ikonami */

.tile {
    background: #FFFFFF;
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 28px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    color: inherit;
    text-decoration: none;
}
.tile-icon { color: var(--accent); display: flex; }
.tile-title { font-size: 19px; font-weight: 700; }
.tile-text { font-size: 15px; color: var(--text); }
.bg-brand .tile { background: rgba(255, 255, 255, 0.06); border-color: rgba(255, 255, 255, 0.14); }
.bg-brand .tile-icon { color: var(--on-brand-accent); }
.bg-brand .tile-text { color: var(--on-brand-muted); }
a.tile:hover { color: inherit; border-color: var(--accent); }
.bg-brand a.tile:hover { color: #FFFFFF; border-color: var(--on-brand-accent); }

/* Rozšíření – štítky */

.split { display: flex; flex-wrap: wrap; align-items: center; gap: 48px; }
.split > * { flex: 1 1 440px; min-width: 0; }
.split-text { display: flex; flex-direction: column; gap: 16px; align-items: flex-start; }

.tags { display: flex; flex-wrap: wrap; gap: 10px; align-content: flex-start; }
.tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border-radius: 999px;
    background: #FFFFFF;
    border: 1px solid var(--line-strong);
    font-size: 15px;
    color: var(--ink);
    text-decoration: none;
}
.tag:hover { border-color: var(--accent); color: var(--accent); }
.tag.is-active { background: var(--brand); border-color: var(--brand); color: #FFFFFF; }
.tag-count { font-size: 12px; font-weight: 600; color: var(--muted); }
.tag.is-active .tag-count { color: var(--on-brand-muted); }

/* Kroky */

.steps {
    margin: 0;
    padding: 0;
    list-style: none;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 20px;
}
.step {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding-top: 20px;
    border-top: 3px solid var(--accent);
}
.step-num { font-size: 14px; font-weight: 700; color: var(--accent); }
.bg-brand .step-num { color: var(--on-brand-accent); }
.bg-brand .step { border-top-color: var(--on-brand-accent); }
.step-title { font-size: 19px; font-weight: 700; }
.step-text { font-size: 15px; color: var(--text); }
.bg-brand .step-text { color: var(--on-brand-muted); }

/* Informační karty */

.info-cards { display: flex; flex-wrap: wrap; gap: 20px; }
.info-card {
    flex: 1 1 360px;
    min-width: 0;
    background: #FFFFFF;
    color: var(--ink);
    border-radius: 16px;
    padding: 32px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.bg-white .info-card { border: 1px solid var(--line); }
.info-card h3 { margin: 0; font-size: 22px; }
.info-card-value { font-size: 30px; font-weight: 700; letter-spacing: -0.02em; }
.info-card-value small { font-size: 16px; font-weight: 400; letter-spacing: 0; color: var(--muted); }
.info-card-text { font-size: 16px; color: var(--text); }
.info-card-text p { margin: 0 0 8px; }
.info-card-text p:last-child { margin-bottom: 0; }
.info-card-text ul { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 6px; }

/* Textový blok */

.prose { font-size: 17px; color: var(--text); max-width: 760px; }
.prose > :first-child { margin-top: 0; }
.prose > :last-child { margin-bottom: 0; }
.prose h2, .prose h3 { color: var(--ink); letter-spacing: -0.01em; }
.bg-brand .prose { color: var(--on-brand-muted); }
.bg-brand .prose h2, .bg-brand .prose h3 { color: #FFFFFF; }
.bg-brand .prose a { color: var(--on-brand-accent); }

/* Kontakt */

.contact .container { display: flex; flex-wrap: wrap; gap: 48px; }
.contact-text { flex: 1 1 380px; min-width: 0; display: flex; flex-direction: column; gap: 16px; }
.contact-info { font-size: 16px; color: var(--text); }
.bg-brand .contact-info { color: var(--on-brand-muted); }
.contact-info a { color: inherit; }
.bg-brand .contact-info a:hover { color: #FFFFFF; }

.contact-form {
    flex: 1 1 440px;
    min-width: 0;
    background: #FFFFFF;
    color: var(--ink);
    border-radius: 20px;
    padding: 32px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    align-content: start;
}
.bg-white .contact-form { border: 1px solid var(--line); }

.field { display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-weight: 600; }
.field-full { grid-column: 1 / -1; }
.field input, .field textarea {
    min-height: 46px;
    border: 1px solid var(--input);
    border-radius: 10px;
    padding: 0 12px;
    font: inherit;
    font-weight: 400;
    color: var(--ink);
    background: #FFFFFF;
}
.field textarea { padding: 10px 12px; resize: vertical; }
.field input:focus, .field textarea:focus { outline: 2px solid var(--accent); outline-offset: 0; border-color: var(--accent); }
.field [aria-invalid="true"] { border-color: var(--danger); }
.field-error { color: var(--danger); font-size: 13px; font-weight: 500; }

.form-alert {
    padding: 12px 14px;
    border-radius: 10px;
    background: #FEF3F2;
    color: var(--danger);
    font-size: 14px;
    font-weight: 600;
}
.form-consent { grid-column: 1 / -1; margin: 0; font-size: 13px; color: var(--muted); }

.form-done {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 12px;
    min-height: 260px;
    color: var(--ink);
}
.form-done svg { color: var(--accent); }
.form-done p { margin: 0; font-size: 18px; font-weight: 600; max-width: 380px; }

.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Patička ---------- */

.site-footer { background: var(--footer); color: var(--on-brand-muted); }
.site-footer .container {
    padding-top: 32px;
    padding-bottom: 32px;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 16px;
    font-size: 14px;
}
.footer-links { display: flex; flex-wrap: wrap; gap: 20px; }
.footer-links a { color: var(--on-brand-muted); }
.footer-links a:hover { color: #FFFFFF; }

/* ---------- Katalog rozšíření ---------- */

.page-head .container {
    padding-top: 56px;
    padding-bottom: 64px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}
.page-head .lead { max-width: 720px; }
.page-title {
    margin: 0;
    font-size: 46px;
    line-height: 1.1;
    letter-spacing: -0.03em;
}
.breadcrumbs { display: flex; flex-wrap: wrap; gap: 8px; font-size: 14px; color: var(--muted); }
.breadcrumbs a { color: var(--muted); }
.breadcrumbs a:hover { color: var(--accent); }

.catalog-search { display: flex; flex-wrap: wrap; gap: 10px; max-width: 560px; margin-top: 8px; }
.catalog-search input {
    flex: 1 1 260px;
    min-height: 44px;
    border: 1px solid var(--input);
    border-radius: 10px;
    padding: 0 14px;
    font: inherit;
    color: var(--ink);
    background: #FFFFFF;
}

.plugin-card {
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    background: #FFFFFF;
    color: var(--ink);
    text-decoration: none;
    transition: border-color .15s ease, box-shadow .15s ease;
}
.plugin-card:hover { color: var(--ink); border-color: var(--accent); box-shadow: 0 6px 24px rgba(20, 35, 60, .08); }
.plugin-card-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 8px; }
.plugin-card-img { max-height: 48px; width: auto; border-radius: 8px; }
.plugin-card-cat { font-size: 13px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }
.plugin-card-title { font-size: 19px; font-weight: 700; }
.plugin-card-text { font-size: 15px; color: var(--text); flex-grow: 1; }
.plugin-card-more { font-size: 14px; font-weight: 600; color: var(--accent); margin-top: 8px; }

.plugin-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px; height: 52px;
    border-radius: 14px;
    background: var(--light);
    color: var(--accent);
    flex-shrink: 0;
}
.plugin-icon-lg { width: 72px; height: 72px; border-radius: 18px; background: #FFFFFF; border: 1px solid var(--line); }

.badges { display: flex; flex-wrap: wrap; gap: 6px; }
.badge {
    display: inline-flex;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    background: var(--brand);
    color: #FFFFFF;
}
.badge-new { background: var(--accent); }
.badge-muted { background: #FFFFFF; color: var(--ink); border: 1px solid var(--line-strong); }

.plugin-head { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.plugin-head .badges { margin-top: 10px; }

.plugin-detail { display: flex; flex-wrap: wrap; gap: 48px; align-items: flex-start; }
.plugin-main { flex: 1 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 24px; }
.plugin-aside { flex: 0 1 340px; min-width: 0; position: sticky; top: 24px; }
.plugin-image { align-self: flex-start; max-height: 480px; object-fit: contain; border-radius: 16px; border: 1px solid var(--line); }
.h3 { margin: 0; font-size: 22px; }
.check-list { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 10px; font-size: 16px; color: var(--text); }
.check-list li { display: flex; gap: 10px; align-items: flex-start; }
.check-list svg { color: var(--accent); flex-shrink: 0; margin-top: 2px; }

.aside-card {
    background: var(--light);
    border-radius: 16px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}
.aside-row { display: flex; justify-content: space-between; gap: 12px; font-size: 15px; }
.aside-row span { color: var(--muted); }

.cta { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; }

.empty {
    border: 1px dashed var(--line-strong);
    border-radius: 16px;
    padding: 48px 24px;
    text-align: center;
    color: var(--text);
}
.empty p { margin: 0 0 8px; }

.error-page { min-height: 50vh; }

/* ---------- Responzivita ---------- */

@media (max-width: 960px) {
    .nav-toggle { display: inline-flex; }
    .main-nav {
        display: none;
        width: 100%;
        flex-direction: column;
        align-items: stretch;
        gap: 4px;
        padding-top: 8px;
    }
    .main-nav.is-open { display: flex; }
    .main-nav a:not(.btn) { padding: 10px 0; border-bottom: 1px solid var(--line); }
    .main-nav .btn { margin-top: 8px; }
    .no-js .main-nav { display: flex; }
    .no-js .nav-toggle { display: none; }
    .plugin-aside { position: static; flex-basis: 100%; }
}

@media (max-width: 640px) {
    .container { padding-left: 16px; padding-right: 16px; }
    .section { padding: 64px 0; }
    .section-compact { padding: 48px 0; }
    .hero .container { padding-top: 48px; padding-bottom: 64px; gap: 40px; }
    .hero h1 { font-size: 38px; }
    .hero-lead { font-size: 17px; }
    .section-title { font-size: 30px; }
    .page-title { font-size: 34px; }
    .lead { font-size: 17px; }
    .flow-card, .contact-form, .info-card { padding: 24px; }
    .card, .tile { padding: 24px; }
    .logo { font-size: 26px; }
    .grid-280, .grid-300 { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    * { transition: none !important; }
}
