/* tpl-product.css — product/supply page template v1.0 */

/* ===== PRICE CARD SIDEBAR ===== */
.prod-price-card {
    background: var(--dark-card, #161b22);
    border: 1px solid rgba(37,99,235,.25);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 0;
    overflow: hidden;
}
.prod-price-card__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}
.prod-price-card__title {
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .5px;
    color: #8b949e;
}
.prod-price-card__pulse {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    color: #22c55e;
}
.prod-price-card__pulse-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #22c55e;
    animation: prodPulse 2s ease-in-out infinite;
}
@keyframes prodPulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: .5; transform: scale(.8); }
}
.prod-price-card__main {
    display: flex;
    align-items: baseline;
    gap: 6px;
    margin-bottom: 4px;
}
.prod-price-card__val {
    font-size: 28px;
    font-weight: 800;
    color: #e6edf3;
    letter-spacing: -1px;
}
.prod-price-card__unit { font-size: 13px; color: #8b949e; }
.prod-price-card__date { font-size: 11px; color: #8b949e; margin-bottom: 16px; }
.prod-price-card__trend {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 20px;
    width: fit-content;
    margin-bottom: 16px;
}
.prod-price-card__trend--up { background: rgba(239,68,68,.1); color: #ef4444; }
.prod-price-card__trend--down { background: rgba(34,197,94,.1); color: #22c55e; }
.prod-price-card__trend--flat { background: rgba(139,148,158,.1); color: #8b949e; }
.prod-price-card__divider {
    height: 1px;
    background: rgba(48,54,61,.8);
    margin: 12px 0;
}
.prod-price-card__rows { display: flex; flex-direction: column; gap: 6px; }
.prod-price-card__row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
}
.prod-price-card__row-key { color: #8b949e; }
.prod-price-card__row-val { font-weight: 600; color: #e6edf3; }
.prod-price-card__loading {
    text-align: center;
    padding: 20px 0;
    font-size: 13px;
    color: #8b949e;
}
.prod-price-card__error {
    font-size: 12px;
    color: #8b949e;
    text-align: center;
    padding: 8px 0;
}

/* ===== SORTAMENT TABLES ===== */
.svc-content .sortament-table,
.page-content__inner .sortament-table,
.page-content__inner table.sortament,
.page-content__inner table {
    width: 100%;
    border-collapse: collapse;
    margin: 24px 0;
    font-size: 13px;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid #30363d;
}
.page-content__inner th {
    background: #21262d;
    padding: 10px 12px;
    text-align: left;
    font-size: 11px;
    font-weight: 700;
    color: #8b949e;
    text-transform: uppercase;
    letter-spacing: .5px;
    border-bottom: 1px solid #30363d;
    position: sticky;
    top: 0;
    z-index: 1;
}
.page-content__inner td {
    padding: 9px 12px;
    border-bottom: 1px solid rgba(48,54,61,.6);
    color: #c9d1d9;
    vertical-align: middle;
}
.page-content__inner tr:nth-child(even) td {
    background: rgba(255,255,255,.015);
}
.page-content__inner tr:last-child td { border-bottom: none; }
.page-content__inner tr:hover td {
    background: rgba(37,99,235,.04);
}

/* Scrollable table wrapper */
.page-content__inner .table-wrap {
    overflow-x: auto;
    border-radius: 8px;
    margin: 24px 0;
}
.page-content__inner .table-wrap table {
    margin: 0;
    min-width: 500px;
}

/* ===== FAQ ITEMS ===== */
.page-content__inner .faq__item,
.page-content__inner .faq__entry {
    border: 1px solid #30363d;
    border-radius: 8px;
    margin-bottom: 8px;
    overflow: hidden;
}
.page-content__inner .faq__q,
.page-content__inner .faq__question {
    padding: 14px 18px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    background: #161b22;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #e6edf3;
    transition: background .15s;
}
.page-content__inner .faq__q:hover,
.page-content__inner .faq__question:hover { background: #21262d; }
.page-content__inner .faq__a,
.page-content__inner .faq__answer {
    display: none !important;
    padding: 14px 18px;
    font-size: 14px;
    color: #8b949e;
    line-height: 1.7;
    border-top: 1px solid #30363d;
    background: #0f1318;
}

.page-content__inner .faq__item.is-open .faq__a,
.page-content__inner .faq__item.is-open .faq__answer,
.page-content__inner .faq__entry.is-open .faq__a,
.page-content__inner .faq__entry.is-open .faq__answer {
    display: block !important;
}

/* button variant: wpautop injects stray </p>, use ~ not + */
.page-content__inner .faq__item button.faq__question ~ div,
.page-content__inner .faq__entry button.faq__question ~ div {
    display: none !important;
    padding: 14px 18px;
    font-size: 14px;
    color: #8b949e;
    line-height: 1.7;
    border-top: 1px solid #30363d;
    background: #0f1318;
}

.page-content__inner .faq__item.is-open button.faq__question ~ div,
.page-content__inner .faq__entry.is-open button.faq__question ~ div {
    display: block !important;
}

/* Content headings */
.page-content__inner h2 {
    font-size: 24px;
    font-weight: 700;
    color: #e6edf3;
    margin: 40px 0 14px;
    padding-left: 14px;
    border-left: 3px solid #2563eb;
    line-height: 1.3;
}
.page-content__inner h3 {
    font-size: 18px;
    font-weight: 600;
    color: #e6edf3;
    margin: 28px 0 10px;
}
.page-content__inner p {
    font-size: 14px;
    line-height: 1.8;
    color: #c9d1d9;
    margin-bottom: 14px;
}
.page-content__inner ul, .page-content__inner ol {
    padding-left: 24px;
    margin-bottom: 16px;
}
.page-content__inner li {
    font-size: 14px;
    line-height: 1.7;
    color: #c9d1d9;
    margin-bottom: 4px;
}
.page-content__inner strong { color: #e6edf3; }

/* Spec list (ГОСТ, марки стали) */
.page-content__inner .spec-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    margin: 16px 0 24px;
    list-style: none;
    padding: 0;
}
.page-content__inner .spec-list li {
    background: #161b22;
    border: 1px solid #30363d;
    border-radius: 6px;
    padding: 10px 14px;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.page-content__inner .spec-list li::before {
    content: '';
    display: block;
    width: 6px;
    height: 6px;
    background: #2563eb;
    border-radius: 50%;
    flex-shrink: 0;
}

/* ===== PROD HERO ===== */
.prod-hero {
    background: linear-gradient(135deg, #0d1117 0%, #161b22 100%);
    border-bottom: 1px solid #21262d;
    padding: 64px 0 48px;
}
.prod-hero__inner {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
    display: grid;
    grid-template-columns: 1fr 420px;
    gap: 48px;
    align-items: center;
}
.prod-hero__label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #2563eb;
    background: rgba(37,99,235,.1);
    border: 1px solid rgba(37,99,235,.25);
    border-radius: 20px;
    padding: 5px 12px;
    margin-bottom: 18px;
}
.prod-hero__title {
    font-size: clamp(28px, 4vw, 44px);
    font-weight: 800;
    color: #e6edf3;
    line-height: 1.2;
    margin-bottom: 14px;
    letter-spacing: -.5px;
}
.prod-hero__excerpt {
    font-size: 16px;
    color: #8b949e;
    line-height: 1.7;
    margin-bottom: 28px;
    max-width: 560px;
}
.prod-hero__actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}
.prod-hero__btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 13px 24px;
    background: #2563eb;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background .2s, transform .15s;
    text-decoration: none;
}
.prod-hero__btn-primary:hover { background: #1d4ed8; transform: translateY(-1px); }
.prod-hero__btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 13px 20px;
    background: transparent;
    color: #c9d1d9;
    font-size: 14px;
    font-weight: 500;
    border: 1px solid #30363d;
    border-radius: 8px;
    text-decoration: none;
    transition: border-color .2s, color .2s;
}
.prod-hero__btn-secondary:hover { border-color: #2563eb; color: #fff; }
.prod-hero__img {
    width: 100%;
    height: 320px;
    object-fit: cover;
    border-radius: 12px;
    border: 1px solid #21262d;
}
.prod-hero__img-placeholder {
    width: 100%;
    height: 320px;
    background: #161b22;
    border: 1px solid #21262d;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 64px;
}

/* ===== PROD LAYOUT ===== */
.prod-layout {
    max-width: 1280px;
    margin: 0 auto;
    padding: 40px 24px 60px;
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 40px;
    align-items: start;
}
.prod-content { min-width: 0; }
.prod-children { margin-top: 32px; }

/* ===== PROD SIDEBAR ===== */
.prod-sidebar {
    position: sticky;
    top: 80px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}
.prod-price-card__head {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 700;
    color: #22c55e;
    margin-bottom: 16px;
    text-transform: uppercase;
    letter-spacing: .5px;
}
.prod-price-card__body { margin-bottom: 12px; }
.prod-price-card__footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 11px;
    color: #8b949e;
    border-top: 1px solid #21262d;
    padding-top: 10px;
    margin-top: 10px;
}
.prod-price-card__all { color: #2563eb; text-decoration: none; }
.prod-price-card__all:hover { text-decoration: underline; }
.prod-price-card__updated { color: #c9d1d9; }

.prod-sidebar__cta {
    background: #161b22;
    border: 1px solid #21262d;
    border-radius: 12px;
    padding: 24px;
}
.prod-sidebar__cta-title {
    font-size: 16px;
    font-weight: 700;
    color: #e6edf3;
    margin-bottom: 8px;
}
.prod-sidebar__cta-text {
    font-size: 13px;
    color: #8b949e;
    margin-bottom: 16px;
    line-height: 1.5;
}
.prod-sidebar__phone {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: rgba(37,99,235,.08);
    border: 1px solid rgba(37,99,235,.2);
    border-radius: 8px;
    color: #2563eb;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    margin-bottom: 10px;
    transition: background .2s;
}
.prod-sidebar__phone:hover { background: rgba(37,99,235,.15); }
.prod-sidebar__btn {
    width: 100%;
    padding: 12px;
    background: #2563eb;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background .2s;
}
.prod-sidebar__btn:hover { background: #1d4ed8; }

.prod-sidebar__nav-block {
    background: #161b22;
    border: 1px solid #21262d;
    border-radius: 12px;
    padding: 20px;
}
.prod-sidebar__nav-title {
    font-size: 12px;
    font-weight: 700;
    color: #8b949e;
    text-transform: uppercase;
    letter-spacing: .5px;
    margin-bottom: 12px;
}
.prod-sidebar__nav-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.prod-sidebar__nav-list a {
    display: block;
    padding: 8px 10px;
    font-size: 13px;
    color: #8b949e;
    text-decoration: none;
    border-radius: 6px;
    transition: color .15s, background .15s;
}
.prod-sidebar__nav-list a:hover,
.prod-sidebar__nav-list a.active {
    color: #e6edf3;
    background: rgba(37,99,235,.08);
}
.prod-sidebar__nav-list a.active { color: #2563eb; font-weight: 600; }

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
    .prod-hero__inner { grid-template-columns: 1fr; }
    .prod-hero__right { display: none; }
    .prod-layout { grid-template-columns: 1fr; }
    .prod-sidebar { position: static; }
}
@media (max-width: 768px) {
    .prod-hero { padding: 40px 0 32px; }
    .prod-hero__title { font-size: 28px; }
    .page-content__inner .spec-list { grid-template-columns: 1fr; }
}
