:root {
    --brand: #6e1a6a;
    --ink: #293747;
    --muted: #5d5062;
    --line: #eaddea;
    --soft: #faf5fa;
    --paper: #fff;
    --gallery-heading: "Bricolage Grotesque", Montserrat, sans-serif;
}
body {font-family: Montserrat, system-ui, sans-serif;}
main {max-width: 1336px;}
.site-header {
    max-width: none;
    padding: 14px max(28px, calc((100% - 1280px) / 2));
    gap: 12px;
    background: var(--soft);
    border-bottom: 1px solid var(--line);
}
.site-header::after {content: none;}
.site-header .brand {gap: 16px;}
.site-header .logo {height: 60px; width: auto; background: transparent;}
.site-header .brand .brand-tagline {
    font: 400 clamp(18px, 1.4vw, 22px)/1.16 "Zart Cormorant", Georgia, serif;
    color: var(--brand);
}
.site-header .brand .brand-tagline em {
    font: inherit;
    font-style: italic;
    display: inline;
    padding: 0;
    color: inherit;
}
.site-header nav {align-items: stretch; gap: 6px;}
.site-header nav a,
.site-header nav .gallery-upload-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 8px 13px;
    border: 1px solid #eae2eb;
    border-radius: 12px;
    background: #f7f2f7;
    color: var(--ink);
    box-shadow: none;
    font-weight: 650;
    line-height: 1.2;
    text-align: center;
}
.site-header nav a:hover,
.site-header nav a.selected,
.site-header nav .gallery-upload-link:hover {
    background: #f0e2f2;
    border-color: #dfc7e2;
    color: var(--brand);
    box-shadow: none;
}
.site-header nav .gallery-upload-link {
    background: var(--brand);
    border-color: var(--brand);
    color: #fff;
    box-shadow: 0 3px 9px #6e1a6a29;
    font-weight: 750;
}
.site-header nav .gallery-upload-link:hover,
.site-header nav .gallery-upload-link:focus-visible {
    background: #54134f;
    border-color: #54134f;
    color: #fff;
}
h1, h2, .grid .caption h2 {font-family: var(--gallery-heading); font-weight: 700; color: var(--brand);}
.tile, .community-invite, .filters {border-radius: 16px;}
.tile {box-shadow: 0 2px 8px #321c3214;}
.button, button {border-radius: 10px;}
a:focus-visible, button:focus-visible {outline: 3px solid #9a4278; outline-offset: 3px;}
.home-hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: linear-gradient(135deg, #faf5fa, #f3e5f4);
}
.home-hero-empty {grid-template-columns: 1fr;}
.home-intro {padding: clamp(24px, 5vw, 72px); align-self: center;}
.home-intro h1 {font-size: clamp(38px, 5.3vw, 82px); line-height: 1.03; letter-spacing: -.05em; margin: 0;}
.home-intro p {max-width: 38ch;}
.home-photos {
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    grid-template-rows: repeat(2, 1fr);
    gap: 5px;
    min-height: 440px;
}
.home-photos a {position: relative; overflow: hidden; min-width: 0;}
.home-photos a:first-child, .home-photos-2 a {grid-row: span 2;}
.home-photos-1 {grid-template-columns: 1fr;}
.home-photos img {position: absolute; width: 100%; height: 100%; object-fit: cover;}
.home-photos a:focus-visible {outline-offset: -5px; z-index: 1;}
.home-photos a:hover img, .home-card:hover img {filter: brightness(.94);}
.home-routes {display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 12px; margin: 16px 0 38px;}
.home-routes a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 6px;
    padding: 14px 16px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: var(--soft);
    font-weight: 700;
    text-decoration: none;
}
.home-routes a:hover {background: #f0e2f2;}
.home-latest {margin-bottom: 32px;}
.home-latest .heading-row {margin-bottom: 10px;}
.home-latest h2 {font-size: clamp(28px, 4vw, 48px);}
.home-latest .grid {grid-template-columns: repeat(4,minmax(0,1fr));}
.home-card {display: block; text-decoration: none;}
.home-card h3 {margin: 0 0 5px; font: 700 1.05rem/1.2 var(--gallery-heading);}
.home-card small {display: block;}
@media (max-width: 850px) {
    .site-header {padding-inline: 20px;}
    .home-hero {grid-template-columns: 1fr;}
    .home-photos {min-height: 360px;}
    .home-latest .grid {grid-template-columns: repeat(2,minmax(0,1fr));}
}
@media (max-width: 540px) {
    .site-header, main {padding-inline: 14px;}
    .site-header .logo {height: 48px;}
    .site-header .brand {gap: 10px;}
    .site-header .brand .brand-tagline {font-size: 17px;}
    .site-header nav {gap: 4px;}
    .site-header nav a,
    .site-header nav .gallery-upload-link {font-size: .75rem; min-height: 42px; padding: 7px 8px;}
    .home-photos {min-height: 260px;}
    .home-routes {gap: 5px; margin-bottom: 24px;}
    .home-routes a {padding: 8px 6px; font-size: .72rem; overflow-wrap: anywhere;}
    .home-latest .grid {gap: 10px;}
    .home-card .caption {padding: 10px;}
}
