@font-face {
    font-family: "HeaderFont";
    src: url("AsapSharp-ExtraBold.ttf") format("truetype");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

body {
    margin: 0;
    background-color: #FFFFFF;
    font-family: Arial, sans-serif;
    font-size: 1.25rem;           
    line-height: 1.2;
    color: #1a1a1a;               
    text-align: center;
}

.lead {
    font-weight: bold;
}

/* Fixed header: JavaScript changes its height as you scroll */
header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 10;
    box-sizing: border-box;
    overflow: hidden;
    background-color: #7D2328;
    color: #FFFFFF;
    padding: 30px 20px 0;
    height: 250px;                /* temporary; JavaScript sets the real height */
}

.logo {
    position: absolute;
    left: 20px;
    top: 20px;
    display: block;
    height: clamp(50px, 10vw, 110px);
    width: auto;
}

.title {
    display: block;
    width: fit-content;
    margin: 0 auto;
    text-align: left;
}

header h1 {
    margin: 0;
    font-family: "HeaderFont", "Arial Black", sans-serif;
    font-weight: 400;
    font-variant-caps: small-caps;
    font-size: clamp(2rem, 7vw, 4rem);
    line-height: 1.1;
}

.rotator {
    display: grid;
}

.rotator .word {
    grid-area: 1 / 1;
}

.rotator .word span {
    opacity: 0;
    transition: opacity 0.4s ease;
}

.rotator .word span.show {
    opacity: 1;
}

#header-spacer {
    height: 250px;                /* temporary; JavaScript sets the real height */
}

/* ---------- Page content ---------- */

section {
    padding: 40px 10px;
}

/* The text column. The thin line is its bottom border, so the line
   is exactly as wide as the text. */
.content {
    max-width: 600px;
    margin: 0 auto;
    padding-bottom: 40px;
    border-bottom: 2px solid #7D2328;
}

.contentcontact {
    max-width: 600px;
    margin: 0 auto;
    padding-bottom: 40px;
}

.content p {
    margin: 0 0 1.2em;
}

/* Centered + justified: paragraphs are justified, last lines are centered */
.centered-text p {
    text-align: justify;
    text-align-last: center;
    hyphens: auto;
    -webkit-hyphens: auto;        /* for older Safari/iPhone versions */
}

/* Services photos */
.photo-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    max-width: 500px;             
    margin: 0 auto;               
}

.photo-grid img {
    width: 100%;
    aspect-ratio: 9 / 10;
    object-fit: cover;
    display: block;
    border-radius: 14px;          
}


.photo-grid figure {
    margin: 0;
}


.photo-grid figcaption {
    margin-top: 8px;
    font-weight: bold;
}

/* About portrait */
.portrait {
    display: block;
    margin: 0 auto 1.2em;
    max-width: 100%;
    width: 220px;                
    height: auto;
    border-radius: 14px;          
}

/* Logo at the bottom of Contact */
.bottom-logo {
    display: block;
    margin: 30px auto 0;
    height: 90px;
    width: auto;
}

/* Footer bar */
footer {
    background-color: #7D2328;
    height: 80px;                /* a bit shorter than the full header */
}

.email-btn {
    background-color: #7D2328;
    color: #FFFFFF;
    border: none;
    border-radius: 14px;
    padding: 12px 24px;
    font-size: 1rem;
    font-family: inherit;
    font-weight: bold;
    cursor: pointer;
}

.email-btn:hover,
.email-btn:focus-visible {
    background-color: #5c1a1e;    /* slightly darker on hover */
}

.email-box {
    margin-top: 20px;
}

.email-box img {
    max-width: 100%;
    width: 340px;
    height: auto;
}

/* One column of photos on narrow phones */
@media (max-width: 500px) {
    .photo-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
    .centered-text p {
        text-align: center;
        text-align-last: center;
    }
}