/* Voucha - Style 1 (Glass + Gradient), mobile-first */
:root {
    --bg-0: #070b16;
    --bg-1: #0f1830;
    --bg-2: #1c2a54;

    --glass: rgba(30, 41, 59, 0.76);
    --glass-strong: rgba(15, 23, 42, 0.9);
    --glass-border: rgba(148, 163, 184, 0.34);

    --text: #f1f5f9;
    --text-soft: #cbd5e1;
    --text-dim: #94a3b8;

    --brand-a: #0ea5e9;
    --brand-b: #6366f1;
    --mint: #2dd4bf;
    --warn: #f59e0b;
    --danger: #ef4444;

    --btn-radius: 12px;
    --btn-padding-vertical: 0.72rem;
    --btn-font-size: 0.92rem;
}

html, body {
    height: 100%;
    margin: 0;
    font-family: 'Open Sans', 'Helvetica Neue', Helvetica, Arial, sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at 90% -10%, rgba(99, 102, 241, 0.35) 0%, rgba(99, 102, 241, 0) 35%),
        radial-gradient(circle at -10% 20%, rgba(14, 165, 233, 0.25) 0%, rgba(14, 165, 233, 0) 40%),
        linear-gradient(160deg, var(--bg-0), var(--bg-1) 55%, var(--bg-2));
    background-attachment: fixed;
}

.page {
    display: flex;
    min-height: 100vh;
    background: transparent;
}

.sidebar {
    width: 240px;
    background: linear-gradient(180deg, rgba(8, 13, 24, 0.88), rgba(16, 22, 38, 0.88));
    border-right: 1px solid var(--glass-border);
    backdrop-filter: blur(10px);
    color: white;
}

.sidebar a {
    color: rgba(229, 231, 235, 0.82);
}

.sidebar a.active,
.sidebar a:hover {
    color: #fff;
}

.nav-link.active {
    font-weight: 700;
    color: #fff !important;
}

.bg-voucha-navy {
    background: linear-gradient(90deg, rgba(8, 13, 24, 0.92), rgba(16, 22, 38, 0.92)) !important;
    border-bottom: 1px solid var(--glass-border);
    backdrop-filter: blur(10px);
}

.offcanvas {
    background: linear-gradient(180deg, rgba(8, 13, 24, 0.96), rgba(16, 22, 38, 0.96));
    color: white;
}

.offcanvas .nav-link {
    color: rgba(229, 231, 235, 0.82);
}

.offcanvas .nav-link.active,
.offcanvas .nav-link:hover {
    color: white;
}

.top-row {
    background: transparent;
    border-bottom: 1px solid rgba(148, 163, 184, 0.18);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
}

.top-row a {
    color: var(--text-soft) !important;
    text-decoration: none;
}

.top-row a:hover {
    color: #fff !important;
}

.content {
    padding: 1rem;
    flex: 1;
    background: rgba(2, 6, 23, 0.22);
    border-left: 1px solid rgba(148, 163, 184, 0.16);
}

/* Glass containers */
.card,
.toast,
.alert {
    background: var(--glass);
    border: 1px solid var(--glass-border);
    color: var(--text);
    backdrop-filter: blur(10px);
    box-shadow: 0 12px 34px rgba(2, 6, 23, 0.42);
}

.card-title,
h1, h2, h3, h4, h5, h6 {
    color: #f3f4f6;
}

.text-muted {
    color: var(--text-dim) !important;
}

/* Inputs */
.form-control,
.form-select {
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(148, 163, 184, 0.25);
    color: #f1f5f9;
    border-radius: 10px;
}

.form-control::placeholder {
    color: rgba(203, 213, 225, 0.6);
}

.form-control:focus,
.form-select:focus {
    background: rgba(15, 23, 42, 0.75);
    color: #fff;
    border-color: rgba(45, 212, 191, 0.7);
    box-shadow: 0 0 0 0.2rem rgba(45, 212, 191, 0.22);
}

/* Buttons */
.btn {
    border-radius: var(--btn-radius);
    padding: var(--btn-padding-vertical) 1rem;
    font-weight: 700;
    font-size: var(--btn-font-size);
    border-width: 1px;
}

.btn-primary {
    color: #fff;
    border: none;
    background: linear-gradient(135deg, var(--brand-a), var(--brand-b));
    box-shadow: 0 8px 18px rgba(99, 102, 241, 0.3);
}

.btn-primary:hover {
    color: #fff;
    filter: brightness(1.06);
}

.btn-secondary {
    color: #042f2e;
    border: none;
    background: linear-gradient(135deg, #5eead4, var(--mint));
    box-shadow: 0 8px 18px rgba(45, 212, 191, 0.24);
}

.btn-secondary:hover {
    color: #022c22;
    filter: brightness(1.04);
}

.btn-outline-secondary {
    color: #dbeafe;
    background: transparent;
    border: 1px solid rgba(147, 197, 253, 0.52);
}

.btn-outline-secondary:hover {
    color: #fff;
    background: rgba(59, 130, 246, 0.14);
    border-color: rgba(147, 197, 253, 0.75);
}

.btn-warning {
    color: #1f2937;
    background-color: var(--warn);
    border-color: var(--warn);
}

/* High-visibility Google auth button */
.btn-google {
    color: #111827;
    background: #ffffff;
    border: 1px solid #d1d5db;
    box-shadow: 0 6px 18px rgba(2, 6, 23, 0.22);
    font-weight: 700;
}

.btn-google:hover {
    color: #111827;
    background: #f8fafc;
    border-color: #e5e7eb;
}

.btn-google:focus,
.btn-google:active:focus {
    box-shadow: 0 0 0 0.14rem rgba(10, 14, 24, 1), 0 0 0 0.3rem rgba(59, 130, 246, 0.45);
}

/* Utility focus states */
.btn:focus,
.btn:active:focus,
.btn-link.nav-link:focus,
.form-control:focus,
.form-check-input:focus {
    box-shadow: 0 0 0 0.14rem rgba(10, 14, 24, 1), 0 0 0 0.3rem rgba(45, 212, 191, 0.5);
}

/* Validation */
.valid.modified:not([type=checkbox]) {
    outline: 1px solid #22c55e;
}

.invalid {
    outline: 1px solid var(--danger);
}

.validation-message {
    color: #fca5a5;
}

/* Alerts */
.alert-success {
    background: rgba(22, 163, 74, 0.16);
    border-color: rgba(74, 222, 128, 0.35);
    color: #dcfce7;
}

.alert-danger {
    background: rgba(185, 28, 28, 0.16);
    border-color: rgba(248, 113, 113, 0.35);
    color: #fee2e2;
}

.alert-warning {
    background: rgba(180, 83, 9, 0.18);
    border-color: rgba(251, 191, 36, 0.35);
    color: #fef3c7;
}

.alert-info {
    background: rgba(2, 132, 199, 0.17);
    border-color: rgba(56, 189, 248, 0.35);
    color: #e0f2fe;
}

/* Links */
a {
    color: #93c5fd;
}

a:hover {
    color: #bfdbfe;
}

/* Toast */
.toast-container {
    position: fixed;
    top: 0.9rem;
    right: 0.9rem;
    z-index: 1050;
}

.toast {
    min-width: 16rem;
}

/* Ad banner policy: one per page, fixed height, clearly marked */
.ad-banner-wrapper {
    width: 100%;
}

.ad-banner-label {
    font-size: 0.72rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-dim);
    margin-bottom: 0.35rem;
}

.ad-banner-slot {
    height: 90px; /* fixed height to prevent layout shift */
    min-height: 90px;
    max-height: 90px;
    border-radius: 12px;
    border: 1px dashed rgba(148, 163, 184, 0.4);
    background: rgba(15, 23, 42, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.ad-banner-placeholder {
    color: var(--text-soft);
    font-size: 0.9rem;
}

/* Cookie consent UI */
.cookie-consent-banner {
    position: fixed;
    left: 0.75rem;
    right: 0.75rem;
    bottom: 0.75rem;
    z-index: 1080;
    background: var(--glass-strong);
    border: 1px solid var(--glass-border);
    border-radius: 14px;
    backdrop-filter: blur(12px);
    box-shadow: 0 12px 30px rgba(2, 6, 23, 0.45);
}

.cookie-consent-content {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding: 0.85rem;
}

.cookie-consent-content p {
    margin: 0;
    color: var(--text-soft);
    font-size: 0.9rem;
    line-height: 1.4;
}

.consent-manage-box {
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    background: rgba(15, 23, 42, 0.45);
    padding: 0.9rem;
}

@media (min-width: 768px) {
    .cookie-consent-banner {
        left: auto;
        right: 1rem;
        max-width: 520px;
        bottom: 1rem;
    }

    .cookie-consent-content {
        padding: 1rem;
    }
}

/* Mobile-first spacing and tap targets */
.nav-link,
.btn {
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* Side menu links should be left-aligned */
.sidebar .nav-link,
.offcanvas .nav-link {
    justify-content: flex-start;
    text-align: left;
}

.card-body {
    padding: 1rem;
}

/* Desktop refinements */
@media (min-width: 768px) {
    .content {
        padding: 1.5rem;
    }

    .card-body {
        padding: 1.25rem;
    }

    .top-row {
        margin-bottom: 1.1rem;
    }
}

/* ── Landing page hero ──────────────────────────── */
.bg-voucha-hero {
    background:
        radial-gradient(ellipse at 30% 0%, rgba(99, 102, 241, 0.28) 0%, transparent 60%),
        radial-gradient(ellipse at 80% 100%, rgba(14, 165, 233, 0.22) 0%, transparent 55%),
        var(--glass);
    border: 1px solid rgba(148, 163, 184, 0.22);
}

.bg-voucha-hero h1 {
    background: linear-gradient(135deg, #e0f2fe 0%, #c4b5fd 50%, #5eead4 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Blog card images on landing page */
.card-img-top {
    border-bottom: 1px solid var(--glass-border);
}

/* Badge tweaks for dark theme */
.badge.bg-secondary {
    background: rgba(99, 102, 241, 0.3) !important;
    color: #c4b5fd;
    border: 1px solid rgba(99, 102, 241, 0.4);
}

/* Quick-link cards on landing page */
section .card .fs-3 {
    filter: brightness(1.1);
}

/* How it Works page */
.how-guide-card {
    border-radius: 16px;
}

.how-guide-section {
    margin-top: 1.75rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(148, 163, 184, 0.18);
}

.how-guide-section:first-of-type {
    margin-top: 0;
    padding-top: 0;
    border-top: 0;
}

.how-shot img {
    width: 100%;
    border: 1px solid rgba(148, 163, 184, 0.32);
    background: rgba(15, 23, 42, 0.45);
    box-shadow: 0 10px 24px rgba(2, 6, 23, 0.38);
}

.how-guide-box {
    border: 1px solid rgba(148, 163, 184, 0.26);
    background: rgba(15, 23, 42, 0.42);
}

.how-guide-actions {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.how-guide-ack-form {
    width: 100%;
}

.how-guide-ack-form .btn {
    width: 100%;
}

.how-guide-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: flex-start;
}

@media (min-width: 768px) {
    .how-guide-actions {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }

    .how-guide-ack-form {
        width: auto;
    }

    .how-guide-ack-form .btn {
        width: auto;
    }
}
