:root {
    --paper: #f7f3ec;
    --paper-deep: #f1ece3;
    --sage: #f0f2e9;
    --ink: #181511;
    --muted: #66615c;
    --accent: #8b683d;
    --accent-dark: #765631;
    --line: rgba(24, 21, 17, 0.15);
    --line-strong: rgba(24, 21, 17, 0.26);
    --display: "Newsreader", Georgia, serif;
    --body: "Manrope", "Segoe UI", sans-serif;
    --page-padding: clamp(24px, 4.4vw, 66px);
    --content-max: 1312px;
    --header-height: 86px;
}

* {
    box-sizing: border-box;
}

html {
    min-width: 320px;
    color-scheme: light;
    background: var(--paper);
    scroll-behavior: smooth;
}

body {
    min-height: 100dvh;
    margin: 0;
    color: var(--ink);
    font-family: var(--body);
    font-size: 16px;
    line-height: 1.6;
    background: var(--paper);
    -webkit-font-smoothing: antialiased;
}

button,
a {
    font: inherit;
}

a {
    color: inherit;
    text-decoration: none;
}

button {
    color: inherit;
}

img {
    display: block;
}

.skip-link {
    position: fixed;
    z-index: 20;
    top: 12px;
    left: 12px;
    padding: 10px 14px;
    color: white;
    background: var(--ink);
    border-radius: 6px;
    transform: translateY(-150%);
}

.skip-link:focus {
    transform: translateY(0);
}

:focus-visible {
    outline: 3px solid #b68343;
    outline-offset: 4px;
}

.site-header {
    width: min(calc(100% - (2 * var(--page-padding))), var(--content-max));
    min-height: var(--header-height);
    margin: 0 auto;
    display: grid;
    grid-template-columns: minmax(230px, 1fr) auto auto;
    align-items: center;
    gap: 68px;
    border-bottom: 1px solid var(--line);
}

.brand {
    width: max-content;
    font-family: var(--display);
    font-size: clamp(1.8rem, 2.5vw, 2.25rem);
    font-weight: 600;
    line-height: 1;
    letter-spacing: -0.045em;
}

.desktop-nav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: clamp(28px, 3.6vw, 52px);
}

.desktop-nav a,
.mobile-nav a {
    position: relative;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    color: var(--muted);
    font-size: 1.02rem;
}

.desktop-nav a::after,
.mobile-nav a::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 5px;
    height: 2px;
    background: var(--accent);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 160ms ease;
}

.desktop-nav a:hover::after,
.desktop-nav a[aria-current="page"]::after,
.mobile-nav a:hover::after,
.mobile-nav a[aria-current="page"]::after {
    transform: scaleX(1);
}

.desktop-nav a[aria-current="page"],
.mobile-nav a[aria-current="page"] {
    color: var(--ink);
}

.header-action,
.button-link {
    min-height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 23px;
    color: #fffdf9;
    background: var(--accent);
    border-radius: 7px;
    font-weight: 600;
    transition: background 160ms ease, transform 160ms ease;
}

.header-action {
    justify-self: end;
}

.header-action:hover,
.button-link:hover {
    background: var(--accent-dark);
    transform: translateY(-1px);
}

.menu-button,
.mobile-nav {
    display: none;
}

#main-content:focus {
    outline: none;
}

.home-grid {
    width: min(100%, 1440px);
    min-height: calc(100dvh - var(--header-height));
    margin: 0 auto;
    padding-left: max(var(--page-padding), calc((100vw - var(--content-max)) / 2));
    display: grid;
    grid-template-columns: minmax(0, calc(100% - 477px)) 477px;
}

.home-main {
    min-width: 0;
    padding: 32px clamp(38px, 4vw, 50px) 32px 0;
    display: flex;
    flex-direction: column;
}

.kicker,
.aside-kicker {
    margin: 0;
    color: var(--accent);
    font-weight: 500;
}

.home-intro h1,
.content-hero h1,
.article-hero h1 {
    margin: 18px 0 0;
    font-family: var(--display);
    font-weight: 500;
    letter-spacing: -0.045em;
}

.home-intro h1 {
    max-width: 18ch;
    font-size: clamp(2.8rem, 3.15vw, 3.25rem);
    line-height: 0.97;
    font-weight: 600;
}

.needs {
    margin-top: 34px;
    padding-top: 28px;
    border-top: 1px solid var(--line);
}

.needs > h2,
.index-section > h2 {
    margin: 0;
    color: var(--accent);
    font-family: var(--display);
    font-size: clamp(1.5rem, 2vw, 1.85rem);
    font-weight: 500;
    letter-spacing: -0.025em;
}

.need-list {
    margin-top: 10px;
}

.need-row {
    min-height: 128px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--line);
}

.need-row > span {
    min-width: 0;
    display: grid;
    gap: 3px;
}

.need-row strong {
    font-family: var(--display);
    font-size: clamp(2rem, 2.9vw, 2.65rem);
    font-weight: 600;
    line-height: 1.03;
    letter-spacing: -0.04em;
}

.need-row small {
    color: var(--muted);
    font-size: 0.98rem;
}

.arrow-icon {
    flex: 0 0 auto;
    width: 30px;
    height: 30px;
    transition: transform 160ms ease;
}

.need-row:hover .arrow-icon,
.compact-guide:hover .arrow-icon,
.text-action:hover .arrow-icon,
.guide-list-row:hover .arrow-icon {
    transform: translateX(5px);
}

.home-note {
    margin: auto 0 0;
    padding-top: 30px;
    color: var(--muted);
    font-size: 0.98rem;
}

.home-aside {
    min-width: 0;
    margin-top: 42px;
    padding: 48px clamp(30px, 4vw, 66px) 38px 44px;
    background: var(--sage);
    border-radius: 30px 0 0;
}

.start-guide {
    padding-bottom: 32px;
    border-bottom: 1px solid var(--line);
}

.aside-kicker {
    padding-bottom: 12px;
    border-bottom: 1px solid var(--line);
    font-family: var(--display);
    font-size: 1.45rem;
}

.start-guide h2 {
    margin: 26px 0 0;
    font-family: var(--display);
    font-size: clamp(2.15rem, 2.6vw, 2.35rem);
    font-weight: 600;
    line-height: 1.02;
    letter-spacing: -0.045em;
}

.start-guide > p:not(.aside-kicker) {
    max-width: 315px;
    margin: 18px 0 0;
    color: var(--muted);
    font-size: 1.02rem;
    line-height: 1.5;
}

.text-action {
    width: max-content;
    min-height: 48px;
    margin-top: 14px;
    display: inline-flex;
    align-items: center;
    gap: 12px;
    font-weight: 600;
}

.text-action span {
    border-bottom: 2px solid var(--accent);
}

.arrow-icon--inline {
    width: 24px;
    height: 24px;
}

.popular-guides {
    margin-top: 15px;
}

.popular-guides > h2 {
    margin: 0;
    padding-bottom: 10px;
    color: var(--accent);
    border-bottom: 1px solid var(--line);
    font-family: var(--display);
    font-size: 1.35rem;
    font-weight: 500;
}

.compact-guide {
    min-height: 78px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    border-bottom: 1px solid var(--line);
    font-size: 0.95rem;
    line-height: 1.4;
}

.arrow-icon--small {
    width: 22px;
    height: 22px;
}

.content-page,
.article-page {
    width: min(calc(100% - (2 * var(--page-padding))), 1100px);
    margin: 0 auto;
    padding: clamp(56px, 8vw, 96px) 0 80px;
}

.content-hero,
.article-hero {
    max-width: 850px;
}

.content-hero h1,
.article-hero h1 {
    font-size: clamp(3.2rem, 7vw, 6.2rem);
    line-height: 0.93;
}

.content-hero > p:last-child,
.article-hero > p:last-child {
    max-width: 62ch;
    margin: 28px 0 0;
    color: var(--muted);
    font-size: clamp(1.05rem, 1.6vw, 1.22rem);
    line-height: 1.75;
}

.index-section,
.section-stack,
.article-body {
    margin-top: 68px;
    padding-top: 32px;
    border-top: 1px solid var(--line-strong);
}

.large-link-list {
    margin-top: 8px;
}

.large-link-list .need-row {
    min-height: 134px;
}

.guide-list {
    margin-top: 12px;
}

.guide-list-row {
    min-height: 150px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 34px;
    border-bottom: 1px solid var(--line);
}

.guide-list-copy {
    max-width: 820px;
    display: grid;
    gap: 8px;
}

.guide-list-copy small {
    color: var(--accent);
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.guide-list-copy strong {
    font-family: var(--display);
    font-size: clamp(1.8rem, 3vw, 2.5rem);
    font-weight: 500;
    line-height: 1.05;
    letter-spacing: -0.035em;
}

.guide-list-copy > span {
    color: var(--muted);
}

.section-stack,
.article-body {
    max-width: 760px;
    display: grid;
    gap: 42px;
}

.section-stack section,
.article-body section {
    padding-bottom: 36px;
    border-bottom: 1px solid var(--line);
}

.section-stack h2,
.article-body h2,
.content-cta h2 {
    margin: 0;
    font-family: var(--display);
    font-size: clamp(2rem, 3vw, 2.7rem);
    font-weight: 500;
    line-height: 1.05;
    letter-spacing: -0.035em;
}

.section-stack p,
.article-body p,
.content-cta p {
    margin: 15px 0 0;
    color: var(--muted);
    font-size: 1.05rem;
    line-height: 1.8;
}

.back-link {
    width: max-content;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    margin-bottom: 30px;
    color: var(--muted);
    text-decoration: underline;
    text-underline-offset: 0.25em;
}

.care-note {
    padding: 28px 30px 32px;
    background: var(--sage);
    border-radius: 8px;
}

.care-note h2 {
    font-size: 1.8rem;
}

.content-cta {
    margin-top: 72px;
    padding: 34px 38px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 34px;
    background: var(--sage);
    border-radius: 8px;
}

.content-cta h2 {
    font-size: 2rem;
}

.content-cta p {
    max-width: 52ch;
    font-size: 0.98rem;
}

.site-footer {
    width: min(calc(100% - (2 * var(--page-padding))), var(--content-max));
    min-height: 94px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 22px;
    color: var(--muted);
    border-top: 1px solid var(--line);
    font-size: 0.88rem;
}

.site-footer a {
    text-decoration: underline;
    text-underline-offset: 0.22em;
}

.error-page .button-link {
    margin-top: 38px;
}

.no-script {
    padding: 48px;
}

@media (max-width: 1100px) {
    .site-header {
        grid-template-columns: 1fr auto auto;
        gap: 24px;
    }

    .desktop-nav {
        gap: 24px;
    }

    .home-grid {
        grid-template-columns: minmax(0, 1.5fr) minmax(350px, 1fr);
    }

    .need-row {
        min-height: 118px;
    }
}

@media (max-width: 820px) {
    :root {
        --page-padding: 20px;
        --header-height: 72px;
    }

    .site-header {
        grid-template-columns: 1fr auto;
        min-height: var(--header-height);
    }

    .brand {
        font-size: 1.7rem;
    }

    .desktop-nav,
    .header-action {
        display: none;
    }

    .menu-button {
        min-width: 72px;
        min-height: 44px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        padding: 0 16px;
        border: 1px solid var(--line-strong);
        border-radius: 7px;
        background: transparent;
        font-weight: 600;
        cursor: pointer;
    }

    .mobile-nav {
        width: calc(100% - (2 * var(--page-padding)));
        margin: 0 auto;
        padding: 10px 0 18px;
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 4px 20px;
        border-bottom: 1px solid var(--line);
    }

    .mobile-nav[hidden] {
        display: none;
    }

    .home-grid {
        width: 100%;
        min-height: auto;
        padding-left: 0;
        display: block;
    }

    .home-main {
        padding: 30px var(--page-padding) 34px;
    }

    .home-intro h1 {
        max-width: none;
        font-size: clamp(2.55rem, 12vw, 4.15rem);
    }

    .home-intro h1 br {
        display: none;
    }

    .needs {
        margin-top: 34px;
        padding-top: 24px;
    }

    .need-row,
    .large-link-list .need-row {
        min-height: 114px;
        padding-bottom: 8px;
    }

    .need-row strong {
        font-size: clamp(1.75rem, 8vw, 2.25rem);
    }

    .need-row small {
        font-size: 0.93rem;
        line-height: 1.5;
    }

    .arrow-icon {
        width: 27px;
        height: 27px;
    }

    .home-note {
        margin-top: 32px;
    }

    .home-aside {
        margin-top: 0;
        padding: 36px var(--page-padding) 42px;
        border-radius: 24px 24px 0 0;
    }

    .content-page,
    .article-page {
        width: calc(100% - (2 * var(--page-padding)));
        padding: 52px 0 64px;
    }

    .content-hero h1,
    .article-hero h1 {
        font-size: clamp(2.9rem, 13vw, 4.7rem);
    }

    .index-section,
    .section-stack,
    .article-body {
        margin-top: 48px;
        padding-top: 26px;
    }

    .guide-list-row {
        min-height: 142px;
        gap: 20px;
    }

    .guide-list-copy strong {
        font-size: 1.8rem;
    }

    .content-cta {
        margin-top: 54px;
        padding: 28px;
        flex-direction: column;
        align-items: flex-start;
    }

    .site-footer {
        min-height: 0;
        padding: 28px 0 34px;
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (max-width: 430px) {
    .home-intro h1 {
        font-size: clamp(2.45rem, 11.8vw, 3.15rem);
    }

    .needs > h2 {
        font-size: 1.45rem;
    }

    .need-row {
        gap: 14px;
    }

    .need-row strong {
        font-size: 1.78rem;
    }

    .home-aside {
        padding-top: 32px;
    }

    .start-guide h2 {
        font-size: 2.25rem;
    }

    .guide-list-row {
        align-items: flex-start;
        padding: 24px 0;
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        transition: none !important;
    }
}
