/* -----------------------------
   Global Styles
------------------------------- */
body, html {
    height: 100%;
    margin: 0;
    font-family: "Montserrat", sans-serif;
    /* Uses cover to ensure background always fills the viewport */
    background: url("/compass/img/mountains.avif") no-repeat center center fixed;
    background-size: cover;
    color: #fff;
    overflow-x: hidden; /* Prevents horizontal scroll from responsive layout issues */
    /*overflow-y: auto;*/
}

body {
    display: flex;             /* 1. Enable Flexbox */
    flex-direction: column;    /* 2. Stack elements (content then footer) vertically */
    min-height: 100vh;         /* 3. Ensure the body is at least the full viewport height */
    overflow-y: auto;          /* 4. Put scroll back on the body for long pages */
}

.content-wrap {
    flex-grow: 1; /* THE KEY RULE: Takes up all remaining space */
    position: relative; /* May be useful for positioning children relative to content */
    z-index: 2; /* Keep content above the fixed overlay */

    display: flex;             /* 1. Enable Flexbox on the wrapper */
    justify-content: center;   /* 2. Center children horizontally */
    align-items: center;       /* 3. Center children vertically */
    padding: 20px 0; /* Adds vertical padding for spacing */
}

.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    background-color: rgba(0,0,0,0.5); /* Semi-transparent black layer */
    z-index: 1;
}

/* -----------------------------
   Landing Container (Hero Section & Content Wrapper)
------------------------------- */
.landing-container {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 500px; /* Default max-width for the hero part */
    padding: 2rem;
    background: rgba(0,0,0,0.45); /* Dark, translucent background */
    border-radius: 1rem;
    margin: 5rem auto 2rem auto;
}

.landing-container h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
    /* Gradient text for aesthetic effect */
    background: linear-gradient(135deg, #f6f8f8 0%, #ffffff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.landing-container p {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: #ddd;
}

.landing-container .small {
    color: #ddd;
}

.landing-container .btn {
    min-width: 140px;
    font-weight: 600;
    margin: 0.5rem;
}

/* -----------------------------
   Content Page Layout (Applies to the htmx loaded partials)
------------------------------- */

/* Ensures gradient styling is applied to headings inside content partials */
.landing-container h2,
.landing-container h3 {
    /* Reuses the gradient effect for sub-headings */
    background: linear-gradient(135deg, #f6f8f8 0%, #ffffff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 600; 
    margin-top: 1.5rem;
}


/* -----------------------------
   Info Cards Section (Original landing page cards)
------------------------------- */
.info-cards-container {
    position: relative;
    z-index: 2;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1rem;
    max-width: 1000px;
    /* Allows content to expand and trigger main page scroll */
    margin: 2rem auto 4rem auto; 
    padding: 1rem; /* Added back padding for spacing around cards */
}

.info-card {
    /* FIXED: Using a dark, translucent background for better blending (0.35 opacity) */
    background: rgba(0, 0, 0, 0.4); 
    border-radius: 1rem;
    padding: 1.5rem;
    /* Defines base size for Flexbox */
    width: 280px; 
    flex: 1 1 280px;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.info-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.6);
}

.info-card h5 {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 0.8rem;
    /* Applies gradient text style */
    background: linear-gradient(135deg, #f6f8f8 0%, #ffffff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.info-card p {
    font-size: 1rem;
    color: #ddd;
    margin-bottom: 1rem;
}

.card-btn {
    display: inline-block;
    padding: 0.5rem 1rem;
    font-weight: 600;
    color: #007bff;
    background: #fff;
    border-radius: 0.5rem;
    text-decoration: none;
    transition: background 0.3s ease, color 0.3s ease;
}

.card-btn:hover {
    background: #007bff;
    color: #fff;
}


/* -----------------------------
   Features Grid Styles (For the /compass/info/features partial)
------------------------------- */

.features-grid {
    display: grid;
    /* Allows three cards across on larger screens, two on medium, one on mobile */
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); 
    gap: 1.25rem;
    margin-bottom: 2.5rem;
    padding: 0 1rem;
}

.feature-card {
    /* Style to match the translucent, dark aesthetic */
    background: rgba(0, 0, 0, 0.4); 
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 0.75rem;
    padding: 1.5rem;
    text-align: center;
    transition: all 0.2s ease;
}

.feature-card:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.25);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.4);
}

.feature-icon {
    font-size: 2.25rem;
    margin-bottom: 0.75rem;
    display: inline-block;
    text-shadow: 0 0 8px rgba(0,0,0,0.8);
}

.feature-title {
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #fff;
}

.feature-description {
    font-size: 0.95rem;
    color: #cbd5e1;
    line-height: 1.5;
}

.floating-action {
    position: relative;
    z-index: 2;
    text-align: center;
    margin: 2rem auto 0 auto;
}

.more-info-btn {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.6);
    color: #f6f8f8;
    font-size: 0.85rem;
    letter-spacing: 0.08em;
    padding: 0.4rem 1.2rem;
    border-radius: 999px;
    opacity: 0.75;
    transition: all 0.25s ease;
}

.more-info-btn:hover {
    opacity: 1;
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.08);
    border-color: #ffffff;
}

/* -----------------------------
   Responsive Layouts
------------------------------- */
@media (max-width: 768px) {
    .info-cards-container {
        /* Stacks cards vertically on smaller tablets/phones */
        flex-direction: column;
        align-items: center;
    }
}

@media (max-width: 600px) {
    .features-grid {
        grid-template-columns: 1fr; /* Stack feature cards vertically on small screens */
    }
}

@media (max-width: 576px) {
    .landing-container h1 {
        font-size: 2rem;
    }

    .landing-container p {
        font-size: 1rem;
    }
}