/* ===========================
   ROOT COLORS
   =========================== */
:root {
    --base-navyblue: #0f172a;
    --accent-red: #dc2626;
    --text-blue: #334155;
    --clr-white: #ffffff;
    --clr-charcoal: #333333;
    --clr-offwhite: #f8fafc;
    --clr-highlight-bg: #4f5f7f;
    --clr-border: rgba(15, 23, 42, 0.08);
    --clr-shadow: rgba(15, 23, 42, 0.05);
    --clr-card-hover: #f7f9fc;
}

/* ===========================
   GLOBAL
   =========================== */
body {
    font-family: "Inter", "Lato", sans-serif;
    background: var(--clr-offwhite);
    color: var(--text-blue);
    margin: 0;
    padding: 0;
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3 {
    color: var(--base-navyblue);
    margin-top: 0;
    font-family: "Inter", sans-serif;
    letter-spacing: -0.015em;
}

h1 {
    font-size: clamp(1.8rem, 2.5vw + 0.5rem, 2.8rem);
    font-weight: 700;
    line-height: 1.2;
}

h2 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    position: relative;
    padding-bottom: 0.75rem;
}

h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 2px;
    background: var(--accent-red);
    border-radius: 2px;
}

h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
}

a {
    text-decoration: none;
    color: var(--base-navyblue);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

a:hover {
    color: var(--accent-red);
}

/* ===========================
   PAGE HEADER
   =========================== */
.page-header {
    text-align: center;
    padding: 5rem 1.5rem 4rem;
    background: var(--clr-white);
    position: relative;
    overflow: hidden;
}

.page-header::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 120px;
    height: 3px;
    background: var(--accent-red);
    border-radius: 2px;
}

.page-header h1 {
    margin-bottom: 1rem;
    position: relative;
}

.page-header .subtitle {
    max-width: 700px;
    margin: 0 auto;
    font-size: 1.125rem;
    color: var(--clr-highlight-bg);
    font-family: "Lato", sans-serif;
    font-weight: 400;
    line-height: 1.6;
}

/* ===========================
   SECTIONS
   =========================== */
.resource-section {
    max-width: 880px;
    margin: 4rem auto;
    padding: 0 1.5rem;
    position: relative;
}

.section-description {
    color: var(--clr-highlight-bg);
    margin-bottom: 2.5rem;
    margin-block-start: .7rem;
    font-family: "Lato", sans-serif;
    font-size: 1.05rem;
    line-height: 1.6;
    font-style: italic;
    padding-left: 1rem;
    border-left: 2px solid rgba(220, 38, 38, 0.2);
}

.resource-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.resource-list li {
    background: var(--clr-white);
    padding: 1.25rem 1.5rem;
    border-radius: 10px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
}

.resource-list li:hover {
    background: var(--clr-card-hover);
    transform: translateX(4px);
    box-shadow: 0 6px 20px rgba(15, 23, 42, 0.08);
}

.resource-list li a {
    font-weight: 500;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-family: "Inter", sans-serif;
}

.resource-list li a::after {
    content: '→';
    font-weight: 600;
    color: var(--accent-red);
    opacity: 0;
    transform: translateX(-10px);
    transition: all 0.3s ease;
}

.resource-list li:hover a::after {
    opacity: 1;
    transform: translateX(0);
}

/* ===========================
   FEATURED GUIDES
   =========================== */
.featured-guides {
    background: var(--clr-white);
    padding: 5rem 1.5rem;
    margin-top: 2rem;
    position: relative;
}

.featured-guides::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0%;
    transform: translateX(-50%);
    width: 200px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--clr-border), transparent);
}

.featured-guides h2 {
    text-align: center;
    margin-bottom: 3rem;
}



.featured-grid {
    max-width: 880px;
    margin: 0 auto;
    display: grid;
    gap: 2rem;
}

@media (min-width: 700px) {
    .featured-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.featured-card {
    display: block;
    background: var(--clr-offwhite);
    border-radius: 12px;
    padding: 2.25rem 2rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    height: 100%;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.05);
}

.featured-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 100%;
    background: linear-gradient(135deg, transparent, rgba(220, 38, 38, 0.02), transparent);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.featured-card:hover {
    background: var(--clr-white);
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.1);
}

.featured-card:hover::before {
    opacity: 1;
}

.featured-card h3 {
    margin-top: 0;
    margin-bottom: 1rem;
    color: var(--base-navyblue);
    position: relative;
}

.featured-card p {
    margin-bottom: 0;
    color: var(--clr-highlight-bg);
    font-family: "Lato", sans-serif;
    line-height: 1.6;
    position: relative;
}

.featured-card .icon-wrapper {
    display: inline-block;
    width: 32px;
    height: 32px;
    background: var(--accent-red);
    border-radius: 6px;
    margin-bottom: 1.25rem;
    position: relative;
}

.featured-card .icon-wrapper::before {
    content: '→';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-weight: 600;
    font-size: 1.1rem;
}

/* ===========================
   RESPONSIVE ADJUSTMENTS
   =========================== */
@media (min-width: 768px) {
    .page-header {
        padding: 6rem 2rem 5rem;
    }
    
    .page-header h1 {
        font-size: 3rem;
    }
    
    h2 {
        font-size: 1.75rem;
    }
    
    h2::after {
        width: 50px;
    }
    
    h3 {
        font-size: 1.4rem;
    }
    
    .resource-section {
        padding: 0 2rem;
    }
    
    .resource-list li {
        padding: 1.5rem 2rem;
    }
    
    .featured-card {
        padding: 2.5rem 2rem;
    }
}

@media (max-width: 700px) {
    .featured-grid {
        grid-template-columns: 1fr;
    }
    
    .resource-section {
        padding: 0 1rem;
    }
    
    h2::after {
        left: 0;
        transform: none;
    }
}

/* ===========================
   ANIMATIONS & MICRO-INTERACTIONS
   =========================== */
@keyframes fade-in-up {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.resource-section {
    animation: fade-in-up 0.6s ease-out;
}

.resource-section:nth-child(2) {
    animation-delay: 0.1s;
}

.resource-section:nth-child(3) {
    animation-delay: 0.2s;
}

.featured-guides {
    animation: fade-in-up 0.6s ease-out 0.3s both;
}

/* Smooth scroll behavior */
@media (prefers-reduced-motion: no-preference) {
    html {
        scroll-behavior: smooth;
    }
}

/* ===========================
   UTILITY CLASSES
   =========================== */
.text-gradient {
    background: linear-gradient(90deg, var(--base-navyblue), var(--accent-red));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* ===========================
   HEADING ::AFTER ENHANCEMENTS
   =========================== */
h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 2.5rem;
    width: 40px;
    height: 2px;
    background: var(--accent-red);
    border-radius: 1px;
    transform-origin: left;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 1px 3px rgba(220, 38, 38, 0.3);
}

h2:hover::after {
    transform: scaleX(1.8);
    width: 60px;
    box-shadow: 0 2px 6px rgba(220, 38, 38, 0.4);
    height: 3px;
}

/* Featured guides heading positioning */
.featured-guides h2::after {
    left: 50%;
    transform: translateX(-50%);
    bottom: 0;
}

/* .featured-guides h2:hover::after {
    transform: translateX(-50%) scaleX(1.8);
    width: 80px;
} */

/* Adjust for responsive */
@media (min-width: 768px) {
    h2::after {
        left: 3rem;
        width: 50px;
    }
    
    h2:hover::after {
        width: 70px;
    }
    
    /* .featured-guides h2:hover::after {
        width: 100px;
    } */
}