/* ============================================================
   SightGaming — base.css
   ریست، تایپوگرافی، المان‌های پایه
   ============================================================ */

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

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: 'Vazir', 'Segoe UI', Tahoma, sans-serif;
    background: var(--bg-base);
    color: var(--text-primary);
    line-height: 1.65;
    direction: rtl;
    overflow-x: hidden;
    transition: background 0.3s, color 0.3s;
}

/* ── Scrollbar ── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--scrollbar-track); }
::-webkit-scrollbar-thumb { background: var(--scrollbar-thumb); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--accent); }

/* ── Selection ── */
::selection { background: var(--accent-dim2); color: var(--accent); }

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

p { color: var(--text-secondary); }
a { text-decoration: none; color: inherit; transition: var(--transition); }
ul,ol { list-style: none; }
img,svg { display: block; max-width: 100%; }
button { cursor: pointer; font-family: inherit; border: none; background: none; }
input,select,textarea { font-family: inherit; }

/* ── Layout helpers ── */
.container {
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 24px;
    width: 100%;
}

.container--sm { max-width: 760px; margin: 0 auto; padding: 0 24px; width: 100%; }

.section {
    padding: clamp(48px, 9vw, 96px) 0;
}

.section--sm { padding: clamp(36px, 6vw, 64px) 0; }

/* ── Eyebrow label ── */
.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 11px;
    font-weight: bold;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--accent);
    margin-bottom: 16px;
    opacity: 0.85;
}

.eyebrow::before,
.eyebrow::after {
    content: '';
    display: block;
    width: 20px;
    height: 1px;
    background: var(--accent);
    opacity: 0.5;
}

/* ── Section title ── */
.section-title {
    font-size: clamp(26px, 4vw, 44px);
    font-weight: bold;
    line-height: 1.2;
    margin-bottom: 56px;
}

.section-title .hl { color: var(--accent); }

/* ── Buttons ── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 26px;
    border-radius: var(--radius);
    font-size: 14px;
    font-weight: bold;
    font-family: 'Vazir', sans-serif;
    transition: var(--transition);
    cursor: pointer;
    border: none;
    text-decoration: none;
    line-height: 1;
    white-space: nowrap;
}

.btn svg { width: 16px; height: 16px; flex-shrink: 0; }

.btn--primary {
    background: var(--accent);
    color: var(--text-inverted);
    box-shadow: var(--accent-glow);
}
.btn--primary:hover {
    background: var(--accent-hover);
    box-shadow: var(--accent-glow-lg);
    transform: translateY(-2px);
}

.btn--ghost {
    background: transparent;
    border: 1px solid var(--border-strong);
    color: var(--text-primary);
}
.btn--ghost:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: var(--accent-dim);
}

.btn--accent-ghost {
    background: var(--accent-dim);
    border: 1px solid var(--border-accent);
    color: var(--accent);
}
.btn--accent-ghost:hover {
    background: var(--accent);
    color: var(--text-inverted);
    box-shadow: var(--accent-glow);
}

.btn--danger {
    background: rgba(245,82,82,0.1);
    border: 1px solid rgba(245,82,82,0.25);
    color: var(--danger);
}
.btn--danger:hover { background: var(--danger); color: #fff; }

.btn--sm { padding: 8px 16px; font-size: 13px; }
.btn--lg { padding: 16px 36px; font-size: 16px; border-radius: var(--radius-lg); }

/* ── Badge ── */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 10px;
    border-radius: var(--radius-full);
    font-size: 11px;
    font-weight: bold;
}

.badge--green  { background: rgba(96,213,163,0.12); color: var(--accent); border: 1px solid rgba(96,213,163,0.25); }
.badge--red    { background: rgba(245,82,82,0.10);  color: var(--danger); border: 1px solid rgba(245,82,82,0.25); }
.badge--yellow { background: rgba(245,200,66,0.10); color: var(--warning); border: 1px solid rgba(245,200,66,0.25); }
.badge--blue   { background: rgba(82,180,245,0.10); color: var(--info);    border: 1px solid rgba(82,180,245,0.25); }

/* ── Pulse dot ── */
.pulse-dot {
    width: 8px; height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}
.pulse-dot--green { background: var(--accent); box-shadow: 0 0 0 0 var(--accent); animation: pulse-anim 1.8s infinite; }
.pulse-dot--red   { background: var(--danger); animation: none; }

@keyframes pulse-anim {
    0%   { box-shadow: 0 0 0 0 rgba(96,213,163,0.5); }
    70%  { box-shadow: 0 0 0 6px rgba(96,213,163,0); }
    100% { box-shadow: 0 0 0 0 rgba(96,213,163,0); }
}

/* ── Card base ── */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    transition: var(--transition);
}

.card--hover:hover {
    border-color: var(--border-accent);
    background: var(--bg-card-hover);
    transform: translateY(-3px);
    box-shadow: var(--shadow);
}

/* ── Divider ── */
.divider {
    border: none;
    border-top: 1px solid var(--border);
    margin: 48px 0;
}

/* ── Reveal animation ── */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.visible { opacity: 1; transform: none; }

/* ── Theme transition ── */
body, .card, header, footer, .btn, input, select, textarea {
    transition: background 0.3s ease, border-color 0.3s ease, color 0.2s ease, box-shadow 0.3s ease;
}

/* ── Icon sizing helpers ── */
.icon-sm { width: 16px; height: 16px; }
.icon-md { width: 20px; height: 20px; }
.icon-lg { width: 24px; height: 24px; }
.icon-xl { width: 32px; height: 32px; }

/* ════════════════════════════════════════════════════════════
   GLOBAL RESPONSIVE — base.css
   ════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
    .container,
    .container--sm { padding: 0 20px; }

    .section-title { margin-bottom: 40px; }

    .btn--lg { padding: 14px 28px; font-size: 15px; }
}

@media (max-width: 480px) {
    .container,
    .container--sm { padding: 0 16px; }

    .eyebrow { font-size: 10px; letter-spacing: 2px; margin-bottom: 12px; }
    .eyebrow::before,
    .eyebrow::after { width: 14px; }

    .section-title { margin-bottom: 28px; }

    .btn { padding: 11px 20px; font-size: 13px; }
    .btn--lg { width: 100%; padding: 14px 24px; font-size: 14.5px; }

    .divider { margin: 32px 0; }
}

@media (max-width: 360px) {
    .container,
    .container--sm { padding: 0 14px; }
}

/* Respect reduced motion preference across the whole site */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}
