/* =========================================================
   Семяныч — минималистичная тема (RstRss)
   ========================================================= */

:root {
    --bg: #ffffff;
    --bg-soft: #f7f8f9;
    --bg-row: #fafbfc;
    --border: #e6e8ec;
    --border-soft: #eef0f3;
    --text: #1a1f2c;
    --text-muted: #6b7280;
    --text-dim: #94a0b1;
    --accent: #dd662e;
    --accent-dark: #b94f1e;
    --accent-soft: #fff4ec;
    --green: #74b908;
    --cyan: #00b8e9;
    --sale: #e23131;
    --sale-soft: #ffe9e9;
    --shadow-sm: 0 1px 2px rgba(15, 23, 42, .04);
    --shadow-md: 0 4px 12px rgba(15, 23, 42, .06);
    --radius: 6px;
    --radius-lg: 10px;
    --sidebar-w: 260px;
    --container-max: 1320px;
    --font-base: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
}

* { box-sizing: border-box; }

html, body {
    margin: 0;
    padding: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-base);
    font-size: 15px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

a { color: var(--text); text-decoration: none; }
a:hover { color: var(--accent); }

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

button { font: inherit; color: inherit; cursor: pointer; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

/* ---------- HEADER ---------- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
}

.site-header__inner {
    max-width: var(--container-max);
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 14px 24px;
}

.site-header__logo {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}
.site-header__logo img { height: 34px; width: auto; }

.site-nav {
    display: flex;
    align-items: center;
    gap: 28px;
}
.site-nav a {
    font-size: 14px;
    font-weight: 500;
    color: var(--text);
    padding: 6px 0;
    border-bottom: 2px solid transparent;
    transition: color .15s ease, border-color .15s ease;
}
.site-nav a:hover { color: var(--accent); }
.site-nav a.is-active { color: var(--accent); border-bottom-color: var(--accent); }

.site-header__tg {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    color: var(--text-muted);
}
.site-header__tg:hover { color: var(--accent); }

.nav-toggle {
    display: none;
    background: none;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    width: 40px;
    height: 40px;
    align-items: center;
    justify-content: center;
}
.nav-toggle span,
.nav-toggle span::before,
.nav-toggle span::after {
    content: "";
    display: block;
    width: 20px;
    height: 2px;
    background: var(--text);
    position: relative;
    transition: transform .2s ease;
}
.nav-toggle span::before { position: absolute; top: -6px; left: 0; }
.nav-toggle span::after  { position: absolute; top:  6px; left: 0; }

/* ---------- MIRROR BANNER ---------- */
.mirror-banner {
    background: var(--accent-soft);
    border-bottom: 1px solid var(--border-soft);
    color: var(--accent-dark);
}
.mirror-banner__inner {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 10px 24px;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.4;
    text-align: center;
}

/* ---------- LAYOUT ---------- */
.page {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 24px;
    display: grid;
    grid-template-columns: var(--sidebar-w) minmax(0, 1fr);
    gap: 28px;
}

.page--single {
    grid-template-columns: minmax(0, 1fr);
    max-width: 920px;
}

/* ---------- SIDEBAR ---------- */
.sidebar {
    align-self: start;
    position: sticky;
    top: 72px;
    max-height: calc(100vh - 88px);
    overflow-y: auto;
    padding-right: 6px;
}
.sidebar::-webkit-scrollbar { width: 6px; }
.sidebar::-webkit-scrollbar-thumb { background: #d0d4db; border-radius: 3px; }

.sidebar__title {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: var(--text-dim);
    margin: 18px 0 8px;
}

.sidebar__list {
    list-style: none;
    margin: 0 0 12px;
    padding: 0;
}
.sidebar__list li { margin: 0; }

.sidebar__link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 7px 10px;
    border-radius: var(--radius);
    color: var(--text);
    font-size: 14px;
    line-height: 1.3;
    cursor: pointer;
    transition: background .12s ease, color .12s ease;
}
.sidebar__link:hover {
    background: var(--bg-soft);
    color: var(--accent);
}
.sidebar__link.is-active {
    background: var(--accent-soft);
    color: var(--accent);
    font-weight: 600;
}

.sidebar__divider {
    border: 0;
    border-top: 1px solid var(--border);
    margin: 16px 0;
}

.seedbank-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 10px;
    border-radius: var(--radius);
    color: var(--text);
    font-size: 14px;
    line-height: 1.25;
    cursor: pointer;
}
.seedbank-link:hover { background: var(--bg-soft); color: var(--accent); }
.seedbank-link.is-active { background: var(--accent-soft); color: var(--accent); font-weight: 600; }

.seedbank-link__logo {
    width: 28px;
    height: 28px;
    border-radius: 4px;
    object-fit: contain;
    background: #fff;
    flex-shrink: 0;
    border: 1px solid var(--border-soft);
}

.seedbank-link__name { flex: 1 1 auto; min-width: 0; word-wrap: break-word; }

.sale-badge {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    background: var(--sale-soft);
    color: var(--sale);
    border-radius: 50%;
    font-size: 11px;
    font-weight: 700;
    line-height: 1;
}
.sale-badge::before { content: "%"; }

/* ---------- MAIN ---------- */
.main {
    min-width: 0;
}

.crumbs {
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 12px;
}
.crumbs a { color: var(--text-muted); }
.crumbs a:hover { color: var(--accent); }
.crumbs__sep { margin: 0 6px; color: var(--text-dim); }

.h1 {
    font-size: 26px;
    font-weight: 700;
    margin: 0 0 18px;
    line-height: 1.2;
}

.toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: var(--bg-soft);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-lg);
    margin-bottom: 16px;
}

.tabs {
    display: flex;
    flex-wrap: nowrap;
    gap: 4px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 3px;
    min-width: 0;
    max-width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}
.tabs::-webkit-scrollbar { display: none; }
.tabs__btn {
    flex-shrink: 0;
    white-space: nowrap;
    border: 0;
    background: transparent;
    padding: 6px 14px;
    border-radius: 999px;
    font-size: 13px;
    color: var(--text-muted);
    transition: background .12s ease, color .12s ease;
}
.tabs__btn:hover { color: var(--accent); }
.tabs__btn.is-active {
    background: var(--accent);
    color: #fff;
    font-weight: 600;
}

.sort {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    max-width: 100%;
    flex-shrink: 1;
}
.sort label { flex-shrink: 0; }
.sort select { min-width: 0; flex: 0 1 auto; max-width: 100%; }
.sort label {
    font-size: 13px;
    color: var(--text-muted);
}
.sort select {
    appearance: none;
    -webkit-appearance: none;
    padding: 7px 30px 7px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: #fff
        url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'><path d='M2 4l4 4 4-4' fill='none' stroke='%23555' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/></svg>")
        no-repeat right 10px center;
    background-size: 10px 10px;
    font-size: 13px;
    color: var(--text);
}

.summary {
    font-size: 13px;
    color: var(--text-muted);
    margin: 0 0 12px;
}

/* ---------- PRODUCT LIST ---------- */
.product-list {
    display: flex;
    flex-direction: column;
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-lg);
    overflow: hidden;
    background: #fff;
}

.product {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 16px;
    align-items: center;
    padding: 14px 18px;
    border-bottom: 1px solid var(--border-soft);
    transition: background .12s ease;
}
.product:last-child { border-bottom: 0; }
.product:nth-child(odd) { background: var(--bg-row); }
.product:hover { background: var(--accent-soft); }

.product__info { min-width: 0; }
.product__name {
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
    line-height: 1.3;
    word-wrap: break-word;
}
.product__meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 10px;
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 4px;
}
.product__seedbank {
    color: var(--accent);
    cursor: pointer;
}
.product__seedbank:hover { text-decoration: underline; }

.tag {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 999px;
    background: var(--bg-soft);
    border: 1px solid var(--border-soft);
    font-size: 11px;
    font-weight: 500;
    color: var(--text-muted);
    line-height: 1.5;
}
.tag--auto { color: #2a8e3c; background: #e7f6ea; border-color: #d3eed8; }
.tag--fem  { color: #c44a83; background: #fdeaf2; border-color: #f6d6e3; }
.tag--reg  { color: #5f6b85; background: #eef1f8; border-color: #dde2ec; }
.tag--sale { color: var(--sale); background: var(--sale-soft); border-color: #f6cccc; }

.product__control {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-shrink: 0;
}

.product__price {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    line-height: 1.2;
}
.product__price-label {
    font-size: 11px;
    color: var(--text-dim);
}
.product__price-value {
    font-size: 16px;
    font-weight: 700;
    color: var(--text);
    white-space: nowrap;
}
.product__price-value .rub { font-weight: 500; color: var(--text-muted); }

a.buy-btn,
a.buy-btn:link,
a.buy-btn:visited,
a.buy-btn:hover,
a.buy-btn:focus,
a.buy-btn:active,
.buy-btn {
    color: #fff;
    text-decoration: none;
}
.buy-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 18px;
    border-radius: 999px;
    background: var(--accent-dark);
    border: 0;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .01em;
    line-height: 1;
    white-space: nowrap;
    transition: background .15s ease, transform .15s ease;
    text-shadow: 0 1px 1px rgba(0, 0, 0, .18);
}
.buy-btn:hover,
.buy-btn:focus { background: #8e3a14; }
.buy-btn:active { transform: translateY(1px); }
.buy-btn svg { width: 14px; height: 14px; color: #fff; }

/* ---------- PAGINATION ---------- */
.pagination {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px;
    margin: 22px 0;
}
.pagination__btn {
    min-width: 36px;
    height: 36px;
    padding: 0 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--text);
    font-size: 13px;
    font-weight: 500;
}
.pagination__btn:hover:not(:disabled):not(.is-active) {
    border-color: var(--accent);
    color: var(--accent);
}
.pagination__btn.is-active {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}
.pagination__btn:disabled {
    opacity: .4;
    cursor: not-allowed;
}
.pagination__gap {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    color: var(--text-dim);
}

.no-results {
    padding: 40px 20px;
    text-align: center;
    color: var(--text-muted);
    background: #fff;
    border: 1px dashed var(--border);
    border-radius: var(--radius-lg);
}

/* ---------- FOOTER ---------- */
.site-footer {
    margin-top: 40px;
    background: var(--bg-soft);
    border-top: 1px solid var(--border);
    padding: 28px 24px 32px;
}
.site-footer__inner {
    max-width: var(--container-max);
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    align-items: center;
    justify-content: space-between;
}
.site-footer__nav {
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
}
.site-footer__nav a {
    font-size: 14px;
    color: var(--text-muted);
}
.site-footer__nav a:hover { color: var(--accent); }
.site-footer__copy {
    font-size: 13px;
    color: var(--text-dim);
}
.site-footer__tg {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--text-muted);
    font-size: 14px;
}
.site-footer__tg:hover { color: var(--accent); }

/* ---------- CONTENT PAGES (Help / Contacts) ---------- */
.content {
    background: #fff;
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-lg);
    padding: 28px 32px;
}
.content h2 {
    font-size: 20px;
    margin: 28px 0 10px;
    color: var(--text);
}
.content h2:first-child { margin-top: 0; }
.content h3 {
    font-size: 16px;
    margin: 18px 0 6px;
    color: var(--text);
}
.content p { margin: 0 0 12px; color: var(--text); }
.content ul { margin: 0 0 14px; padding-left: 20px; }
.content li { margin: 4px 0; }
.content a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
.content a:hover { color: var(--accent-dark); }

/* ---------- CTA block ---------- */
.cta {
    margin: 22px 0;
    padding: 22px 26px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 22px;
    background: linear-gradient(135deg, var(--accent-soft) 0%, #fffaf6 100%);
    border: 1px solid #f4d4be;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
}
.cta__content { flex: 1 1 auto; min-width: 0; }
.cta__title {
    margin: 0 0 6px;
    font-size: 18px;
    font-weight: 700;
    color: var(--text);
    line-height: 1.3;
}
.cta__text {
    margin: 0;
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.5;
}
a.cta__btn,
a.cta__btn:link,
a.cta__btn:visited,
a.cta__btn:hover,
a.cta__btn:focus,
a.cta__btn:active,
.cta__btn {
    color: #fff;
    text-decoration: none;
}
.cta__btn {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 13px 26px;
    border-radius: 999px;
    background: var(--accent-dark);
    font-size: 15px;
    font-weight: 700;
    letter-spacing: .01em;
    line-height: 1;
    white-space: nowrap;
    transition: background .15s ease, transform .15s ease, box-shadow .15s ease;
    box-shadow: 0 4px 14px rgba(185, 79, 30, .35);
    text-shadow: 0 1px 1px rgba(0, 0, 0, .2);
}
.cta__btn:hover,
.cta__btn:focus {
    background: #8e3a14;
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(142, 58, 20, .45);
}
.cta__btn:active { transform: translateY(0); }
.cta__btn svg { width: 16px; height: 16px; color: #fff; }

@media (max-width: 640px) {
    .cta {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
        padding: 18px;
    }
    .cta__btn { justify-content: center; padding: 13px 22px; }
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 14px;
    margin: 14px 0 20px;
}
.contact-card {
    padding: 18px;
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-lg);
    background: var(--bg-soft);
}
.contact-card__label {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--text-dim);
    margin-bottom: 6px;
}
.contact-card__value { font-size: 15px; font-weight: 500; }
.contact-card__value a { font-weight: 500; }

/* ---------- RESPONSIVE ---------- */
@media (max-width: 1020px) {
    :root { --sidebar-w: 230px; }
    .product { padding: 12px 14px; }
}

@media (max-width: 880px) {
    .page {
        grid-template-columns: 1fr;
        gap: 18px;
        padding: 16px;
    }
    .sidebar {
        position: static;
        max-height: none;
        overflow: visible;
        border: 1px solid var(--border-soft);
        border-radius: var(--radius-lg);
        padding: 12px 14px;
        background: var(--bg-soft);
    }
    .site-nav { gap: 16px; }
    .site-header__inner { padding: 12px 16px; }
    .mirror-banner__inner { padding: 8px 16px; font-size: 13px; }
    .site-footer { padding: 24px 16px; }
    .content { padding: 22px 20px; }
}

@media (max-width: 640px) {
    body { font-size: 14px; }
    .h1 { font-size: 22px; }
    .site-header__logo img { height: 28px; }

    .nav-toggle { display: inline-flex; }
    .site-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: #fff;
        border-bottom: 1px solid var(--border);
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        padding: 8px 16px 14px;
        box-shadow: var(--shadow-md);
    }
    .site-nav.is-open { display: flex; }
    .site-nav a { padding: 10px 0; border-bottom: 1px solid var(--border-soft); border-bottom-width: 1px; }
    .site-nav a.is-active { border-bottom-color: var(--accent); }
    .site-header__tg { display: none; }

    .toolbar {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }
    .tabs {
        min-width: 0;
        overflow-x: auto;
        flex-wrap: nowrap;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }
    .tabs__btn { flex-shrink: 0; white-space: nowrap; }
    .tabs::-webkit-scrollbar { display: none; }

    .sort {
        min-width: 0;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 8px;
    }
    .sort label { flex-shrink: 0; }
    .sort select { min-width: 0; flex: 1 1 auto; max-width: 100%; }

    .product {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    .product__control {
        justify-content: space-between;
        gap: 10px;
    }
    .product__price { align-items: flex-start; }

    .site-footer__inner {
        flex-direction: column;
        align-items: flex-start;
        gap: 14px;
    }
}

@media (max-width: 420px) {
    .buy-btn { padding: 9px 14px; font-size: 12px; }
    .product__price-value { font-size: 15px; }
    .pagination__btn { min-width: 32px; height: 32px; padding: 0 8px; font-size: 12px; }
}
