/**
 * Главная — the routing hero.
 *
 * Replaces nothing: it sits above the existing promo tiles, so the videocourse
 * keeps its place and the page gains the thing it never had — a first screen
 * that tells a visitor what this is and sends them somewhere.
 *
 * Colours come from the theme's own custom properties, which header.php
 * overwrites from the module options, so changing the site's palette in the
 * admin changes this too.
 *
 * @see /ROADMAP.md  "The homepage"
 */

.home-hero {
    padding: 48px 0 8px;
}

.home-hero__title {
    font-size: calc(44px * var(--base-font-size));
    line-height: 1.1;
    font-weight: 900;
    color: #000;
    margin-bottom: 16px;
}

.home-hero__lead {
    font-size: calc(19px * var(--base-font-size));
    line-height: 1.5;
    color: #555;
    max-width: 44em;
    margin-bottom: 32px;
}

/* auto-fit rather than three fixed columns: a fourth route can be added
   without touching the CSS, and one route still fills the row sensibly. */
.home-hero__routes {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 16px;
}

.home-hero__route {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 22px;
    background: #fff;
    border: 1px solid #e3e3e3;
    border-radius: 12px;
    text-decoration: none;
    color: inherit;
    transition: border-color .15s ease, transform .15s ease, box-shadow .15s ease;
}

.home-hero__route:hover,
.home-hero__route:focus-visible {
    border-color: var(--color-gradient-second);
    box-shadow: 0 6px 20px rgba(0, 0, 0, .07);
    transform: translateY(-2px);
}

.home-hero__route-name {
    font-size: calc(20px * var(--base-font-size));
    font-weight: 700;
    color: #000;
}

/* Grows so the "go" line sits on the baseline across all three cards,
   whatever length the notes are. */
.home-hero__route-note {
    font-size: calc(15px * var(--base-font-size));
    line-height: 1.4;
    color: #777;
    flex-grow: 1;
}

.home-hero__route-go {
    font-size: calc(15px * var(--base-font-size));
    font-weight: 600;
    color: var(--color-gradient-first);
}

.home-hero__secondary {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    margin-top: 24px;
}

.home-hero__secondary a {
    color: var(--color-gradient-first);
    text-decoration: none;
    border-bottom: 1px solid rgba(0, 0, 0, .15);
}

.home-hero__secondary a:hover {
    border-bottom-color: var(--color-gradient-first);
}

@media (max-width: 767px) {
    .home-hero {
        padding: 28px 0 4px;
    }

    .home-hero__title {
        font-size: calc(30px * var(--base-font-size));
    }

    .home-hero__lead {
        font-size: calc(17px * var(--base-font-size));
        margin-bottom: 24px;
    }

    .home-hero__route {
        padding: 18px;
    }
}
