/* rejestrlekow.com: a register data sheet, white and precise — no rounded corners, no ads.
   Theme colours and fonts come from registry.css custom properties (config/services-registry.php);
   the availability/vet colours below are this site's own (Ui::tokens() only carries the shared ones). */
:root {
    --otc: #1D6B43; --otc-bg: #DFF1E6;
    --rp: #1C4A84; --rp-bg: #E0E9F6;
    --rpz: #57399A; --rpz-bg: #EAE4F7;
    --rpw: #962A2A; --rpw-bg: #F6E0E0;
    --lz: #46515E; --lz-bg: #E6EBEF;
    --vet: #7A5A12; --vet-bg: #F5EDD9;

    /* a register data sheet has no rounded corners anywhere */
    --radius-lg: 0;
    --radius-md: 0;
    --radius-sm: 0;
    --radius-xs: 0;
    --display-weight: 600;

    /* the header and footer stay on the light surface, not the shared dark one */
    --header-bg: var(--card);
    --header-fg: var(--ink);
    --header-line: var(--line);
    --header-control: var(--line);
    --footer-bg: var(--card);
    --footer-fg: var(--ink);
    --footer-text: var(--text-2);
    --footer-muted: var(--caption);
    --footer-line: var(--line-soft);
    --footer-tld: var(--caption);
}

/* brand mark: a bordered monospace tile, not a filled rounded one */
.mark--tile {
    background: transparent;
    border: 2px solid var(--accent);
    color: var(--accent);
    font-family: var(--font-mono);
    font-weight: 600;
    font-size: 0.875rem;
}

.footer-brand .mark--tile {
    border-color: var(--accent);
}

.site-notice__operator { color: var(--footer-muted); font-size: 0.875rem; margin-top: 8px; }

/* the shared footer hardcodes white text for its own dark background */
.footer-brand, .footer-brand .brand__name { color: var(--footer-fg); }
.footer-col__title { font: 500 0.75rem/1.3 var(--font-mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--caption); margin-bottom: 10px; }
.site-header .brand__tld { color: var(--caption); font-weight: 400; }
.footer-brand .brand__tld,
[data-display="grotesk"] .footer-brand .brand__tld { color: var(--footer-tld); }

/* legal note: a square "+" disclosure, not the shared chevron pill */
.legal-note {
    background: var(--card);
    border: 1px solid var(--line);
}
.legal-note summary {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 16px 20px;
    cursor: pointer;
    font-weight: 600;
    list-style: none;
}
.legal-note summary::-webkit-details-marker { display: none; }
.legal-note__title { display: flex; align-items: center; gap: 10px; }
.legal-note__chevron { display: none; }
.legal-note summary::after {
    content: '+';
    margin-left: auto;
    font: 500 20px/1 var(--font-mono);
    color: var(--caption);
}
.legal-note[open] summary::after { content: '\2212'; }
.legal-note__body { padding: 0 20px 20px; display: grid; gap: 14px; }
.legal-note__intro { font-size: 0.875rem; }
.legal-note__acts { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 28px; }
.legal-note__act-title { display: block; font-size: 0.875rem; font-weight: 600; }
.legal-note__act-text { display: block; font-size: 0.875rem; color: var(--text-2); }
.legal-note__act a { font-size: 0.8125rem; }
@media (max-width: 860px) {
    .legal-note__acts { grid-template-columns: minmax(0, 1fr); }
}

/* buttons and fields, sharp-edged in place of the shared rounded ones */
.btn {
    border-radius: 0;
}

.hero__search .field {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 12px;
    height: 60px;
    padding: 0 8px 0 18px;
    background: var(--card);
    border: 2px solid var(--ink);
    border-radius: 0;
}

.hero__search .field input {
    flex: 1;
    min-width: 0;
    border: 0;
    outline: 0;
    font: 400 18px var(--font-body);
    color: var(--ink);
    background: transparent;
}

.hero__search .field .btn {
    height: 44px;
}

.check {
    border-radius: 0;
}

.check input {
    border-radius: 0;
}

.select {
    border-radius: 0;
}

/* category chips (accessibility category and veterinary tag) */
.cat {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 2px 8px;
    font: 600 12px/1.6 var(--font-mono);
    letter-spacing: 0.02em;
    border: 1px solid currentColor;
    white-space: nowrap;
}
.cat--otc { color: var(--otc); background: var(--otc-bg); }
.cat--rp { color: var(--rp); background: var(--rp-bg); }
.cat--rpz { color: var(--rpz); background: var(--rpz-bg); }
.cat--rpw { color: var(--rpw); background: var(--rpw-bg); }
.cat--lz { color: var(--lz); background: var(--lz-bg); }
.tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 2px 8px;
    font: 500 12px/1.6 var(--font-mono);
    border: 1px solid var(--line);
    color: var(--text-2);
    background: var(--card);
}
.tag--vet { color: var(--vet); background: var(--vet-bg); border-color: currentColor; }

/* section headers */
.sec-head {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 8px 24px;
    margin-bottom: 22px;
}
.sec-head h2 { font-size: 1.75rem; font-weight: 600; }
.sec-head a { font-size: 0.9375rem; font-weight: 500; }
.panel { background: var(--card); border: 1px solid var(--line); }

/* home hero */
.hero { background: var(--card); border-bottom: 1px solid var(--line); }
.hero .wrap { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 56px; padding-block: 64px 56px; align-items: start; }
.hero h1 { font-size: 3.5rem; line-height: 1.04; font-weight: 600; letter-spacing: -0.025em; margin: 14px 0 0; }
.hero h1 span { display: block; color: var(--accent); }
.hero__sub { margin-top: 18px; max-width: 58ch; font-size: 1.125rem; color: var(--text-2); }
.hero__search { margin-top: 30px; display: grid; gap: 10px; }
.hero__hint { font: 400 13px/1.4 var(--font-mono); color: var(--caption); }
.quick { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.quick a { padding: 6px 12px; border: 1px solid var(--line); color: var(--text-2); font-size: 0.875rem; text-decoration: none; background: var(--page); }
.legend { padding: 24px; }
.legend h2 { font-size: 1.0625rem; font-weight: 600; margin-bottom: 14px; }
.legend ul { list-style: none; margin: 0; padding: 0; }
.legend li { display: grid; grid-template-columns: 58px 1fr; gap: 12px; align-items: start; padding-block: 10px; border-top: 1px solid var(--line-soft); font-size: 0.875rem; color: var(--text-2); }
.legend li .cat { justify-content: center; }
.legend__note { margin-top: 14px; font-size: 0.8125rem; color: var(--caption); }

/* ATC grid (home) */
.atc-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.atc-grid a { display: grid; gap: 10px; align-content: start; min-height: 128px; padding: 16px; background: var(--card); color: var(--ink); text-decoration: none; }
.atc-grid b { display: grid; place-items: center; width: 36px; height: 36px; background: var(--tint); color: var(--accent); font: 600 18px/1 var(--font-mono); }
.atc-grid span { font-size: 0.875rem; line-height: 1.35; }
.atc-grid small { font: 400 12px/1 var(--font-mono); color: var(--caption); }

/* substance chips, recently changed */
.subst { display: flex; flex-wrap: wrap; gap: 8px 10px; list-style: none; margin: 0; padding: 0; }
.subst a { padding: 8px 12px; background: var(--card); border: 1px solid var(--line); color: var(--ink); text-decoration: none; font-size: 0.9375rem; font-style: italic; }
.recent { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 32px; list-style: none; margin: 0; padding: 0; }
.recent a { display: flex; justify-content: space-between; gap: 16px; padding-block: 12px; border-top: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.recent .mono { color: var(--caption); font-size: 0.8125rem; }

.no-ads { display: grid; grid-template-columns: auto 1fr; gap: 18px; padding: 24px; border: 2px solid var(--ink); background: var(--card); }
.no-ads h2 { font-size: 1.25rem; font-weight: 600; }
.no-ads p { margin-top: 6px; color: var(--text-2); }

.seo { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 32px; }
.seo h2 { font-size: 1.375rem; font-weight: 600; }
.seo p + p { margin-top: 12px; }
.seo p { color: var(--text-2); max-width: 70ch; }

/* list page */
.page-title { padding-block: 28px 24px; }
.page-title h1 { font-size: 2.5rem; font-weight: 600; letter-spacing: -0.02em; margin: 0; }
.page-title p { margin-top: 8px; color: var(--text-2); max-width: 70ch; }
.list-layout { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 9fr); gap: 24px; align-items: start; }
.filters { display: grid; gap: 22px; padding: 20px; background: var(--card); border: 1px solid var(--line); }
.filters h3 { font: 500 12px/1.3 var(--font-mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--caption); margin-bottom: 10px; }
.filters .check em { margin-left: auto; font: normal 400 12px/1 var(--font-mono); color: var(--caption); }
.toolbar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; font-size: 0.875rem; color: var(--text-2); }
.toolbar select { width: auto; display: inline-block; height: 36px; }

/* result rows (shared by the list, a substance hub and a letter index) */
.rows { background: var(--card); border: 1px solid var(--line); }
.row { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2.2fr) minmax(0, 2fr) auto 120px; gap: 16px; align-items: center; padding: 14px 18px; border-top: 1px solid var(--line-soft); text-decoration: none; color: var(--ink); }
.row:first-child { border-top: 0; }
.row--head { font: 500 12px/1.3 var(--font-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--caption); background: var(--page); }
.row__name { font-weight: 600; }
.row__name small { display: block; font-weight: 400; color: var(--caption); font-size: 0.8125rem; }
.row__subst { font-style: italic; color: var(--text-2); font-size: 0.9375rem; }
.row__cats { display: flex; gap: 6px; flex-wrap: wrap; }
.row__holder { color: var(--text-2); }
.row__no { text-align: right; font: 400 13px/1 var(--font-mono); color: var(--caption); }

/* substance hub */
.hub-head { background: var(--card); border-bottom: 1px solid var(--line); }
.hub-head .wrap { padding-block: 22px 36px; }
.hub-head h1 { margin-top: 12px; font-size: 3.25rem; font-weight: 600; font-style: italic; letter-spacing: -0.02em; }
.facts { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); margin-top: 26px; }
.facts > div { background: var(--card); padding: 14px 16px; display: flex; flex-direction: column-reverse; gap: 4px; }
.facts dt { font-size: 0.8125rem; color: var(--caption); }
.facts dd { margin: 0; font: 600 26px/1 var(--font-mono); color: var(--ink); }

/* rules ("Zasady serwisu") */
.rules { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 8fr); gap: 48px; align-items: start; }
.rules .toc { position: sticky; top: 16px; display: grid; gap: 2px; font-size: 0.875rem; list-style: none; margin: 0; padding: 0; }
.rules .toc a { display: block; padding: 8px 0; border-top: 1px solid var(--line-soft); color: var(--text-2); text-decoration: none; }
.rule { padding-block: 22px; border-top: 2px solid var(--ink); }
.rule h2 { font-size: 1.375rem; font-weight: 600; }
.rule p { margin-top: 10px; color: var(--text-2); max-width: 68ch; }
.gloss { display: grid; gap: 0; margin-top: 14px; }
.gloss > div { display: grid; grid-template-columns: 70px 1fr; gap: 14px; padding-block: 10px; border-top: 1px solid var(--line-soft); font-size: 0.9375rem; }
.prov { padding: 16px 20px; border: 1px dashed var(--line); font-size: 0.875rem; color: var(--text-2); background: var(--card); }

@media (max-width: 1080px) {
    .atc-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .facts { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 860px) {
    .hero .wrap, .seo, .rules { grid-template-columns: minmax(0, 1fr); gap: 24px; }
    .hero .wrap { padding-block: 32px 28px; }
    .hero h1 { font-size: 2.25rem; }
    .hero__sub { font-size: 1rem; }
    .hero__search .field { height: 54px; }
    .hero__search .field input { font-size: 16px; }
    .atc-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .atc-grid a { min-height: 104px; }
    .recent { grid-template-columns: minmax(0, 1fr); }
    .list-layout { grid-template-columns: minmax(0, 1fr); }
    .row { grid-template-columns: minmax(0, 1fr) auto; gap: 6px 12px; }
    .row--head { display: none; }
    .row__subst, .row__holder { grid-column: 1 / -1; }
    .row__no { display: none; }
    .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .hub-head h1 { font-size: 2.25rem; }
    .rules .toc { position: static; }
    .filters { display: none; }
}

.small { font-size: 0.875rem; }
