/* JupitERP Default Theme Stylesheet */
/*
 * Frontend-facing styles for the default Twig theme.
 *
 * CSS custom properties below are injected by base.twig from theme settings
 * stored in the database (via ThemeService). Do NOT define default values here;
 * base.twig injects them so they are always present when this file is loaded.
 *
 * Available variables (injected by base.twig):
 *   --color-primary       Primary brand colour (default: #2a5298)
 *   --color-secondary     Secondary / background colour (default: #f8f9fa)
 *   --color-accent        Accent / CTA colour (default: #e63946)
 *   --color-nav-bg        Navbar background (default: #2a5298)
 *   --color-nav-bg-light  Navbar gradient highlight (auto-calculated lighter variant)
 *   --color-footer-bg     Footer background (default: #1a3a6b)
 *   --color-footer-bg-light Footer gradient highlight (auto-calculated lighter variant)
 *   --color-text          Body text colour (default: #212529)
 *   --font-heading        Heading font family (default: system-ui)
 *   --font-body           Body font family (default: system-ui)
 */

:root {
    /* Layout */
    --theme-border-radius: 5px;
    --theme-border-radius-badge: 15px;
}

/* ===== Typography ===== */
body {
    font-family: var(--font-body, system-ui, -apple-system, sans-serif);
    color: var(--color-text, #212529);
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading, system-ui, -apple-system, sans-serif);
}

/* ===== Public Navigation Bar ===== */
.navbar:not(.admin-top-navbar) {
    background: linear-gradient(135deg, var(--color-nav-bg, #2a5298) 0%, var(--color-nav-bg-light, #3a6ec0) 100%);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.navbar:not(.admin-top-navbar) .navbar-brand,
.navbar:not(.admin-top-navbar) .nav-link {
    color: #fff !important;
}

.navbar:not(.admin-top-navbar) .nav-link:hover {
    color: rgba(255, 255, 255, 0.75) !important;
}

.navbar:not(.admin-top-navbar) .nav-link.active {
    color: #fff !important;
    font-weight: 600;
}

.navbar:not(.admin-top-navbar) .dropdown-menu {
    border: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.navbar:not(.admin-top-navbar) .navbar-toggler {
    border-color: rgba(255, 255, 255, 0.3);
}

.navbar:not(.admin-top-navbar) .navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba(255, 255, 255, 0.85)' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* ===== Hero Section ===== */
.hero-section {
    background: linear-gradient(135deg, var(--color-primary, #2a5298) 0%, var(--color-primary-light, #3a6ec0) 100%);
    color: #fff;
    padding: 4rem 0;
    margin-bottom: 2rem;
}

.hero-hot-deals {
    background: linear-gradient(135deg, var(--color-accent, #e63946) 0%, color-mix(in srgb, var(--color-accent, #e63946) 70%, white) 100%);
}

.hero-hot-deals .timer-badge {
    background: #ffc107;
    color: #000;
    padding: 8px 16px;
    border-radius: 10px;
    font-weight: bold;
}

.hero-section h1,
.hero-section h2,
.hero-section p,
.hero-section .lead {
    color: #fff;
}

.hero-section .btn-primary {
    background-color: var(--color-accent, #e63946);
    border-color: var(--color-accent, #e63946);
}

.hero-section .btn-primary:hover {
    filter: brightness(0.9);
}

/* ===== Footer ===== */
footer.bg-dark,
.footer-section {
    background: linear-gradient(135deg, var(--color-footer-bg, #1a3a6b) 0%, var(--color-footer-bg-light, #2a5298) 100%) !important;
}

/* ===== Hot Deals Section ===== */
.hot-deals-section {
    background: linear-gradient(135deg, #ff6b6b 0%, #ff8e8e 100%);
    color: #fff;
    padding: 3rem 0;
}

.badge-hot {
    background: linear-gradient(135deg, #ff6b6b 0%, #ff8e8e 100%);
    color: #fff;
}

/* ===== New Arrivals Section ===== */
.new-arrivals-section {
    background: linear-gradient(135deg, #28a745 0%, #48c765 100%);
    color: #fff;
    padding: 3rem 0;
}

.badge-new {
    background: linear-gradient(135deg, #28a745 0%, #48c765 100%);
    color: #fff;
}

/* ===== Promotions Page Hero ===== */
.promotions-hero {
    background: linear-gradient(135deg, #ffc107 0%, #ff9800 100%);
    color: #fff;
    padding: 4rem 0;
    margin-bottom: 2rem;
    position: relative;
    overflow: hidden;
}

.promotions-hero::before {
    content: '🏷️';
    font-size: 15rem;
    position: absolute;
    right: -50px;
    top: -50px;
    opacity: 0.1;
    pointer-events: none;
}

.promotion-banner {
    background: linear-gradient(135deg, #ffc107 0%, #ff9800 100%);
    color: #fff;
    padding: 1.5rem;
    border-radius: 15px;
    text-align: center;
}

/* ===== Sidebar Filters (Public Product Pages) ===== */
.sidebar-filter {
    background: #fff;
    border-radius: var(--theme-border-radius-badge);
    padding: 1.5rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

@media (max-width: 767.98px) {
    .sidebar-filter {
        margin-bottom: 1rem;
    }
}

.filter-chip {
    display: inline-block;
    padding: 0.2rem 0.65rem;
    border-radius: 20px;
    font-size: 0.8rem;
    background: #f0f0f0;
    color: #333;
    border: 1px solid #ddd;
    cursor: pointer;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.filter-chip:hover {
    background: #e2e2e2;
    border-color: #bbb;
}

.filter-chip-input:checked + .filter-chip,
.filter-chip-active {
    background: var(--color-primary, #2a5298);
    color: #fff;
    border-color: var(--color-primary, #2a5298);
}

/* ===== Category Items (Sidebar) ===== */
.category-item {
    padding: 0.5rem 0;
    cursor: pointer;
    transition: all 0.3s;
}

.category-item:hover {
    color: var(--color-primary, #2a5298);
    padding-left: 10px;
}

.category-item.active {
    color: var(--color-primary, #2a5298);
    font-weight: bold;
    padding-left: 10px;
}

/* Mobile collapsible subcategory toggle */
.subcategory-toggle {
    cursor: pointer;
    padding: 0.5rem 0.25rem;
    color: #6c757d;
    transition: color 0.2s;
    position: absolute;
    right: 0;
}

.subcategory-toggle:hover {
    color: var(--color-primary, #2a5298);
}

/* ===== Product Cards (Public Storefront) — Blueprint A design — Gitea #54 ===== */
.product-card {
    border: none;
    border-radius: 16px;
    overflow: hidden;
    transition: transform 0.28s ease, box-shadow 0.28s ease;
    box-shadow: 0 2px 14px rgba(42, 82, 152, 0.11);
}

.product-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 36px rgba(42, 82, 152, 0.20);
}

/* ── Image wrap with name overlay ── */
.pc-img-wrap {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: #f0f3f8;
}

.pc-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.35s ease;
}

.product-card:hover .pc-img {
    transform: scale(1.05);
}

.pc-name-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 2rem 0.875rem 0.75rem;
    background: linear-gradient(to top, rgba(0,0,0,0.75) 0%, rgba(0,0,0,0.28) 55%, transparent 100%);
}

.pc-product-name {
    font-size: 0.9rem;
    font-weight: 600;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ── Card body content grid (price|qty / axis1|axis2 / axis3|empty) ── */
.pc-content-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
    margin-bottom: 0.65rem;
}

.pc-content-grid > * { min-width: 0; }

/* ── Price cell ── */
.pc-price-cell {
    align-self: center;
}

.pc-price-pill {
    display: flex;
    align-items: center;
    background: #eff4ff;
    border: 1px solid #c7d8f8;
    border-radius: 8px;
    padding: 0.28rem 0.6rem;
}

.pc-price-stacked {
    display: flex;
    width: 100%;
    align-items: center;
    gap: 0.35rem;
}

.pc-price-nums {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.05rem;
    line-height: 1.2;
    font-family: var(--font-heading, system-ui);
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--color-primary, #2a5298);
}

.pc-currency {
    font-family: var(--font-heading, system-ui);
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--color-primary, #2a5298);
    align-self: center;
    flex-shrink: 0;
}

.pc-price-resolved {
    color: var(--color-primary, #2a5298);
}

.pc-price-single {
    font-size: 1rem;
    font-weight: 700;
    color: var(--color-primary, #2a5298);
}

/* Ensure .pc-price-pill.hide works over display:flex */
.pc-price-cell > .pc-price-range.hide { display: none; }

/* ── Fallback stock hint (5+-axis configurable cards) ── */
.pc-stock-hint {
    font-size: 0.7rem;
    font-weight: 600;
    margin-top: 0.25rem;
}
.pc-stock-in  { color: #16a34a; }
.pc-stock-out { color: #dc2626; }

/* ── Qty cell ── */
.pc-qty-cell {
    align-self: center;
    display: flex;
    flex-direction: column;
    gap: 0.28rem;
}

.pc-label {
    font-size: 0.67rem;
    font-weight: 700;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    display: block;
}

.pc-qty-wrap {
    display: flex;
    border: 1.5px solid #e2e8f0;
    border-radius: 9px;
    overflow: hidden;
    background: #fff;
    transition: border-color 0.18s;
    min-width: 0;
}

.pc-qty-wrap:focus-within {
    border-color: var(--color-primary, #2a5298);
    box-shadow: 0 0 0 3px rgba(42, 82, 152, 0.11);
}

.pc-qty-dec,
.pc-qty-inc {
    width: 30px;
    height: 34px;
    border: none;
    background: none;
    font-size: 1rem;
    color: #64748b;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.12s;
    flex-shrink: 0;
}

.pc-qty-dec:hover,
.pc-qty-inc:hover { background: #f1f5f9; color: var(--color-primary, #2a5298); }

.pc-qty-input {
    flex: 1;
    min-width: 0;
    border: none;
    border-left: 1px solid #e2e8f0;
    border-right: 1px solid #e2e8f0;
    text-align: center;
    font-size: 0.875rem;
    font-weight: 700;
    height: 34px;
    padding: 0;
    background: #fff;
    -moz-appearance: textfield;
}

.pc-qty-input:focus { outline: none; }
.pc-qty-input::-webkit-inner-spin-button,
.pc-qty-input::-webkit-outer-spin-button { -webkit-appearance: none; }

/* ── Axis select cells ── */
.pc-axis-cell {
    display: flex;
    flex-direction: column;
    gap: 0.28rem;
    min-width: 0;
}

.pc-axis-empty { /* spacer cell for grids with odd axis count (1 or 3 axes) */ }

.pc-select {
    width: 100%;
    padding: 0.44rem 0.6rem;
    border: 1.5px solid #e2e8f0;
    border-radius: 9px;
    font-size: 0.85rem;
    color: #1a202c;
    background: #fff;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    transition: border-color 0.18s;
    min-width: 0;
}

.pc-select:focus {
    outline: none;
    border-color: var(--color-primary, #2a5298);
    box-shadow: 0 0 0 3px rgba(42, 82, 152, 0.11);
}

/* ── Add-to-cart button ── */
.pc-add-btn {
    transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
}

.pc-add-btn:hover:not(:disabled) {
    background-color: var(--color-accent, #e63946) !important;
    border-color: var(--color-accent, #e63946) !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(230, 57, 70, 0.30);
}

.pc-add-btn:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

/* Legacy rules kept for backward compatibility with any remaining uses */
.product-card-img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.product-card .product-price { font-size: 1.25rem; font-weight: bold; color: var(--color-primary, #2a5298); }
.product-card .product-price-old { text-decoration: line-through; color: #6c757d; font-size: 1rem; margin-right: 0.5rem; }

/* ===== Shopping Cart ===== */
.cart-item {
    border-bottom: 1px solid #dee2e6;
    padding: 1rem 0;
}

.cart-item:last-child {
    border-bottom: none;
}

.cart-summary {
    background: #f8f9fa;
    border-radius: var(--theme-border-radius);
    padding: 1.5rem;
}

.cart-summary .summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.75rem;
}

.cart-summary .summary-total {
    font-size: 1.5rem;
    font-weight: bold;
    border-top: 2px solid #dee2e6;
    padding-top: 1rem;
    margin-top: 1rem;
}

/* ===== Order Status Timeline ===== */
.order-timeline {
    position: relative;
    padding-left: 2rem;
}

.order-timeline::before {
    content: '';
    position: absolute;
    left: 8px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: #dee2e6;
}

.order-timeline-item {
    position: relative;
    margin-bottom: 2rem;
}

.order-timeline-item::before {
    content: '';
    position: absolute;
    left: -1.5rem;
    top: 5px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #dee2e6;
    border: 3px solid #fff;
}

.order-timeline-item.active::before {
    background: var(--color-primary, #2a5298);
}

.order-timeline-item.completed::before {
    background: #28a745;
}

/* ===== Auth Pages (Login, Password Reset) ===== */
.auth-page {
    --hero-bg: var(--color-primary, #2a5298);
    background: #fff;
    min-height: 100vh;
    display: flex;
    align-items: center;
    font-family: var(--font-body, 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif);
}

.auth-card {
    max-width: 450px;
    margin: 2rem auto;
}

.auth-page .card {
    border: none;
    border-radius: var(--theme-border-radius);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.auth-page .card-header {
    background: var(--hero-bg);
    color: #fff;
    border-radius: var(--theme-border-radius) var(--theme-border-radius) 0 0 !important;
    padding: 2rem;
    text-align: center;
}

.auth-page .card-header h2 {
    margin: 0;
    font-weight: 600;
}

.auth-page .card-body {
    padding: 2rem;
}

.auth-page .form-label {
    font-weight: 500;
    color: #495057;
}

.auth-page .form-control:focus {
    border-color: var(--hero-bg);
    box-shadow: 0 0 0 0.2rem rgba(0, 0, 0, 0.1);
}

.auth-page .btn-primary {
    background: var(--hero-bg);
    border: none;
    padding: 0.75rem 2rem;
    font-weight: 500;
    border-radius: var(--theme-border-radius);
    transition: transform 0.2s;
}

.auth-page .btn-primary:hover {
    transform: translateY(-2px);
    filter: brightness(0.9);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.auth-page .alert {
    border-radius: var(--theme-border-radius);
    border: none;
}

.auth-page .password-wrapper,
.register-page .password-wrapper {
    position: relative;
}

.auth-page .password-toggle,
.register-page .password-toggle {
    position: absolute;
    right: 1px;
    top: 1px;
    bottom: 1px;
    padding: 0 12px;
    display: flex;
    align-items: center;
    cursor: pointer;
    color: #6c757d;
    background: #f8f9fa;
    border-left: 1px solid #ced4da;
    border-radius: 0 0.375rem 0.375rem 0;
}

.auth-page .password-toggle:hover,
.register-page .password-toggle:hover {
    color: #495057;
    background: #e9ecef;
}

.auth-page .links {
    text-align: center;
    margin-top: 1.5rem;
}

.auth-page .links a {
    color: var(--hero-bg);
    text-decoration: none;
    display: block;
    margin: 0.5rem 0;
}

.auth-page .links a:hover {
    text-decoration: underline;
}

.auth-page .back-link {
    text-align: center;
    margin-top: 1rem;
}

.auth-page .back-link a {
    color: var(--hero-bg);
    text-decoration: none;
}

.auth-page .back-link a:hover {
    text-decoration: underline;
}

/* Success card */
.auth-page .success-card {
    max-width: 550px;
    margin: 2rem auto;
}

.auth-page .success-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

.auth-page .success-icon.animate-envelope {
    animation: theme-envelope 0.8s ease-in-out;
}

.auth-page .info-text {
    font-size: 1.1rem;
    color: #495057;
    margin: 1.5rem 0;
}

.auth-page .email-highlight {
    color: var(--hero-bg);
    font-weight: 600;
}

.auth-page .info-box {
    background: #e7f3ff;
    border-left: 4px solid var(--hero-bg);
    padding: 1rem;
    border-radius: var(--theme-border-radius);
    margin: 1.5rem 0;
    text-align: left;
}

.auth-page .info-box ul {
    margin: 0.5rem 0 0 0;
    padding-left: 1.5rem;
}

.auth-page .info-box li {
    margin: 0.5rem 0;
    color: #495057;
}

.auth-page .card-header.success-header {
    background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
}

.auth-page .success-icon.animate-checkmark {
    animation: theme-checkmark 0.8s ease-in-out;
}

/* Password requirements */
.password-requirements {
    background: #f8f9fa;
    padding: 1rem;
    border-radius: var(--theme-border-radius);
    margin-top: 1rem;
    font-size: 0.9rem;
}

.password-requirements ul {
    margin: 0.5rem 0 0 0;
    padding-left: 0;
    list-style: none;
}

.password-requirements li {
    margin: 0.25rem 0;
    padding-left: 1.5rem;
    position: relative;
}

.password-requirements li.valid {
    color: #28a745;
}

.password-requirements li.invalid {
    color: #dc3545;
}

.password-requirements li::before {
    position: absolute;
    left: 0;
    font-family: 'bootstrap-icons';
    font-weight: bold;
}

.password-requirements li.valid::before {
    content: "\f26b";
    color: #28a745;
}

.password-requirements li.invalid::before {
    content: "\f659";
    color: #dc3545;
}

/* ===== Registration Pages ===== */
.register-page {
    --hero-bg: var(--color-primary, #2a5298);
    background: #fff;
    min-height: 100vh;
    display: flex;
    align-items: center;
    font-family: var(--font-body, 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif);
}

.register-page.centered {
    justify-content: center;
    padding: 2rem 0;
}

.register-page .register-container {
    max-width: 550px;
    width: 100%;
    padding: 20px;
}

.register-page .register-card {
    max-width: 600px;
    margin: 2rem auto;
}

.register-page .register-card.wide {
    max-width: 700px;
}

.register-page .register-card-simple {
    background: #fff;
    border-radius: var(--theme-border-radius);
    padding: 3rem 2.5rem;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
}

.register-page .card {
    border: none;
    border-radius: var(--theme-border-radius);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.register-page .card-header {
    background: var(--hero-bg);
    color: #fff;
    border-radius: var(--theme-border-radius) var(--theme-border-radius) 0 0 !important;
    padding: 2rem;
    text-align: center;
}

.register-page .card-header h2 {
    margin: 0;
    font-weight: 600;
}

.register-page .card-header p {
    margin: 0.5rem 0 0 0;
    opacity: 0.9;
}

.register-page .card-body {
    padding: 2rem;
}

.register-page .card-body.text-center {
    text-align: center;
}

.register-page .form-label {
    font-weight: 500;
    color: #495057;
}

.register-page .form-floating {
    margin-bottom: 1rem;
}

.register-page .form-control:focus,
.register-page .form-select:focus {
    border-color: var(--hero-bg);
    box-shadow: 0 0 0 0.2rem rgba(0, 0, 0, 0.1);
}

.register-page .btn-primary {
    background: var(--hero-bg);
    border: none;
    padding: 0.75rem 2rem;
    font-weight: 500;
    border-radius: var(--theme-border-radius);
    transition: transform 0.2s;
}

.register-page .btn-primary:hover {
    transform: translateY(-2px);
    filter: brightness(0.9);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.register-page .alert {
    border-radius: var(--theme-border-radius);
    border: none;
}

.register-page .brand-logo {
    text-align: center;
    margin-bottom: 2rem;
}

.register-page .brand-logo i {
    font-size: 4rem;
    color: var(--hero-bg);
}

.register-page .brand-logo h2 {
    color: #343a40;
    margin-top: 1rem;
    font-weight: 600;
}

/* Step indicator */
.register-page .step-indicator {
    display: flex;
    justify-content: center;
    margin-bottom: 2rem;
}

.register-page .step {
    flex: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #e9ecef;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    margin: 0 0.5rem;
    position: relative;
}

.register-page .step.active {
    background: var(--hero-bg);
    color: #fff;
}

.register-page .step.completed {
    background: #28a745;
    color: #fff;
}

.register-page .step:not(:last-child)::after {
    content: '';
    position: absolute;
    width: 50px;
    height: 2px;
    background: #e9ecef;
    left: 100%;
    top: 50%;
    transform: translateY(-50%);
}

.register-page .step.completed:not(:last-child)::after {
    background: #28a745;
}

.register-page .step.pending {
    background: #e9ecef;
    color: #6c757d;
}

.register-page .step.pending::after {
    background: #e9ecef;
}

.register-page .step.in-progress {
    background: #fd7e14;
    color: #fff;
}

.register-page .step.in-progress::after {
    background: #e9ecef;
}

.register-page .user-info {
    background: #f8f9fa;
    padding: 1rem;
    border-radius: var(--theme-border-radius);
    margin-bottom: 1.5rem;
}

.register-page .user-info strong {
    color: var(--hero-bg);
}

.register-page .section-header {
    font-weight: 600;
    color: var(--hero-bg);
    margin-top: 1.5rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #e9ecef;
}

.register-page .form-check-input:checked {
    background-color: var(--hero-bg);
    border-color: var(--hero-bg);
}

.register-page .back-link {
    text-align: center;
    margin-top: 1rem;
}

.register-page .back-link a {
    color: var(--hero-bg);
    text-decoration: none;
}

.register-page .back-link a:hover {
    text-decoration: underline;
}

/* Password strength indicator */
.register-page .password-strength {
    height: 5px;
    border-radius: var(--theme-border-radius);
    margin-top: 0.5rem;
    transition: all 0.3s;
}

.register-page .strength-weak {
    background: #dc3545;
    width: 33%;
}

.register-page .strength-medium {
    background: #ffc107;
    width: 66%;
}

.register-page .strength-strong {
    background: #28a745;
    width: 100%;
}

.register-page .divider {
    text-align: center;
    margin: 1.5rem 0;
    position: relative;
}

.register-page .divider::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    width: 100%;
    height: 1px;
    background: #dee2e6;
}

.register-page .divider span {
    background: #fff;
    padding: 0 1rem;
    position: relative;
    color: #6c757d;
}

.register-page .social-login {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.register-page .social-btn {
    flex: 1;
    padding: 0.75rem;
    border: 1px solid #dee2e6;
    border-radius: var(--theme-border-radius);
    background: #fff;
    cursor: pointer;
    transition: all 0.3s;
}

.register-page .social-btn:hover {
    border-color: var(--hero-bg);
    background: #f8f9fa;
}

.register-page .footer-links {
    text-align: center;
    margin-top: 1.5rem;
}

.register-page .footer-links a {
    color: var(--hero-bg);
    text-decoration: none;
}

.register-page .footer-links a:hover {
    text-decoration: underline;
}

.register-page .benefits {
    background: #f8f9fa;
    border-radius: var(--theme-border-radius);
    padding: 1rem;
    margin-bottom: 1.5rem;
}

.register-page .benefits ul {
    margin: 0;
    padding-left: 1.5rem;
}

.register-page .benefits li {
    margin-bottom: 0.5rem;
}

.register-page .success-card {
    max-width: 550px;
    margin: 2rem auto;
}

.register-page .success-card.wide {
    max-width: 600px;
}

.register-page .success-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

.register-page .success-icon.large {
    font-size: 5rem;
}

.register-page .success-icon.animate-envelope {
    animation: theme-envelope 0.8s ease-in-out;
}

.register-page .success-icon.animate-checkmark {
    animation: theme-checkmark 0.8s ease-in-out;
}

.register-page .info-text {
    font-size: 1.1rem;
    color: #495057;
    margin: 1.5rem 0;
}

.register-page .email-highlight {
    color: var(--hero-bg);
    font-weight: 600;
}

.register-page .info-box {
    background: #d4edda;
    border-left: 4px solid #28a745;
    padding: 1rem;
    border-radius: var(--theme-border-radius);
    margin: 1.5rem 0;
    text-align: left;
}

.register-page .info-box ul {
    margin: 0.5rem 0 0 0;
    padding-left: 1.5rem;
}

.register-page .info-box li {
    margin: 0.5rem 0;
    color: #495057;
}

.register-page .user-details {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: var(--theme-border-radius);
    margin: 1.5rem 0;
    text-align: left;
}

.register-page .user-details strong {
    color: var(--hero-bg);
}

/* ===== Membership Pages (Public) ===== */
.membership-page .card {
    border: none;
    border-radius: var(--theme-border-radius);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
}

.tier-badge {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: inline-block;
    vertical-align: middle;
}

.tier-filter {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.tier-radio {
    display: none;
}

.tier-radio-label {
    padding: 0.5rem 1.25rem;
    border: 2px solid #dee2e6;
    border-radius: var(--theme-border-radius-badge);
    cursor: pointer;
    transition: all 0.3s;
    background: #fff;
    font-weight: 500;
}

.tier-radio-label:hover {
    border-color: var(--color-primary, #2a5298);
    background: #f8f9fa;
}

.tier-radio:checked + .tier-radio-label {
    border-color: var(--color-primary, #2a5298);
    background: var(--color-primary, #2a5298);
    color: #fff;
}

/* Request cards */
.request-card {
    border-left: 5px solid;
    transition: all 0.3s;
}

.request-card:hover {
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.request-pending {
    border-left-color: #ffc107;
}

.request-approved {
    border-left-color: #28a745;
}

.request-rejected {
    border-left-color: #dc3545;
}

.status-badge {
    padding: 0.5rem 1rem;
    border-radius: var(--theme-border-radius-badge);
    font-weight: bold;
}

/* Filter tabs */
.filter-tabs .nav-link {
    border-radius: var(--theme-border-radius) var(--theme-border-radius) 0 0;
    color: #495057;
    background: #e9ecef;
    border: 1px solid #dee2e6;
    margin-right: 0.25rem;
}

.filter-tabs .nav-link:hover {
    background: #dee2e6;
    color: #212529;
}

.filter-tabs .nav-link.active {
    background: #fff;
    border-bottom-color: #fff;
    color: var(--color-primary, #2a5298);
    font-weight: 600;
}

/* ===== Public Page Layout ===== */
.public-page .main-content {
    padding: 2rem 0;
}

/* ===== Buttons (Theme-specific) ===== */
.btn-theme-primary {
    background: var(--color-primary, #2a5298);
    border-color: var(--color-primary, #2a5298);
    color: #fff;
}

.btn-theme-primary:hover {
    filter: brightness(0.9);
    color: #fff;
}

.btn-theme-accent {
    background: var(--color-accent, #e63946);
    border-color: var(--color-accent, #e63946);
    color: #fff;
}

.btn-theme-accent:hover {
    filter: brightness(0.9);
    color: #fff;
}

/* ===== Animations ===== */
@keyframes theme-envelope {
    0% {
        transform: scale(0) rotate(-180deg);
        opacity: 0;
    }
    50% {
        transform: scale(1.2) rotate(10deg);
    }
    100% {
        transform: scale(1) rotate(0deg);
        opacity: 1;
    }
}

@keyframes theme-checkmark {
    0% {
        transform: scale(0);
        opacity: 0;
    }
    50% {
        transform: scale(1.2);
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

/* ===== Responsive ===== */
@media (max-width: 767.98px) {
    .auth-card {
        margin: 1rem;
    }

    /* Touch-friendly minimum tap target size (WCAG 2.5.5) */
    .input-group .btn,
    .quantity-btn {
        min-width: 44px;
        min-height: 44px;
    }
}

@media (max-width: 575.98px) {
    .container {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }
}

/* Footer */
.social-links a:hover {
    opacity: 0.7;
    transition: opacity 0.3s;
}

footer a:hover {
    color: white !important;
    transition: color 0.3s;
}

/* Membership tier cards */
.tier-card {
    border-radius: 15px;
    padding: 2rem;
    border: 3px solid transparent;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s;
}
.tier-card--active {
    border-color: #28a745;
    box-shadow: 0 5px 20px rgba(40, 167, 69, 0.3);
}

/* Search page */
.search-input-group {
    max-width: 600px;
    margin: 0 auto;
}
.search-empty-icon {
    font-size: 4rem;
    color: #dee2e6;
}

/* Back to top button */
.btn-back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 9990;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.3s, transform 0.3s, visibility 0.3s;
    border: none;
    cursor: pointer;
}
.btn-back-to-top:hover {
    opacity: 1;
    transform: translateY(-3px);
}
.btn-back-to-top.show {
    opacity: 0.85;
    visibility: visible;
    pointer-events: auto;
}
@media print {
    .btn-back-to-top { display: none !important; }
}

/* Alternative product names */
.product-alt-names {
    font-size: 0.9rem;
    color: var(--bs-secondary-color, #6c757d);
    margin-top: -0.5rem;
}
.product-alt-names li { line-height: 1.4; }

/* ===== Error pages ===== */
/* Styles for the canonical themes/_shared/templates/errors/error.twig template.
 * Each theme defines these classes in its own theme.css — no inline styles allowed. */
.error-page { min-height: 60vh; display: flex; align-items: center; }
.error-stage { max-width: 640px; margin: 0 auto; text-align: center; padding: 3rem 1rem; }
.error-grid { display: none; }
.section-eyebrow { display: none; }
.error-numeric {
    font-size: clamp(5rem, 14vw, 9rem);
    font-weight: 700;
    line-height: 1;
    background: linear-gradient(180deg, var(--color-primary), color-mix(in srgb, var(--color-primary) 30%, var(--color-accent)));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.04em;
    margin-bottom: 0.5rem;
}
.error-headline { font-size: 2rem; margin-top: 1rem; font-family: var(--font-heading, system-ui); text-wrap: pretty; }
.error-sub { color: var(--bs-secondary-color, #6c757d); font-size: 1.05rem; max-width: 48ch; margin: 0.5rem auto 0; text-wrap: pretty; }
.error-sub-small { font-size: 0.92rem; }
.error-path { display: inline-block; margin-top: 1rem; padding: 0.4rem 0.75rem; border: 1px dashed var(--bs-border-color, #dee2e6); background: var(--bs-tertiary-bg, #f8f9fa); border-radius: 0.375rem; color: var(--color-primary); font-size: 0.9rem; }
.error-actions { display: flex; gap: 0.75rem; justify-content: center; margin-top: 1.75rem; flex-wrap: wrap; }
