/* Explain: Base reset and typography defaults with updated colors. */
* { box-sizing: border-box; }

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
    background: var(--background-color);
}

body {
    margin: 0;
    overflow-x: hidden;
    font-family: var(--font-body);
    color: var(--text-color);
    background: var(--background-color);
    line-height: 1.68;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, h5 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.14;
    color: var(--heading-color);
    margin: 0 0 .55em;
    letter-spacing: -.012em;
}

h1 { font-size: clamp(2.15rem, 5vw, 3.65rem); }
h2 { font-size: clamp(1.6rem, 3.4vw, 2.5rem); }
h3 { font-size: clamp(1.18rem, 2vw, 1.5rem); }
h4 { font-size: 1.08rem; }
p { margin: 0 0 1rem; }

a { color: var(--royal-700); text-decoration: none; transition: color .25s ease; }
a:hover { color: var(--royal-600); }

img { max-width: 100%; display: block; }
button { font-family: inherit; }

:focus-visible {
    outline: 2px solid var(--royal-500);
    outline-offset: 2px;
    border-radius: 4px;
}

::selection { background: var(--navy-800); color: #fff; }

/* Scrollbar */
::-webkit-scrollbar { width: 11px; height: 11px; }
::-webkit-scrollbar-track { background: var(--platinum-100); }
::-webkit-scrollbar-thumb { background: var(--platinum-400); border-radius: 99px; border: 3px solid var(--platinum-100); }
::-webkit-scrollbar-thumb:hover { background: var(--navy-700); }

/* Scroll-reveal */
.reveal {
    opacity: 0;
    transform: translateY(26px);
    transition: opacity .85s cubic-bezier(.16,1,.3,1), transform .85s cubic-bezier(.16,1,.3,1);
}
.reveal.is-visible { opacity: 1; transform: none; }

[x-cloak] { display: none !important; }

@media (prefers-reduced-motion: reduce) {
    .reveal { opacity: 1; transform: none; transition: none; }
    html { scroll-behavior: auto; }
    * { animation-duration: .001ms !important; animation-iteration-count: 1 !important; }
}