:root {
    --primary: #C8A951;
    /* Gold / Amber from label */
    --primary-dark: #b5963e;
    --accent: #C8A951;
    --bg-body: #fafaf8;
    --bg-card: #ffffff;
    --text-dark: #1a1a1a;
    --text-gray: #6b7280;
    --text-light: #9ca3af;
    --border: #e5e5e0;
    --border-light: #f5f5f0;
    --danger: #EF4444;
    --success: #10b981;

    --font-main: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --font-mono: 'Courier New', Courier, monospace;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--bg-body);
    color: var(--text-dark);
    font-family: var(--font-main);
    line-height: 1.6;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.1s;
}

ul {
    list-style: none;
}

/* --- TYPOGRAPHY --- */
.font-mono {
    font-family: var(--font-mono);
    letter-spacing: -0.5px;
}

/* --- UTILITIES --- */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.full-width {
    width: 100%;
}

.btn {
    display: inline-block;
    padding: 10px 20px;
    border-radius: 4px;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.85rem;
    cursor: pointer;
    border: none;
    font-family: var(--font-main);
    transition: all 0.2s ease;
}

.small-btn {
    padding: 8px 12px;
    font-size: 0.75rem;
}

.btn-primary {
    background-color: var(--primary);
    color: #fff;
    border: 1px solid var(--primary);
}

.btn-primary:hover {
    background-color: var(--primary-dark);
    border-color: var(--primary-dark);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--primary);
    color: var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: #fff;
}

.section-title {
    font-size: 2rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 3rem;
    color: var(--text-dark);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.page-header {
    background: #fff;
    padding: 100px 0 40px;
    text-align: center;
    border-bottom: 1px solid var(--border);
}

.page-header h1 {
    font-size: 2.5rem;
    color: var(--text-dark);
    margin-bottom: 10px;
    font-weight: 700;
}

.page-header p {
    color: var(--text-gray);
    font-size: 1rem;
    font-family: var(--font-mono);
}

/* --- HEADER --- */
header {
    background-color: #fff;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid var(--border);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
    position: relative;
}

.logo {
    display: flex;
    align-items: center;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1001;
}

.logo img {
    height: 180px;
    width: auto;
    display: block;
    filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.15));
}

.nav-links {
    display: flex;
    gap: 30px;
    align-items: center;
}

.nav-links a {
    font-weight: 500;
    color: var(--text-gray);
    font-size: 0.85rem;
    text-transform: uppercase;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--text-dark);
}

.hamburger {
    display: none;
    cursor: pointer;
    z-index: 1002;
}

.hamburger span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--text-dark);
    margin: 5px 0;
    transition: all 0.3s ease;
}

.nav-icon {
    display: none;
}

/* --- HERO SECTION --- */
.hero {
    height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: #fff;
    padding-top: 150px;
}

.hero h1 {
    font-size: 3.5rem;
    line-height: 1.1;
    margin-bottom: 20px;
    font-weight: 800;
}

.hero h1 span {
    color: var(--accent);
}

.hero p {
    font-size: 1.1rem;
    color: var(--text-gray);
    margin-bottom: 40px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    font-family: var(--font-mono);
}

.hero-btns {
    display: flex;
    gap: 15px;
    justify-content: center;
}

/* --- PRODUCT SHOWCASE / SCIENTIFIC CARDS --- */
.products {
    padding: 60px 0;
    background-color: var(--bg-body);
}

.filter-controls {
    display: flex;
    gap: 15px;
    margin-bottom: 30px;
    align-items: center;
    justify-content: space-between;
}

.catalog-search {
    flex: 1;
    max-width: 400px;
}

.catalog-category {
    width: auto;
}

/* Category titles removed as per single-grid request */

.product-grid {
    display: grid;
    /* Updated for smaller cards to allow 2-column on mobile */
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 15px;
    margin-bottom: 40px;
}

.product-card {
    background: white;
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 15px;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    cursor: pointer;
    text-align: center;
    border-left: 4px solid var(--accent);
}

.product-img-wrapper {
    width: 100%;
    aspect-ratio: 1/1;
    height: auto;
    background: var(--border-light);
    margin-bottom: 12px;
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-vial-img {
    height: 75%;
    width: auto;
    object-fit: contain;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.product-card:hover .product-vial-img {
    transform: scale(1.1);
}

.product-info-centered {
    padding: 0 5px;
}

.product-title-onyx {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0 0 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.product-purity-onyx {
    font-size: 0.85rem;
    color: var(--text-gray);
    margin-bottom: 8px;
    font-weight: 400;
}

.product-price-onyx {
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--accent);
    margin-bottom: 12px;
}

.product-action-onyx {
    font-size: 0.75rem;
    font-weight: 700;
    color: #3b82f6;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.product-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transform: translateY(-2px);
    border-color: var(--border);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
}

.product-title {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0;
    font-family: var(--font-main);
}

.purity-badge {
    font-size: 0.65rem;
    padding: 3px 6px;
    border: 1px solid var(--success);
    color: var(--success);
    border-radius: 3px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    background: rgba(34, 197, 94, 0.1);
    /* Subtle green tint */
}

.purity-badge.experimental {
    border-color: var(--primary);
    color: var(--primary);
    background: rgba(250, 204, 21, 0.1);
}

.product-desc {
    font-size: 0.85rem;
    color: var(--text-gray);
    line-height: 1.6;
    margin-bottom: 20px;
    flex-grow: 1;
}

.mono {
    font-family: var(--font-mono);
    background: var(--border-light);
    padding: 2px 5px;
    border-radius: 3px;
    color: #334155;
    font-size: 0.8rem;
    margin-right: 5px;
}

.card-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--border-light);
    padding-top: 15px;
    margin-top: auto;
}

.product-price {
    font-weight: 700;
    color: var(--text-dark);
    font-size: 1.1rem;
}

.unit-label {
    font-size: 0.75rem;
    color: var(--text-gray);
    font-weight: 400;
    margin-left: 5px;
}

/* --- CART MODAL --- */
.cart-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 2000;
    display: none;
}

.cart-modal {
    position: fixed;
    top: 0;
    right: -100%;
    /* Hidden */
    width: 100%;
    max-width: 450px;
    height: 100%;
    background: var(--bg-card);
    z-index: 2001;
    transition: right 0.2s ease;
    /* Faster */
    border-left: 1px solid var(--border);
    display: flex;
    flex-direction: column;
}

.cart-modal.open {
    right: 0;
}

.cart-header {
    padding: 20px;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff;
}

.cart-header h2 {
    font-size: 1rem;
    margin: 0;
    text-transform: uppercase;
    font-weight: 700;
}

.close-btn {
    background: none;
    border: none;
    color: var(--text-gray);
    font-size: 1.5rem;
    cursor: pointer;
}

.cart-items {
    flex-grow: 1;
    overflow-y: auto;
    padding: 20px;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border);
}

.cart-item-info h4 {
    margin-bottom: 5px;
    font-size: 0.9rem;
    color: var(--primary);
}

.cart-item-price {
    color: var(--text-gray);
    font-size: 0.85rem;
    font-family: var(--font-mono);
}

.remove-btn {
    background: none;
    border: 1px solid var(--border);
    color: var(--danger);
    cursor: pointer;
    font-size: 0.7rem;
    padding: 4px 8px;
    text-transform: uppercase;
}

.remove-btn:hover {
    border-color: var(--danger);
}

.cart-footer {
    padding: 20px;
    border-top: 1px solid var(--border);
    background: #fff;
}

.cart-total {
    display: flex;
    justify-content: space-between;
    font-size: 1rem;
    font-weight: bold;
    margin-bottom: 20px;
    font-family: var(--font-mono);
}

/* --- COMPLIANCE WIDGET REFINED --- */
.compliance-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 95%;
    max-width: 500px;
    z-index: 3000;
    display: none;
}

/* Active state for modal */
.compliance-modal.open {
    display: block;
}

.compliance-wrapper {
    background-color: #111;
    border: 1px solid var(--border);
    border-top: 4px solid var(--primary);
    color: var(--text-light);
    border-radius: 2px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8);
    padding: 30px;
}

.compliance-header {
    color: var(--primary);
    font-weight: 800;
    text-transform: uppercase;
    font-size: 0.9rem;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    border-bottom: 1px solid var(--border);
    padding-bottom: 15px;
}

.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    font-weight: 700;
    color: var(--text-dark);
    font-size: 0.9rem;
    margin-bottom: 8px;
}

.form-subtext {
    font-size: 0.8rem;
    color: #64748b;
    margin-bottom: 8px;
    line-height: 1.4;
}

.intended-use-input {
    width: 100%;
    padding: 10px;
    background-color: #fff;
    border: 1px solid var(--border);
    color: var(--text-dark);
    border-radius: 4px;
    font-size: 0.9rem;
    font-family: var(--font-mono);
    resize: vertical;
}

/* --- GLOBAL FORM ELEMENTS --- */
input[type="text"],
input[type="email"],
input[type="password"],
input[type="search"],
input[type="number"],
input[type="tel"],
textarea,
select {
    background-color: #fff;
    border: 1px solid var(--border);
    color: var(--text-dark);
    border-radius: 4px;
    padding: 10px 12px;
    font-size: 0.9rem;
    font-family: var(--font-main);
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    -webkit-appearance: none;
    appearance: none;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
input[type="search"]:focus,
input[type="number"]:focus,
input[type="tel"]:focus,
textarea:focus,
select:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(200, 169, 81, 0.15);
}

input::placeholder,
textarea::placeholder {
    color: var(--text-light);
}

select {
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236b7280' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    padding-right: 30px;
}

.intended-use-input:focus {
    outline: none;
    border-color: var(--primary);
}

.intended-use-input::placeholder {
    color: #6b7280;
}

.checkbox-group {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 15px;
    background: #000;
    border: 1px solid var(--border);
    border-radius: 2px;
    cursor: pointer;
}

.checkbox-group:hover {
    border-color: #555;
}

.checkbox-group input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin-top: 2px;
    accent-color: var(--primary);
}

.submit-btn {
    background-color: var(--primary);
    color: var(--text-dark);
    width: 100%;
    padding: 15px;
    border: none;
    border-radius: 2px;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    margin-top: 20px;
    opacity: 0.5;
    pointer-events: none;
    transition: all 0.2s;
    text-transform: uppercase;
}

.submit-btn.active {
    background-color: var(--primary);
    color: #000;
    opacity: 1;
    pointer-events: auto;
}

.submit-btn:hover {
    background-color: var(--primary-dark);
}

/* --- FOOTER --- */
footer {
    padding: 50px 0;
    border-top: 1px solid var(--border);
    text-align: center;
    color: var(--text-gray);
    font-size: 0.85rem;
    background: #fff;
}

/* --- RESPONSIVE --- */
@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }

    .hero h1 {
        font-size: 2.2rem;
    }

    .hero p {
        font-size: 1rem;
        padding: 0 15px;
    }

    .filter-controls {
        flex-direction: column;
        align-items: stretch;
    }

    .catalog-search {
        max-width: none;
    }

    .catalog-category {
        width: 100%;
    }

    /* Hamburger Menu Styles */
    .hamburger {
        display: block;
    }

    .hamburger.active span:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    .hamburger.active span:nth-child(2) {
        opacity: 0;
    }

    .hamburger.active span:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

    .nav-links {
        position: fixed;
        top: 80px;
        /* Below header */
        left: -100%;
        width: 100%;
        height: calc(100vh - 80px);
        background: #fff;
        flex-direction: column;
        justify-content: flex-start;
        align-items: center;
        padding-top: 40px;
        transition: left 0.3s ease;
        border-top: 1px solid var(--border);
        z-index: 1000;
        gap: 0;
    }

    .nav-links.active {
        left: 0;
    }

    .nav-links a {
        font-size: 1.2rem;
        width: 100%;
        padding: 20px 0;
        border-bottom: 1px solid #222;
        flex-direction: row;
        justify-content: center;
        gap: 15px;
    }

    .nav-icon {
        display: block;
        margin-bottom: 0;
    }

    body.menu-open {
        overflow: hidden;
    }

    body {
        padding-bottom: 0;
    }

    /* Adjust Cart Modal */
    .cart-modal {
        max-width: 100%;
    }

    .compliance-modal {
        width: 95%;
        max-height: 90vh;
        overflow-y: auto;
    }

    .detail-grid {
        grid-template-columns: 1fr;
        /* Stack specifics and actions on mobile */
    }
}

/* --- PRODUCT DETAIL PAGE --- */
.product-detail-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 4px;
    padding: 30px;
    margin-top: 40px;
}

.detail-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 30px;
    border-bottom: 2px solid var(--primary);
    padding-bottom: 20px;
}

.detail-grid {
    display: grid;
    grid-template-columns: 400px 1fr 350px;
    gap: 40px;
}

.detail-image {
    background: transparent;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.detail-vial-img {
    max-width: 100%;
    height: auto;
    object-fit: contain;
}

/* --- DETAIL PAGE TYPOGRAPHY & COMPONENTS --- */
.detail-title-cas {
    font-size: 2rem;
    color: var(--primary);
}

.detail-title-name {
    font-size: 1.2rem;
    color: var(--text-light);
    margin-top: 5px;
}

.detail-badge {
    font-size: 1rem;
    padding: 8px 15px;
}

.detail-section-title {
    border-bottom: 1px solid var(--border);
    padding-bottom: 10px;
    margin-bottom: 15px;
    color: var(--text-gray);
}

.detail-specs-list {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    color: var(--text-light);
    line-height: 2;
}

.detail-actions {
    background: #fff;
    padding: 30px;
    border-radius: 4px;
    text-align: center;
    border: 1px solid var(--border);
}

.detail-ref-label {
    color: var(--text-gray);
    font-size: 0.9rem;
    margin-bottom: 10px;
}

.detail-price-text {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text-light);
    margin-bottom: 0px;
}

.detail-unit-text {
    color: var(--text-gray);
    font-size: 0.8rem;
    margin-bottom: 30px;
}

.detail-add-btn {
    padding: 15px;
    font-size: 1rem;
}

.detail-disclaimer {
    margin-top: 20px;
    font-size: 0.75rem;
    color: #666;
}

.detail-safety {
    margin-top: 60px;
}

.detail-safety-text {
    color: var(--text-gray);
    font-size: 0.9rem;
    max-width: 800px;
}

.variant-select {
    width: 100%;
    padding: 12px;
    background-color: var(--bg-dark);
    color: var(--text-light);
    border: 1px solid var(--border);
    border-radius: 4px;
    font-size: 1rem;
    font-family: var(--font-mono);
    cursor: pointer;
    margin-bottom: 20px;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%239CA3AF' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 16px;
}

.variant-select:focus {
    outline: none;
    border-color: var(--primary);
}

/* --- TIERED PRICING GRID --- */
.tier-grid {
    margin-bottom: 15px;
}

.tier-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    border: 1px solid var(--border);
    border-radius: 4px;
    margin-bottom: 4px;
    font-size: 0.8rem;
    color: var(--text-gray);
    transition: all 0.3s ease;
}

.tier-row.active {
    border-color: var(--primary);
    background: rgba(250, 204, 21, 0.08);
    color: var(--text-dark);
    transform: scale(1.02);
}

.tier-label {
    flex: 2;
    font-weight: 600;
}

.tier-price {
    flex: 1;
    text-align: center;
    font-family: var(--font-mono);
}

.tier-tag {
    flex: 1;
    text-align: right;
    font-weight: 700;
    color: var(--success);
    font-size: 0.75rem;
}

.tier-row:first-child .tier-tag {
    color: var(--text-gray);
}

/* --- QUANTITY STEPPER --- */
.qty-stepper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 10px;
}

.qty-btn {
    width: 36px;
    height: 36px;
    border: 1px solid var(--border);
    background: var(--border-light);
    color: var(--text-dark);
    font-size: 1.2rem;
    cursor: pointer;
    border-radius: 4px;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.qty-btn:hover {
    border-color: var(--primary);
    background: var(--border);
}

.qty-value {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--primary);
    min-width: 30px;
    text-align: center;
    font-family: var(--font-mono);
}

/* --- RECONSTITUTION CALCULATOR --- */
.recon-calculator {
    margin-top: 40px;
    padding: 30px;
    background: #f8fafc;
    border: 1px solid var(--border);
    border-radius: 8px;
}

.recon-grid {
    display: grid;
    grid-template-columns: 1fr 120px;
    gap: 30px;
    align-items: start;
}

.recon-inputs {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.recon-slider {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 6px;
    background: var(--border);
    border-radius: 3px;
    outline: none;
    margin-bottom: 8px;
}

.recon-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    background: var(--primary);
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(250, 204, 21, 0.4);
}

.recon-result {
    display: flex;
    gap: 20px;
    margin-top: 15px;
}

.recon-result-item {
    background: var(--border-light);
    padding: 15px;
    border-radius: 6px;
    flex: 1;
    text-align: center;
    border: 1px solid var(--border);
}

.recon-result-label {
    display: block;
    color: var(--text-gray);
    font-size: 0.75rem;
    text-transform: uppercase;
    margin-bottom: 5px;
}

.recon-result-value {
    display: block;
    color: var(--primary);
    font-size: 1.3rem;
    font-weight: 700;
    font-family: var(--font-mono);
}

.recon-vial-visual {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.recon-vial {
    width: 50px;
    height: 130px;
    border: 2px solid #555;
    border-radius: 4px 4px 12px 12px;
    position: relative;
    overflow: hidden;
    background: #fff;
}

.recon-vial-fill {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 0%;
    background: linear-gradient(to top, #3b82f6, #60a5fa);
    transition: height 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 0 0 10px 10px;
}

/* --- CROSS-SELL --- */
.cross-sell-section {
    margin-top: 40px;
}

.cross-sell-grid {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.cross-sell-card {
    display: flex;
    align-items: center;
    gap: 15px;
    background: #f8fafc;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 15px;
    flex: 1;
    min-width: 250px;
    transition: border-color 0.2s;
}

.cross-sell-card:hover {
    border-color: var(--primary);
}

.cross-sell-img {
    width: 50px;
    height: 50px;
    object-fit: contain;
}

.cross-sell-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
    color: var(--text-dark);
    font-size: 0.9rem;
}

@media (max-width: 768px) {
    .recon-grid {
        grid-template-columns: 1fr;
    }

    .recon-vial-visual {
        flex-direction: row;
        gap: 15px;
    }

    .recon-vial {
        height: 80px;
        width: 40px;
    }

    .tier-row {
        font-size: 0.7rem;
    }

    .cross-sell-card {
        min-width: 100%;
    }
}

@media (max-width: 768px) {
    .product-detail-card {
        padding: 20px;
        margin-top: 20px;
    }

    .detail-grid {
        grid-template-columns: 1fr;
        gap: 25px;
    }

    .detail-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }

    .detail-title-cas {
        font-size: 1.6rem;
    }

    .detail-actions {
        padding: 20px;
        /* Reduced padding for mobile */
    }

    .detail-price-text {
        font-size: 2rem;
        /* Smaller price font */
    }
}

/* --- TOAST NOTIFICATIONS --- */
#toast-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.toast {
    background: var(--border-light);
    color: var(--text-dark);
    padding: 15px 25px;
    border-radius: 4px;
    border-left: 4px solid var(--primary);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
    font-size: 0.9rem;
    font-weight: bold;
    opacity: 0;
    transform: translateX(100%);
    animation: slideIn 0.3s forwards;
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-width: 250px;
}

.toast.error {
    border-left-color: var(--danger);
}

.toast.success {
    border-left-color: var(--success);
}

.toast.fade-out {
    animation: slideOut 0.3s forwards;
}

@keyframes slideIn {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideOut {
    to {
        opacity: 0;
        transform: translateX(100%);
    }
}

/* --- SKELETON LOADERS --- */
.skeleton {
    background: var(--border-light);
    border-radius: 4px;
    overflow: hidden;
    position: relative;
}

.skeleton::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.05), transparent);
    animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
    0% {
        transform: translateX(-100%);
    }

    100% {
        transform: translateX(100%);
    }
}

.skeleton-card {
    display: flex;
    flex-direction: column;
    gap: 15px;
    padding: 15px;
}

.skeleton-img {
    width: 100%;
    aspect-ratio: 1/1;
    border-radius: 24px;
}

.skeleton-text {
    height: 15px;
    width: 80%;
    border-radius: 2px;
}

.skeleton-text.short {
    width: 40%;
}

/* --- FLOATING AI CHATBOX --- */
.chatbox-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 9000;
    font-family: var(--font-main);
}

.chatbox-toggle {
    background: #FACC15;
    color: #000;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
    cursor: pointer;
    transition: transform 0.2s;
}

.chatbox-toggle:hover {
    transform: scale(1.05);
}

.chatbox-container {
    display: none;
    position: absolute;
    bottom: 60px;
    right: 0;
    width: 320px;
    height: 400px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8);
    flex-direction: column;
    overflow: hidden;
}

.chatbox-container.open {
    display: flex;
}

.chatbox-header {
    background: var(--border-light);
    padding: 12px 15px;
    color: var(--accent);
    font-weight: 700;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chatbox-close {
    cursor: pointer;
    color: var(--text-gray);
}

.chatbox-close:hover {
    color: var(--text-dark);
}

.chatbox-messages {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.chat-msg {
    max-width: 85%;
    padding: 10px 12px;
    border-radius: 6px;
    font-size: 0.85rem;
    line-height: 1.4;
    word-wrap: break-word;
}

.chat-msg.bot {
    background: #e5e5e0;
    color: var(--text-dark);
    align-self: flex-start;
}

/* AI Product Card Injected via Stream */
.ai-product-card {
    background: var(--border-light);
    border: 1px solid var(--border);
    padding: 12px;
    border-radius: 6px;
    margin-top: 10px;
    cursor: pointer;
    transition: transform 0.2s;
    font-family: var(--font-main);
}

.ai-product-card:hover {
    transform: translateY(-2px);
    border-color: #FACC15;
}

.chat-msg.user {
    background: #FACC15;
    color: #000;
    align-self: flex-end;
}

.chatbox-input-area {
    display: flex;
    padding: 10px;
    background: var(--border-light);
    border-top: 1px solid var(--border);
}

.chatbox-input {
    flex: 1;
    background: #fff;
    border: 1px solid var(--border);
    color: var(--text-dark);
    padding: 8px 12px;
    border-radius: 4px;
    outline: none;
    font-size: 0.85rem;
}

.chatbox-input:focus {
    border-color: #FACC15;
}

.chatbox-send {
    background: transparent;
    border: none;
    color: var(--accent);
    padding: 0 10px;
    cursor: pointer;
    font-weight: bold;
}

/* --- AI PROTOCOL WIDGET --- */
.ai-protocol-widget {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 20px;
    margin-top: 12px;
    font-size: 0.85rem;
}

.ai-protocol-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 10px;
}

.ai-protocol-title {
    color: var(--accent);
    font-weight: 700;
    font-size: 1rem;
    margin-bottom: 4px;
}

.ai-protocol-desc {
    color: var(--text-gray);
    font-size: 0.8rem;
    line-height: 1.5;
}

.ai-protocol-duration {
    background: rgba(250, 204, 21, 0.15);
    color: var(--accent);
    padding: 6px 14px;
    border-radius: 20px;
    font-weight: 700;
    font-size: 0.8rem;
    white-space: nowrap;
}

.ai-protocol-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 15px;
    border-top: 1px solid var(--border);
}

/* ============================================================
   GOLD SWIRL DECORATIONS — Matching Vial Label Aesthetic
   ============================================================ */

/* Decorative gold swirl on the hero section */
.hero {
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    bottom: -60px;
    right: -80px;
    width: 500px;
    height: 500px;
    background: radial-gradient(ellipse at 70% 70%,
            rgba(200, 169, 81, 0.12) 0%,
            transparent 70%);
    pointer-events: none;
    z-index: 0;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 100%;
    height: 100%;
    background:
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 800 400'%3E%3Cpath d='M800,400 C600,380 400,300 200,350 C100,375 50,390 0,400' fill='none' stroke='%23C8A951' stroke-width='1.5' opacity='0.25'/%3E%3Cpath d='M800,380 C550,340 350,280 150,340 C75,365 30,385 0,395' fill='none' stroke='%23C8A951' stroke-width='1' opacity='0.15'/%3E%3Cpath d='M800,360 C500,300 300,260 100,330 C50,355 10,380 0,390' fill='none' stroke='%23b5963e' stroke-width='0.8' opacity='0.1'/%3E%3C/svg%3E") no-repeat bottom right;
    background-size: 60% auto;
    pointer-events: none;
    z-index: 0;
}

.hero .container {
    position: relative;
    z-index: 1;
}

/* Gold swoosh decoration on section titles */
.section-title {
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--primary), transparent);
    border-radius: 2px;
}

/* Gold swirl on product detail card */
.product-detail-card {
    position: relative;
    overflow: hidden;
}

.product-detail-card::before {
    content: '';
    position: absolute;
    top: -40px;
    right: -40px;
    width: 300px;
    height: 300px;
    background: radial-gradient(ellipse at 60% 40%,
            rgba(200, 169, 81, 0.08) 0%,
            transparent 70%);
    pointer-events: none;
    z-index: 0;
}

.product-detail-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 100%;
    height: 100%;
    background:
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 600 300'%3E%3Cpath d='M600,300 C450,280 300,220 150,260 C75,280 30,295 0,300' fill='none' stroke='%23C8A951' stroke-width='1.2' opacity='0.18'/%3E%3Cpath d='M600,280 C400,250 250,200 100,250 C50,270 15,290 0,295' fill='none' stroke='%23C8A951' stroke-width='0.8' opacity='0.1'/%3E%3C/svg%3E") no-repeat bottom right;
    background-size: 50% auto;
    pointer-events: none;
    z-index: 0;
}

.product-detail-card>* {
    position: relative;
    z-index: 1;
}

/* Gold swirl on individual product cards */
.product-card {
    position: relative;
    overflow: hidden;
}

.product-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 100%;
    height: 100%;
    background:
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200'%3E%3Cpath d='M200,200 C150,190 100,160 50,180 C25,190 10,198 0,200' fill='none' stroke='%23C8A951' stroke-width='1' opacity='0.2'/%3E%3Cpath d='M200,190 C130,170 80,150 30,175 C15,185 5,195 0,198' fill='none' stroke='%23C8A951' stroke-width='0.7' opacity='0.12'/%3E%3C/svg%3E") no-repeat bottom right;
    background-size: 70% auto;
    pointer-events: none;
    z-index: 0;
}

.product-card>* {
    position: relative;
    z-index: 1;
}

.product-trending-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 6;
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid var(--success);
    color: var(--success);
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 4px 8px;
    border-radius: 3px;
}

/* Gold swirl on footer */
footer {
    position: relative;
    overflow: hidden;
}

footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 800 200'%3E%3Cpath d='M0,0 C200,20 400,80 600,50 C700,35 770,10 800,0' fill='none' stroke='%23C8A951' stroke-width='1' opacity='0.15'/%3E%3Cpath d='M0,10 C250,40 450,90 650,55 C725,40 780,15 800,5' fill='none' stroke='%23C8A951' stroke-width='0.7' opacity='0.1'/%3E%3C/svg%3E") no-repeat top left;
    background-size: 100% auto;
    pointer-events: none;
    z-index: 0;
}

footer .container {
    position: relative;
    z-index: 1;
}

/* ============================================================
   SOLD OUT — Product Card Overlay & Styling
   ============================================================ */

.product-card.sold-out {
    opacity: 0.7;
    filter: grayscale(30%);
}

.product-card.sold-out:hover {
    transform: none;
    box-shadow: none;
}

.sold-out-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 5;
    display: flex;
    align-items: flex-start;
    justify-content: flex-end;
    padding: 12px;
    pointer-events: none;
}

.sold-out-overlay span {
    background: #EF4444;
    color: #fff;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    padding: 4px 10px;
    border-radius: 3px;
    text-transform: uppercase;
}

/* ── Discord Styles ── */

.btn-discord {
    background: var(--primary);
    color: #1a1a1a;
    border: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 6px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
}

.btn-discord:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(200, 169, 81, 0.4);
}

.btn-discord svg {
    flex-shrink: 0;
}

/* Discord Community Banner */
.discord-banner {
    padding: 0;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #1a1a2e 100%);
    position: relative;
    overflow: hidden;
}

.discord-banner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #C8A951, #e6d48e, #C8A951);
    background-size: 200% 100%;
    animation: shimmer 3s ease-in-out infinite;
}

@keyframes shimmer {

    0%,
    100% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }
}

.discord-banner-content {
    display: flex;
    align-items: center;
    gap: 30px;
    padding: 50px 0;
}

.discord-banner-icon {
    flex-shrink: 0;
    width: 70px;
    height: 70px;
    background: rgba(200, 169, 81, 0.12);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #C8A951;
    border: 1px solid rgba(200, 169, 81, 0.3);
}

.discord-banner-text {
    flex: 1;
}

.discord-banner-text h3 {
    color: #fff;
    font-size: 1.4rem;
    margin: 0 0 6px;
    letter-spacing: 0.5px;
}

.discord-banner-text p {
    color: #a0aec0;
    margin: 0;
    font-size: 0.95rem;
}

.btn-discord-lg {
    padding: 14px 32px;
    font-size: 1rem;
    flex-shrink: 0;
    white-space: nowrap;
}

/* Footer */
.footer-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
}

.footer-discord {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #a0aec0;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s;
}

.footer-discord:hover {
    color: #C8A951;
}

.footer-discord svg {
    flex-shrink: 0;
}

/* Responsive */
@media (max-width: 768px) {
    .discord-banner-content {
        flex-direction: column;
        text-align: center;
        padding: 40px 0;
    }

    .footer-content {
        flex-direction: column;
        text-align: center;
    }
}

/* ============================================================
   SITE CLEANUP PASS — White/Gold polish without changing brand
   ============================================================ */
:root {
    --bg-surface: #fffdf8;
    --bg-soft: #fafaf8;
    --gold-soft: rgba(200, 169, 81, 0.12);
    --gold-line: rgba(200, 169, 81, 0.28);
    --shadow-sm: 0 8px 24px rgba(26, 26, 26, 0.06);
    --shadow-md: 0 18px 50px rgba(26, 26, 26, 0.10);
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 22px;
}

html {
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    background:
        radial-gradient(circle at top left, rgba(200, 169, 81, 0.08), transparent 32rem),
        linear-gradient(180deg, #fff 0%, var(--bg-body) 55%, #fff 100%);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
    outline: 3px solid rgba(200, 169, 81, 0.35);
    outline-offset: 3px;
}

.container {
    width: min(100% - 32px, 1200px);
    padding-left: 0;
    padding-right: 0;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 42px;
    border-radius: 999px;
    letter-spacing: 0.04em;
    box-shadow: none;
}

.btn-primary {
    color: #1a1a1a;
    box-shadow: 0 10px 22px rgba(200, 169, 81, 0.22);
}

.btn-primary:hover {
    color: #1a1a1a;
    transform: translateY(-1px);
    box-shadow: 0 14px 30px rgba(200, 169, 81, 0.28);
}

.btn-outline {
    background: rgba(255, 255, 255, 0.7);
}

.btn-outline:hover {
    color: #1a1a1a;
    transform: translateY(-1px);
}

header {
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(16px);
}

header .container {
    height: 76px;
}

.logo img {
    height: 132px;
}

.nav-links {
    gap: 22px;
}

.nav-links a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border-radius: 999px;
    padding: 8px 10px;
    letter-spacing: 0.04em;
}

.nav-links a:hover,
.nav-links a.active {
    background: rgba(200, 169, 81, 0.10);
    color: var(--text-dark);
}

.hero {
    min-height: 760px;
    height: auto;
    padding: 180px 0 110px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(250, 250, 248, 0.96)),
        #fff;
}

.hero h1 {
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
    font-size: clamp(2.75rem, 8vw, 5.8rem);
    letter-spacing: -0.07em;
    text-transform: none;
}

.hero p {
    color: #4b5563;
    font-family: var(--font-main);
    font-size: clamp(1rem, 2vw, 1.25rem);
}

.hero-btns {
    flex-wrap: wrap;
}

.section-title {
    display: block;
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
    letter-spacing: -0.02em;
    text-transform: none;
}

.page-header {
    padding: 130px 0 56px;
    background:
        radial-gradient(circle at 20% 20%, rgba(200, 169, 81, 0.10), transparent 28rem),
        #fff;
}

.page-header h1 {
    font-size: clamp(2rem, 5vw, 3.25rem);
    letter-spacing: -0.04em;
}

.page-header p {
    font-family: var(--font-main);
}

.products {
    padding: 76px 0;
}

.product-grid {
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 22px;
}

.product-card,
.tool-card,
.auth-container,
.checkout-container,
.admin-container,
.dashboard-container,
.legal-container,
.footer-community-banner {
    background: rgba(255, 255, 255, 0.88) !important;
    border: 1px solid var(--border) !important;
    border-radius: var(--radius-md) !important;
    box-shadow: var(--shadow-sm);
}

.product-card {
    border-left: 1px solid var(--border) !important;
    padding: 18px;
}

.product-card:hover,
.tool-card:hover {
    border-color: var(--gold-line) !important;
    box-shadow: var(--shadow-md);
    transform: translateY(-3px);
}

.product-img-wrapper {
    background:
        radial-gradient(circle at center, rgba(200, 169, 81, 0.12), transparent 62%),
        var(--bg-soft);
}

.product-title-onyx {
    text-transform: none;
    letter-spacing: -0.01em;
}

.product-action-onyx {
    color: var(--primary-dark);
}

.filter-controls,
.tool-cta,
.trust-strip,
.order-summary-box,
.points-box,
.recon-calculator,
.ai-protocol-widget {
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.72);
    box-shadow: var(--shadow-sm);
}

.filter-controls {
    padding: 16px;
}

.auth-container {
    margin: 120px auto 70px !important;
    padding: 38px !important;
}

.auth-container h2 {
    letter-spacing: -0.03em;
}

.admin-container,
.dashboard-container {
    margin-top: 115px !important;
    margin-bottom: 60px !important;
    padding: 28px !important;
}

.legal-container {
    padding: 40px !important;
}

.legal-wrap {
    padding-top: 110px !important;
}

.tab,
.admin-container .tab,
.dashboard-container .tab {
    border-radius: 999px;
}

table {
    border-collapse: separate;
    border-spacing: 0;
}

th {
    color: var(--text-dark);
}

td,
th {
    border-color: var(--border) !important;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="search"],
input[type="number"],
input[type="tel"],
textarea,
select,
.form-input,
.auth-input,
.variant-select,
.intended-use-input {
    border-radius: 10px;
    background-color: #fff;
}

.variant-select {
    color: var(--text-dark);
}

.cart-overlay {
    background: rgba(26, 26, 26, 0.48);
    backdrop-filter: blur(6px);
}

.cart-modal {
    box-shadow: -24px 0 60px rgba(26, 26, 26, 0.18);
}

.cart-item {
    border-radius: 12px;
    padding: 14px;
    background: var(--bg-soft);
}

.remove-btn {
    border-radius: 999px;
}

.compliance-wrapper {
    background: #fff;
    color: var(--text-dark);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
}

.checkbox-group {
    background: var(--bg-soft);
    border-color: var(--border);
    color: var(--text-dark);
    border-radius: 10px;
}

.submit-btn {
    color: #1a1a1a;
    border-radius: 999px;
}

.detail-grid {
    grid-template-columns: minmax(220px, 360px) minmax(0, 1fr) minmax(280px, 340px);
    gap: 28px;
}

.detail-title-cas {
    color: var(--text-dark);
    letter-spacing: -0.04em;
}

.detail-title-name,
.detail-price-text {
    color: var(--primary);
}

.detail-specs-list {
    color: var(--text-gray);
}

.detail-actions,
.cross-sell-card,
.recon-result-item {
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

.footer-community-banner {
    padding: 30px !important;
    margin-bottom: 26px !important;
    text-align: center !important;
}

footer {
    padding: 42px 0;
    background: linear-gradient(180deg, #fff, var(--bg-soft));
}

footer .footer-content {
    border-top: 1px solid var(--border);
    padding-top: 20px;
}

.site-section {
    padding: 100px 0;
}

.site-section-soft {
    background: var(--bg-soft);
}

.feature-grid,
.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 22px;
}

.feature-card,
.tool-card {
    padding: 24px;
}

.tool-icon {
    width: 50px;
    height: 50px;
    border-radius: 14px;
    background: var(--gold-soft);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
}

.tool-card h3,
.feature-card h3 {
    margin: 0 0 8px;
    color: var(--text-dark);
    letter-spacing: -0.02em;
}

.tool-card p,
.feature-card p {
    margin: 0;
    color: var(--text-gray);
}

.empty-state {
    grid-column: 1 / -1;
    width: 100%;
    padding: 28px;
    text-align: center;
    color: var(--text-gray);
    background: rgba(255, 255, 255, 0.82);
    border: 1px dashed var(--gold-line);
    border-radius: var(--radius-md);
}

.lead-popup-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 9998;
    padding: 20px;
    background: rgba(26, 26, 26, 0.45);
    backdrop-filter: blur(8px);
}

.lead-popup {
    max-width: 460px;
    margin: 10vh auto;
    padding: 24px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
}

.tool-cta {
    margin-top: 40px;
    padding: 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    flex-wrap: wrap;
    border-left: 4px solid var(--primary);
}

.tools-page,
.calculator-page,
.protocol-page,
.wiki-page,
.plasma-page,
.compare-page,
.integrity-page,
.pathway-page {
    background: var(--bg-soft);
}

@media (max-width: 900px) {
    .detail-grid,
    .recon-grid {
        grid-template-columns: 1fr;
    }

    .logo {
        position: static;
        transform: none;
    }

    header .container {
        justify-content: space-between;
    }
}

@media (max-width: 768px) {
    .container {
        width: min(100% - 28px, 1200px);
        padding-left: 0;
        padding-right: 0;
    }

    .logo img {
        height: 104px;
    }

    .hero {
        min-height: auto;
        padding: 136px 0 76px;
    }

    .hero-btns {
        flex-direction: column;
        align-items: stretch;
    }

    .nav-links {
        top: 76px;
        height: calc(100vh - 76px);
        align-items: stretch;
        padding: 28px 16px;
        gap: 8px;
    }

    .nav-links a {
        border-bottom: 1px solid var(--border);
        border-radius: 14px;
        padding: 16px;
    }

    .product-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 14px;
    }

    .product-card {
        padding: 12px;
    }

    .tool-cta,
    .footer-content {
        text-align: center;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .product-grid {
        grid-template-columns: 1fr;
    }
}

/* ============================================================
   RESPONSIVE POLISH PASS — consistent desktop + mobile finish
   ============================================================ */
body {
    overflow-x: hidden;
}

img,
svg {
    max-width: 100%;
}

header .container {
    gap: 18px;
}

.hamburger {
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 7px 9px;
    background: rgba(255, 255, 255, 0.88);
}

.hamburger span {
    width: 22px;
    height: 2px;
    border-radius: 999px;
}

.product-card,
.tool-card,
.feature-card,
.detail-actions,
.checkout-container,
.auth-container {
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.product-card {
    min-width: 0;
}

.product-title-onyx,
.product-purity-onyx,
.product-price-onyx {
    overflow-wrap: anywhere;
}

.product-trending-badge {
    max-width: calc(100% - 20px);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.detail-header {
    gap: 18px;
}

.detail-actions {
    position: sticky;
    top: 96px;
}

.detail-safety-text {
    line-height: 1.7;
}

.cross-sell-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 14px;
}

.cross-sell-card {
    min-width: 0;
}

.recon-result,
.checkout-actions,
.form-row,
.summary-item,
.footer-content {
    min-width: 0;
}

.checkout-actions .btn,
.hero-btns .btn,
.tool-cta .btn {
    white-space: normal;
}

.cart-modal {
    width: min(100%, 450px);
}

#toast-container {
    max-width: min(420px, calc(100vw - 24px));
}

.toast {
    overflow-wrap: anywhere;
}

@media (min-width: 901px) {
    .nav-links {
        flex-wrap: wrap;
        row-gap: 8px;
    }

    header .container {
        min-height: 76px;
    }
}

@media (max-width: 1100px) {
    .nav-links {
        gap: 10px;
    }

    .nav-links a {
        font-size: 0.76rem;
        padding: 7px 8px;
    }

    .hero h1 {
        font-size: clamp(2.5rem, 7vw, 4.8rem);
    }
}

@media (max-width: 900px) {
    header .container {
        width: min(100% - 24px, 1200px);
    }

    .hamburger {
        display: block;
        order: 3;
    }

    .logo img {
        height: 96px;
    }

    .nav-links {
        overflow-y: auto;
        box-shadow: 0 20px 50px rgba(26, 26, 26, 0.12);
    }

    .nav-links.active {
        left: 0 !important;
    }

    .nav-links a {
        justify-content: flex-start;
        width: 100%;
        font-size: 0.95rem;
    }

    .nav-icon {
        display: block;
    }

    .detail-actions {
        position: static;
    }

    .detail-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .checkout-container,
    .auth-container,
    .admin-container,
    .dashboard-container,
    .legal-container {
        width: 100%;
    }
}

@media (max-width: 768px) {
    .page-header {
        padding: 112px 0 38px;
    }

    .products,
    .site-section {
        padding: 52px 0;
    }

    .hero {
        padding: 124px 0 58px;
    }

    .hero h1 {
        letter-spacing: -0.055em;
        line-height: 1;
    }

    .hero p {
        margin-bottom: 28px;
    }

    .discord-banner-content {
        gap: 18px;
    }

    .filter-controls {
        gap: 10px;
        padding: 12px;
    }

    .product-img-wrapper {
        margin-bottom: 10px;
    }

    .product-title-onyx {
        font-size: 0.92rem;
    }

    .product-purity-onyx,
    .product-price-onyx {
        font-size: 0.85rem;
    }

    .product-action-onyx {
        font-size: 0.68rem;
    }

    .detail-header,
    .product-detail-card,
    .detail-actions,
    .recon-calculator {
        padding: 20px;
    }

    .detail-title-cas {
        font-size: clamp(1.55rem, 8vw, 2rem);
    }

    .detail-price-text {
        font-size: 2rem;
    }

    .qty-stepper {
        gap: 10px;
    }

    .recon-result,
    .ai-protocol-header,
    .ai-protocol-footer {
        flex-direction: column;
        align-items: stretch;
    }

    .checkout-container {
        margin-top: 96px !important;
        padding: 22px !important;
    }

    .checkout-header {
        font-size: 1.15rem;
        margin-bottom: 22px !important;
    }

    .step-indicator {
        gap: 10px;
        margin-bottom: 26px !important;
    }

    .step-indicator div {
        border: 1px solid var(--border) !important;
        border-radius: 12px;
        padding: 10px !important;
        background: #fff;
    }

    .step-indicator div.active {
        border-color: var(--primary) !important;
        background: var(--gold-soft);
    }

    .checkout-actions {
        gap: 10px;
    }

    .checkout-actions .btn {
        width: 100%;
    }

    .summary-item,
    .summary-total {
        gap: 12px;
        align-items: flex-start;
    }

    .footer-community-banner {
        padding: 22px !important;
    }
}

@media (max-width: 520px) {
    .container {
        width: min(100% - 22px, 1200px);
    }

    .btn {
        width: 100%;
        padding: 11px 16px;
    }

    .logo img {
        height: 82px;
    }

    .hero {
        padding-top: 110px;
    }

    .hero h1 {
        font-size: clamp(2.25rem, 14vw, 3.35rem);
    }

    .section-title {
        font-size: 1.6rem;
    }

    .product-grid,
    .feature-grid,
    .tools-grid,
    .cross-sell-grid {
        grid-template-columns: 1fr;
    }

    .product-card {
        padding: 16px;
    }

    .cart-modal {
        max-width: none;
    }

    .cart-item {
        align-items: flex-start;
        gap: 12px;
    }

    .lead-popup {
        margin: 8vh auto;
        padding: 20px;
    }

    .lead-popup .btn {
        width: auto;
    }
}