/**
 * BVMK GLOBAL — MASTER UNIFIED GLOBAL STYLESHEET
 * Single entrypoint for all global resets, typography, shared UI components, navbar, and footer.
 * File: /css/global.css
 */

@import url('variables.css');

/* ==========================================================================
   1. RESET & NORMALIZATION
   ========================================================================== */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-sans);
    background-color: var(--color-bg-body);
    color: var(--color-text-body);
    line-height: 1.6;
    min-height: 100vh;
}

img,
picture,
video,
canvas,
svg {
    display: block;
    max-width: 100%;
    height: auto;
}

input,
button,
textarea,
select {
    font: inherit;
    color: inherit;
}

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition-fast);
}

ul,
ol {
    list-style: none;
}

/* ==========================================================================
   2. TYPOGRAPHY
   ========================================================================== */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    color: var(--color-text-main);
    font-weight: 700;
    line-height: 1.25;
}

h1 {
    font-size: 2.25rem;
}

h2 {
    font-size: 1.75rem;
}

h3 {
    font-size: 1.35rem;
}

h4 {
    font-size: 1.15rem;
}

h5 {
    font-size: 1rem;
}

h6 {
    font-size: 0.875rem;
}

.bvmk-brand-font {
    font-family: var(--font-heading);
    letter-spacing: -0.5px;
}

/* ==========================================================================
   3. LAYOUT & CONTAINERS
   ========================================================================== */
.container {
    width: 100%;
    max-width: 1320px;
    margin-left: auto;
    margin-right: auto;
    padding-left: var(--space-5);
    padding-right: var(--space-5);
}

.container-fluid {
    width: 100%;
    padding-left: var(--space-6);
    padding-right: var(--space-6);
}

.d-flex {
    display: flex;
}

.d-grid {
    display: grid;
}

.d-none {
    display: none;
}

.d-block {
    display: block;
}

.flex-column {
    flex-direction: column;
}

.flex-wrap {
    flex-wrap: wrap;
}

.align-center {
    align-items: center;
}

.justify-center {
    justify-content: center;
}

.justify-between {
    justify-content: space-between;
}

.gap-2 {
    gap: var(--space-2);
}

.gap-3 {
    gap: var(--space-3);
}

.gap-4 {
    gap: var(--space-4);
}

/* ==========================================================================
   4. SHARED UI COMPONENTS (BUTTONS, FORMS, BADGES, TOASTS)
   ========================================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-2);
    padding: 0.65rem 1.25rem;
    font-size: 0.9rem;
    font-weight: 600;
    border-radius: var(--radius-md);
    border: 1px solid transparent;
    cursor: pointer;
    transition: var(--transition-base);
    text-align: center;
}

.btn-primary {
    background-color: var(--color-primary);
    color: var(--color-text-inverse);
}

.btn-primary:hover {
    background-color: var(--color-primary-hover);
    box-shadow: var(--shadow-md);
}

.btn-gold {
    background: var(--color-gold-gradient);
    color: #0c141c;
    font-weight: 700;
    box-shadow: var(--shadow-gold);
}

.btn-gold:hover {
    filter: brightness(1.06);
    box-shadow: 0 12px 28px -4px rgba(197, 164, 126, 0.45);
}

.btn-outline {
    background: transparent;
    border-color: var(--color-border-strong);
    color: var(--color-text-main);
}

.btn-outline:hover {
    background: var(--color-bg-alt);
    border-color: var(--color-text-main);
}

.btn-sm {
    padding: 0.4rem 0.85rem;
    font-size: 0.8rem;
    border-radius: var(--radius-sm);
}

.btn-lg {
    padding: 0.85rem 1.75rem;
    font-size: 1.05rem;
    border-radius: var(--radius-lg);
}

.form-group {
    margin-bottom: var(--space-4);
}

.form-label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--color-text-body);
    margin-bottom: var(--space-2);
}

.form-control,
.form-select {
    width: 100%;
    padding: 0.65rem 0.9rem;
    font-size: 0.9rem;
    background-color: var(--color-bg-surface);
    border: 1.5px solid var(--color-border-strong);
    border-radius: var(--radius-md);
    color: var(--color-text-main);
    outline: none;
    transition: var(--transition-fast);
}

.form-control:focus,
.form-select:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(1, 51, 153, 0.12);
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: var(--space-1);
    padding: 0.25rem 0.65rem;
    font-size: 0.75rem;
    font-weight: 700;
    border-radius: var(--radius-sm);
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

.badge-gold {
    background: #fef3c7;
    color: #92400e;
    border: 1px solid #fde68a;
}

.badge-blue {
    background: #eff6ff;
    color: #1e40af;
    border: 1px solid #bfdbfe;
}

.badge-green {
    background: #f0fdf4;
    color: #166534;
    border: 1px solid #bbf7d0;
}

.badge-red {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

/* Toast Notification Stack */
.toast-container {
    position: fixed;
    bottom: var(--space-6);
    right: var(--space-6);
    z-index: var(--z-toast, 99999);
    display: flex;
    flex-direction: column;
    gap: var(--space-3);
    max-width: 400px;
    pointer-events: none;
}

.toast-message {
    pointer-events: auto;
    background: #0f172a;
    color: #ffffff;
    padding: 0.9rem 1.25rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    font-size: 0.88rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: var(--space-3);
    border-left: 4px solid var(--color-primary);
    animation: toastSlideIn 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.toast-success {
    border-left-color: var(--color-success);
}

.toast-error {
    border-left-color: var(--color-danger);
}

.toast-warning {
    border-left-color: var(--color-warning);
}

@keyframes toastSlideIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ==========================================================================
   5. NAVBAR & TOPBAR STYLES
   ========================================================================== */
.top-bar {
    background-color: #2c3e50;
    padding: 12px 30px;
    display: flex;
    justify-content: flex-end;
    gap: 35px;
    flex-wrap: wrap;
    position: relative;
    z-index: 2000;
    width: 100%;
}

.top-link {
    color: #ecf0f1;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.top-link:hover {
    transform: translateY(-2px);
    color: #3498db;
}

.navbar {
    position: sticky;
    top: 0;
    background: #ffffff;
    padding: 18px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.1);
    z-index: 1500;
    height: 90px;
    width: 100%;
}

.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    max-width: 50%;
}

.logo img {
    width: 200px;
    height: auto;
    max-height: 75px;
    object-fit: contain;
}

.nav-links {
    display: flex;
    gap: 23px;
    font-size: 18px;
    align-items: center;
}

.nav-item {
    position: relative;
    color: #2c3e50;
    text-decoration: none;
    font-weight: 600;
    padding: 8px 0;
    transition: all 0.4s ease;
    white-space: nowrap;
}

.nav-item:hover {
    transform: translateY(-3px);
}

/* Lock body scroll when mobile navigation menu is active */
body.menu-open {
    overflow: hidden !important;
    touch-action: none;
}

@keyframes bvmkNavSlideDown {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.nav-hamburger {
    display: none;
    font-size: 26px;
    color: #1a2a3a;
    cursor: pointer;
    z-index: 1600;
    padding: 6px 10px;
    border-radius: 6px;
    transition: background-color 0.2s ease, transform 0.15s ease, color 0.2s ease;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.nav-hamburger:hover {
    background-color: #f1f5f9;
    color: #013399;
}

.nav-hamburger:active {
    transform: scale(0.92);
}

@media (max-width: 991px) {
    .top-bar {
        justify-content: center;
        gap: 15px;
        padding: 8px 15px;
    }

    .navbar {
        padding: 15px 24px;
        height: 75px;
    }

    .logo img {
        max-height: 55px;
    }

    .nav-hamburger {
        display: block;
    }

    .nav-links {
        display: none;
    }

    .nav-links.active {
        display: flex !important;
        flex-direction: column !important;
        position: absolute !important;
        top: 75px;
        left: 0;
        width: 100%;
        background-color: #ffffff !important;
        box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
        padding: 20px 30px !important;
        gap: 12px !important;
        z-index: 9999;
        border-top: 1px solid #f0f2f5;
        border-bottom: 3px solid #013399;
        animation: bvmkNavSlideDown 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
        max-height: calc(100vh - 75px);
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .nav-item {
        width: 100%;
        padding: 12px 10px;
        border-bottom: 1px solid #f0f2f5;
        font-size: 17px;
        text-align: left;
        border-radius: 6px;
        transition: background-color 0.2s ease, color 0.2s ease;
    }

    .nav-item:hover,
    .nav-item:active {
        background-color: #f8fafc;
        transform: none;
    }
}

@media (max-width: 480px) {
    .logo img {
        max-height: 45px;
    }

    .navbar {
        padding: 15px;
    }

    .top-bar {
        display: none;
    }
}

/* ==========================================================================
   6. FOOTER STYLES
   ========================================================================== */
.bvmk-footer {
    background: var(--color-bg-dark, #0b1523);
    color: #94a3b8;
    position: relative;
    overflow: hidden;
    margin-top: auto;
}

.footer-main {
    padding: 3rem 0 2rem;
}

.footer-bottom {
    background: #080d13;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    padding: 1rem 0;
    font-size: 0.82rem;
}

.footer-bottom-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.footer-bar-divider {
    color: #475569;
}

.footer-legal-link:hover {
    color: #ffffff;
}