/* ===========================
   1. Design Tokens
=========================== */

:root {

    /* Colors - Premium Architecture Palette */
    --color-primary: #080808;
    --color-primary-light: #141414;
    --color-secondary: #757575;
    --color-secondary-light: #A0A0A0;
    --color-background: #FAFAFA;
    --color-background-alt: #F0F0F0;
    --color-white: #FFFFFF;
    --color-accent:#525252;
    --color-accent-hover: #9A7209;
    --color-border: #E8E8E8;
    --color-border-dark: #D4D4D4;

    /* Semantic Colors */
    --color-success: #2E7D32;
    --color-error: #D32F2F;
    --color-warning: #ED6C02;

    /* Typography - Premium Editorial */
    --font-heading: "Manrope", sans-serif;
    --font-body: "Manrope", sans-serif;
    --font-mono: "IBM Plex Mono", monospace;

    /* Font Sizes - Fluid Typography (Editorial Scale) */
   --fs-display: clamp(3rem, 4.5vw, 6rem);
    --fs-h1: clamp(2.5rem, 6vw, 5rem);
    --fs-h2: clamp(2rem, 5vw, 3.5rem);
    --fs-h3: clamp(1.5rem, 3vw, 2.25rem);
    --fs-h4: clamp(1.25rem, 2.5vw, 1.75rem);
    --fs-h5: clamp(1.125rem, 2vw, 1.5rem);
    --fs-body: clamp(1rem, 1.1vw, 1.125rem);
    --fs-small: clamp(0.875rem, 1vw, 1rem);
    --fs-tiny: 0.75rem;
    --fs-caption: 0.875rem;

    /* Font Weights */
    --fw-light: 300;
    --fw-regular: 400;
    --fw-medium: 500;
    --fw-semibold: 600;
    --fw-bold: 700;
    --fw-extrabold: 800;

    /* Line Heights - Editorial */
    --lh-display: 0.95;
    --lh-heading: 1.1;
    --lh-body: 1.7;
    --lh-tight: 1.2;
    --lh-loose: 1.8;

    /* Letter Spacing */
    --ls-tight: -0.02em;
    --ls-normal: 0;
    --ls-wide: 0.05em;
    --ls-wider: 0.1em;
    --ls-widest: 0.15em;

    /* Spacing Scale - Premium Whitespace */
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-5: 1.25rem;
    --space-6: 1.5rem;
    --space-8: 2rem;
    --space-10: 2.5rem;
    --space-12: 3rem;
    --space-16: 4rem;
    --space-20: 5rem;
    --space-24: 6rem;
    --space-32: 8rem;
    --space-40: 10rem;
    --space-48: 12rem;
    --space-64: 16rem;
    --space-80: 20rem;
    --space-96: 24rem;

    /* Section Spacing */
    --section-space-sm: var(--space-16);
    --section-space-md: var(--space-24);
    --section-space-lg: var(--space-32);

    /* Container Widths */
    --container-sm: 640px;
    --container-md: 768px;
    --container-lg: 1024px;
    --container-xl: 1280px;
    --container-xxl: 1440px;
    --container-width: var(--container-xl);

    /* Border Radius */
    --radius-none: 0;
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    --radius-2xl: 24px;
    --radius-full: 9999px;

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);

    /* Transitions */
    --transition-fast: 150ms ease;
    --transition-base: 250ms ease;
    --transition-slow: 400ms ease;
    --transition-slower: 600ms ease;
    --transition-spring: 500ms cubic-bezier(0.175, 0.885, 0.32, 1.275);

    /* Z-Index Scale */
    --z-dropdown: 100;
    --z-sticky: 200;
    --z-fixed: 300;
    --z-modal-backdrop: 400;
    --z-modal: 500;
    --z-popover: 600;
    --z-tooltip: 700;

    /* Grid */
    --grid-cols: 12;
    --grid-gap: var(--space-6);
    --grid-gap-lg: var(--space-8);

    /* Focus States */
    --focus-ring: 0 0 0 3px rgba(201, 169, 98, 0.4);
    --focus-outline: 2px solid var(--color-accent);

    /* Overlay */
    --overlay-light: rgba(255, 255, 255, 0.9);
    --overlay-dark: rgba(10, 10, 10, 0.9);
    --overlay-accent: rgba(201, 169, 98, 0.9);
}

/* ===========================
   2. Reset & Base
=========================== */

*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-size-adjust: 100%;
}

body {
    font-family: var(--font-body);
    background: var(--color-background);
    color: var(--color-primary);
    line-height: var(--lh-body);
    font-size: var(--fs-body);
    overflow-x: hidden;
}

img,
picture,
video,
canvas,
svg {
    display: block;
    max-width: 100%;
    height: auto;
    content-visibility: auto;
}

input,
button,
textarea,
select {
    font: inherit;
    color: inherit;
}

button {
    cursor: pointer;
    background: none;
    border: none;
}

a {
    color: inherit;
    text-decoration: none;
}

ul,
ol {
    list-style: none;
}

/* Performance: Contain paint where possible */
.hero-bg,
.project-image img,
.studio-image img {
    contain: layout paint;
}

/* ===========================
   3. Typography
=========================== */

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: var(--fw-bold);
    line-height: var(--lh-heading);
    color: var(--color-primary);
    letter-spacing: var(--ls-tight);
}

h1 {
    font-size: var(--fs-h1);
    font-weight: var(--fw-extrabold);
}

h2 {
    font-size: var(--fs-h2);
}

h3 {
    font-size: var(--fs-h3);
    font-weight: var(--fw-semibold);
}

h4 {
    font-size: var(--fs-h4);
    font-weight: var(--fw-semibold);
}

h5 {
    font-size: var(--fs-h5);
    font-weight: var(--fw-medium);
}

h6 {
    font-size: var(--fs-small);
    font-weight: var(--fw-semibold);
    text-transform: uppercase;
    letter-spacing: var(--ls-wide);
}

p {
    font-family: var(--font-body);
    font-size: var(--fs-body);
    color: var(--color-secondary);
    line-height: var(--lh-loose);
    max-width: 65ch;
}

a {
    color: var(--color-primary);
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--color-accent);
}

a:focus {
    outline: var(--focus-outline);
    outline-offset: 2px;
}

small {
    font-family: var(--font-mono);
    font-size: var(--fs-small);
    color: var(--color-secondary);
}

strong,
b {
    font-weight: var(--fw-semibold);
}

em,
i {
    font-style: italic;
}

/* ===========================
   4. Selection
=========================== */

::selection {
    background: var(--color-accent);
    color: var(--color-white);
}

::-moz-selection {
    background: var(--color-accent);
    color: var(--color-white);
}

/* ===========================
   5. Scrollbar
=========================== */

::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--color-background-alt);
}

::-webkit-scrollbar-thumb {
    background: var(--color-secondary-light);
    border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--color-secondary);
}

/* ===========================
   6. Focus Visible
=========================== */

:focus-visible {
    outline: var(--focus-outline);
    outline-offset: 2px;
}

/* ===========================
   7. Reduced Motion
=========================== */

@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;
    }
}