/* DEN site. Layout concept: paper ground, one bold italic headline per section,
   the logo's four quadrant colors used as a recurring "four corners" motif. */
:root {
  --paper: #FFF8EE;
  --surface: #FFFFFF;
  --ink: #16161D;
  --ink-soft: #4A4756;
  --line: #EADFD0;
  --navy: #14285C;          /* wordmark */
  --magenta: #FF1EE6;
  --magenta-deep: #B0009A;  /* text-safe magenta */
  --green: #2EEA1A;
  --green-deep: #138A07;
  --blue: #0812E8;
  --orange: #FF8A1F;
  --orange-deep: #B85A00;
  --pink: #FFD6F8;
  --mint: #D9FBD3;
  --peach: #FFE3C7;
  --lightblue: #E3E5FF;
  --focus: #0812E8;
  --font-display: "Playfair Display", Georgia, "Times New Roman", serif;
  --font-body: Arial, "Helvetica Neue", Helvetica, sans-serif;
  --font-script: "Brush Script MT", "Dancing Script", cursive;
  --radius: 14px;
  --max: 1120px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #15141B; --surface: #1E1D26; --ink: #F6F1EA; --ink-soft: #BDB7C8; --line: #33303F;
    --navy: #C9D3FF; --magenta-deep: #FF7DF0; --green-deep: #7CF26E; --orange-deep: #FFB36B;
    --pink: #3A1836; --mint: #18301A; --peach: #3A2818; --lightblue: #1D2050; --focus: #9AA0FF;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #15141B; --surface: #1E1D26; --ink: #F6F1EA; --ink-soft: #BDB7C8; --line: #33303F;
  --navy: #C9D3FF; --magenta-deep: #FF7DF0; --green-deep: #7CF26E; --orange-deep: #FFB36B;
  --pink: #3A1836; --mint: #18301A; --peach: #3A2818; --lightblue: #1D2050; --focus: #9AA0FF;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--font-body); font-size: 17px; line-height: 1.6;
}
img { max-width: 100%; height: auto; display: block; }
[hidden] { display: none !important; }
a { color: var(--magenta-deep); text-underline-offset: 3px; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 4px; }
.wrap {
  max-width: var(--max); margin: 0 auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--paper); padding: 8px 14px; z-index: 50; }
.skip:focus { left: 12px; }

/* Type */
h1, h2, h3 { font-family: var(--font-display); font-style: italic; font-weight: 700; line-height: 1.1; text-wrap: balance; margin: 0; color: var(--navy); }
h1 { font-size: clamp(2.4rem, 6vw, 4.2rem); letter-spacing: -0.01em; }
h2 { font-size: clamp(1.8rem, 3.6vw, 2.6rem); }
h3 { font-size: 1.35rem; }
.label { font-size: .78rem; font-weight: 700; letter-spacing: .18em; text-transform: uppercase; color: var(--ink-soft); margin: 0; }
.lede { font-size: 1.2rem; color: var(--ink-soft); max-width: 60ch; margin: 0; }
.script { font-family: var(--font-script); font-size: 1.9rem; color: var(--magenta-deep); line-height: 1; }
p { margin: 0; max-width: 65ch; }

/* Four-corner motif */
.quad { display: inline-grid; grid-template-columns: 1fr 1fr; gap: 3px; width: 22px; height: 22px; flex: none; }
.quad i { border-radius: 2px; }
.quad i:nth-child(1) { background: var(--magenta); }
.quad i:nth-child(2) { background: var(--green); }
.quad i:nth-child(3) { background: var(--blue); }
.quad i:nth-child(4) { background: var(--orange); }
.stripe { height: 6px; background: linear-gradient(90deg, var(--magenta) 0 25%, var(--green) 25% 50%, var(--blue) 50% 75%, var(--orange) 75%); }

/* Header */
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 30; background: var(--surface); }
.site-header { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; background: var(--surface); border-bottom: 1px solid var(--line); }
.nav { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 76px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--navy); }
.brand img { width: 52px; height: 52px; object-fit: contain; }
.brand span { font-family: var(--font-display); font-weight: 700; font-size: 1.05rem; line-height: 1.15; }
.brand small { display: block; font-family: var(--font-body); font-weight: 700; font-size: .66rem; letter-spacing: .2em; text-transform: uppercase; color: var(--ink-soft); }
.menu { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; align-items: center; }
.menu a { display: block; padding: 10px 14px; border-radius: 999px; text-decoration: none; color: var(--ink); font-weight: 700; font-size: .95rem; }
.menu a:hover { background: var(--peach); }
.menu a[aria-current="page"] { background: var(--navy); color: var(--paper); }
.menu-toggle { display: none; background: none; border: 2px solid var(--ink); color: var(--ink); border-radius: 10px; padding: 8px 12px; font: 700 .9rem var(--font-body); cursor: pointer; }
@media (max-width: 880px) {
  .menu-toggle { display: block; }
  .menu { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--surface); flex-direction: column; align-items: stretch; padding: 8px max(16px, env(safe-area-inset-right, 0px)) 16px max(16px, env(safe-area-inset-left, 0px)); border-bottom: 1px solid var(--line); }
  .menu.open { display: flex; }
  .menu a { padding: 14px 16px; }
  .brand span { font-size: .95rem; }
}

/* Buttons */
.btn { display: inline-flex; align-items: center; gap: 10px; padding: 14px 24px; border-radius: 999px; font: 700 1rem var(--font-body); text-decoration: none; border: 2px solid var(--ink); background: var(--ink); color: var(--paper); cursor: pointer; transition: transform .15s ease, box-shadow .15s ease; }
.btn:hover { transform: translateY(-2px); box-shadow: 4px 4px 0 var(--magenta); }
.btn.ghost { background: transparent; color: var(--ink); }
.btn.ghost:hover { box-shadow: 4px 4px 0 var(--orange); }

/* Sections */
main { display: block; }
.section { padding-block: clamp(56px, 8vw, 96px); }
.section.tint-pink { background: var(--pink); }
.section.tint-mint { background: var(--mint); }
.section.tint-peach { background: var(--peach); }
.section.tint-blue { background: var(--lightblue); }
.stack { display: flex; flex-direction: column; gap: 18px; }
.page-head { padding-block: clamp(48px, 7vw, 84px) clamp(24px, 4vw, 40px); }
.page-head .stack { gap: 14px; }

/* Home hero */
.hero { padding-block: clamp(40px, 7vw, 88px); }
.hero-grid { display: grid; grid-template-columns: 1.2fr .8fr; gap: clamp(24px, 5vw, 64px); align-items: center; }
.hero-grid > * { min-width: 0; }
.hero-logo { width: min(100%, 380px); justify-self: center; animation: spin-in 1.1s cubic-bezier(.2,.8,.2,1) both; }
@keyframes spin-in { from { transform: rotate(-24deg) scale(.9); } to { transform: none; } }
@media (prefers-reduced-motion: reduce) { .hero-logo { animation: none; } .btn { transition: none; } html { scroll-behavior: auto; } }
.hero .actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
@media (max-width: 760px) { .hero-grid { grid-template-columns: 1fr; } .hero-logo { width: 220px; grid-row: 1; } }

.next-event { display: grid; grid-template-columns: auto 1fr auto; gap: 20px; align-items: center; background: var(--surface); border: 2px solid var(--ink); border-radius: var(--radius); padding: 18px 22px; box-shadow: 6px 6px 0 var(--orange); }
.next-event > * { min-width: 0; }
.datebox { align-self: start; width: 72px; text-align: center; border-radius: 10px; background: var(--navy); color: var(--paper); padding: 8px 0; line-height: 1.1; }
.datebox b { display: block; font-family: var(--font-display); font-size: 1.8rem; }
.datebox small { font-size: .7rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; }
@media (max-width: 600px) { .next-event { grid-template-columns: auto 1fr; } .next-event .btn { grid-column: 1 / -1; justify-content: center; } }

/* Mission split */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 5vw, 64px); }
.split > * { min-width: 0; }
@media (max-width: 760px) { .split { grid-template-columns: 1fr; } }
.statement { font-family: var(--font-display); font-style: italic; font-size: clamp(1.4rem, 2.6vw, 1.9rem); line-height: 1.3; color: var(--ink); max-width: 30ch; }

/* Value words */
.values { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.value { border-radius: var(--radius); padding: 26px 22px; color: #16161D; display: flex; flex-direction: column; gap: 8px; }
.value b { font-family: var(--font-display); font-style: italic; font-size: 1.7rem; }
.value:nth-child(1) { background: #FFD6F8; border-top: 8px solid var(--magenta); }
.value:nth-child(2) { background: #D9FBD3; border-top: 8px solid var(--green); }
.value:nth-child(3) { background: #DCDEFF; border-top: 8px solid var(--blue); }
.value:nth-child(4) { background: #FFE3C7; border-top: 8px solid var(--orange); }
@media (max-width: 860px) { .values { grid-template-columns: 1fr 1fr; } }
@media (max-width: 460px) { .values { grid-template-columns: 1fr; } }

.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px 40px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.grid-2 > *, .grid-4 > * { min-width: 0; }
@media (max-width: 860px) { .grid-4 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 620px) { .grid-2, .grid-4 { grid-template-columns: 1fr; } }
.point { display: flex; gap: 14px; align-items: flex-start; }
.point h3 { font-size: 1.2rem; margin-bottom: 4px; }

.faq { display: flex; flex-direction: column; gap: 10px; max-width: 760px; }
.faq details { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 4px 20px; }
.faq summary { cursor: pointer; font-weight: 700; padding: 14px 0; list-style-position: outside; }
.faq details p { padding-bottom: 16px; color: var(--ink-soft); }

/* Team */
.team { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
@media (max-width: 960px) { .team { grid-template-columns: 1fr 1fr; } }
@media (max-width: 620px) { .team { grid-template-columns: 1fr; } }
.member { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.member header { display: flex; gap: 16px; align-items: center; }
.avatar { width: 72px; height: 72px; border-radius: 50%; display: grid; place-items: center; font-family: var(--font-display); font-style: italic; font-weight: 700; font-size: 1.6rem; color: #16161D; flex: none; overflow: hidden; }
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.member .role { font-size: .78rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-soft); }
.member blockquote { margin: 0; padding-left: 14px; border-left: 4px solid var(--orange); font-style: italic; color: var(--ink); }
.member details summary { cursor: pointer; font-weight: 700; color: var(--magenta-deep); }
.member details[open] summary { margin-bottom: 10px; }
.member details h4 { margin: 12px 0 4px; font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; color: var(--ink-soft); }
.member details p { font-size: .97rem; }

/* Events */
.events-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 32px; align-items: start; }
@media (max-width: 900px) { .events-layout { grid-template-columns: 1fr; } }
.calendar { background: var(--surface); border: 2px solid var(--ink); border-radius: var(--radius); padding: 18px; box-shadow: 6px 6px 0 var(--magenta); }
.cal-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 12px; }
.cal-head h3 { font-size: 1.4rem; }
.cal-nav { display: flex; gap: 6px; }
.cal-nav button { width: 40px; height: 40px; border-radius: 50%; border: 2px solid var(--ink); background: var(--surface); color: var(--ink); font-size: 1.1rem; cursor: pointer; }
.cal-nav button:hover { background: var(--peach); }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.cal-dow { text-align: center; font-size: .7rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-soft); padding: 6px 0; }
.cal-day { aspect-ratio: 1; max-width: 100%; border: 0; border-radius: 10px; background: transparent; color: var(--ink); font: 700 .95rem var(--font-body); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; cursor: default; font-variant-numeric: tabular-nums; }
.cal-day.muted { color: var(--line); }
.cal-day.today { outline: 2px dashed var(--orange-deep); }
.cal-day.has { cursor: pointer; background: var(--pink); }
.cal-day.has.past { background: var(--lightblue); }
.cal-day.has:hover, .cal-day.selected { background: var(--navy); color: var(--paper); }
.cal-day .dots { display: flex; gap: 3px; }
.cal-day .dots i { width: 6px; height: 6px; border-radius: 50%; background: var(--magenta); }
.cal-day.past .dots i { background: var(--blue); }
.cal-legend { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 12px; font-size: .85rem; color: var(--ink-soft); }
.cal-legend span::before { content: ""; display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 6px; vertical-align: middle; }
.cal-legend .up::before { background: var(--magenta); }
.cal-legend .pa::before { background: var(--blue); }

.tabs { display: inline-flex; border: 2px solid var(--ink); border-radius: 999px; padding: 4px; gap: 4px; background: var(--surface); }
.tabs button { border: 0; background: transparent; color: var(--ink); padding: 10px 20px; border-radius: 999px; font: 700 .95rem var(--font-body); cursor: pointer; }
.tabs button[aria-selected="true"] { background: var(--ink); color: var(--paper); }
.event-list { display: flex; flex-direction: column; gap: 14px; margin-top: 18px; }
.event { display: grid; grid-template-columns: auto 1fr; gap: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; }
.event > * { min-width: 0; }
.event.past .datebox { background: var(--ink-soft); }
.event h3 { font-size: 1.3rem; margin-bottom: 4px; }
.event .meta { font-size: .78rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--magenta-deep); margin-bottom: 6px; }
.event .where { font-size: .92rem; color: var(--ink-soft); margin-top: 6px; }
.event .actions { margin-top: 10px; display: flex; gap: 10px; flex-wrap: wrap; }
.event .actions a { font-weight: 700; font-size: .92rem; }
.chip { display: inline-block; font-size: .68rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; padding: 3px 8px; border-radius: 999px; background: var(--peach); color: var(--ink); vertical-align: middle; margin-left: 6px; font-family: var(--font-body); font-style: normal; }
.empty { padding: 24px; border: 2px dashed var(--line); border-radius: var(--radius); color: var(--ink-soft); }

/* Gallery */
.filters { display: flex; flex-wrap: wrap; gap: 8px; }
.filters button { border: 2px solid var(--ink); background: var(--surface); color: var(--ink); border-radius: 999px; padding: 8px 16px; font: 700 .9rem var(--font-body); cursor: pointer; }
.filters button[aria-pressed="true"] { background: var(--ink); color: var(--paper); }
.gallery { columns: 3 260px; column-gap: 16px; margin-top: 24px; }
.tile { break-inside: avoid; margin-bottom: 16px; border-radius: var(--radius); overflow: hidden; position: relative; border: 0; padding: 0; width: 100%; display: block; cursor: zoom-in; background: var(--surface); text-align: left; }
.tile img { width: 100%; height: auto; }
.tile .cap { position: absolute; left: 0; right: 0; bottom: 0; padding: 28px 14px 12px; background: linear-gradient(transparent, rgba(22,22,29,.78)); color: #fff; font-size: .9rem; font-weight: 700; }
.tile.sample { cursor: default; aspect-ratio: var(--ar, 4/5); display: flex; flex-direction: column; justify-content: space-between; padding: 18px; color: #16161D; }
.tile.sample .cap { position: static; background: none; color: #16161D; padding: 0; }
.tile.sample svg { width: 64px; height: 64px; }
.lightbox { position: fixed; inset: 0; z-index: 60; background: rgba(10,10,14,.92); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; padding: calc(24px + env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) calc(24px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); }
.lightbox img { max-height: 78vh; width: auto; border-radius: 10px; }
.lightbox p { color: #fff; text-align: center; }
.lightbox button { position: absolute; background: #fff; color: #16161D; border: 0; border-radius: 50%; width: 46px; height: 46px; font-size: 1.3rem; cursor: pointer; }
.lb-close { top: calc(16px + env(safe-area-inset-top, 0px)); right: max(16px, env(safe-area-inset-right, 0px)); }
.lb-prev { left: max(16px, env(safe-area-inset-left, 0px)); top: 50%; }
.lb-next { right: max(16px, env(safe-area-inset-right, 0px)); top: 50%; }

/* Contact */
.contact-layout { display: grid; grid-template-columns: 1.3fr .7fr; gap: 40px; align-items: start; }
.contact-layout > * { min-width: 0; }
@media (max-width: 860px) { .contact-layout { grid-template-columns: 1fr; } }
form.card { background: var(--surface); border: 2px solid var(--ink); border-radius: var(--radius); padding: clamp(20px, 3vw, 32px); box-shadow: 6px 6px 0 var(--green); display: flex; flex-direction: column; gap: 18px; }
.row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.row > * { min-width: 0; }
@media (max-width: 560px) { .row { grid-template-columns: 1fr; } }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label, fieldset legend { font-weight: 700; font-size: .95rem; }
.field .hint { font-size: .85rem; color: var(--ink-soft); }
input, select, textarea { font: inherit; color: var(--ink); background: var(--paper); border: 2px solid var(--line); border-radius: 10px; padding: 12px 14px; width: 100%; }
input:focus, select:focus, textarea:focus { border-color: var(--navy); outline: none; box-shadow: 0 0 0 3px var(--lightblue); }
textarea { min-height: 140px; resize: vertical; }
fieldset { border: 0; padding: 0; margin: 0; }
.checks { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.checks label { display: inline-flex; align-items: center; gap: 8px; border: 2px solid var(--line); border-radius: 999px; padding: 8px 14px; cursor: pointer; font-size: .92rem; }
.checks input { width: auto; accent-color: var(--magenta-deep); }
.checks label:has(input:checked) { border-color: var(--ink); background: var(--pink); }
.consent { display: flex; gap: 10px; align-items: flex-start; font-size: .92rem; color: var(--ink-soft); }
.consent input { width: auto; margin-top: 4px; accent-color: var(--magenta-deep); }
.err { color: #C4002B; font-size: .85rem; font-weight: 700; }
:root[data-theme="dark"] .err { color: #FF8FA6; }
.hp { position: absolute; left: -5000px; }
.notice { border-radius: 12px; padding: 16px 18px; font-size: .97rem; }
.notice.ok { background: var(--mint); }
.notice.info { background: var(--peach); }
.aside-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; display: flex; flex-direction: column; gap: 12px; }
.aside-card + .aside-card { margin-top: 18px; }
.copyline { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.copyline code { font-family: var(--font-body); font-weight: 700; word-break: break-all; user-select: all; }
.copyline button { border: 2px solid var(--ink); background: transparent; color: var(--ink); border-radius: 999px; padding: 4px 12px; font: 700 .8rem var(--font-body); cursor: pointer; }

/* Footer */
.site-footer { background: var(--navy); color: var(--paper); padding-block: 48px 32px; }
:root[data-theme="dark"] .site-footer { background: #0E0D14; color: var(--ink); }
.site-footer a { color: inherit; }
.foot-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 32px; }
.foot-grid > * { min-width: 0; }
.foot-grid h4 { margin: 0 0 10px; font-size: .78rem; letter-spacing: .18em; text-transform: uppercase; opacity: .8; }
.foot-grid ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.foot-logo { display: flex; gap: 14px; align-items: center; }
.foot-logo img { width: 64px; height: 64px; object-fit: contain; background: #fff; border-radius: 50%; padding: 4px; }
.foot-base { margin-top: 32px; padding-top: 18px; border-top: 1px solid rgba(255,255,255,.2); font-size: .85rem; opacity: .85; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
@media (max-width: 760px) { .foot-grid { grid-template-columns: 1fr; } }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .site-footer { background: #0E0D14; color: var(--ink); } }
