/* The Open Book Project — site styles */

@font-face { font-family: "Poppins"; font-weight: 500; font-style: normal; font-display: swap; src: url("../fonts/poppins-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Poppins"; font-weight: 600; font-style: normal; font-display: swap; src: url("../fonts/poppins-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Poppins"; font-weight: 700; font-style: normal; font-display: swap; src: url("../fonts/poppins-latin-700-normal.woff2") format("woff2"); }
@font-face { font-family: "Nunito Sans"; font-weight: 400; font-style: normal; font-display: swap; src: url("../fonts/nunito-sans-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Nunito Sans"; font-weight: 600; font-style: normal; font-display: swap; src: url("../fonts/nunito-sans-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Nunito Sans"; font-weight: 700; font-style: normal; font-display: swap; src: url("../fonts/nunito-sans-latin-700-normal.woff2") format("woff2"); }

:root {
  --teal: #1F5F78;
  --teal-dark: #164A5E;
  --teal-mid: #5E9FB5;
  --gold: #C29A4E;
  --gold-text: #8A6420;
  --gold-tint: #FBF6EC;
  --tint: #F2F7F8;
  --ink: #1B2A30;
  --ink-on-gold: #14232B;
  --body: #3E5059;
  --muted: #4E5F66;
  --line: #E3ECEF;
  --field: #B9CDD4;
  --pill: #C9D9DF;
  --heading: "Poppins", system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: #FFFFFF;
  color: var(--ink);
  font-family: "Nunito Sans", system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; }
a { color: var(--teal); }
a:hover { color: var(--teal-dark); }
h1, h2, h3 { font-family: var(--heading); color: var(--teal); margin: 0; }
p { margin: 0; }
section { scroll-margin-top: 118px; }
input, select, textarea, button { font: inherit; }
:focus-visible { outline: 3px solid var(--teal-mid); outline-offset: 2px; }

.wrap { max-width: 1200px; margin: 0 auto; padding-left: 24px; padding-right: 24px; }
.section { padding-top: 100px; padding-bottom: 100px; }
.bg-tint { background: var(--tint); }
.bg-teal { background: var(--teal); color: #FFFFFF; }

.eyebrow { font-family: var(--heading); font-weight: 600; font-size: 13px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--gold-text); }
.h1 { font-weight: 700; font-size: clamp(38px, 5vw, 60px); line-height: 1.1; letter-spacing: -0.01em; }
.h2 { font-weight: 700; font-size: clamp(30px, 3.6vw, 42px); line-height: 1.15; }
.h3 { font-weight: 600; font-size: 22px; }
.lead { font-size: 18px; color: var(--body); }
.small { font-size: 14px; color: var(--muted); }
.stack { display: flex; flex-direction: column; }
.gap-6 { gap: 6px; } .gap-14 { gap: 14px; } .gap-16 { gap: 16px; } .gap-20 { gap: 20px; } .gap-22 { gap: 22px; } .gap-24 { gap: 24px; }
.row { display: flex; flex-wrap: wrap; gap: 56px; align-items: flex-start; }
.narrow { max-width: 720px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 54px; padding: 0 32px; border-radius: 999px;
  font-family: var(--heading); font-weight: 600; font-size: 16px;
  text-decoration: none; border: 2px solid transparent; cursor: pointer; text-align: center;
  transition: filter 0.15s ease;
}
.btn:hover { filter: brightness(0.94); }
.btn-gold { background: var(--gold); color: var(--ink-on-gold); }
.btn-gold:hover { color: var(--ink-on-gold); }
.btn-teal { background: var(--teal); color: #FFFFFF; }
.btn-teal:hover { color: #FFFFFF; }
.btn-outline { background: transparent; color: var(--teal); border-color: var(--teal); }
.btn-block { display: flex; width: 100%; min-height: 56px; font-size: 17px; }
.btn[disabled], .btn[aria-disabled="true"] { background: var(--pill); color: var(--body); cursor: not-allowed; filter: none; pointer-events: none; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 20; background: rgba(255,255,255,0.97); border-bottom: 1px solid var(--line); }
.header-bar { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding-top: 14px; padding-bottom: 14px; }
.site-logo { height: 88px; width: auto; display: block; }
.nav-links { display: flex; align-items: center; gap: 30px; font-weight: 600; font-size: 16px; }
.nav-links a { color: var(--ink); text-decoration: none; }
.nav-links a:hover { color: var(--teal); }
.header-actions { display: flex; align-items: center; gap: 10px; }
.header-actions .btn { min-height: 46px; padding: 0 24px; font-size: 15px; }
.menu-btn { display: none; align-items: center; justify-content: center; width: 48px; height: 48px; border-radius: 12px; border: 1.5px solid var(--pill); background: #FFFFFF; cursor: pointer; }
.mobile-nav { display: none; border-top: 1px solid var(--line); padding: 8px 24px 20px; flex-direction: column; font-weight: 700; font-size: 18px; }
.mobile-nav.open { display: flex; }
.mobile-nav a { padding: 12px 0; text-decoration: none; color: var(--ink); }
.mobile-nav .btn { margin-top: 10px; color: var(--ink-on-gold); }

@media (max-width: 1000px) {
  .nav-links, .header-actions .btn { display: none; }
  .menu-btn { display: inline-flex; }
}
@media (max-width: 600px) {
  .site-logo { height: 60px; }
  section { scroll-margin-top: 90px; }
  .section { padding-top: 72px; padding-bottom: 72px; }
}

/* Hero */
.hero .wrap { padding-top: 84px; padding-bottom: 92px; display: flex; flex-wrap: wrap; align-items: center; gap: 56px; }
.hero-text { flex: 1 1 500px; min-width: 0; }
.hero-text .lead { font-size: 19px; max-width: 560px; }
.hero-side { flex: 1 1 380px; min-width: 0; display: flex; justify-content: center; }
.founder-card { width: 100%; max-width: 440px; background: #FFFFFF; border-radius: 28px; padding: 36px 32px 30px; box-shadow: 0 24px 50px -26px rgba(22,74,94,0.4); display: flex; flex-direction: column; align-items: center; gap: 22px; text-align: center; }
.founder-card img { width: 190px; height: 190px; }
.founder-card .h3 { font-size: 20px; }
.btn-row { display: flex; flex-wrap: wrap; gap: 14px; padding-top: 8px; }

/* About */
.about-text { flex: 1 1 460px; min-width: 0; }
.about-intro { font-family: var(--heading); font-weight: 600; font-size: 22px; line-height: 1.4; color: var(--ink); }
.quote { margin: 0; padding: 22px 26px; border-radius: 20px; background: var(--gold-tint); display: flex; flex-direction: column; gap: 8px; }
.quote blockquote { margin: 0; font-family: var(--heading); font-weight: 600; font-size: 21px; line-height: 1.4; color: var(--teal); }
.quote figcaption { font-size: 15px; color: var(--muted); }
.panel { flex: 1 1 420px; min-width: 0; background: var(--tint); border-radius: 28px; padding: 36px; }
.step { display: flex; gap: 16px; align-items: flex-start; font-size: 16px; }
.step-num { flex: 0 0 auto; width: 36px; height: 36px; border-radius: 50%; background: var(--teal); color: #FFFFFF; display: flex; align-items: center; justify-content: center; font-family: var(--heading); font-weight: 600; font-size: 16px; }
.step p { margin-top: 4px; }
.step strong { color: var(--teal); }
.panel-note { padding-top: 18px; border-top: 1px solid #D6E4E9; font-size: 16px; color: var(--body); }

/* Programmes */
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 28px; }
.card { background: #FFFFFF; border-radius: 24px; padding: 36px 32px; display: flex; flex-direction: column; gap: 14px; }
.card h3 { font-weight: 600; font-size: 21px; }
.card p { font-size: 16px; color: var(--body); }
.card-icon { width: 56px; height: 56px; border-radius: 16px; background: var(--teal); display: flex; align-items: center; justify-content: center; }

/* Donate */
.bg-teal h2 { color: #FFFFFF; font-size: clamp(32px, 4vw, 48px); line-height: 1.12; }
.on-teal { color: #DCEBF0; font-size: 18px; }
.donate-row { display: flex; flex-wrap: wrap; gap: 28px; align-items: flex-start; }
.donate-card { background: #FFFFFF; color: var(--ink); border-radius: 28px; padding: 36px; display: flex; flex-direction: column; }
.donate-card.paypal { flex: 1.2 1 420px; min-width: 0; gap: 22px; }
.donate-card.bank { flex: 1 1 380px; min-width: 0; gap: 14px; }
.card-sub { font-size: 15px; color: var(--muted); margin-top: 2px; }
.amounts { display: flex; flex-wrap: wrap; gap: 10px; }
.amount { flex: 1 0 72px; min-height: 52px; padding: 0 14px; border-radius: 14px; border: 2px solid var(--pill); background: #FFFFFF; color: var(--teal); font-family: var(--heading); font-weight: 600; font-size: 17px; cursor: pointer; }
.amount[aria-pressed="true"] { background: var(--teal); border-color: var(--teal); color: #FFFFFF; }
.impact { background: var(--gold-tint); border-radius: 18px; padding: 20px 22px; display: flex; flex-direction: column; gap: 4px; }
.impact-label { font-size: 13px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--gold-text); }
.impact-title { font-family: var(--heading); font-weight: 600; font-size: 19px; color: var(--teal); }
.impact-desc { font-size: 16px; color: var(--body); }
.bank-list { margin: 0; }
.bank-row { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; padding: 12px 0; border-top: 1px solid var(--line); }
.bank-row dt { font-size: 12px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
.bank-row dd { margin: 2px 0 0; font-weight: 700; color: var(--teal); overflow-wrap: anywhere; }
.copy-btn { flex: 0 0 auto; min-height: 44px; min-width: 76px; padding: 0 14px; border-radius: 12px; border: 1.5px solid var(--pill); background: #FFFFFF; color: var(--teal); font-weight: 700; font-size: 14px; cursor: pointer; }

/* Apply */
.apply-info { flex: 1 1 360px; min-width: 0; }
.apply-info h3 { font-weight: 600; font-size: 18px; }
.apply-info p { font-size: 16px; color: var(--body); }
.apply-form { flex: 1.4 1 480px; min-width: 0; background: var(--tint); border-radius: 28px; padding: 36px; display: flex; flex-direction: column; gap: 20px; }
.field-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 20px; }
.field { display: flex; flex-direction: column; gap: 8px; }
.field label { font-weight: 700; font-size: 15px; }
.field input, .field select { min-height: 50px; padding: 0 16px; border-radius: 12px; border: 1.5px solid var(--field); background: #FFFFFF; color: var(--ink); }
.field textarea { padding: 14px 16px; border-radius: 12px; border: 1.5px solid var(--field); background: #FFFFFF; color: var(--ink); resize: vertical; }
.consent { display: flex; gap: 12px; align-items: flex-start; }
.consent input { width: 22px; height: 22px; margin: 2px 0 0; flex: 0 0 auto; accent-color: var(--teal); }
.consent label { font-size: 15px; color: var(--body); }

/* Footer */
.site-footer { background: var(--teal-dark); color: #DCEBF0; }
.site-footer .wrap { padding-top: 56px; padding-bottom: 40px; display: flex; flex-wrap: wrap; gap: 28px; align-items: center; justify-content: space-between; }
.footer-logo { height: 64px; width: auto; display: block; }
.footer-links { display: flex; flex-wrap: wrap; gap: 24px; font-weight: 600; font-size: 15px; }
.footer-links a { color: #FFFFFF; }
.footer-links a:hover { color: #DCEBF0; }
.copyright { flex-basis: 100%; font-size: 14px; color: #B7D0D9; border-top: 1px solid rgba(255,255,255,0.15); padding-top: 24px; }

/* Legal pages */
.legal-header .site-logo { height: 80px; }
@media (max-width: 600px) { .legal-header .site-logo { height: 56px; } }
.legal { max-width: 760px; margin: 0 auto; padding: 72px 24px 96px; display: flex; flex-direction: column; gap: 32px; line-height: 1.65; }
.legal h1 { font-weight: 700; font-size: clamp(34px, 4vw, 46px); line-height: 1.15; }
.legal h2 { font-weight: 600; font-size: 20px; }
.legal-footer { background: var(--teal-dark); color: #B7D0D9; }
.legal-footer .wrap { padding-top: 28px; padding-bottom: 28px; display: flex; flex-wrap: wrap; gap: 20px; justify-content: space-between; font-size: 14px; }
.legal-footer a { color: #FFFFFF; font-weight: 600; }
.back-link { font-weight: 700; font-size: 16px; }
