/* ============================================================
   PENTASYSAI — BASE STYLES
   Reset, typography, and global utility classes.
   ============================================================ */

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

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

body {
    font-family: var(--font-body);
    font-size: var(--fs-body);
    font-weight: 400;
    line-height: var(--lh-normal);
    color: var(--text-primary);
    background-color: var(--bg-void);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

a {
    text-decoration: none;
    color: inherit;
    transition: color var(--transition-fast);
}

ul, ol {
    list-style: none;
}

button, input, textarea, select {
    font: inherit;
    color: inherit;
    border: none;
    outline: none;
    background: none;
}

button {
    cursor: pointer;
}

table {
    border-collapse: collapse;
}

/* ——— Typography ——— */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-display);
    font-weight: 700;
    line-height: var(--lh-tight);
    text-transform: uppercase;
    letter-spacing: var(--ls-wide);
    color: var(--text-white);
}

h1 { font-size: var(--fs-h1); }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); }
h4 { font-size: var(--fs-h4); }

p {
    color: var(--text-secondary);
    line-height: var(--lh-relaxed);
    margin-bottom: var(--space-4);
}

p:last-child {
    margin-bottom: 0;
}

strong {
    font-weight: 700;
    color: var(--text-white);
}

small {
    font-size: var(--fs-small);
}

/* ——— Selection ——— */
::selection {
    background: rgba(var(--neon-cyan-rgb), 0.3);
    color: var(--text-white);
}

/* ——— Scrollbar ——— */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-void);
}

::-webkit-scrollbar-thumb {
    background: rgba(var(--neon-cyan-rgb), 0.25);
    border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(var(--neon-cyan-rgb), 0.45);
}

/* ——— Container ——— */
.container {
    width: 100%;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--container-pad);
}

/* ——— Section Base ——— */
section {
    position: relative;
    z-index: var(--z-content);
    padding: var(--section-pad) 0;
}

/* ——— Utility — Text ——— */
.text-center  { text-align: center; }
.text-left    { text-align: left; }
.text-right   { text-align: right; }

.text-cyan    { color: var(--neon-cyan); }
.text-purple  { color: var(--neon-purple); }
.text-gold    { color: var(--neon-gold); }
.text-green   { color: var(--neon-green); }
.text-indigo  { color: var(--dev-indigo); }
.text-amber   { color: var(--dev-amber); }
.text-emerald { color: var(--dev-emerald); }
.text-muted   { color: var(--text-muted); }
.text-dim     { color: var(--text-dim); }
.text-white   { color: var(--text-white); }

.text-gradient-cyan {
    background: linear-gradient(135deg, var(--neon-cyan), var(--neon-purple));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.text-gradient-dev {
    background: linear-gradient(135deg, var(--dev-indigo), var(--dev-violet));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.text-glow-cyan {
    text-shadow: 0 0 20px rgba(var(--neon-cyan-rgb), 0.4), 0 0 60px rgba(var(--neon-cyan-rgb), 0.15);
}

.text-glow-purple {
    text-shadow: 0 0 20px rgba(var(--neon-purple-rgb), 0.4), 0 0 60px rgba(var(--neon-purple-rgb), 0.15);
}

/* ——— Utility — Font ——— */
.font-display { font-family: var(--font-display); }
.font-body    { font-family: var(--font-body); }
.font-mono    { font-family: var(--font-mono); }

.uppercase    { text-transform: uppercase; }
.lowercase    { text-transform: lowercase; }
.capitalize   { text-transform: capitalize; }
.normal-case  { text-transform: none; }

.tracking-wide   { letter-spacing: var(--ls-wide); }
.tracking-wider  { letter-spacing: var(--ls-wider); }
.tracking-widest { letter-spacing: var(--ls-widest); }

/* ——— Utility — Display ——— */
.block        { display: block; }
.inline-block { display: inline-block; }
.flex         { display: flex; }
.inline-flex  { display: inline-flex; }
.grid         { display: grid; }

.flex-center {
    display: flex;
    align-items: center;
    justify-content: center;
}

.flex-between {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.flex-col {
    display: flex;
    flex-direction: column;
}

.flex-wrap { flex-wrap: wrap; }
.gap-2 { gap: var(--space-2); }
.gap-3 { gap: var(--space-3); }
.gap-4 { gap: var(--space-4); }
.gap-6 { gap: var(--space-6); }
.gap-8 { gap: var(--space-8); }

/* ——— Utility — Spacing ——— */
.mx-auto { margin-left: auto; margin-right: auto; }
.mt-4  { margin-top: var(--space-4); }
.mt-8  { margin-top: var(--space-8); }
.mt-12 { margin-top: var(--space-12); }
.mt-16 { margin-top: var(--space-16); }
.mb-4  { margin-bottom: var(--space-4); }
.mb-6  { margin-bottom: var(--space-6); }
.mb-8  { margin-bottom: var(--space-8); }
.mb-12 { margin-bottom: var(--space-12); }
.mb-16 { margin-bottom: var(--space-16); }
.pt-8  { padding-top: var(--space-8); }
.pb-8  { padding-bottom: var(--space-8); }

/* ——— Utility — Visibility ——— */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.hidden { display: none !important; }
.visible { visibility: visible; }
.invisible { visibility: hidden; }

/* ——— Utility — Max Width ——— */
.max-w-sm   { max-width: 640px; }
.max-w-md   { max-width: 768px; }
.max-w-lg   { max-width: 900px; }
.max-w-xl   { max-width: 1100px; }
.max-w-full { max-width: 100%; }

/* ——— Background Layers ——— */
#particles-js {
    position: fixed;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    background: radial-gradient(circle at 30% 20%, rgba(79, 70, 229, 0.03) 0%, transparent 50%), radial-gradient(circle at 80% 70%, rgba(225, 29, 72, 0.02) 0%, transparent 50%), var(--bg-void);
    z-index: var(--z-particles);
}

.scanlines {
    display: none !important;
}
