/* ==== Reset & základ ==== */
*, *::before, *::after { box-sizing: border-box; }
html { font-size: 16px; }
body {
    margin: 0;
    font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
    line-height: 1.6;
    color: #0f172a;             /* slate-900 */
    background: #f8fafc;        /* slate-50 */
}

/* Systém farieb a rádiusy */
:root{
    --bg: #ffffff;
    --text: #0f172a;
    --muted: #475569;           /* slate-600 */
    --primary: #2563eb;         /* blue-600 */
    --primary-weak: #dbeafe;    /* blue-100 */
    --card: #ffffff;
    --ring: rgba(37, 99, 235, .25);
    --radius: 16px;
    --shadow: 0 8px 24px rgba(2, 6, 23, .08);
}

/* Dark mode podpora (automaticky podľa OS) */
@media (prefers-color-scheme: dark) {
    :root{
        --bg: #0b1220;           /* slate-950-ish */
        --text: #e5e7eb;         /* slate-200 */
        --muted: #94a3b8;        /* slate-400 */
        --primary: #60a5fa;      /* blue-400 */
        --primary-weak: #0b2549; /* tlmený modrý podklad */
        --card: #0f172a;         /* slate-900 */
        --ring: rgba(96, 165, 250, .35);
        --shadow: 0 10px 30px rgba(0,0,0,.35);
    }
    body { background: #0a0f1a; color: var(--text); }
}

/* ==== Layout kontajner ==== */
.container {
    width: min(1100px, 92vw);
    margin-inline: auto;
}

/* ==== Header / Navigácia ==== */
.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: saturate(140%) blur(8px);
    background: color-mix(in oklab, var(--bg), transparent 25%);
    border-bottom: 1px solid color-mix(in oklab, var(--text), transparent 90%);
}

.site-header .nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 0;
}

/* Logo ako jednoduchý značkový prvok */
.logo {
    display: inline-flex;
    align-items: center;
    gap: .6rem;
    text-decoration: none;
}
.logo::before{
    content: "";
    width: 34px; height: 34px;
    border-radius: 10px;
    background:
            radial-gradient(120% 120% at 80% 20%, var(--primary) 0 40%, transparent 41%),
            linear-gradient(135deg, var(--primary), color-mix(in oklab, var(--primary), black 22%));
    box-shadow: inset 0 0 0 2px color-mix(in oklab, var(--bg), transparent 85%), 0 6px 16px var(--ring);
}
.logo::after{
    content: "Domov";
    font-weight: 700;
    color: var(--text);
    letter-spacing: .2px;
}

/* Hlavná navigácia */
nav ul {
    display: flex;
    gap: clamp(.5rem, 2vw, 1.25rem);
    list-style: none;
    margin: 0; padding: 0;
}
.blocks{
    display: flex;
    gap: 20px;
}

.results{
    flex: 1;
    background: #d0dff3;
    min-height: 250px;
    color: #0a0f1a;
}

.plan{
    flex: 1;
    background: #d0dff3;
    min-height: 250px;
    color: #0a0f1a;
}
nav a{
    display: inline-block;
    padding: .55rem .9rem;
    border-radius: 12px;
    text-decoration: none;
    color: var(--text);
    font-weight: 600;
    transition: transform .15s ease, background-color .2s ease, color .2s ease;
}
nav a:hover{
    background: var(--primary-weak);
    color: var(--primary);
    transform: translateY(-1px);
}
nav a:focus-visible{
    outline: 3px solid var(--ring);
    outline-offset: 2px;
    border-radius: 14px;
}


body > div{
    width: min(1100px, 92vw);
    margin: 28px auto 64px;
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    gap: 18px;
}

@media (min-width: 640px){
    body > div{ grid-template-columns: repeat(2, 1fr); gap: 22px; }
}
@media (min-width: 920px){
    body > div{ grid-template-columns: repeat(3, 1fr); gap: 24px; }
}


body > div > section{
    background: var(--card);
    border: 1px solid color-mix(in oklab, var(--text), transparent 90%);
    border-radius: var(--radius);
    padding: 18px 18px 20px;
    box-shadow: var(--shadow);
    transition: transform .18s ease, box-shadow .2s ease, border-color .2s ease;
    position: relative;
    overflow: clip;
}


body > div > section::before{
    content: "";
    position: absolute;
    inset: 0 0 auto 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), color-mix(in oklab, var(--primary), white 25%));
    opacity: .85;
}


body > div > section:hover{
    transform: translateY(-3px);
    box-shadow: 0 14px 36px rgba(2, 6, 23, .12);
    border-color: color-mix(in oklab, var(--text), transparent 80%);
}


body > div > section > h2{
    margin: 8px 0 10px 0;
    font-size: clamp(1.05rem, 1rem + .5vw, 1.25rem);
    line-height: 1.25;
    display: flex;
    align-items: center;
    gap: .6rem;
}


body > div > section > h2::before{
    content: "";
    width: 10px; height: 10px;
    border-radius: 8px;
    background: var(--primary);
    box-shadow: 0 0 0 4px color-mix(in oklab, var(--primary), transparent 75%);
}


body > div > section{
    color: var(--muted);
    font-size: .98rem;
}


body > div > section p{ margin: .4rem 0; }

/* === Linky v obsahu (ak nejaké budú) === */
body > div > section a{
    color: var(--primary);
    text-decoration: none;
    border-bottom: 1px dotted color-mix(in oklab, var(--primary), transparent 35%);
}
body > div > section a:hover{
    border-bottom-style: solid;
}


@media (prefers-reduced-motion: reduce) {
    nav a, body > div > section { transition: none; }
}


@media print{
    .site-header { display: none; }
    body { background: #fff; color: #000; }
    body > div{
        width: 100%;
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
        margin: 0;
    }
    body > div > section{
        box-shadow: none;
        border: 1px solid #aaa;
        break-inside: avoid;
    }
}


body > div > section img{
    display: block;
    max-width: 200px;
    height: 200px;
    border-radius: 12px;
    border: 1px solid color-mix(in oklab, var(--text), transparent 90%);
    box-shadow: 0 6px 16px rgba(2, 6, 23, .06);
    transition: transform .18s ease, box-shadow .2s ease, filter .2s ease, border-color .2s ease;
    -webkit-user-drag: none;
}

/* Jemný hover efekt obrázka (kopíruje efekt karty) */
body > div > section:hover img{
    transform: translateY(-1px);
    box-shadow: 0 12px 28px rgba(2, 6, 23, .10);
    border-color: color-mix(in oklab, var(--text), transparent 82%);
}
.minutes .filters { margin: 12px 0 16px; }
.minutes-table { width: 100%; border-collapse: collapse; background: var(--card); border-radius: 12px; overflow: hidden; }
.minutes-table th, .minutes-table td { padding: 10px 12px; border-bottom: 1px solid color-mix(in oklab, var(--text), transparent 90%); text-align: left; }
.minutes-table tr:hover { background: color-mix(in oklab, var(--primary-weak), transparent 40%); }
.badge { padding: 4px 8px; border-radius: 999px; font-size: .85rem; font-weight: 700; }
.badge.ok { background: #dcfce7; }
.badge.late { background: #fee2e2; }

/*zapisnice*/
/* ===== Karta zápisnice ===== */
.note{
    width: min(900px, 92vw);
    margin: 28px auto 72px;
    background: var(--card, #ffffff);
    color: var(--text, #0f172a);
    border: 1px solid color-mix(in oklab, var(--text, #0f172a), transparent 90%);
    border-radius: var(--radius, 16px);
    padding: clamp(18px, 2.4vw, 28px);
    box-shadow: var(--shadow, 0 8px 24px rgba(2,6,23,.08));
    position: relative;
    overflow: clip;
}

/* dekoratívny prúžok hore */
.note::before{
    content:"";
    position:absolute; inset:0 0 auto 0; height:4px;
    background: linear-gradient(90deg, var(--primary, #2563eb),
    color-mix(in oklab, var(--primary, #2563eb), white 20%));
    opacity:.9;
}

.note h1{
    margin: 6px 0 14px;
    font-size: clamp(1.3rem, 1rem + 1vw, 1.8rem);
    line-height: 1.2;
}
.note h2{
    margin: 22px 0 10px;
    font-size: clamp(1.05rem, 1rem + .3vw, 1.25rem);
    border-top: 1px solid color-mix(in oklab, var(--text, #0f172a), transparent 90%);
    padding-top: 14px;
}

/* meta informácie – pekná mriežka */
.note .meta{
    list-style: none;
    margin: 0 0 12px; padding: 0;
    display: grid;
    grid-template-columns: repeat(2, minmax(0,1fr));
    gap: 8px 16px;
}
@media (max-width: 560px){ .note .meta{ grid-template-columns: 1fr; } }

.note .meta li{
    background: color-mix(in oklab, var(--primary-weak, #dbeafe), transparent 70%);
    border: 1px solid color-mix(in oklab, var(--text, #0f172a), transparent 92%);
    border-radius: 10px;
    padding: 8px 10px;
}
.note .meta strong{
    display: inline-block;
    min-width: 160px;
    font-weight: 700;
    color: var(--text, #0f172a);
}

/* texty a zoznamy */
.note p, .note li{ color: var(--muted, #475569); }
.note ol, .note ul{ margin: 8px 0 0 1.1rem; }
.note li + li{ margin-top: 4px; }

/* odkazy + prílohy */
.note a{
    color: var(--primary, #2563eb);
    text-decoration: none;
    border-bottom: 1px dotted color-mix(in oklab, var(--primary, #2563eb), transparent 35%);
}
.note a:hover{ border-bottom-style: solid; }

/* posledný zoznam (Prílohy) – sprav z odkazu “štítok” */
.note ul:last-child li a{
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    background: color-mix(in oklab, var(--primary-weak, #dbeafe), transparent 40%);
    border: 1px solid color-mix(in oklab, var(--primary, #2563eb), transparent 70%);
    border-radius: 10px;
}

/* (voliteľné) pekné badge pre stav úloh – pridaj .task + .badge do HTML nižšie */
.note .task{ list-style: none; margin-left: 0; }
.note .task .badge{
    display: inline-block;
    margin-right: .5rem;
    padding: 2px 8px;
    font-size: .85rem;
    font-weight: 700;
    border-radius: 999px;
    background: #e2e8f0;
}
.note .task .badge.ok{ background: #dcfce7; }   /* zelené OK */
.note .task .badge.fail{ background: #fee2e2; } /* červené NESPLNENÉ */


@media print{
    .site-header{ display:none; }
    body{ background:#fff; }
    .note{ box-shadow:none; border:1px solid #aaa; width:100%; margin:0; }
}


/*index*/

:root{
    --bg: #f8fafc;
    --card: #ffffff;
    --text: #0f172a;
    --muted: #475569;
    --primary: #2563eb;
    --primary-weak: #dbeafe;
    --ring: rgba(37,99,235,.25);
    --radius: 16px;
    --shadow: 0 8px 24px rgba(2,6,23,.08);
}
@media (prefers-color-scheme: dark){
    :root{
        --bg:#0b1220; --card:#0f172a; --text:#e5e7eb; --muted:#94a3b8;
        --primary:#60a5fa; --primary-weak:#0b2549; --ring:rgba(96,165,250,.35);
        --shadow: 0 10px 30px rgba(0,0,0,.35);
    }
}
body{ background:var(--bg); color:var(--text); margin:0; font-family: ui-sans-serif, system-ui, "Segoe UI", Roboto, Arial; }
.container{ width:min(1100px, 92vw); margin-inline:auto; }


.site-header{ position:sticky; top:0; z-index:10; backdrop-filter:saturate(140%) blur(8px);
    background: color-mix(in oklab, var(--bg), transparent 25%); border-bottom:1px solid color-mix(in oklab, var(--text), transparent 90%); }
.site-header .nav{ display:flex; align-items:center; justify-content:space-between; padding:14px 0; }
nav ul{ display:flex; gap:14px; list-style:none; margin:0; padding:0; }
nav a{ text-decoration:none; color:var(--text); font-weight:600; padding:.5rem .8rem; border-radius:12px; }
nav a:hover{ background:var(--primary-weak); color:var(--primary); }


.hero{ padding:28px 0 10px; }
.hero h1{ margin:.2rem 0 .3rem; font-size:clamp(1.4rem, 1.1rem + 1.2vw, 2rem); }
.hero .lead{ color:var(--muted); }


.blocks{
    display:grid; gap:22px; margin:18px 0 28px;
    grid-template-columns: 1fr; /* mobil */
}
@media (min-width: 820px){ .blocks{ grid-template-columns: 1fr 1fr; } }

.card{
    background:var(--card); border:1px solid color-mix(in oklab, var(--text), transparent 90%);
    border-radius:var(--radius); box-shadow:var(--shadow); overflow:clip;
}
.card-head{ padding:16px 18px; border-bottom:1px solid color-mix(in oklab, var(--text), transparent 90%); display:flex; align-items:baseline; justify-content:space-between; gap:12px; }
.card-head h2{ margin:0; font-size:1.1rem; }
.card-foot{ padding:12px 18px; border-top:1px solid color-mix(in oklab, var(--text), transparent 90%); }
.card .btn{ display:inline-block; text-decoration:none; padding:8px 12px; border-radius:10px; font-weight:700;
    background:var(--primary); color:white; box-shadow:0 6px 16px var(--ring); }
.card .btn:hover{ filter:brightness(1.05); transform:translateY(-1px); }
.card > *:not(.card-head):not(.card-foot){ padding: 14px 18px; }


.minutes-list{ list-style:none; margin:0; padding:0; }
.minutes-list li{
    display:grid; grid-template-columns: auto 1fr auto; gap:10px; align-items:center;
    padding:10px 0; border-bottom:1px solid color-mix(in oklab, var(--text), transparent 92%);
}
.minutes-list li:last-child{ border-bottom:none; }
.min-date{ font-variant-numeric: tabular-nums; color:var(--muted); min-width: 7ch; }
.min-link{ text-decoration:none; color:var(--text); font-weight:600; }
.min-link:hover{ color:var(--primary); }
.badge{
    padding:4px 8px; border-radius:999px; font-size:.8rem; font-weight:700;
    background:#e2e8f0; color:#0f172a;
}
.badge.ok{ background:#dcfce7; }
.badge.late{ background:#fee2e2; }


.plan-box p{ margin:.2rem 0; color:var(--muted); }
.plan-grid{ display:grid; gap:8px; }
.plan-item{ display:flex; align-items:center; gap:10px; padding:10px; border:1px dashed color-mix(in oklab, var(--text), transparent 80%); border-radius:12px; background: color-mix(in oklab, var(--primary-weak), transparent 60%); }


.status{ margin: 6px 0 64px; }
.status h2{ margin: 6px 0 14px; }
.status-cards{
    display:grid; gap:14px;
    grid-template-columns: repeat(1, minmax(0,1fr));
}
@media (min-width:680px){ .status-cards{ grid-template-columns: repeat(2, 1fr); } }
@media (min-width:980px){ .status-cards{ grid-template-columns: repeat(4, 1fr); } }

.stat{
    background:var(--card); border:1px solid color-mix(in oklab, var(--text), transparent 90%);
    border-radius:14px; padding:14px; box-shadow:var(--shadow);
}
.stat h3{ margin:.2rem 0 .4rem; font-size:1rem; }
.stat p, .stat li{ color:var(--muted); }


@media print{
    .site-header{ display:none; }
    .card, .stat{ box-shadow:none; border:1px solid #aaa; }
}
