/* ========== VARIABLES & RESET ========== */
:root {
    --bg: #0f0f1a;
    --bg-card: #1a1a2e;
    --bg-card-hover: #1f1f35;
    --bg-input: #ffffff;
    --border: rgba(255, 255, 255, 0.08);
    --border-light: rgba(255, 255, 255, 0.12);
    --text: #e2e8f0;
    --text-muted: #94a3b8;
    --text-dim: #64748b;
    --text-input: #1a1a2e;
    --accent: #5a67d8;
    --accent-hover: #4c56c0;
    --success: #10b981;
    --danger: #ef4444;
    --warning: #f59e0b;
    --radius: 12px;
    --radius-sm: 8px;
    --transition: 0.25s ease;
}

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

body {
    background: var(--bg);
    color: var(--text);
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.main-wrap { flex: 1; }
a { color: inherit; }

/* ========== NAVBAR ========== */
.navbar-header {
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    padding: 0.8rem 1.5rem;
    position: sticky;
    top: 0;
    z-index: 100;
}

.navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
}

.navbar-brand {
    color: #fff;
    text-decoration: none;
    font-size: 1.3rem;
    font-weight: 800;
    letter-spacing: -0.3px;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.navbar-logo {
    width: 28px;
    height: 28px;
    object-fit: contain;
}

.navbar-menu {
    display: flex;
    list-style: none;
    gap: 2.5rem;
    flex: 1;
    justify-content: center;
}

.nav-link {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    padding: 0.3rem 0;
    transition: color var(--transition);
}

.nav-link:hover {
    color: #fff;
}

.nav-cart-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--accent);
    color: #fff;
    font-size: 0.6rem;
    font-weight: 700;
    min-width: 17px;
    height: 17px;
    border-radius: 9px;
    padding: 0 4px;
    margin-left: 5px;
    vertical-align: middle;
}

.nav-cat-wrap { position: relative; }

.nav-cat-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%);
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-sm);
    min-width: 200px;
    list-style: none;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
    z-index: 999;
    overflow: hidden;
    padding: 0.3rem 0;
}

.nav-cat-wrap:hover .nav-cat-dropdown { display: block; }

.nav-cat-dropdown li a {
    display: block;
    padding: 0.55rem 1.1rem;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.82rem;
    transition: all var(--transition);
}

.nav-cat-dropdown li a:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
}

.navbar-buttons {
    display: flex;
    gap: 0.6rem;
    align-items: center;
}

/* ========== BUTTONS ========== */
.btn {
    padding: 0.5rem 1.1rem;
    border-radius: var(--radius-sm);
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 600;
    transition: all var(--transition);
    cursor: pointer;
    border: none;
    font-family: inherit;
}

.btn-login {
    color: var(--text-muted);
    border: 1px solid var(--border-light);
    background: transparent;
}

.btn-login:hover {
    color: #fff;
    border-color: rgba(255, 255, 255, 0.25);
}

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

.btn-register:hover {
    background: var(--accent-hover);
    border-color: var(--accent-hover);
}

.btn-vendor {
    padding: 0.5rem 1.1rem;
    border-radius: var(--radius-sm);
    font-size: 0.82rem;
    font-weight: 600;
    text-decoration: none;
    background: var(--warning);
    color: #fff;
    border: 1px solid var(--warning);
    cursor: pointer;
    transition: all var(--transition);
    font-family: inherit;
}

.btn-vendor:hover {
    background: #d97706;
    border-color: #d97706;
}

.btn-disabled {
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-dim);
    cursor: not-allowed;
    border: 1px solid var(--border);
}

/* ========== AVATAR & DROPDOWN ========== */
.nav-avatar-wrap { position: relative; }

.nav-avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: var(--accent);
    color: #fff;
    font-weight: 700;
    font-size: 0.95rem;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background var(--transition);
}

.nav-avatar:hover {
    background: var(--accent-hover);
}

.nav-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-sm);
    min-width: 210px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
    z-index: 1000;
    overflow: hidden;
}

.nav-dropdown.open { display: block; }

.nav-dropdown-header {
    padding: 0.9rem 1.1rem 0.7rem;
    border-bottom: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
}

.nav-dropdown-pseudo { font-weight: 700; font-size: 0.9rem; color: #fff; }
.nav-dropdown-email { font-size: 0.72rem; color: var(--text-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.nav-dropdown-item {
    display: block;
    padding: 0.6rem 1.1rem;
    font-size: 0.82rem;
    color: var(--text-muted);
    text-decoration: none;
    transition: all var(--transition);
}

.nav-dropdown-item:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
}

.nav-dropdown-vendor { color: var(--warning); }
.nav-dropdown-divider { height: 1px; background: var(--border); margin: 0.2rem 0; }
.nav-dropdown-admin { color: #60a5fa; }
.nav-dropdown-admin:hover { background: rgba(96, 165, 250, 0.08); }
.nav-dropdown-logout { color: var(--danger); }
.nav-dropdown-logout:hover { background: rgba(239, 68, 68, 0.08); }

/* ========== FOOTER ========== */
.footer {
    background: var(--bg);
    border-top: 1px solid var(--border);
    padding: 2.5rem 1.5rem 2rem;
    margin-top: auto;
}

.footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr 1.5fr;
    gap: 2rem;
}

.footer-brand {
    font-size: 1.3rem;
    font-weight: 800;
    color: #fff;
    margin-bottom: 0.8rem;
}

.footer-contact p {
    font-size: 0.82rem;
    color: var(--text-muted);
    line-height: 1.8;
}

.footer-nav-title,
.footer-about-title {
    font-size: 0.85rem;
    font-weight: 700;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 0.8rem;
}

.footer-nav-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.footer-nav-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.82rem;
    transition: color var(--transition);
}

.footer-nav-links a:hover { color: #fff; }

.footer-about p {
    color: var(--text-muted);
    font-size: 0.82rem;
    line-height: 1.7;
}

.footer-copy {
    max-width: 1200px;
    margin: 1.5rem auto 0;
    padding-top: 1rem;
    border-top: 1px solid var(--border);
    font-size: 0.75rem;
    color: var(--text-dim);
    text-align: center;
}

/* ========== HOME / HERO ========== */
.main {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 60vh;
    padding: 2rem 1rem;
}

.main h1 {
    font-size: 3.5rem;
    font-weight: 900;
    text-align: center;
    margin-bottom: 0.8rem;
    color: #fff;
    line-height: 1.15;
}

.main h2 {
    font-size: 1.2rem;
    font-weight: 400;
    text-align: center;
    color: var(--text-muted);
    margin-bottom: 2.5rem;
}

.home-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.home-actions .btn {
    padding: 0.7rem 1.8rem;
    font-size: 0.9rem;
}

/* ========== CATALOGUE ========== */
.catalogue {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 1.5rem;
}

.catalogue-title {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 2rem;
    text-align: center;
    color: #fff;
}

.catalogue-empty { text-align: center; color: var(--text-dim); font-size: 0.95rem; }

.catalogue-filters {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 2rem;
}

.filter-btn {
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.78rem;
    font-weight: 500;
    text-decoration: none;
    color: var(--text-muted);
    background: transparent;
    border: 1px solid var(--border-light);
    transition: all var(--transition);
}

.filter-btn:hover {
    color: #fff;
    border-color: rgba(255, 255, 255, 0.25);
}

.filter-btn.active {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
    transition: all var(--transition);
}

.card:hover {
    border-color: var(--border-light);
    background: var(--bg-card-hover);
    transform: translateY(-2px);
}

.card-title { font-size: 1.1rem; font-weight: 700; color: #fff; }

.card-badges { display: flex; gap: 0.4rem; align-items: center; flex-wrap: wrap; }

.card-category {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 600;
    background: rgba(90, 103, 216, 0.15);
    color: #818cf8;
    padding: 0.2rem 0.6rem;
    border-radius: 20px;
}

.card-stock-badge {
    display: inline-block;
    font-size: 0.68rem;
    font-weight: 600;
    background: rgba(239, 68, 68, 0.12);
    color: #fca5a5;
    padding: 0.2rem 0.6rem;
    border-radius: 20px;
}

.card-out-of-stock { opacity: 0.45; }
.card-out-of-stock:hover { transform: none; }

.card-description { font-size: 0.85rem; color: var(--text-muted); flex: 1; line-height: 1.5; }

.card-price { font-size: 1.1rem; font-weight: 700; color: #fff; }

.btn-card {
    display: inline-block;
    background: var(--accent);
    color: #fff;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    text-decoration: none;
    text-align: center;
    margin-top: auto;
    font-weight: 600;
    font-size: 0.82rem;
    transition: background var(--transition);
}

.btn-card:hover {
    background: var(--accent-hover);
}

/* ========== PRODUCT SHOW ========== */
.product-show {
    max-width: 800px;
    margin: 2rem auto;
    padding: 0 1.5rem;
}

.product-back {
    display: inline-block;
    color: var(--text-dim);
    text-decoration: none;
    margin-bottom: 1.5rem;
    font-size: 0.85rem;
    transition: color var(--transition);
}

.product-back:hover { color: #fff; }

.product-show-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 2.5rem;
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.product-show-title {
    font-size: 2rem;
    font-weight: 800;
    color: #fff;
}

.product-show-description { color: var(--text-muted); line-height: 1.8; }

.product-show-footer { display: flex; align-items: center; gap: 1.5rem; }

.product-show-price { font-size: 1.6rem; font-weight: 800; color: #fff; }

.product-show-stock { font-size: 0.85rem; color: var(--text-dim); }

.product-show-btn {
    align-self: flex-start;
    padding: 0.7rem 1.8rem;
    font-size: 0.95rem;
}

/* ========== CART ========== */
.cart-wrap { max-width: 850px; margin: 2rem auto; padding: 0 1.5rem; }

.cart-title {
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    color: #fff;
}

.cart-table-wrap { overflow-x: auto; }

.cart-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--bg-card);
    border-radius: var(--radius-sm);
    overflow: hidden;
    border: 1px solid var(--border);
}

.cart-table thead { background: rgba(255, 255, 255, 0.03); }

.cart-table th {
    padding: 0.9rem 1.1rem;
    text-align: left;
    font-size: 0.72rem;
    color: var(--text-dim);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 600;
}

.cart-table td {
    padding: 0.9rem 1.1rem;
    border-top: 1px solid var(--border);
    font-size: 0.88rem;
    vertical-align: middle;
}

.cart-table tbody tr { transition: background var(--transition); }
.cart-table tbody tr:hover { background: rgba(255, 255, 255, 0.02); }

.cart-product-name a {
    color: var(--text);
    text-decoration: none;
    font-weight: 600;
    transition: color var(--transition);
}

.cart-product-name a:hover { color: var(--accent); }

.cart-qty { display: flex; align-items: center; gap: 0.5rem; }

.cart-qty-btn {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    color: var(--text);
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    transition: all var(--transition);
}

.cart-qty-btn:hover {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
}

.cart-subtotal { font-weight: 700; color: #fff; }

.cart-remove {
    color: var(--danger);
    text-decoration: none;
    font-size: 1rem;
    transition: color var(--transition);
}

.cart-remove:hover { color: #ff6b6b; }

.cart-footer {
    margin-top: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.cart-total { font-size: 1.2rem; color: var(--text); }
.cart-total strong { color: #fff; font-weight: 800; }

.cart-actions { display: flex; gap: 0.5rem; flex-wrap: wrap; }

/* ========== ORDER ========== */
.order-wrap { max-width: 750px; margin: 2rem auto; padding: 0 1.5rem; }

.order-title {
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    color: #fff;
}

.order-subtitle { font-size: 1.1rem; font-weight: 700; margin-bottom: 1rem; color: #fff; }

.order-total { text-align: right; font-size: 1.2rem; margin: 1.2rem 0; color: var(--text); }
.order-total strong { color: #fff; font-weight: 800; }

.order-form { margin-top: 1.5rem; }

.order-form textarea {
    width: 100%;
    padding: 0.65rem 0.9rem;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: var(--bg-input);
    color: var(--text-input);
    font-size: 0.9rem;
    outline: none;
    resize: vertical;
    font-family: inherit;
    transition: border-color var(--transition);
}

.order-form textarea:focus {
    border-color: var(--accent);
}

.order-address-row { display: grid; grid-template-columns: 1fr 2fr; gap: 1rem; }

.order-actions {
    display: flex;
    gap: 0.7rem;
    justify-content: flex-end;
    margin-top: 1.5rem;
    flex-wrap: wrap;
}

.order-confirmation-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 2.5rem 2rem;
    text-align: center;
}

.order-check {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: rgba(16, 185, 129, 0.12);
    color: var(--success);
    font-size: 2rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
}

.order-conf-subtitle { color: var(--text-dim); font-size: 0.9rem; margin-bottom: 1.5rem; }

.order-email-notice {
    background: rgba(96, 165, 250, 0.08);
    border: 1px solid rgba(96, 165, 250, 0.2);
    color: #93c5fd;
    padding: 0.7rem 1.1rem;
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    margin: 1rem 0;
}

.order-conf-details {
    text-align: left;
    border-top: 1px solid var(--border);
    padding-top: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

/* ========== AUTH FORMS ========== */
.auth-form-wrap {
    max-width: 440px;
    margin: 3rem auto;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 2.5rem 2rem;
}

.auth-title {
    font-size: 1.6rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    text-align: center;
    color: #fff;
}

.auth-error {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.25);
    color: #fca5a5;
    padding: 0.7rem 1rem;
    border-radius: var(--radius-sm);
    margin-bottom: 1rem;
    font-size: 0.85rem;
}

.auth-success {
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.25);
    color: #6ee7b7;
    padding: 0.7rem 1rem;
    border-radius: var(--radius-sm);
    margin-bottom: 1rem;
    font-size: 0.85rem;
}

.auth-form { display: flex; flex-direction: column; gap: 1rem; }

.auth-field { display: flex; flex-direction: column; gap: 0.35rem; }

.auth-field label { font-size: 0.8rem; color: var(--text-muted); font-weight: 500; }

.auth-field input {
    padding: 0.65rem 0.9rem;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: var(--bg-input);
    color: var(--text-input);
    font-size: 0.9rem;
    outline: none;
    transition: border-color var(--transition);
    font-family: inherit;
}

.auth-field input:focus {
    border-color: var(--accent);
}

.auth-field textarea {
    padding: 0.65rem 0.9rem;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: var(--bg-input);
    color: var(--text-input);
    font-size: 0.9rem;
    outline: none;
    transition: border-color var(--transition);
    font-family: inherit;
    resize: vertical;
    width: 100%;
}

.auth-field textarea:focus {
    border-color: var(--accent);
}

.auth-field select {
    padding: 0.65rem 0.9rem;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: var(--bg-input);
    color: var(--text-input);
    font-size: 0.9rem;
    outline: none;
    transition: border-color var(--transition);
    font-family: inherit;
}

.auth-field select:focus {
    border-color: var(--accent);
}

.auth-form input[type="text"],
.auth-form input[type="email"],
.auth-form input[type="password"],
.auth-form input[type="number"],
.auth-form input[type="tel"],
.auth-form input[type="url"],
.auth-form select,
.auth-form textarea,
.order-form input[type="text"],
.order-form input[type="email"],
.order-form input[type="number"],
.order-form select {
    padding: 0.65rem 0.9rem;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: var(--bg-input);
    color: var(--text-input);
    font-size: 0.9rem;
    outline: none;
    transition: border-color var(--transition);
    font-family: inherit;
    width: 100%;
}

.auth-form input:focus,
.auth-form select:focus,
.auth-form textarea:focus,
.order-form input:focus,
.order-form select:focus {
    border-color: var(--accent);
}

.auth-form label,
.order-form label {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 500;
}

.auth-remember { font-size: 0.8rem; color: var(--text-muted); }
.auth-switch { text-align: center; font-size: 0.8rem; color: var(--text-muted); margin-top: 0.5rem; }
.auth-switch a { color: var(--accent); text-decoration: none; font-weight: 500; transition: color var(--transition); }
.auth-switch a:hover { color: #fff; }

/* ========== PROFILE ========== */
.profile-wrap { max-width: 620px; margin: 3rem auto; padding: 0 1.5rem; }

.profile-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 2.5rem 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.profile-avatar {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: var(--accent);
    color: #fff;
    font-size: 2rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.5rem;
}

.profile-pseudo { font-size: 1.5rem; font-weight: 800; margin: 0; color: #fff; }
.profile-email { font-size: 0.82rem; color: var(--text-dim); margin: 0 0 1rem; }

.profile-info {
    width: 100%;
    border-top: 1px solid var(--border);
    padding-top: 1.2rem;
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
}

.profile-info-row { display: flex; justify-content: space-between; align-items: center; font-size: 0.88rem; }
.profile-info-label { color: var(--text-dim); }
.profile-info-value { color: var(--text); font-weight: 500; }

.profile-badge {
    font-size: 0.7rem;
    padding: 0.2rem 0.6rem;
    border-radius: 20px;
    font-weight: 600;
}

.profile-badge.vendor {
    background: rgba(245, 158, 11, 0.12);
    color: #fcd34d;
}

.profile-badge.user {
    background: rgba(96, 165, 250, 0.12);
    color: #93c5fd;
}

.profile-actions {
    display: flex;
    gap: 0.7rem;
    margin-top: 1.5rem;
    flex-wrap: wrap;
    justify-content: center;
}

.profile-page-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.profile-page-header h1 { margin: 0; font-size: 1.5rem; font-weight: 800; }

.profile-back {
    font-size: 0.82rem;
    color: var(--text-dim);
    text-decoration: none;
    white-space: nowrap;
    transition: color var(--transition);
}

.profile-back:hover { color: #fff; }

.profile-empty {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 3rem 2rem;
    text-align: center;
    color: var(--text-dim);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.2rem;
}

/* ========== ERROR PAGES ========== */
.error-page {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 60vh;
    text-align: center;
    padding: 2rem 1rem;
}

.error-code {
    font-size: 6rem;
    font-weight: 900;
    line-height: 1;
    margin-bottom: 0.5rem;
    color: var(--accent);
}

.error-message { font-size: 1.2rem; color: var(--text); margin-bottom: 0.5rem; }
.error-detail { font-size: 0.88rem; color: var(--text-dim); margin-bottom: 2rem; }

/* ========== LEGAL PAGES ========== */
.legal-wrap { max-width: 800px; margin: 2rem auto; padding: 0 1.5rem 2rem; }

.legal-title {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 2rem;
    text-align: center;
    color: #fff;
}

.legal-section {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 1.5rem;
    margin-bottom: 1rem;
}

.legal-section h2 {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 0.7rem;
}

.legal-section p { color: var(--text-muted); line-height: 1.7; font-size: 0.88rem; margin-bottom: 0.5rem; }
.legal-section ul { color: var(--text-muted); padding-left: 1.5rem; margin: 0.5rem 0; line-height: 1.8; font-size: 0.88rem; }
.legal-section a { color: var(--accent); text-decoration: none; }
.legal-section a:hover { text-decoration: underline; }
.legal-note { color: var(--text-dim); font-style: italic; }

.contact-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    background: transparent;
    border: none;
    padding: 0;
}

.contact-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 1.5rem;
    text-align: center;
    transition: border-color var(--transition);
}

.contact-card:hover { border-color: var(--border-light); }

.contact-card h2 { color: var(--accent); font-size: 0.95rem; margin-bottom: 0.5rem; }
.contact-card p { color: var(--text-muted); font-size: 0.85rem; line-height: 1.6; }
.contact-card a { color: var(--accent); text-decoration: none; }
.contact-card a:hover { text-decoration: underline; }

/* ========== RESPONSIVE ========== */

@media (max-width: 768px) {
    .navbar { flex-wrap: wrap; gap: 0.5rem; }

    .navbar-menu {
        order: 3;
        flex-basis: 100%;
        justify-content: center;
        gap: 1.2rem;
        padding-top: 0.5rem;
    }

    .main h1 { font-size: 2.2rem; }
    .main h2 { font-size: 1rem; }

    .cards-grid { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 1rem; }
    .product-show-title { font-size: 1.5rem; }

    .cart-footer { flex-direction: column; align-items: stretch; }
    .cart-actions { justify-content: center; }
    .order-actions { justify-content: center; }
    .order-address-row { grid-template-columns: 1fr; }

    .profile-card { padding: 1.5rem 1rem; }
    .profile-actions { flex-direction: column; align-items: stretch; }
    .profile-actions .btn { text-align: center; }

    .auth-form-wrap { margin: 1.5rem auto; padding: 1.5rem 1rem; }
    .legal-title { font-size: 1.5rem; }
    .contact-info { grid-template-columns: 1fr; }

    .footer-inner { grid-template-columns: 1fr; gap: 1.5rem; text-align: center; }
}

@media (max-width: 480px) {
    .navbar-header { padding: 0.5rem 0.5rem; }
    .navbar-brand { font-size: 1.1rem; }
    .navbar-menu { gap: 0.8rem; font-size: 0.78rem; }
    .navbar-buttons .btn { padding: 0.4rem 0.7rem; font-size: 0.75rem; }

    .main h1 { font-size: 1.7rem; margin-bottom: 0.6rem; }
    .main h2 { font-size: 0.88rem; }

    .cards-grid { grid-template-columns: 1fr; }
    .catalogue-title { font-size: 1.5rem; }

    .product-show-card { padding: 1.5rem; }
    .product-show-footer { flex-direction: column; align-items: flex-start; gap: 0.5rem; }

    .cart-table th, .cart-table td { padding: 0.6rem 0.5rem; font-size: 0.78rem; }
    .cart-total { font-size: 1rem; text-align: center; }

    .order-confirmation-card { padding: 1.5rem 1rem; }
    .order-check { width: 50px; height: 50px; font-size: 1.5rem; }

    .profile-avatar { width: 56px; height: 56px; font-size: 1.5rem; }
    .profile-pseudo { font-size: 1.2rem; }

    .error-code { font-size: 4rem; }
    .error-message { font-size: 0.95rem; }

    .footer { padding: 1.5rem 0.5rem; }
    .footer-inner { gap: 1rem; }
}
