/* =============================================
 * WHISKIES MUNDIAIS — CUSTOMER ACCOUNT AREA
 * Mobile-First Design System
 * Colors: Dark (#0b0e13, #121620), Gold (#d4af37), Green (#22c55e)
 * ============================================= */

/* === CSS CUSTOM PROPERTIES === */
:root {
    --acc-bg-primary: #0b0e13;
    --acc-bg-card: #121620;
    --acc-bg-card-hover: #1a1f2e;
    --acc-bg-input: #0f1219;
    --acc-border: rgba(212, 175, 55, 0.15);
    --acc-border-active: rgba(212, 175, 55, 0.5);
    --acc-gold: #d4af37;
    --acc-gold-dim: rgba(212, 175, 55, 0.7);
    --acc-green: #22c55e;
    --acc-green-dim: rgba(34, 197, 94, 0.15);
    --acc-red: #ef4444;
    --acc-yellow: #eab308;
    --acc-blue: #3b82f6;
    --acc-text-primary: #f1f1f1;
    --acc-text-secondary: rgba(255, 255, 255, 0.6);
    --acc-text-muted: rgba(255, 255, 255, 0.35);
    --acc-radius: 12px;
    --acc-radius-sm: 8px;
    --acc-radius-pill: 50px;
    --acc-transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    --acc-shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
    --acc-shadow-gold: 0 0 20px rgba(212, 175, 55, 0.08);
    --acc-font: 'Inter', 'Segoe UI', system-ui, sans-serif;
    --acc-bottom-bar-h: 64px;
}

/* === RESET for account scope === */
.acc-wrapper,
.acc-wrapper * {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* === TOP BAR === */
.acc-topbar {
    position: sticky;
    top: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: rgba(11, 14, 19, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--acc-border);
}

.acc-topbar-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.acc-topbar-logo img {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    border: 1px solid rgba(212, 175, 55, 0.3);
    object-fit: cover;
}

.acc-topbar-logo span {
    font-family: var(--acc-font);
    font-size: 14px;
    font-weight: 700;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

.acc-topbar-back {
    display: flex;
    align-items: center;
    gap: 6px;
    font-family: var(--acc-font);
    font-size: 12px;
    font-weight: 500;
    color: var(--acc-green);
    text-decoration: none;
    letter-spacing: 0.5px;
    transition: var(--acc-transition);
    padding: 6px 12px;
    border-radius: var(--acc-radius-pill);
    border: 1px solid rgba(34, 197, 94, 0.2);
}

.acc-topbar-back:hover {
    background: var(--acc-green-dim);
    border-color: rgba(34, 197, 94, 0.4);
}

/* === WRAPPER === */
.acc-wrapper {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background: var(--acc-bg-primary);
    font-family: var(--acc-font);
    color: var(--acc-text-primary);
}

/* === MAIN CONTENT === */
.acc-main {
    flex: 1;
    padding: 16px;
    padding-bottom: calc(var(--acc-bottom-bar-h) + 24px);
    max-width: 900px;
    margin: 0 auto;
    width: 100%;
}

/* === BOTTOM NAVIGATION BAR (Mobile) === */
.acc-bottombar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: space-around;
    height: var(--acc-bottom-bar-h);
    background: rgba(18, 22, 32, 0.97);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-top: 1px solid var(--acc-border);
    padding: 0 4px;
    padding-bottom: env(safe-area-inset-bottom, 0);
}

.acc-bottombar-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    padding: 6px 4px;
    text-decoration: none;
    color: var(--acc-text-muted);
    font-size: 10px;
    font-weight: 500;
    letter-spacing: 0.3px;
    transition: var(--acc-transition);
    border-radius: var(--acc-radius-sm);
    min-width: 56px;
    position: relative;
}

.acc-bottombar-item span[class^="icon-"] {
    font-size: 20px;
    margin-bottom: 1px;
}

.acc-bottombar-item.active,
.acc-bottombar-item:active {
    color: var(--acc-gold);
}

.acc-bottombar-item.active::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 24px;
    height: 2px;
    background: var(--acc-gold);
    border-radius: 0 0 4px 4px;
}

/* === SIDEBAR (Desktop) === */
.acc-sidebar {
    display: none;
}

/* === LOGIN / AUTH FORMS === */
.acc-auth {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - 56px);
    padding: 24px 16px;
}

.acc-auth-card {
    width: 100%;
    max-width: 420px;
    background: var(--acc-bg-card);
    border: 1px solid var(--acc-border);
    border-radius: var(--acc-radius);
    padding: 32px 24px;
    box-shadow: var(--acc-shadow);
}

.acc-auth-header {
    text-align: center;
    margin-bottom: 28px;
}

.acc-auth-header h1 {
    font-family: var(--acc-font);
    font-size: 22px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 6px;
    letter-spacing: 0.5px;
}

.acc-auth-header p {
    font-size: 13px;
    color: var(--acc-text-secondary);
    line-height: 1.5;
}

/* === FORM ELEMENTS === */
.acc-field {
    margin-bottom: 16px;
}

.acc-field label {
    display: block;
    font-size: 11px;
    font-weight: 600;
    color: var(--acc-text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 6px;
}

.acc-field input,
.acc-field select,
.acc-field textarea {
    width: 100%;
    padding: 14px 16px;
    font-family: var(--acc-font);
    font-size: 15px;
    color: var(--acc-text-primary);
    background: var(--acc-bg-input);
    border: 1px solid var(--acc-border);
    border-radius: var(--acc-radius-sm);
    outline: none;
    transition: var(--acc-transition);
    -webkit-appearance: none;
}

.acc-field input:focus,
.acc-field select:focus,
.acc-field textarea:focus {
    border-color: var(--acc-border-active);
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.08);
}

.acc-field input::placeholder {
    color: var(--acc-text-muted);
}

/* === BUTTONS === */
.acc-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 14px 24px;
    font-family: var(--acc-font);
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    border: none;
    border-radius: var(--acc-radius-sm);
    cursor: pointer;
    transition: var(--acc-transition);
    text-decoration: none;
}

.acc-btn-gold {
    background: linear-gradient(135deg, var(--acc-gold), #c5a028);
    color: #0b0e13;
    box-shadow: 0 4px 16px rgba(212, 175, 55, 0.25);
}

.acc-btn-gold:hover {
    box-shadow: 0 6px 24px rgba(212, 175, 55, 0.35);
    transform: translateY(-1px);
}

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

.acc-btn-outline:hover {
    border-color: var(--acc-border-active);
    color: var(--acc-gold);
}

.acc-btn-green {
    background: linear-gradient(135deg, var(--acc-green), #16a34a);
    color: #fff;
    box-shadow: 0 4px 16px rgba(34, 197, 94, 0.2);
}

.acc-btn-sm {
    padding: 10px 16px;
    font-size: 12px;
}

/* === LINK STYLES === */
.acc-link {
    color: var(--acc-gold-dim);
    text-decoration: none;
    font-size: 13px;
    transition: var(--acc-transition);
}

.acc-link:hover {
    color: var(--acc-gold);
    text-decoration: underline;
}

/* === CARDS === */
.acc-card {
    background: var(--acc-bg-card);
    border: 1px solid var(--acc-border);
    border-radius: var(--acc-radius);
    padding: 20px;
    margin-bottom: 12px;
    transition: var(--acc-transition);
}

.acc-card:hover {
    border-color: var(--acc-border-active);
}

.acc-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.acc-card-title {
    font-size: 16px;
    font-weight: 700;
    color: #fff;
    letter-spacing: 0.3px;
}

/* === STAT CARDS === */
.acc-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 20px;
}

.acc-stat {
    background: var(--acc-bg-card);
    border: 1px solid var(--acc-border);
    border-radius: var(--acc-radius);
    padding: 16px;
    text-align: center;
}

.acc-stat-value {
    font-size: 22px;
    font-weight: 800;
    color: var(--acc-gold);
    margin-bottom: 2px;
}

.acc-stat-label {
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--acc-text-muted);
}

/* === BADGES === */
.acc-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    font-size: 11px;
    font-weight: 700;
    border-radius: var(--acc-radius-pill);
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.acc-badge-paid {
    background: rgba(34, 197, 94, 0.12);
    color: var(--acc-green);
}

.acc-badge-pending {
    background: rgba(234, 179, 8, 0.12);
    color: var(--acc-yellow);
}

.acc-badge-cancelled {
    background: rgba(239, 68, 68, 0.12);
    color: var(--acc-red);
}

.acc-badge-waiting {
    background: rgba(59, 130, 246, 0.12);
    color: var(--acc-blue);
}

/* === COTA NUMBERS === */
.acc-cotas-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 10px;
}

.acc-cota-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    height: 36px;
    padding: 0 10px;
    font-size: 13px;
    font-weight: 700;
    color: var(--acc-gold);
    background: rgba(212, 175, 55, 0.08);
    border: 1px solid rgba(212, 175, 55, 0.25);
    border-radius: 6px;
    font-variant-numeric: tabular-nums;
}

.acc-cota-num.winner {
    background: rgba(34, 197, 94, 0.15);
    border-color: var(--acc-green);
    color: var(--acc-green);
    box-shadow: 0 0 12px rgba(34, 197, 94, 0.2);
}

/* === ORDER LIST ITEM (Mobile card) === */
.acc-order-item {
    display: flex;
    flex-direction: column;
    gap: 10px;
    background: var(--acc-bg-card);
    border: 1px solid var(--acc-border);
    border-radius: var(--acc-radius);
    padding: 16px;
    margin-bottom: 10px;
    text-decoration: none;
    color: inherit;
    transition: var(--acc-transition);
}

.acc-order-item:hover {
    border-color: var(--acc-border-active);
}

.acc-order-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.acc-order-id {
    font-size: 15px;
    font-weight: 700;
    color: #fff;
}

.acc-order-date {
    font-size: 12px;
    color: var(--acc-text-muted);
}

.acc-order-price {
    font-size: 16px;
    font-weight: 800;
    color: var(--acc-gold);
}

/* === SECTION TITLES === */
.acc-section-title {
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 16px;
    letter-spacing: 0.3px;
}

.acc-section-subtitle {
    font-size: 13px;
    color: var(--acc-text-secondary);
    margin-bottom: 20px;
    line-height: 1.5;
}

/* === COPY FIELD === */
.acc-copy-box {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--acc-bg-input);
    border: 1px solid var(--acc-border);
    border-radius: var(--acc-radius-sm);
    padding: 4px 4px 4px 14px;
    margin-bottom: 16px;
}

.acc-copy-box input {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--acc-text-primary);
    font-family: monospace;
    font-size: 13px;
    padding: 10px 0;
    outline: none;
}

.acc-copy-box button {
    flex-shrink: 0;
    padding: 10px 16px;
    background: var(--acc-gold);
    color: #0b0e13;
    border: none;
    border-radius: 6px;
    font-family: var(--acc-font);
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: var(--acc-transition);
}

.acc-copy-box button:active {
    transform: scale(0.96);
}

/* === EMPTY STATE === */
.acc-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 48px 24px;
    text-align: center;
}

.acc-empty-icon {
    font-size: 48px;
    color: var(--acc-text-muted);
    margin-bottom: 16px;
}

.acc-empty-text {
    font-size: 14px;
    color: var(--acc-text-secondary);
    line-height: 1.6;
}

/* === ALERT / TRIGGER BOX === */
.acc-wrapper .trigger {
    padding: 14px 16px;
    border-radius: var(--acc-radius-sm);
    font-size: 13px;
    line-height: 1.5;
    margin-bottom: 16px;
    border: 1px solid transparent;
}

.acc-wrapper .trigger.err_warning {
    background: rgba(234, 179, 8, 0.1);
    border-color: rgba(234, 179, 8, 0.3);
    color: var(--acc-yellow);
}

.acc-wrapper .trigger.err_information {
    background: rgba(34, 197, 94, 0.1);
    border-color: rgba(34, 197, 94, 0.3);
    color: var(--acc-green);
}

.acc-wrapper .trigger.err_error {
    background: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.3);
    color: var(--acc-red);
}

/* === COMMISSION HISTORY TABLE (as card list on mobile) === */
.acc-commission-item {
    display: flex;
    flex-direction: column;
    gap: 6px;
    background: var(--acc-bg-card);
    border: 1px solid var(--acc-border);
    border-radius: var(--acc-radius);
    padding: 14px;
    margin-bottom: 8px;
}

.acc-commission-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.acc-commission-amount {
    font-size: 16px;
    font-weight: 700;
    color: var(--acc-green);
}

/* === FORM GRID (2 cols on mobile for compact fields) === */
.acc-form-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0;
}

.acc-form-actions {
    margin-top: 8px;
}

/* === DIVIDER === */
.acc-divider {
    height: 1px;
    background: var(--acc-border);
    margin: 20px 0;
}

/* === PAGE TITLE WITH GREETING === */
.acc-greeting {
    margin-bottom: 20px;
}

.acc-greeting h2 {
    font-size: 20px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 4px;
}

.acc-greeting p {
    font-size: 13px;
    color: var(--acc-text-secondary);
}

/* === QUICK ACTIONS (Dashboard) === */
.acc-quick-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 20px;
}

.acc-quick-action {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 20px 12px;
    background: var(--acc-bg-card);
    border: 1px solid var(--acc-border);
    border-radius: var(--acc-radius);
    text-decoration: none;
    color: var(--acc-text-secondary);
    transition: var(--acc-transition);
}

.acc-quick-action:hover,
.acc-quick-action:active {
    border-color: var(--acc-border-active);
    color: var(--acc-gold);
}

.acc-quick-action span[class^="icon-"] {
    font-size: 24px;
    color: var(--acc-gold);
}

.acc-quick-action-label {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.8px;
}

/* ===========================================
 * DESKTOP LAYOUT (768px+)
 * =========================================== */
@media (min-width: 768px) {
    .acc-bottombar {
        display: none;
    }

    .acc-sidebar {
        display: flex;
        flex-direction: column;
        gap: 4px;
        width: 240px;
        min-height: calc(100vh - 56px);
        padding: 20px 16px;
        background: var(--acc-bg-card);
        border-right: 1px solid var(--acc-border);
        position: sticky;
        top: 56px;
        align-self: flex-start;
    }

    .acc-sidebar-item {
        display: flex;
        align-items: center;
        gap: 10px;
        padding: 12px 14px;
        font-size: 13px;
        font-weight: 500;
        color: var(--acc-text-secondary);
        text-decoration: none;
        border-radius: var(--acc-radius-sm);
        transition: var(--acc-transition);
    }

    .acc-sidebar-item:hover {
        background: var(--acc-bg-card-hover);
        color: var(--acc-text-primary);
    }

    .acc-sidebar-item.active {
        background: rgba(212, 175, 55, 0.08);
        color: var(--acc-gold);
        border: 1px solid rgba(212, 175, 55, 0.15);
    }

    .acc-sidebar-item span[class^="icon-"] {
        font-size: 18px;
        width: 20px;
        text-align: center;
    }

    .acc-sidebar-divider {
        height: 1px;
        background: var(--acc-border);
        margin: 8px 0;
    }

    .acc-sidebar-label {
        font-size: 10px;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 1.5px;
        color: var(--acc-text-muted);
        padding: 8px 14px 4px;
    }

    .acc-layout {
        display: flex;
    }

    .acc-main {
        padding: 32px 40px;
        padding-bottom: 40px;
        max-width: none;
    }

    .acc-auth-card {
        padding: 40px 36px;
    }

    .acc-stats {
        grid-template-columns: repeat(4, 1fr);
    }

    .acc-form-grid {
        grid-template-columns: 1fr 1fr;
        gap: 0 16px;
    }

    .acc-quick-actions {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* === ANIMATIONS === */
@keyframes acc-fadeIn {
    from {
        opacity: 0;
        transform: translateY(8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.acc-animate-in {
    animation: acc-fadeIn 0.3s ease-out;
}

/* === LOADING SPINNER === */
.acc-spinner {
    display: inline-block;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-top-color: var(--acc-gold);
    border-radius: 50%;
    animation: acc-spin 0.6s linear infinite;
}

@keyframes acc-spin {
    to {
        transform: rotate(360deg);
    }
}

/* === OVERRIDE LEGACY WIDGET STYLES === */
.login_box {
    width: 100%;
}

.login_box,
.account_box {
    all: unset;
    display: block;
}