/* ═══════════════════════════════════════════
   PORTFOLIO — Gabriel Vita
   base.css — variables, reset, utilities, buttons, animations
   ═══════════════════════════════════════════ */

/* ── VARIABLES ── */
:root {
    /* Backgrounds — warm dark tinted with brand hue */
    --bg-primary: #0c0a09;
    --bg-secondary: #1c1917;
    --bg-card: #1c1917;
    --bg-card-hover: #292524;
    --border: #292524;
    --border-light: #44403c;

    /* Text */
    --text-primary: #fafaf9;
    --text-secondary: #a8a29e;
    --text-muted: #78716c;

    /* Accent — amber/orange tones */
    --accent: #f59e0b;
    --accent-light: #fbbf24;
    --accent-glow: rgba(245, 158, 11, 0.12);
    --accent-gradient: linear-gradient(135deg, #f59e0b, #ef4444);
    --accent-violet: #ef4444;

    /* Skill levels */
    --senior: #22c55e;
    --pleno: #eab308;
    --inter: #f97316;

    /* Typography */
    --font-display: 'Space Grotesk', sans-serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --container: 1080px;
    --radius: 12px;
    --radius-sm: 8px;

    /* Glow effects — amber */
    --glow-sm: 0 0 20px rgba(245, 158, 11, 0.1);
    --glow-md: 0 0 30px rgba(245, 158, 11, 0.18);

    /* Type scale (1.25 ratio — Major Third) */
    --text-xs: 0.75rem;
    --text-sm: 0.875rem;
    --text-base: 1rem;
    --text-lg: 1.25rem;
    --text-xl: 1.563rem;
    --text-2xl: 1.953rem;
    --text-3xl: 2.441rem;
    --text-4xl: 3.052rem;

    /* Spacing scale (4px base) */
    --space-1: 4px;
    --space-2: 8px;
    --space-3: 12px;
    --space-4: 16px;
    --space-6: 24px;
    --space-8: 32px;
    --space-12: 48px;
    --space-16: 64px;
    --space-24: 96px;

    /* Motion tokens */
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
    --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
    --duration-fast: 150ms;
    --duration-normal: 300ms;
    --duration-slow: 500ms;
}

/* ── FOCUS STYLES ── */
:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
    border-radius: 4px;
}

:focus:not(:focus-visible) {
    outline: none;
}

/* ── SKIP LINK ── */
.skip-link {
    position: absolute;
    top: -100px;
    left: 16px;
    padding: 8px 16px;
    background: var(--accent);
    color: var(--bg-primary);
    font-weight: 600;
    font-size: var(--text-sm);
    border-radius: var(--radius-sm);
    z-index: 10000;
    transition: top var(--duration-fast);
}

.skip-link:focus {
    top: 16px;
}

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

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

body {
    font-family: var(--font-body);
    background: var(--bg-primary);
    color: var(--text-secondary);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

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

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

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

ul {
    list-style: none;
}

h1,
h2,
h3,
h4 {
    font-family: var(--font-display);
    color: var(--text-primary);
    line-height: 1.2;
}

/* ── UTILITIES ── */
.container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 24px;
}

.accent {
    color: var(--accent-light);
}

strong {
    color: var(--text-primary);
    font-weight: 600;
}

section {
    padding: 70px 0;
}

section:nth-child(even) {
    background: var(--bg-secondary);
}

.section-label {
    font-size: 0.68rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: var(--accent);
    margin-bottom: 10px;
}

.section-intro {
    font-size: 0.95rem;
    color: var(--text-secondary);
    max-width: 640px;
    margin-bottom: 40px;
}

section>.container>h2 {
    font-size: clamp(1.3rem, 3vw, 1.7rem);
    font-weight: 800;
    margin-bottom: 12px;
}

/* ── BUTTONS ── */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.9rem;
    transition: transform 0.3s, box-shadow 0.3s, background 0.3s, border-color 0.3s;
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: var(--accent-gradient);
    color: #fff;
    box-shadow: 0 4px 20px var(--accent-glow);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(245, 158, 11, 0.3);
    color: #fff;
}

.btn-outline {
    background: transparent;
    color: var(--text-primary);
    border: 1px solid var(--border-light);
}

.btn-outline:hover {
    border-color: var(--accent);
    color: var(--accent-light);
}

.btn-large {
    padding: 14px 32px;
    font-size: 0.95rem;
}

/* ── SCROLL REVEAL ── */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity var(--duration-slow) var(--ease-out), transform var(--duration-slow) var(--ease-out);
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ── ENHANCED INTERACTIONS (cross-component) ── */
.competency,
.framework-card,
.master-card,
.ai-card {
    transition: border-color 0.4s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.4s cubic-bezier(0.4, 0, 0.2, 1), transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.edu-card:hover,
.project-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 30px rgba(245, 158, 11, 0.1);
}

.competency:hover,
.framework-card:hover {
    border-color: var(--accent);
    box-shadow: 0 4px 20px rgba(245, 158, 11, 0.08);
    transform: translateY(-2px);
}

.master-card:hover {
    border-color: var(--accent);
    box-shadow: 0 4px 20px rgba(245, 158, 11, 0.08);
    transform: translateY(-2px);
}

.ai-card:hover {
    border-color: var(--accent);
    box-shadow: 0 8px 30px rgba(245, 158, 11, 0.1);
    transform: translateY(-4px);
}

.case-study {
    transition: border-color 0.3s, box-shadow 0.3s;
}

.case-study:hover {
    border-color: var(--border-light);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.4);
}

/* Logo enhanced */
.logo-item {
    padding: 20px 36px;
    font-weight: 700;
    font-size: 1rem;
    letter-spacing: 0.5px;
    background: var(--bg-card);
    transition: box-shadow 0.4s cubic-bezier(0.4, 0, 0.2, 1), transform 0.4s cubic-bezier(0.4, 0, 0.2, 1), border-color 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.logo-item:hover {
    box-shadow: 0 4px 20px rgba(245, 158, 11, 0.1);
    transform: translateY(-2px);
}

/* Button press */
.btn-primary:active {
    transform: translateY(0);
}

.btn-outline:active {
    transform: scale(0.98);
}

/* Section divider glow */
section+section {
    border-top: 1px solid var(--border);
}
