/* ===================================================================
   homepage.css — Editorial landing page (Variant B: card-up)
   =================================================================== */
/* TOC:
   1. Page overrides
   2. Hero
   3. Hero form (constraint inputs)
   4. Hero card (provider preview)
   5. Fact line
   6. Journey tools
   7. Cities section
   8. Origin line
   9. CTAs
   10. Animations
   11. Mobile overrides
*/

/* --- 1. Page overrides --- */
body.hp { background: var(--linen); }

/* --- 2. Hero --- */
.hero {
    padding: 7rem 0 2rem;
    text-align: center;
    background: var(--linen);
}
.hero h1 {
    font-size: clamp(2.4rem, 5vw, 3.8rem);
    color: var(--black);
    letter-spacing: -0.02em;
    line-height: 1.08;
    max-width: 580px;
    margin: 0 auto 1.25rem;
    opacity: 0;
    animation: fadeUp 0.6s ease forwards;
}
.hero__sub {
    font-size: 0.875rem;
    font-weight: 300;
    color: var(--patina);
    max-width: 400px;
    margin: 0 auto 3.5rem;
    line-height: 1.75;
    opacity: 0;
    animation: fadeUp 0.6s ease 0.1s forwards;
}

/* --- 3. Hero form --- */
.hero__form {
    display: flex;
    align-items: flex-end;
    gap: 1.25rem;
    max-width: 480px;
    margin: 0 auto 3rem;
    opacity: 0;
    animation: fadeUp 0.5s ease 0.2s forwards;
}
.hero__field {
    flex: 1;
    text-align: left;
}
.hero__field-label {
    display: block;
    font-size: 0.58rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--patina);
    margin-bottom: 0.3rem;
}
.hero__field select {
    width: 100%;
    padding: 0.55rem 2rem 0.55rem 0.75rem;
    border: 1px solid var(--patina);
    border-radius: 2px;
    font-family: 'Inter', sans-serif;
    font-size: 0.875rem;
    font-weight: 400;
    color: var(--charcoal);
    background: var(--white);
    cursor: pointer;
    transition: border-color 0.2s;
    -webkit-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg width='10' height='6' viewBox='0 0 10 6' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1L5 5L9 1' stroke='%238A7D6B' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
}
.hero__field select:focus { outline: none; border-color: var(--action-secondary); }
.hero__go {
    font-family: 'Inter', sans-serif;
    font-size: 0.625rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    color: var(--black);
    background: none;
    border: none;
    border-bottom: 1px solid var(--black);
    padding: 0.6rem 0 0.55rem;
    cursor: pointer;
    white-space: nowrap;
    transition: color 0.2s, border-color 0.2s;
    text-transform: uppercase;
}
.hero__go:hover { color: var(--action-secondary); border-color: var(--action-secondary); }

/* --- 4. Hero card --- */
.hero__card-wrap {
    max-width: 640px;
    margin: 0 auto;
    opacity: 0;
    animation: fadeUp 0.6s ease 0.35s forwards;
}
.hp-card {
    max-width: 640px;
    margin: 0 auto;
    background: var(--white);
    border: 1px solid var(--rule);
    transition: border-color 0.2s;
}
.hp-card:hover { border-color: var(--patina); }
.hp-card__z1 {
    padding: 2rem 2.25rem 1.5rem;
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
}
.hp-card__grade {
    width: 42px; height: 42px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-family: 'DM Serif Display', Georgia, serif;
    font-size: 1.1rem; color: var(--white); flex-shrink: 0;
    margin-top: 0.15rem;
}
.hp-card__grade--A { background: var(--grade-A); }
.hp-card__basics { flex: 1; min-width: 0; }
.hp-card__name {
    font-family: 'DM Serif Display', Georgia, serif;
    font-size: 1.25rem; color: var(--black);
    line-height: 1.2; margin-bottom: 0.25rem;
}
.hp-card__meta {
    font-size: 0.625rem; font-weight: 400;
    letter-spacing: 0.04em; color: var(--patina);
}
.hp-card__tags {
    display: flex; gap: 0.75rem; margin-top: 0.85rem; flex-wrap: wrap;
}
.hp-card__tag { font-size: 0.625rem; font-weight: 300; color: var(--patina); }
.hp-card__tag-label { font-weight: 600; color: var(--charcoal); }
.hp-card__enrollment {
    font-size: 0.625rem; font-weight: 500; color: var(--action-primary);
    margin-top: 0.6rem;
}
.hp-card__enrollment::before {
    content: ''; display: inline-block; width: 5px; height: 5px;
    border-radius: 50%; background: var(--action-primary);
    margin-right: 0.35rem; vertical-align: 1px;
}
.hp-card__z2 {
    padding: 1.25rem 2.25rem;
    background: var(--cream);
    border-top: 1px solid var(--rule);
    border-bottom: 1px solid var(--rule);
}
.hp-card__z2-title {
    font-size: 0.55rem; font-weight: 600; text-transform: uppercase;
    letter-spacing: 0.12em; color: var(--patina); margin-bottom: 0.75rem;
}
.hp-card__insights { display: grid; grid-template-columns: 1fr 1fr; gap: 0.5rem 2.5rem; }
.hp-card__insight { font-size: 0.75rem; font-weight: 300; color: var(--charcoal); line-height: 1.5; }
.hp-card__insight-label { font-weight: 500; color: var(--patina); }
.hp-card__z3 { padding: 1.25rem 2.25rem 1.75rem; }
.hp-card__z3-title {
    font-size: 0.55rem; font-weight: 600; text-transform: uppercase;
    letter-spacing: 0.12em; color: var(--patina); margin-bottom: 0.75rem;
}
.hp-card__details { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 0.6rem 2rem; }
.hp-card__detail { font-size: 0.75rem; font-weight: 400; color: var(--charcoal); }
.hp-card__detail-label {
    display: block; font-size: 0.58rem; font-weight: 500;
    color: var(--patina); margin-bottom: 0.1rem; letter-spacing: 0.02em;
}

/* --- 5. Fact line --- */
.fact {
    padding: 1.75rem 0 2rem;
    text-align: center;
    background: var(--linen);
}
.fact__text {
    font-size: 0.75rem;
    font-weight: 300;
    color: var(--patina);
    letter-spacing: 0.03em;
}
.fact__num {
    font-weight: 600;
    color: var(--charcoal);
}
.fact__sep {
    display: inline-block;
    width: 24px;
    height: 1px;
    background: var(--linen-deep);
    margin: 0 0.75rem;
    vertical-align: middle;
}

/* Thin rule divider */
.hp-rule {
    border: none;
    border-top: 1px solid var(--linen-deep);
    margin: 0;
}

/* --- 6. Journey tools --- */
.tools {
    padding: 5.5rem 0;
    background: var(--linen);
}
.tools__header {
    text-align: center;
    margin-bottom: 3rem;
}
.tools__kicker {
    font-size: 0.55rem; font-weight: 600; text-transform: uppercase;
    letter-spacing: 0.14em; color: var(--patina); margin-bottom: 0.5rem;
}
.tools__header h2 {
    font-family: 'DM Serif Display', Georgia, serif;
    font-size: clamp(1.3rem, 3vw, 1.6rem);
    color: var(--black); font-weight: 400;
}
.tools__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
    max-width: 720px;
    margin: 0 auto;
}
.tools__item {
    text-align: center;
    padding: 2.5rem 1.75rem;
    text-decoration: none;
    background: var(--white);
    border: 1px solid var(--rule);
    transition: border-color 0.2s;
}
.tools__item:hover { border-color: var(--patina); }
.tools__item h3 {
    font-family: 'DM Serif Display', Georgia, serif;
    font-size: 1rem; color: var(--black);
    margin-bottom: 0.6rem; font-weight: 400;
}
.tools__item p {
    font-size: 0.75rem; font-weight: 300;
    color: var(--patina); line-height: 1.65;
}
.tools__item-link {
    display: inline-block; margin-top: 1.25rem;
    font-size: 0.58rem; font-weight: 600; text-transform: uppercase;
    letter-spacing: 0.1em; color: var(--black);
    border-bottom: 1px solid var(--black);
    padding-bottom: 1px;
    opacity: 0; transform: translateY(3px);
    transition: opacity 0.2s, transform 0.2s, color 0.2s, border-color 0.2s;
}
.tools__item:hover .tools__item-link {
    opacity: 1; transform: translateY(0);
}
.tools__item:hover .tools__item-link:hover {
    color: var(--action-secondary); border-color: var(--action-secondary);
}

/* --- 7. Cities section --- */
.cities-section {
    padding: 4.5rem 0;
    background: var(--white);
    border-top: 1px solid var(--rule);
}
.cities__row {
    display: flex; justify-content: center;
    align-items: baseline; gap: 3rem; flex-wrap: wrap;
}
.cities__link {
    text-decoration: none; text-align: center;
    padding: 0.5rem 0; transition: color 0.15s;
}
.cities__link:hover .cities__name { color: var(--action-secondary); }
.cities__name {
    font-family: 'DM Serif Display', Georgia, serif;
    font-size: 1.25rem; color: var(--black);
    transition: color 0.15s; display: block;
}
.cities__count {
    font-size: 0.58rem; font-weight: 400;
    letter-spacing: 0.06em; color: var(--patina);
    display: block; margin-top: 0.2rem;
}

/* --- 8. Origin line --- */
.origin {
    padding: 5rem 0;
    text-align: center;
    background: var(--linen);
    border-top: 1px solid var(--linen-deep);
}
.origin__text {
    font-size: 0.875rem;
    font-weight: 300;
    color: var(--patina);
    max-width: 480px;
    margin: 0 auto;
    line-height: 1.85;
}

/* --- 9. CTAs --- */
.hp-cta {
    padding: 4rem 0;
    background: var(--white);
    border-top: 1px solid var(--rule);
}
.hp-cta__grid {
    display: grid; grid-template-columns: 1fr 1fr;
    max-width: 600px; margin: 0 auto;
}
.hp-cta__cell {
    padding: 2.5rem 2rem; text-align: center;
}
.hp-cta__cell + .hp-cta__cell {
    border-left: 1px solid var(--rule);
}
.hp-cta__cell h3 {
    font-size: 1rem; color: var(--black);
    margin-bottom: 0.4rem;
}
.hp-cta__cell p {
    font-size: 0.75rem; font-weight: 300;
    color: var(--patina); line-height: 1.65;
    margin-bottom: 1.5rem;
}
.hp-cta__btn {
    display: inline-block; padding: 0.55rem 1.5rem;
    border: 1px solid var(--black); border-radius: 2px;
    color: var(--black);
    font-family: 'Inter', sans-serif; font-size: 0.58rem;
    font-weight: 600; text-transform: uppercase;
    letter-spacing: 0.08em; text-decoration: none;
    transition: all 0.2s;
}
.hp-cta__btn:hover { background: var(--black); color: var(--white); }

/* --- 10. Animations --- */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: translateY(0); }
}

/* --- 11. Mobile overrides --- */
@media (max-width: 768px) {
    body.hp .hero { padding: 2rem 0 1rem; }
    body.hp .hero h1 { font-size: clamp(1.8rem, 7vw, 2.4rem); max-width: none; margin-bottom: 0.5rem; }
    .hero__sub { max-width: none; margin-bottom: 1.25rem; font-size: 0.8rem; }
    /* Form: centered grid, side-by-side selects with button below */
    .hero__form {
        display: grid;
        grid-template-columns: 1fr 1fr;
        gap: 0.6rem;
        max-width: 340px;
        margin: 0 auto 1.25rem;
    }
    .hero__field { text-align: center; }
    .hero__go {
        grid-column: 1 / -1;
        background: var(--black);
        color: var(--white);
        border: none;
        border-bottom: none;
        padding: 0.75rem 1.5rem;
        font-size: 0.7rem;
        min-height: 44px;
        text-align: center;
    }
    .hero__go:hover { background: var(--charcoal); color: var(--white); }
    .hero__field select { min-height: 44px; font-size: 16px; }
    /* Hero card: compact on mobile */
    .hp-card__z1 { padding: 1.25rem 1.25rem 1rem; gap: 0.85rem; }
    .hp-card__name { font-size: 1.1rem; }
    .hp-card__meta { font-size: 0.7rem; }
    .hp-card__tags { gap: 0.5rem; }
    .hp-card__tag { font-size: 0.7rem; }
    .hp-card__enrollment { font-size: 0.7rem; }
    .hp-card__z2 { padding: 0.85rem 1.25rem; }
    .hp-card__z2-title { font-size: 0.6rem; margin-bottom: 0.5rem; }
    .hp-card__insights { grid-template-columns: 1fr; gap: 0.3rem; }
    .hp-card__insight { font-size: 0.75rem; line-height: 1.4; }
    .hp-card__z3 { display: none; }
    /* Tools section */
    .tools { padding: 3rem 0; }
    .tools__header { margin-bottom: 1.75rem; }
    .tools__grid { grid-template-columns: 1fr; max-width: none; gap: 0.75rem; }
    .tools__item { padding: 1.5rem 1.25rem; text-align: left; }
    .tools__item-link { opacity: 1; transform: translateY(0); }
    /* Cities */
    .cities-section { padding: 3rem 0; }
    .cities__row { gap: 1.25rem 2rem; }
    .cities__name { font-size: 1rem; }
    /* Origin, CTAs */
    .origin { padding: 3rem 0; }
    .hp-cta { padding: 2.5rem 0; }
    .hp-cta__grid { grid-template-columns: 1fr; }
    .hp-cta__cell { padding: 1.75rem 1.5rem; }
    .hp-cta__cell + .hp-cta__cell { border-left: none; border-top: 1px solid var(--rule); }
    /* Fact line */
    .fact { padding: 1.25rem 0 1.5rem; }
    .fact__text { font-size: 0.7rem; line-height: 1.8; }
    .fact__sep { width: 16px; margin: 0 0.5rem; }
}
@media (max-width: 400px) {
    body.hp .hero { padding: 1.5rem 0 0.75rem; }
    .fact__sep { display: none; }
    .fact__text { display: flex; flex-direction: column; gap: 0.25rem; }
}
