/**
 * Main Stylesheet
 * Core Web Vitals Optimized
 */

/* ============================================
   CSS Variables & Reset
   ============================================ */
:root {
    /* Primary Colors */
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-light: #3b82f6;

    /* Secondary Colors */
    --secondary: #64748b;
    --accent: #f59e0b;
    --accent-light: #fbbf24;

    /* Backgrounds */
    --bg-light: #f8fafc;
    --bg-white: #ffffff;
    --bg-dark: #0f172a;
    --bg-darker: #020617;

    /* Text Colors */
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --text-light: #f1f5f9;
    --text-muted: #94a3b8;

    /* Borders */
    --border: #e2e8f0;
    --border-light: #f1f5f9;
    --border-dark: #334155;

    /* Shadows */
    --shadow-xs: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-sm: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px -1px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);

    /* Border Radius */
    --radius-xs: 4px;
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-full: 9999px;

    /* Transitions */
    --transition-fast: all 0.15s ease;
    --transition: all 0.3s ease;
    --transition-slow: all 0.5s ease;

    /* Typography */
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --font-mono: 'JetBrains Mono', Monaco, Consolas, 'Liberation Mono', monospace;
}

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

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-sans);
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-light);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

a {
    color: inherit;
    text-decoration: none;
}

button {
    font-family: inherit;
    cursor: pointer;
}

/* ============================================
   Layout
   ============================================ */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.container-narrow {
    max-width: 800px;
}

.container-wide {
    max-width: 1400px;
}

/* ============================================
   Typography
   ============================================ */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 700;
    line-height: 1.3;
    color: var(--text-primary);
}

h1 {
    font-size: 2.5rem;
}

h2 {
    font-size: 2rem;
}

h3 {
    font-size: 1.5rem;
}

h4 {
    font-size: 1.25rem;
}

h5 {
    font-size: 1rem;
}

h6 {
    font-size: 0.875rem;
}

p {
    margin-bottom: 1rem;
}

/* ============================================
   Hero Section
   ============================================ */
.hero-section {
    background: linear-gradient(135deg, #2563eb 0%, #7c3aed 100%);
    color: #ffffff;
    padding: 50px 0;
    margin-bottom: 30px;
}

.hero-section h1,
.hero-section .hero-title {
    font-size: 42px;
    font-weight: 800;
    margin-bottom: 10px;
    color: #ffffff !important;
}

.hero-section p,
.hero-section .hero-subtitle {
    font-size: 18px;
    opacity: 0.95;
    color: #ffffff !important;
}

/* ============================================
   Buttons
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    font-size: 15px;
    font-weight: 600;
    border-radius: var(--radius-sm);
    border: none;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    box-shadow: 0 4px 14px 0 rgba(37, 99, 235, 0.35);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px 0 rgba(37, 99, 235, 0.45);
}

.btn-secondary {
    background: var(--bg-white);
    color: var(--text-primary);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    background: var(--bg-light);
    border-color: var(--primary);
    color: var(--primary);
}

.btn-accent {
    background: linear-gradient(135deg, var(--accent) 0%, #f97316 100%);
    color: white;
}

/* ============================================
   Cards
   ============================================ */
.card {
    background: var(--bg-white);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    transition: var(--transition);
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.card-body {
    padding: 20px;
}

/* ============================================
   Forms
   ============================================ */
.form-input {
    width: 100%;
    padding: 12px 16px;
    font-size: 15px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--bg-white);
    color: var(--text-primary);
    transition: var(--transition-fast);
}

.form-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

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

/* ============================================
   Utilities
   ============================================ */
.text-center {
    text-align: center;
}

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

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

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

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

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

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

.bg-white {
    background-color: var(--bg-white);
}

.bg-light {
    background-color: var(--bg-light);
}

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

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

.mt-3 {
    margin-top: 1rem;
}

.mt-4 {
    margin-top: 1.5rem;
}

.mt-5 {
    margin-top: 2rem;
}

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

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

.mb-3 {
    margin-bottom: 1rem;
}

.mb-4 {
    margin-bottom: 1.5rem;
}

.mb-5 {
    margin-bottom: 2rem;
}

.p-1 {
    padding: 0.25rem;
}

.p-2 {
    padding: 0.5rem;
}

.p-3 {
    padding: 1rem;
}

.p-4 {
    padding: 1.5rem;
}

.p-5 {
    padding: 2rem;
}

.d-none {
    display: none;
}

.d-block {
    display: block;
}

.d-flex {
    display: flex;
}

.d-grid {
    display: grid;
}

.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-1 {
    gap: 0.25rem;
}

.gap-2 {
    gap: 0.5rem;
}

.gap-3 {
    gap: 1rem;
}

.gap-4 {
    gap: 1.5rem;
}

.gap-5 {
    gap: 2rem;
}

/* ============================================
   Animations
   ============================================ */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

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

@keyframes slideIn {
    from {
        transform: translateX(-100%);
    }

    to {
        transform: translateX(0);
    }
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

.animate-fadeIn {
    animation: fadeIn 0.5s ease forwards;
}

.animate-pulse {
    animation: pulse 2s infinite;
}

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 1024px) {
    .container {
        padding: 0 16px;
    }

    h1 {
        font-size: 2rem;
    }

    h2 {
        font-size: 1.75rem;
    }
}

@media (max-width: 768px) {
    body {
        font-size: 15px;
    }

    h1 {
        font-size: 1.75rem;
    }

    h2 {
        font-size: 1.5rem;
    }

    h3 {
        font-size: 1.25rem;
    }

    .container {
        padding: 0 15px;
    }

    .hide-mobile {
        display: none !important;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 1.5rem;
    }

    h2 {
        font-size: 1.25rem;
    }
}

/* ============================================
   Ad Container (CLS Prevention)
   ============================================ */
.ad-container {
    min-height: 90px;
    background-color: #f8f9fa;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.ad-container.ad-display {
    min-height: 250px;
}

.ad-container.ad-incontent {
    min-height: 280px;
    margin: 25px 0;
}

.ad-container.ad-multiplex {
    min-height: 300px;
}

/* ============================================
   Loading States
   ============================================ */
.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: skeleton 1.5s ease infinite;
}

@keyframes skeleton {
    0% {
        background-position: 200% 0;
    }

    100% {
        background-position: -200% 0;
    }
}

/* ============================================
   Force Light Mode - Dark Mode Disabled
   ============================================ */
/* 
   Dark mode disabled karena menyebabkan text invisible.
   Jika ingin enable dark mode, pastikan semua background
   menggunakan CSS variable dan tidak hardcoded.
*/
:root {
    color-scheme: light only;
}

/* Ensure text is always visible */
body,
.news-card,
.featured-link,
.sidebar-widget,
.article-main,
.related-news {
    color: #1e293b !important;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    color: #1e293b !important;
}

.card-title,
.featured-title,
.article-title,
.widget-title,
.related-title {
    color: #1e293b !important;
}

/* Links should be visible */
a {
    color: inherit;
}

.card-link:hover .card-title,
.featured-link:hover .featured-title {
    color: #2563eb !important;
}