/* Главная Маяка — единый навигационный вход.
   Отдельный файл: общий визуальный каркас остальных страниц не меняется. */

.home-page {
    --home-card: rgba(255, 255, 255, 0.64);
    --home-card-strong: rgba(255, 255, 255, 0.80);
    --home-gold-border: rgba(200, 148, 50, 0.25);
}

.home-page {
    padding-top: 26px;
}

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

.home-brand-hero__content {
    max-width: 820px;
}

.home-brand-hero h1 {
    max-width: 790px;
    font-size: clamp(2.4rem, 8.6vw, 4.65rem);
    line-height: 1.015;
    letter-spacing: -0.058em;
}

.home-brand-hero__intro {
    max-width: 650px;
    margin: 26px 0 0;
    color: var(--muted);
    font-size: clamp(1.04rem, 3.8vw, 1.22rem);
    line-height: 1.58;
}

.home-brand-hero__actions {
    margin-top: 22px;
}

.home-brand-hero__actions .button--primary {
    min-width: min(100%, 310px);
    padding-inline: 24px;
}

.home-brand-hero__motto {
    display: flex;
    flex-wrap: wrap;
    gap: 0 0.3em;
    margin: 20px 0 0;
    color: #6f7b82;
    font-size: clamp(0.80rem, 3vw, 0.94rem);
    font-weight: 680;
    letter-spacing: -0.018em;
}

.home-brand-hero__motto span {
    white-space: nowrap;
}

.home-sections,
.home-popular,
.home-tools,
.home-source {
    margin-top: 72px;
    padding-top: 52px;
    border-top: 1px solid var(--border);
}

.home-page > .home-sections {
    margin-top: 36px;
    padding-top: 34px;
}

.home-section-heading {
    max-width: 760px;
}

.home-section-heading h2,
.home-source h2,
.home-final h2,
.home-method h2 {
    margin: 0;
    color: var(--text);
    font-size: clamp(2rem, 7vw, 3.55rem);
    line-height: 1.04;
    letter-spacing: -0.048em;
    text-wrap: balance;
}

.home-section-heading > p:last-child,
.home-source__copy > p,
.home-final p,
.home-method__heading > p:last-child {
    margin: 18px 0 0;
    max-width: 680px;
    color: var(--muted);
    font-size: 1rem;
    line-height: 1.62;
}

.home-sections__grid {
    display: grid;
    gap: 12px;
    margin-top: 32px;
}

.home-section-card {
    position: relative;
    display: flex;
    min-height: 178px;
    flex-direction: column;
    overflow: hidden;
    padding: 22px;
    border: 1px solid var(--home-gold-border);
    border-radius: 22px;
    background:
        radial-gradient(circle at 92% 8%, rgba(200, 148, 50, 0.10), transparent 8rem),
        linear-gradient(145deg, var(--home-card-strong), var(--home-card));
    color: var(--text);
    text-decoration: none;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
    transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.home-section-card:hover,
.home-section-card:focus-visible,
.home-question-card:hover,
.home-question-card:focus-visible,
.home-tool-card:hover,
.home-tool-card:focus-visible {
    transform: translateY(-2px);
    border-color: rgba(200, 148, 50, 0.48);
}

.home-section-card__number {
    color: var(--accent);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.12em;
}

.home-section-card h3 {
    margin: 18px 0 8px;
    max-width: 92%;
    font-size: 1.25rem;
    line-height: 1.22;
    letter-spacing: -0.035em;
}

.home-section-card p {
    margin: 0 0 22px;
    max-width: 94%;
    color: var(--muted);
    font-size: 0.92rem;
    line-height: 1.5;
}

.home-section-card__action {
    display: inline-flex;
    gap: 10px;
    align-items: center;
    margin-top: auto;
    color: #8b5c08;
    font-size: 0.86rem;
    font-weight: 760;
}

.home-popular__grid {
    display: grid;
    gap: 12px;
    margin-top: 32px;
}

.home-question-card {
    position: relative;
    display: grid;
    min-height: 132px;
    grid-template-columns: minmax(0, 1fr) 42px;
    grid-template-rows: auto auto;
    column-gap: 16px;
    align-items: center;
    padding: 20px;
    border: 1px solid var(--home-gold-border);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.62);
    color: var(--text);
    text-decoration: none;
    transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.home-question-card h3 {
    margin: 0;
    font-size: 1.04rem;
    line-height: 1.28;
    letter-spacing: -0.025em;
}

.home-question-card p {
    margin: 7px 0 0;
    color: var(--muted);
    font-size: 0.88rem;
    line-height: 1.45;
}

.home-question-card > span {
    display: grid;
    width: 42px;
    height: 42px;
    grid-row: 1 / 3;
    grid-column: 2;
    place-items: center;
    border: 1px solid rgba(200, 148, 50, 0.32);
    border-radius: 50%;
    color: #9a6507;
    font-size: 1.2rem;
}

.home-text-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-top: 24px;
    color: var(--text);
    font-size: 0.94rem;
    font-weight: 780;
    text-decoration-color: rgba(200, 148, 50, 0.50);
    text-underline-offset: 6px;
}

.home-method {
    position: relative;
    overflow: hidden;
    margin-top: 82px;
    padding: 30px 22px 22px;
    border: 1px solid rgba(255, 255, 255, 0.10);
    border-radius: 28px;
    background:
        radial-gradient(circle at 92% 6%, rgba(200, 148, 50, 0.18), transparent 20rem),
        linear-gradient(145deg, var(--night-soft), var(--night));
    box-shadow: 0 28px 70px rgba(16, 32, 42, 0.14);
}

.home-method::after {
    content: "";
    position: absolute;
    top: -150px;
    right: -145px;
    width: 300px;
    height: 300px;
    border: 1px solid rgba(231, 199, 123, 0.10);
    border-radius: 50%;
    box-shadow: 0 0 0 48px rgba(231, 199, 123, 0.024), 0 0 0 96px rgba(231, 199, 123, 0.014);
    pointer-events: none;
}

.home-method__heading,
.home-method__grid {
    position: relative;
    z-index: 1;
}

.home-method h2 {
    max-width: 760px;
    color: #fffdf7;
}

.home-method__heading > p:last-child {
    color: rgba(244, 241, 232, 0.72);
}

.home-method__grid {
    display: grid;
    gap: 10px;
    margin-top: 30px;
}

.home-method__item {
    padding: 20px;
    border: 1px solid rgba(231, 199, 123, 0.20);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.045);
}

.home-method__item::before {
    content: "";
    display: block;
    width: 36px;
    height: 3px;
    margin-bottom: 18px;
    border-radius: 999px;
    background: var(--accent-soft);
}

.home-method__item h3 {
    margin: 0 0 8px;
    color: #fffdf7;
    font-size: 1.08rem;
    line-height: 1.28;
}

.home-method__item p {
    margin: 0;
    color: rgba(244, 241, 232, 0.68);
    font-size: 0.91rem;
    line-height: 1.55;
}

.home-tools__grid {
    display: grid;
    gap: 12px;
    margin-top: 32px;
}

.home-tool-card {
    position: relative;
    min-height: 154px;
    padding: 20px 54px 20px 20px;
    border: 1px solid var(--home-gold-border);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.62);
    color: var(--text);
    text-decoration: none;
    transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.home-tool-card > span {
    color: var(--accent);
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.10em;
    text-transform: uppercase;
}

.home-tool-card h3 {
    margin: 14px 0 7px;
    font-size: 1.14rem;
    line-height: 1.25;
    letter-spacing: -0.028em;
}

.home-tool-card p {
    margin: 0;
    color: var(--muted);
    font-size: 0.89rem;
    line-height: 1.48;
}

.home-tool-card > b {
    position: absolute;
    top: 50%;
    right: 20px;
    color: #9a6507;
    font-size: 1.2rem;
    transform: translateY(-50%);
}

.home-source {
    border-top: 0;
    padding-top: 0;
}

.home-source__copy {
    padding: 26px 24px;
    border: 1px solid var(--home-gold-border);
    border-radius: 26px;
    background:
        linear-gradient(135deg, rgba(255, 252, 244, 0.88), rgba(241, 229, 200, 0.56));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.75);
}

.home-source__signals {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 22px;
}

.home-source__signals span {
    padding: 7px 10px;
    border: 1px solid rgba(200, 148, 50, 0.22);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.50);
    color: #6f5b35;
    font-size: 0.76rem;
    font-weight: 680;
}

.home-final {
    display: grid;
    gap: 24px;
    margin-top: 72px;
    padding: 28px 24px;
    border-radius: 28px;
    background: var(--night);
    color: #fffdf7;
    box-shadow: 0 24px 62px rgba(16, 32, 42, 0.13);
}

.home-final h2 {
    color: #fffdf7;
    font-size: clamp(1.8rem, 6.6vw, 3rem);
}

.home-final p {
    color: rgba(244, 241, 232, 0.70);
}

.home-final__button {
    width: fit-content;
    border: 1px solid rgba(231, 199, 123, 0.34);
    background: var(--accent);
    color: #17252d;
    box-shadow: none;
}

.home-final__button:hover {
    background: var(--accent-soft);
    transform: translateY(-2px);
}

@media (max-width: 759px) {
    .home-brand-hero {
        padding: 4px 0 6px;
    }

    .home-brand-hero h1 {
        font-size: clamp(2.28rem, 10.1vw, 3rem);
        line-height: 1.025;
        text-wrap: pretty;
    }

    .home-brand-hero__intro {
        margin-top: 22px;
        font-size: clamp(1rem, 4vw, 1.1rem);
    }

    .home-brand-hero__actions {
        margin-top: 26px;
    }

    .home-brand-hero__actions .button--primary {
        width: auto;
        min-width: min(100%, 286px);
    }

    .home-brand-hero__motto {
        width: max-content;
        max-width: 100%;
        flex-wrap: nowrap;
        margin-top: 22px;
        font-size: clamp(0.72rem, 3.15vw, 0.86rem);
        white-space: nowrap;
    }

    .home-sections,
    .home-popular,
    .home-tools {
        margin-top: 52px;
        padding-top: 40px;
    }

    .home-source {
        margin-top: 52px;
    }

    .home-method {
        margin-top: 58px;
        padding: 26px 20px 20px;
    }

    .home-final {
        margin-top: 52px;
        padding: 24px 20px;
    }
}

@media (min-width: 760px) {
    .home-brand-hero {
        max-width: 900px;
        padding: 12px 0 22px;
    }

    .home-sections,
    .home-popular,
    .home-tools {
        margin-top: 88px;
        padding-top: 62px;
    }

    .home-sections__grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 14px;
        margin-top: 40px;
    }

    .home-section-card {
        min-height: 210px;
        padding: 24px;
    }

    .home-popular__grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 14px;
        margin-top: 40px;
    }

    .home-method {
        margin-top: 96px;
        padding: 44px;
    }

    .home-method__grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 12px;
        margin-top: 38px;
    }

    .home-method__item {
        min-height: 190px;
        padding: 22px;
    }

    .home-tools__grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 14px;
        margin-top: 40px;
    }

    .home-source {
        margin-top: 88px;
    }

    .home-source__copy {
        padding: 38px 40px;
    }

    .home-final {
        grid-template-columns: minmax(0, 1fr) auto;
        align-items: end;
        gap: 44px;
        margin-top: 88px;
        padding: 38px 40px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .home-section-card,
    .home-question-card,
    .home-tool-card,
    .home-final__button {
        transition: none;
    }

    .home-section-card:hover,
    .home-section-card:focus-visible,
    .home-question-card:hover,
    .home-question-card:focus-visible,
    .home-tool-card:hover,
    .home-tool-card:focus-visible,
    .home-final__button:hover {
        transform: none;
    }
}

@media (max-width: 759px) {
    .home-page {
        padding-top: 22px;
    }

    .home-brand-hero h1 {
        margin-top: 0;
    }

    .home-brand-hero__intro {
        margin-top: 22px;
    }

    .home-page > .home-sections {
        margin-top: 30px;
        padding-top: 30px;
    }
}

/* HOME CLEAN COPY R1 FIXED */
.home-page .home-section-card {
    min-height: 128px;
}

.home-page .home-question-card {
    min-height: 0;
}

.home-page .home-tool-card {
    min-height: 112px;
}

.home-page .home-method__item {
    min-height: 0;
}

.home-page .home-source__lead {
    margin: 14px 0 22px;
    max-width: 680px;
    color: var(--muted);
    font-size: 1rem;
    line-height: 1.5;
}

@media (max-width: 759px) {
    .home-page .home-section-card {
        min-height: 112px;
    }

    .home-page .home-tool-card {
        min-height: 96px;
    }
}

/* HOME CARD UNIFORMITY R1 */
.home-page .home-sections__grid,
.home-page .home-popular__grid,
.home-page .home-tools__grid,
.home-page .home-method__grid {
    align-items: stretch;
}

.home-page .home-section-card,
.home-page .home-question-card,
.home-page .home-tool-card,
.home-page .home-method__item {
    min-height: 124px;
    padding: 20px;
    border-radius: 20px;
}

.home-page .home-section-card h3,
.home-page .home-question-card h3,
.home-page .home-tool-card h3,
.home-page .home-method__item h3 {
    margin: 0;
}

.home-page .home-section-card {
    justify-content: space-between;
}

.home-page .home-section-card__action {
    margin-top: 18px;
}

.home-page .home-question-card {
    min-height: 124px;
    grid-template-columns: minmax(0, 1fr) 40px;
    grid-template-rows: 1fr;
    align-items: start;
    padding-right: 18px;
}

.home-page .home-question-card > span {
    width: 40px;
    height: 40px;
    grid-row: 1;
    align-self: end;
}

.home-page .home-method__item::before {
    width: 30px;
    margin-bottom: 16px;
}

.home-page .home-tool-card {
    min-height: 124px;
    padding-right: 56px;
}

.home-page .home-tool-card > b {
    top: auto;
    right: 18px;
    bottom: 18px;
    transform: none;
}

@media (min-width: 760px) {
    .home-page .home-section-card,
    .home-page .home-question-card,
    .home-page .home-tool-card,
    .home-page .home-method__item {
        min-height: 146px;
        padding: 22px;
    }

    .home-page .home-question-card {
        grid-template-columns: minmax(0, 1fr) 42px;
        padding-right: 20px;
    }

    .home-page .home-question-card > span {
        width: 42px;
        height: 42px;
    }

    .home-page .home-tool-card {
        padding-right: 58px;
    }

    .home-page .home-tool-card > b {
        right: 20px;
        bottom: 20px;
    }
}


/* HOME CARD COMPACT R2
   Mobile-first correction after visual review:
   compact cards, consistent inner rhythm, aligned arrows. */

.home-page .home-section-card {
    box-sizing: border-box;
    min-height: 108px;
    height: 108px;
    justify-content: center;
    gap: 10px;
    padding: 16px 18px;
}

.home-page .home-section-card h3 {
    margin: 0;
    line-height: 1.18;
}

.home-page .home-section-card__action {
    margin-top: 0;
}

.home-page .home-question-card {
    box-sizing: border-box;
    min-height: 96px;
    height: 96px;
    grid-template-columns: minmax(0, 1fr) 40px;
    grid-template-rows: 1fr;
    align-items: center;
    column-gap: 14px;
    padding: 16px 18px;
}

.home-page .home-question-card h3 {
    margin: 0;
    align-self: center;
}

.home-page .home-question-card > span {
    width: 40px;
    height: 40px;
    grid-column: 2;
    grid-row: 1;
    align-self: center;
    justify-self: end;
}

.home-page .home-tool-card {
    box-sizing: border-box;
    display: grid;
    min-height: 96px;
    height: 96px;
    grid-template-columns: minmax(0, 1fr) 40px;
    align-items: center;
    column-gap: 14px;
    padding: 16px 18px;
}

.home-page .home-tool-card h3 {
    margin: 0;
    align-self: center;
}

.home-page .home-tool-card > b {
    position: static;
    display: grid;
    width: 40px;
    height: 40px;
    place-items: center;
    justify-self: end;
    border: 1px solid rgba(200, 148, 50, 0.32);
    border-radius: 50%;
    color: #9a6507;
    font-size: 1.2rem;
    transform: none;
}

.home-page .home-method__item {
    box-sizing: border-box;
    min-height: 96px;
    height: 96px;
    padding: 16px 18px;
}

.home-page .home-method__item::before {
    width: 28px;
    margin-bottom: 13px;
}

.home-page .home-method__item h3 {
    margin: 0;
}

.home-page > .home-source {
    margin-bottom: 52px;
}

@media (min-width: 760px) {
    .home-page .home-section-card {
        min-height: 126px;
        height: 126px;
        padding: 20px 22px;
    }

    .home-page .home-question-card,
    .home-page .home-tool-card,
    .home-page .home-method__item {
        min-height: 116px;
        height: 116px;
        padding: 20px 22px;
    }

    .home-page .home-question-card,
    .home-page .home-tool-card {
        grid-template-columns: minmax(0, 1fr) 42px;
        column-gap: 16px;
    }

    .home-page .home-question-card > span,
    .home-page .home-tool-card > b {
        width: 42px;
        height: 42px;
    }

    .home-page > .home-source {
        margin-bottom: 72px;
    }
}


/* HOME CARD COMPACT R3
   Final mobile polish: tighter section cards + restored meaningful method block. */

.home-page .home-section-card {
    min-height: 88px;
    height: auto;
    gap: 6px;
    padding: 13px 16px;
}

.home-page .home-section-card h3 {
    line-height: 1.16;
}

.home-page .home-section-card__action {
    margin-top: 3px;
    font-size: 0.82rem;
}

.home-page .home-method__item {
    min-height: 0;
    height: auto;
    padding: 17px 18px;
}

.home-page .home-method__item::before {
    display: none;
}

.home-page .home-method__item h3 {
    margin: 0;
    line-height: 1.22;
}

.home-page .home-method__item p {
    margin: 8px 0 0;
    color: rgba(244, 241, 232, 0.70);
    font-size: 0.89rem;
    line-height: 1.45;
}

@media (min-width: 760px) {
    .home-page .home-section-card {
        min-height: 104px;
        height: auto;
        padding: 17px 20px;
    }

    .home-page .home-method__item {
        min-height: 138px;
        height: auto;
        padding: 20px 22px;
    }
}
