/* Edit these variables to change the site's palette. No external fonts or images required. */
:root {
    --ink: #19383b;
    --paper: #f5f2eb;
    --muted: #586562;
    --gold: #e8bc78;
    --line: #d9ddd4;
    --serif: Georgia,'Times New Roman',serif;
    --sans: system-ui,-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 90px;
}

body {
    margin: 0;
    background: var(--paper);
    color: var(--ink);
    font-family: var(--sans);
    line-height: 1.7;
}

a {
    color: inherit;
    text-underline-offset: 5px;
}

button {
    font: inherit;
}

a,
button {
    -webkit-tap-highlight-color: transparent;
}

a:focus-visible,
button:focus-visible {
    outline: 3px solid #ba7429;
    outline-offset: 6px;
}

h1,
h2,
h3,
p {
    margin-top: 0;
}

h1,
h2,
h3 {
    font-family: var(--serif);
    font-weight: 400;
    line-height: 1.1;
}

h2 {
    font-size: clamp(2.3rem,4.5vw,3.8rem);
    letter-spacing: -.04em;
    margin-bottom: 26px;
}

h2 em {
    font-weight: 400;
}

p {
    margin-bottom: 20px;
}

.container {
    width: min(1120px,calc(100% - 64px));
    margin-inline: auto;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0,0,0,0);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: fixed;
    top: 10px;
    left: 10px;
    transform: translateY(-160%);
    background: white;
    color: var(--ink);
    padding: 10px 20px;
    z-index: 99;
}

.skip-link:focus {
    transform: translateY(0);
}

/* Header and navigation */
.site-header {
    background: #102b30;
    color: #f5f2eb;
    border-bottom: 1px solid #ffffff1c;
    position: relative;
    z-index: 10;
}

.header-inner {
    min-height: 86px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.brand {
    font-family: var(--serif);
    font-size: 1.5rem;
    text-decoration: none;
    white-space: nowrap;
}

.brand-n {
    font-style: italic;
    color: var(--gold);
}

.brand-icon {
    color: var(--gold);
    font-size: 2rem;
    vertical-align: middle;
    margin-right: 8px;
}

nav {
    display: flex;
    gap: 32px;
}

nav a {
    font-size: .88rem;
    text-decoration: none;
    color: #e1e6e1;
}

nav a:hover,
nav a[aria-current="location"] {
    color: var(--gold);
}

.menu-toggle {
    background: none;
    border: 1px solid #ffffff60;
    color: white;
    border-radius: 4px;
    padding: 6px 12px;
}

.menu-toggle[hidden] {
    display: none;
}

/* Hero and mountain background */
.hero {
    min-height: 680px;
    background: radial-gradient(ellipse at 76% 20%,#466467 0,transparent 48%),linear-gradient(#163138,#24464b);
    color: #f7f4ed;
    position: relative;
    isolation: isolate;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.mountains {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    opacity: .85;
}

.stars {
    position: absolute;
    inset: 0;
    z-index: -1;
    opacity: .35;
    background-image: radial-gradient(1px 1px at 70% 12%,white 99%,transparent),radial-gradient(1px 1px at 84% 26%,white 99%,transparent),radial-gradient(1px 1px at 38% 9%,white 99%,transparent),radial-gradient(1px 1px at 92% 8%,white 99%,transparent);
}

.hero-content {
    padding-top: 65px;
    padding-bottom: 135px;
}

.eyebrow {
    text-transform: uppercase;
    letter-spacing: .19em;
    font-size: .71rem;
    font-weight: 650;
    margin-bottom: 24px;
}

.hero .eyebrow {
    color: var(--gold);
}

h1 {
    font-size: clamp(3.4rem,7.5vw,6.4rem);
    letter-spacing: -.055em;
    margin-bottom: 28px;
    max-width: 760px;
}

h1 em {
    color: #f0d3a5;
}

.hero-description {
    max-width: 480px;
    color: #e0e8e4;
    font-size: 1.02rem;
}

.actions {
    display: flex;
    align-items: center;
    gap: 28px;
    flex-wrap: wrap;
    margin-top: 32px;
}

/* Buttons and links */
.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
    padding: 14px 23px;
    border: 1px solid transparent;
    border-radius: 3px;
    text-decoration: none;
    font-size: .85rem;
    font-weight: 600;
    transition: transform .18s,background .18s;
}

.button:hover {
    transform: translateY(-3px);
}

.button-gold {
    background: var(--gold);
    color: #192e2e;
}

.text-link {
    font-size: .9rem;
    text-decoration: none;
}

.text-link span {
    margin-left: 10px;
}

.hero-foot {
    position: absolute;
    bottom: 27px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: space-between;
    gap: 16px;
    font-size: .72rem;
    color: #c5d2cc;
    letter-spacing: .04em;
}

.hero-foot a {
    text-decoration: none;
}

/* Book section */
.section {
    padding-block: 100px;
}

.book-grid {
    display: grid;
    grid-template-columns: 1fr 1.15fr;
    gap: 90px;
    align-items: center;
}

.book-stage {
    padding: 40px 20px 16px;
    text-align: center;
    background: radial-gradient(ellipse,#d7dbcf,transparent 70%);
}

.book-art {
    width: min(280px,100%);
    min-height: 405px;
    margin: 0 auto;
    padding: 33px 18px 25px;
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #edcf93;
    position: relative;
    background: linear-gradient(145deg,transparent 55%,#173f43 55%,#0c2329 79%),linear-gradient(25deg,#102a32,#2d5155);
    border: 1px solid #a48e5b;
    outline: 7px solid #15363c;
    box-shadow: 16px 22px 35px #18383b30;
    transform: rotate(-5deg);
}

.book-art:before {
    content: '';
    position: absolute;
    inset: 10px;
    border: 1px solid #c8ad6d60;
    pointer-events: none;
}

.cover-kicker {
    font-size: .5rem;
    letter-spacing: .2em;
    text-transform: uppercase;
    margin-bottom: 35px;
}

.cover-title {
    font-family: var(--serif);
    font-size: 2.6rem;
    line-height: 1.1;
    letter-spacing: .03em;
}

.cover-subtitle {
    font-family: var(--serif);
    font-style: italic;
    font-size: 1.15rem;
    margin-top: 15px;
}

.cover-symbol {
    font-size: 4.8rem;
    line-height: 1.6;
}

.cover-author {
    font-size: .7rem;
    letter-spacing: .22em;
    margin-top: auto;
}

.art-note {
    font-size: .66rem;
    color: var(--muted);
    margin: 36px 0 0;
}

.lead {
    font-size: 1.15rem;
    line-height: 1.6;
}

.book-copy>p:not(.eyebrow):not(.lead) {
    color: var(--muted);
}

.tags {
    padding: 0;
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 25px 0;
}

.tags li {
    border: 1px solid var(--line);
    border-radius: 50px;
    padding: 4px 12px;
    font-size: .7rem;
}

.purchase-options {
    display: flex;
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
}

.button-dark {
    background: var(--ink);
    color: white;
}

.button-outline {
    border-color: #a2b1a9;
}

.small-note {
    font-size: .75rem;
    margin-top: 16px;
    max-width: 390px;
}

/* Project cards */
.projects-section {
    background: #e9ede5;
    border-block: 1px solid #dce0d6;
}

.section-heading {
    display: flex;
    justify-content: space-between;
    align-items: end;
    gap: 40px;
    margin-bottom: 45px;
}

.section-heading h2 {
    margin-bottom: 0;
}

.section-heading>p {
    max-width: 300px;
    color: var(--muted);
    font-size: .95rem;
}

.project-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}

.project-card {
    padding: 38px;
    background: #f8f8f1;
    border: 1px solid #d7ddd1;
    border-radius: 4px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.project-number {
    font-size: .64rem;
    letter-spacing: .18em;
    color: var(--muted);
}

.project-symbol {
    font-size: 2.6rem;
    line-height: 1;
    margin: 35px 0 25px;
    color: #557064;
}

.project-card h3 {
    font-size: 2rem;
    margin-bottom: 18px;
}

.project-card p {
    color: var(--muted);
    font-size: .95rem;
}

.project-link {
    margin-top: auto;
    padding-top: 18px;
    border-top: 1px solid var(--line);
    width: 100%;
    display: flex;
    justify-content: space-between;
    font-size: .85rem;
    text-decoration: none;
}

.project-link:hover {
    text-decoration: underline;
}

/* Autobiography and footer */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1.15fr;
    gap: 90px;
}

.signature {
    font-family: var(--serif);
    font-size: 1.8rem;
    font-style: italic;
    color: #819183;
    margin-top: 40px;
}

.about-copy {
    padding-top: 20px;
}

.about-copy>p:not(.lead) {
    color: var(--muted);
}

.bio-placeholder {
    border-left: 2px solid #bc985e;
    padding: 10px 0 10px 24px;
    margin-top: 28px;
}

.bio-placeholder .eyebrow {
    font-size: .65rem;
}

.bio-placeholder p {
    margin: 8px 0 0;
    color: var(--muted);
}

.site-footer {
    background: #102b30;
    color: #e1e7df;
    padding-block: 30px;
}

.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.footer-inner p,
.footer-inner>a:last-child {
    font-size: .72rem;
    margin: 0;
}

.footer-inner>a:last-child {
    text-decoration: none;
}

/* Large screens */
@media (min-width:1500px) {
    .hero {
        min-height: 760px;
    }

}

/* Tablets */
@media (max-width:800px) {
    .container {
        width: calc(100% - 40px);
    }

    .book-grid,
    .about-grid {
        gap: 40px;
        grid-template-columns: 1fr;
    }

    .book-stage {
        padding-bottom: 30px;
    }

    .book-copy {
        max-width: 600px;
    }

    .section {
        padding-block: 70px;
    }

    .section-heading {
        align-items: start;
        flex-direction: column;
        gap: 20px;
    }

    .section-heading>p {
        max-width: 450px;
        margin: 0;
    }

    .project-card {
        padding: 28px;
    }

    .about-copy {
        padding-top: 0;
    }

    .signature {
        margin-top: 20px;
    }

    .footer-inner {
        flex-wrap: wrap;
    }

    .hero {
        min-height: 650px;
    }

    .hero-description {
        max-width: 430px;
    }

}

/* Phones */
@media (max-width:560px) {
    .header-inner {
        min-height: 76px;
        flex-wrap: wrap;
        gap: 0;
        padding-block: 16px;
    }

    .brand {
        font-size: 1.25rem;
    }

    .brand-icon {
        font-size: 1.7rem;
    }

    nav {
        width: 100%;
        gap: 22px;
        padding-top: 15px;
    }

    nav a {
        font-size: .8rem;
    }

    .js nav:not(.is-open) {
        display: none;
    }

    .js .menu-toggle:not([hidden]) {
        display: block;
    }

    .hero {
        min-height: 645px;
    }

    .hero-content {
        padding-top: 65px;
        padding-bottom: 110px;
    }

    h1 {
        font-size: 3.6rem;
    }

    .hero-description {
        font-size: .95rem;
    }

    .hero-foot {
        font-size: .65rem;
    }

    .hero-foot>span {
        max-width: 160px;
    }

    .actions {
        gap: 20px;
    }

    .project-grid {
        grid-template-columns: 1fr;
    }

    .book-grid {
        gap: 35px;
    }

    .book-stage {
        padding-top: 20px;
    }

    .book-art {
        width: 245px;
        min-height: 370px;
    }

    .cover-title {
        font-size: 2.2rem;
    }

    .section {
        padding-block: 60px;
    }

    .button {
        font-size: .78rem;
        padding: 13px 18px;
    }

    .footer-inner {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }

}

/* Respect reduced-motion preferences */
@media (prefers-reduced-motion:reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *:before,
    *:after {
        transition: none!important;
        animation: none!important;
    }

}

/* Book cover image */

.book-cover-link {
    display: inline-block;
    width: 280px;
    max-width: 100%;
    border-radius: 3px;
}

.book-cover {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 3px;
    box-shadow: 16px 22px 35px #18383b30;
    transform: rotate(-4deg);
    transition: transform 0.2s ease;
}

.book-cover-link:hover .book-cover,
.book-cover-link:focus-visible .book-cover {
    transform: rotate(0deg);
}

/* Smaller screens */

@media (max-width: 560px) {
    .book-cover-link {
        width: 245px;
    }
}

/* Reduced-motion accessibility */

@media (prefers-reduced-motion: reduce) {
    .book-cover {
        transition: none;
        transform: none;
    }
}

/* Autobiography paragraph spacing */

.bio-placeholder p {
    margin: 0 0 1.25rem;
    color: var(--muted);
}

.bio-placeholder > .eyebrow {
    display: block;
    margin-bottom: 1rem;
}

.bio-placeholder p:last-child {
    margin-bottom: 0;
}

/* Authorship and AI transparency note */

.author-note {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--line);
}

.author-note h3 {
    margin-bottom: 1rem;
    font-size: 1.4rem;
}

.author-note p {
    margin-bottom: 1rem;
    color: var(--muted);
    font-size: 0.95rem;
}

.author-note p:last-child {
    margin-bottom: 0;
}

/* Mountain photograph behind the introductory section */

.hero {
    background-color: #163138;

    background-image:
        linear-gradient(
            90deg,
            rgba(10, 30, 34, 0.88) 0%,
            rgba(10, 30, 34, 0.65) 45%,
            rgba(10, 30, 34, 0.18) 100%
        ),
        url("images/castle-reef.jpg");

    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
}

/* Hide the original illustrated mountains and stars */

.hero .mountains,
.hero .stars {
    display: none;
}

/* Keep the text above the photographic background */

.hero-content,
.hero-foot {
    z-index: 1;
}

/* Adjust the photograph and shading for smaller screens */

@media (max-width: 560px) {
    .hero {
        background-position: 60% center;

        background-image:
            linear-gradient(
                180deg,
                rgba(10, 30, 34, 0.76) 0%,
                rgba(10, 30, 34, 0.65) 60%,
                rgba(10, 30, 34, 0.82) 100%
            ),
            url("images/castle-reef.jpg");
    }
}