/* ============================================
   MAIN CSS - Global Reset, Typography & Utilities
   Mobile-First Approach
   ============================================ */

/* ===== CSS Reset ===== */
@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;500;700&display=swap');

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

html {
    font-size: 14px;
    -webkit-text-size-adjust: 100%;
    -moz-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
    text-size-adjust: 100%;
    scroll-behavior: smooth;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: 'Roboto', sans-serif;
    font-size: var(--font-size-base);
    font-weight: 400;
    line-height: 1.6;
    color: #e0e0e0;
    background-color: #0a0e14;
    min-height: 100vh;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    -webkit-overflow-scrolling: touch;
}

/* ===== Typography ===== */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'Roboto', sans-serif;
    font-weight: 700;
    line-height: 1.25;
    margin-bottom: 0;
    color: #ffffff;
}

h1 {
    font-size: 1.75rem;
}

h2 {
    font-size: 1.5rem;
}

h3 {
    font-size: 1.3rem;
}

h4 {
    font-size: 1.15rem;
}

h5 {
    font-size: 1.05rem;
}

h6 {
    font-size: 0.95rem;
}

p {
    margin-bottom: 0.875rem;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: var(--transition);
    -webkit-tap-highlight-color: rgba(13, 110, 62, 0.1);
}

a:hover {
    color: var(--primary-hover);
}

a:active {
    opacity: 0.8;
}

img,
svg {
    max-width: 100%;
    height: auto;
    display: block;
}

ul,
ol {
    list-style: none;
    padding: 0;
    margin: 0;
}

/* ===== Utility Classes ===== */
.text-center {
    text-align: center !important;
}

.text-left {
    text-align: left !important;
}

.text-right {
    text-align: right !important;
}

.text-primary {
    color: var(--primary) !important;
}

.text-success {
    color: var(--success) !important;
}

.text-danger {
    color: var(--danger) !important;
}

.text-warning {
    color: var(--warning) !important;
}

.text-info {
    color: var(--info) !important;
}

.text-muted {
    color: var(--secondary) !important;
}

.text-white {
    color: #ffffff !important;
}

.text-dark {
    color: #ffffff !important;
}

.text-sm {
    font-size: 0.8rem !important;
}

.text-base {
    font-size: 0.9rem !important;
}

.text-lg {
    font-size: 1.1rem !important;
}

.text-xl {
    font-size: 1.3rem !important;
}

.text-bold {
    font-weight: 700 !important;
}

.text-medium {
    font-weight: 500 !important;
}

.text-normal {
    font-weight: 400 !important;
}

/* ===== Display & Flex ===== */
.d-none {
    display: none !important;
}

.d-block {
    display: block !important;
}

.d-inline {
    display: inline !important;
}

.d-inline-block {
    display: inline-block !important;
}

.d-flex {
    display: flex !important;
}

.d-inline-flex {
    display: inline-flex !important;
}

.d-grid {
    display: grid !important;
}

.flex-row {
    flex-direction: row !important;
}

.flex-column {
    flex-direction: column !important;
}

.flex-wrap {
    flex-wrap: wrap !important;
}

.flex-nowrap {
    flex-wrap: nowrap !important;
}

.flex-1 {
    flex: 1 !important;
}

.align-items-start {
    align-items: flex-start !important;
}

.align-items-center {
    align-items: center !important;
}

.align-items-end {
    align-items: flex-end !important;
}

.align-items-stretch {
    align-items: stretch !important;
}

.justify-content-start {
    justify-content: flex-start !important;
}

.justify-content-center {
    justify-content: center !important;
}

.justify-content-end {
    justify-content: flex-end !important;
}

.justify-content-between {
    justify-content: space-between !important;
}

.justify-content-around {
    justify-content: space-around !important;
}

/* ===== Spacing ===== */
.m-0 {
    margin: 0 !important;
}

.m-1 {
    margin: 0.25rem !important;
}

.m-2 {
    margin: 0.5rem !important;
}

.m-3 {
    margin: 0.75rem !important;
}

.m-4 {
    margin: 1rem !important;
}

.m-5 {
    margin: 1.5rem !important;
}

.mt-0 {
    margin-top: 0 !important;
}

.mt-1 {
    margin-top: 0.25rem !important;
}

.mt-2 {
    margin-top: 0.5rem !important;
}

.mt-3 {
    margin-top: 0.75rem !important;
}

.mt-4 {
    margin-top: 1rem !important;
}

.mt-5 {
    margin-top: 1.5rem !important;
}

.mb-0 {
    margin-bottom: 0 !important;
}

.mb-1 {
    margin-bottom: 0.25rem !important;
}

.mb-2 {
    margin-bottom: 0.5rem !important;
}

.mb-3 {
    margin-bottom: 0.75rem !important;
}

.mb-4 {
    margin-bottom: 1rem !important;
}

.mb-5 {
    margin-bottom: 1.5rem !important;
}

.ml-auto {
    margin-left: auto !important;
}

.mr-auto {
    margin-right: auto !important;
}

.mx-auto {
    margin-left: auto !important;
    margin-right: auto !important;
}

.p-0 {
    padding: 0 !important;
}

.p-1 {
    padding: 0.25rem !important;
}

.p-2 {
    padding: 0.5rem !important;
}

.p-3 {
    padding: 0.75rem !important;
}

.p-4 {
    padding: 1rem !important;
}

.p-5 {
    padding: 1.5rem !important;
}

.px-3 {
    padding-left: 0.75rem !important;
    padding-right: 0.75rem !important;
}

.px-4 {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
}

.py-3 {
    padding-top: 0.75rem !important;
    padding-bottom: 0.75rem !important;
}

.py-4 {
    padding-top: 1rem !important;
    padding-bottom: 1rem !important;
}

/* ===== Width & Height ===== */
.w-100 {
    width: 100% !important;
}

.w-auto {
    width: auto !important;
}

.w-50 {
    width: 50% !important;
}

.h-100 {
    height: 100% !important;
}

.h-auto {
    height: auto !important;
}

/* ===== Gap ===== */
.gap-1 {
    gap: 0.25rem !important;
}

.gap-2 {
    gap: 0.5rem !important;
}

.gap-3 {
    gap: 0.75rem !important;
}

.gap-4 {
    gap: 1rem !important;
}

/* ===== Position ===== */
.position-relative {
    position: relative !important;
}

.position-absolute {
    position: absolute !important;
}

.position-fixed {
    position: fixed !important;
}

/* ===== Overflow ===== */
.overflow-auto {
    overflow: auto !important;
}

.overflow-hidden {
    overflow: hidden !important;
}

.overflow-x-auto {
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch;
}

/* ===== Visibility ===== */
.visible {
    visibility: visible !important;
}

.invisible {
    visibility: hidden !important;
}

/* ===== Opacity ===== */
.opacity-50 {
    opacity: 0.5 !important;
}

.opacity-75 {
    opacity: 0.75 !important;
}

.opacity-100 {
    opacity: 1 !important;
}

/* ===== Cursor ===== */
.cursor-pointer {
    cursor: pointer !important;
}

.cursor-not-allowed {
    cursor: not-allowed !important;
}

/* ===== Border ===== */
.border {
    border: 1px solid var(--border-color) !important;
}

.border-0 {
    border: 0 !important;
}

.rounded {
    border-radius: var(--border-radius) !important;
}

.rounded-lg {
    border-radius: var(--border-radius-lg) !important;
}

.rounded-circle {
    border-radius: 50% !important;
}

/* ===== Shadow ===== */
.shadow-sm {
    box-shadow: var(--shadow-sm) !important;
}

.shadow-md {
    box-shadow: var(--shadow-md) !important;
}

/* ===== Background ===== */
.bg-white {
    background-color: #1a1f2b !important;
}

.bg-light {
    background-color: #161b22 !important;
}

.bg-primary {
    background-color: var(--primary) !important;
}

/* ===== Truncate Text ===== */
.text-truncate {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.text-clamp-1 {
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.text-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.text-clamp-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ===== CUSTOM SCROLLBAR GLOBAL ===== */
html {
    scroll-behavior: smooth;
}

::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: #0a0e14;
}

::-webkit-scrollbar-thumb {
    background: rgba(52, 152, 219, 0.25);
    border-radius: 10px;
    transition: background 0.3s ease;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(52, 152, 219, 0.5);
}

/* Firefox */
* {
    scrollbar-width: thin;
    scrollbar-color: rgba(52, 152, 219, 0.25) #0a0e14;
}

/* ===== Responsive Typography ===== */
@media (min-width: 576px) {
    html {
        font-size: 15px;
    }

    h1 {
        font-size: 2rem;
    }

    h2 {
        font-size: 1.75rem;
    }

    h3 {
        font-size: 1.5rem;
    }
}

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }
}

@media (min-width: 992px) {
    h1 {
        font-size: 2.5rem;
    }

    h2 {
        font-size: 2rem;
    }

    h3 {
        font-size: 1.75rem;
    }
}

@media (min-width: 1200px) {
    html {
        font-size: 16px;
    }
}

/* ===== Print ===== */
@media print {
    body {
        background: #fff;
        color: #000;
    }

    .no-print {
        display: none !important;
    }

    a {
        color: #000;
    }
}