/*
Theme Name: SVP Grenchen
Description: Responsive Website für die Ortspartei SVP Grenchen.
Version: 1.1.1
Text Domain: svp-grenchen
*/
:root {
    color-scheme: light;
    --forest: #12382b;
    --leaf: #235a41;
    --ink: #142c23;
    --muted: #425b51;
    --paper: #f4f8f2;
    --line: #c7d8ce;
}
* { box-sizing: border-box; }
body { margin: 0; color: var(--ink); background: #fff; font: 1rem/1.65 system-ui, sans-serif; }
a { color: var(--leaf); text-underline-offset: .19em; }
a:focus-visible { outline: 3px solid #bd4726; outline-offset: 4px; }
img { max-width: 100%; height: auto; }
h1, h2, h3, h4 { line-height: 1.12; letter-spacing: -.025em; }
h1 { font-size: clamp(2.2rem, 6vw, 4.5rem); overflow-wrap: anywhere; }
h2 { font-size: clamp(1.65rem, 4vw, 2.6rem); }
h3 { font-size: 1.35rem; }
.wrap { width: min(74rem, calc(100% - 3rem)); margin-inline: auto; }
.skip { position: absolute; top: .5rem; left: .5rem; z-index: 2; padding: .6rem; background: white; transform: translateY(-160%); }
.skip:focus { transform: none; }
.header { background: white; border-bottom: 1px solid var(--line); }
.header-inner { display: flex; justify-content: space-between; align-items: center; gap: 1.2rem; min-height: 5rem; padding-block: .7rem; }
.brand { flex: 0 0 auto; }
.brand img { display: block; width: 10rem; }
.nav { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1.1rem; }
.nav a { font-size: .92rem; font-weight: 650; text-decoration: none; }
.nav a:hover, .nav [aria-current=page] { text-decoration: underline; }
.button { display: inline-block; padding: .65rem 1rem; background: var(--leaf); color: white; border-radius: .4rem; font-weight: 680; text-decoration: none; }
.button:hover { background: var(--forest); color: white; }
.hero { background: linear-gradient(120deg, var(--forest), #246346); color: #fff; }
.hero-inner { display: grid; grid-template-columns: 1.4fr 1fr; align-items: center; gap: 2rem; padding-block: clamp(2.5rem, 7vw, 6rem); }
.eyebrow { color: inherit; font-size: .88rem; font-weight: 670; letter-spacing: .09em; text-transform: uppercase; }
.hero h1 { margin: .15em 0; font-size: clamp(3.2rem, 10vw, 8.6rem); line-height: .88; letter-spacing: -.07em; }
.intro { max-width: 33ch; margin-block: 1.5rem; font-size: clamp(1.1rem, 2vw, 1.35rem); }
.button-light { background: #fff; color: var(--forest); }
.button-light:hover { background: #e4f0e5; color: var(--forest); }
.crest { display: grid; place-items: center; justify-self: center; width: min(100%, 23rem); aspect-ratio: 1; background: #ffffff0b; border: 1px solid #ffffff40; border-radius: 50%; }
.crest img { width: 46%; filter: drop-shadow(0 .45rem 1rem #0b211a60); }
.home-section { padding-block: 2.8rem 4rem; }
.home-section h2 { margin-top: 0; }
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.card { padding: 1.35rem; border: 1px solid var(--line); border-radius: .5rem; text-decoration: none; background: var(--paper); overflow-wrap: anywhere; }
.card:hover h3 { text-decoration: underline; }
.card h3 { margin: 0 0 .65rem; }
.card p { margin: 0; color: var(--muted); }
.page-head { padding-block: 2rem; color: white; background: var(--forest); }
.page-head h1 { margin: .25em 0 0; }
.article { max-width: 48rem; min-height: 17rem; padding-block: 2rem 4rem; overflow-wrap: anywhere; }
.article p { margin: .75rem 0 1rem; }
.article img { max-height: 27rem; width: auto; object-fit: contain; }
.article figure { margin: 1.75rem 0 .5rem; }
.article .portrait img { max-height: 19rem; border-radius: .4rem; }
.notice { border-left: .25rem solid var(--leaf); padding: .75rem 1rem; background: var(--paper); }
.footer { color: #fff; background: var(--forest); }
.footer-inner { padding-block: 2rem; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1.5rem; }
.footer nav { display: flex; flex-wrap: wrap; gap: .4rem 1.2rem; }
.footer a { color: #edf8f0; }
@media (max-width: 52rem) {
    .header-inner { align-items: flex-start; flex-direction: column; }
    .cards { grid-template-columns: 1fr; }
}
@media (max-width: 38rem) {
    .wrap { width: calc(100% - 2rem); }
    .hero-inner { grid-template-columns: 1fr; }
    .crest { justify-self: start; width: 8.5rem; }
}

/* Editorial homepage, team portraits, and compact navigation */
.menu-toggle { display: none; }
.hero { position: relative; isolation: isolate; overflow: hidden; }
.hero::after { position: absolute; z-index: -1; inset: 0; content: ""; background: linear-gradient(90deg, #08281bea 0%, #08281bb8 48%, #08281b18 100%); }
.hero-landscape { position: absolute; z-index: -2; inset: -48px 0 auto; width: 100%; height: calc(100% + 96px); max-width: none; object-fit: cover; transform: translateY(var(--shift, 0px)); }
.hero-inner { display: block; padding-block: clamp(3.6rem, 9vw, 8rem) 4rem; }
.hero h1 { font-size: clamp(3rem, 9vw, 7.4rem); }
.hero-actions, .news-links { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1.15rem; }
.button-outline { color: white; background: #12382b9e; border: 1px solid #fff; }
.photo-credit { position: relative; margin-block: 0; padding-block: .35rem .65rem; font-size: .78rem; }
.photo-credit a { color: white; }
.editorial-section { padding-block: clamp(1.8rem, 5vw, 3.5rem); }
.editorial-section h2 { margin: 0 0 .7rem; }
.news-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; margin: 1.4rem 0; }
.story { overflow: hidden; background: var(--paper); border: 1px solid var(--line); border-radius: .45rem; }
.story-media { position: relative; overflow: hidden; aspect-ratio: 16 / 9; background: var(--line); }
.story-media img { position: absolute; inset: -10px 0 auto; display: block; width: 100%; height: calc(100% + 20px); object-fit: cover; object-position: center 35%; transform: translateY(var(--shift, 0px)); }
.story-body { padding: 1rem 1.15rem 1.25rem; }
.story-body h3 { margin: .45rem 0 .55rem; overflow-wrap: anywhere; }
.story-body p { margin: 0; }
.story-meta { color: var(--muted); font-size: .88rem; font-weight: 650; }
.ballot-band { background: var(--paper); border-block: 1px solid var(--line); }
.ballots { padding: 0; display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: .75rem; list-style: none; }
.ballots li { display: flex; gap: .8rem; align-items: center; padding: .85rem; background: white; border: 1px solid var(--line); border-radius: .4rem; }
.vote { min-width: 3.2rem; padding: .22rem .4rem; text-align: center; color: white; border-radius: .2rem; }
.vote-ja { background: #235a41; }
.vote-nein { background: #9f302c; }
.events { display: grid; gap: .5rem; }
.event { display: grid; grid-template-columns: 6.2rem 1fr; gap: .8rem; align-items: start; padding-block: .75rem; border-bottom: 1px solid var(--line); }
.event time { font-weight: 700; }
.event p { margin: 0; }
.quick-links { border-top: 1px solid var(--line); }
.board-article { max-width: 62rem; }
.team-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: clamp(.5rem, 3vw, 1.7rem); }
.team-card { min-width: 0; overflow: hidden; background: var(--paper); border: 1px solid var(--line); border-radius: .5rem; }
.team-card figure { margin: 0; }
.team-card img { display: block; width: 100%; max-height: none; aspect-ratio: 4 / 5; object-fit: cover; object-position: center; }
.team-card h3, .team-card p { margin-inline: clamp(.5rem, 3vw, 1.25rem); }
.team-card h3 { font-size: clamp(1rem, 3.2vw, 1.6rem); margin-block: .75rem .4rem; }
.team-card p { font-size: clamp(.875rem, 2vw, 1rem); margin-block: .4rem .75rem; }
@media (max-width: 58rem) {
    .header-inner { display: grid; grid-template-columns: 1fr auto; align-items: center; padding-block: .8rem; min-height: 0; }
    .menu-ready .menu-toggle { display: inline-flex; gap: .5rem; align-items: center; border: 1px solid var(--leaf); padding: .55rem .85rem; border-radius: .35rem; color: #fff; background: var(--leaf); font: inherit; font-weight: 700; cursor: pointer; }
    .header-inner .nav { grid-column: 1 / -1; display: grid; width: 100%; gap: .2rem; padding: .5rem; background: var(--forest); border-radius: .4rem; }
    .header-inner .nav a { color: #fff; padding: .65rem .8rem; font-size: 1rem; }
    .menu-ready .menu-toggle[aria-expanded="false"] + .nav { display: none; }
    .news-grid { grid-template-columns: repeat(2,minmax(0,1fr)); }
}
@media (max-width: 38rem) {
    .news-grid, .ballots { grid-template-columns: 1fr; }
    .hero::after { background: linear-gradient(90deg, #08281bf0, #08281b78); }
    .hero-inner { padding-block: 3.25rem 2.25rem; }
}
@media (prefers-reduced-motion: reduce) {
    .hero-landscape, .story-media img { transform: none; }
}
.team-card details { margin: .5rem clamp(.5rem, 3vw, 1.25rem) .95rem; }
.team-card details p { margin-inline: 0; }
.team-card summary { cursor: pointer; font-weight: 650; color: var(--leaf); }
