/*
 * style.css — shared stylesheet untuk semua halaman xcapeads.cloud
 */

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

/* Dark Mode (default) */
:root {
    /* warna utama diambil dari palet logo — biru shield */
    --blue-dark: #0d2d6b;
    --blue-mid: #1a56c4;
    --blue-light: #3b82f6;
    --blue-pale: #dbeafe;
    --red-accent: #dc2626;

    /* dark mode variables */
    --bg-dark: #0a0f1e;
    --bg-card: #111827;
    --bg-card-2: #1f2937;
    --text-primary: #f9fafb;
    --text-muted: #9ca3af;
    --border: #1e3a5f;
    --navbar-bg: rgba(10, 15, 30, 0.85);
    --navbar-bg-scroll: rgba(10, 15, 30, 0.97);

    --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    --section-pad: 5rem 1.5rem;
    --radius: 12px;
    --radius-lg: 20px;

    /* transisi warna saat ganti mode */
    --transition-theme: background 0.3s, color 0.3s, border-color 0.3s;
}

/* Light Mode */
/* variabel di-override kalau html punya class .light */
html.light {
    --bg-dark: #f0f4ff;
    --bg-card: #ffffff;
    --bg-card-2: #e8f0fe;
    --text-primary: #0f172a;
    --text-muted: #475569;
    --border: #bfdbfe;
    --navbar-bg: rgba(240, 244, 255, 0.85);
    --navbar-bg-scroll: rgba(240, 244, 255, 0.97);
    --blue-light: #2563eb;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font);
    background: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    transition: var(--transition-theme);
}

a {
    color: var(--blue-light);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: var(--blue-mid);
}

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

/* Shared Components */

.badge {
    display: inline-block;
    background: rgba(59, 130, 246, 0.15);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 999px;
    padding: 5px 14px;
    font-size: 13px;
    color: var(--blue-light);
    letter-spacing: 0.04em;
    margin-bottom: 1rem;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--blue-mid);
    color: #fff;
    padding: 14px 28px;
    border-radius: var(--radius);
    font-size: 15px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: background 0.2s, transform 0.15s;
    text-decoration: none;
}

.btn-primary:hover {
    background: var(--blue-light);
    color: #fff;
    transform: translateY(-1px);
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: transparent;
    color: var(--text-primary);
    padding: 13px 26px;
    border-radius: var(--radius);
    font-size: 15px;
    font-weight: 500;
    border: 1px solid var(--border);
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
    text-decoration: none;
}

.btn-secondary:hover {
    border-color: var(--blue-light);
    color: var(--blue-light);
    background: rgba(59, 130, 246, 0.05);
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: var(--navbar-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
    padding: 0 1.5rem;
    transition: var(--transition-theme);
}

.navbar-inner {
    max-width: 1100px;
    margin: 0 auto;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.navbar-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.navbar-logo img {
    width: 36px;
    height: 36px;
    object-fit: contain;
}

.navbar-logo span {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-primary);
}

.navbar-logo span em {
    font-style: normal;
    color: var(--red-accent);
}

.navbar-links {
    display: flex;
    align-items: center;
    gap: 2rem;
    list-style: none;
}

.navbar-links a {
    color: var(--text-muted);
    font-size: 14px;
    font-weight: 500;
    transition: color 0.2s;
}

.navbar-links a:hover {
    color: var(--text-primary);
}

/* grup tombol di sisi kanan navbar — lang switcher + theme toggle */
.navbar-controls {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.lang-switcher {
    display: flex;
    align-items: center;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 999px;
    overflow: hidden;
    font-size: 13px;
    transition: var(--transition-theme);
}

.lang-switcher button {
    background: none;
    border: none;
    color: var(--text-muted);
    padding: 5px 12px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.2s;
}

.lang-switcher button.active {
    background: var(--blue-mid);
    color: #fff;
    border-radius: 999px;
}

/* tombol theme toggle — ikon matahari/bulan */
.theme-toggle {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--bg-card);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 16px;
    transition: var(--transition-theme), transform 0.2s;
    flex-shrink: 0;
}

.theme-toggle:hover {
    border-color: var(--blue-light);
    transform: rotate(15deg);
}

/* Footer */
.footer {
    border-top: 1px solid var(--border);
    padding: 2.5rem 1.5rem;
    text-align: center;
    transition: var(--transition-theme);
}

.footer-inner {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.footer-links {
    display: flex;
    gap: 1.5rem;
    list-style: none;
    flex-wrap: wrap;
    justify-content: center;
}

.footer-links a {
    color: var(--text-muted);
    font-size: 13px;
}

.footer-links a:hover {
    color: var(--text-primary);
}

.footer-copy {
    color: var(--text-muted);
    font-size: 12px;
}

/* Responsive */
@media (max-width: 768px) {
    .navbar-links {
        display: none;
    }

    :root {
        --section-pad: 3.5rem 1.25rem;
    }
}
