/* =====================================
   BASE STYLES - Reset & Typography
   ===================================== */

/* Import Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&family=Playfair+Display:ital,wght@0,400;0,500;0,600;0,700;1,400;1,500&display=swap');

/* =========================
   CSS RESET
   ========================= */

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

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

body {
    font-family: var(--font-body);
    font-size: var(--text-base);
    font-weight: var(--font-regular);
    line-height: var(--leading-normal);
    color: var(--color-secondary);
    background-color: var(--color-cream);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Remove default list styles */
ul,
ol {
    list-style: none;
}

/* Remove default link styles */
a {
    color: inherit;
    text-decoration: none;
}

/* Remove default button styles */
button {
    font-family: inherit;
    font-size: inherit;
    cursor: pointer;
    border: none;
    background: none;
}

/* Make images responsive */
img,
picture,
video,
canvas,
svg {
    display: block;
    max-width: 100%;
    height: auto;
}

/* Remove default form styling */
input,
textarea,
select {
    font-family: inherit;
    font-size: inherit;
}

/* Remove default heading styles */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-size: inherit;
    font-weight: inherit;
}

/* =========================
   TYPOGRAPHY
   ========================= */

/* Headings */
.heading-1,
h1 {
    font-family: var(--font-display);
    font-size: var(--text-5xl);
    font-weight: var(--font-bold);
    line-height: var(--leading-tight);
    letter-spacing: var(--tracking-tight);
    color: var(--color-secondary);
}

.heading-2,
h2 {
    font-family: var(--font-display);
    font-size: var(--text-4xl);
    font-weight: var(--font-semibold);
    line-height: var(--leading-tight);
    color: var(--color-secondary);
}

.heading-3,
h3 {
    font-family: var(--font-display);
    font-size: var(--text-3xl);
    font-weight: var(--font-semibold);
    line-height: var(--leading-snug);
    color: var(--color-secondary);
}

.heading-4,
h4 {
    font-family: var(--font-display);
    font-size: var(--text-2xl);
    font-weight: var(--font-medium);
    line-height: var(--leading-snug);
    color: var(--color-secondary);
}

.heading-5,
h5 {
    font-family: var(--font-body);
    font-size: var(--text-xl);
    font-weight: var(--font-semibold);
    line-height: var(--leading-snug);
    color: var(--color-secondary);
}

.heading-6,
h6 {
    font-family: var(--font-body);
    font-size: var(--text-lg);
    font-weight: var(--font-semibold);
    line-height: var(--leading-normal);
    color: var(--color-secondary);
}

/* Text styles */
.text-body {
    font-size: var(--text-base);
    line-height: var(--leading-relaxed);
}

.text-lead {
    font-size: var(--text-xl);
    line-height: var(--leading-relaxed);
    color: var(--color-gray-600);
}

.text-small {
    font-size: var(--text-sm);
    line-height: var(--leading-normal);
}

.text-caption {
    font-size: var(--text-xs);
    line-height: var(--leading-normal);
    color: var(--color-gray-500);
    text-transform: uppercase;
    letter-spacing: var(--tracking-wider);
}

/* Text colors */
.text-primary {
    color: var(--color-primary);
}

.text-secondary {
    color: var(--color-secondary);
}

.text-muted {
    color: var(--color-gray-500);
}

.text-white {
    color: var(--color-white);
}

.text-cream {
    color: var(--color-cream);
}

/* Text alignment */
.text-left {
    text-align: left;
}

.text-center {
    text-align: center;
}

.text-right {
    text-align: right;
}

/* =========================
   LINKS
   ========================= */

.link {
    color: var(--color-primary);
    text-decoration: underline;
    text-underline-offset: 2px;
    transition: color var(--transition-fast);
}

.link:hover {
    color: var(--color-primary-dark);
}

.link-nav {
    position: relative;
    font-weight: var(--font-medium);
    text-decoration: none;
    transition: color var(--transition-fast);
}

.link-nav::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--color-primary);
    transition: width var(--transition-base);
}

.link-nav:hover::after,
.link-nav.active::after {
    width: 100%;
}

/* =========================
   SELECTION
   ========================= */

::selection {
    background-color: var(--color-primary);
    color: var(--color-white);
}

/* =========================
   FOCUS STYLES
   ========================= */

:focus-visible {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

/* =========================
   SCROLLBAR
   ========================= */

::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--color-cream-dark);
}

::-webkit-scrollbar-thumb {
    background: var(--color-gray-400);
    border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--color-gray-500);
}

/* =========================
   UTILITIES
   ========================= */

.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;
}