/* Dunhaven Bank — a fictional bank for the ICE BREAKER game (docs/DUNHAVEN.md).
   Established/traditional look: navy + gold, serif display, warm paper. No real
   bank's branding; everything here is invented. The site collects nothing: see
   app.js (every form fails in the browser, nothing is sent). */

:root {
  --navy:   #0e2742;
  --navy-2: #16395e;
  --navy-3: #0a1d33;
  --gold:   #b6912f;
  --gold-2: #cdac4e;
  --ink:    #1c2530;
  --muted:  #5c6775;
  --paper:  #ffffff;
  --mist:   #f5f2ea;
  --mist-2: #efe9db;
  --line:   #e2dccd;
  --line-2: #d3ccba;
  --ok:     #1f7a4d;
  --bad:    #a3271f;
  --maxw:   1140px;
  --radius: 4px;
  --shadow: 0 1px 2px rgba(14, 39, 66, .06), 0 8px 24px rgba(14, 39, 66, .08);
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: "Source Sans 3", system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  color: var(--ink);
  background: var(--paper);
  font-size: 17px;
  line-height: 1.6;
}

h1, h2, h3, .display { font-family: "Playfair Display", Georgia, "Times New Roman", serif; font-weight: 600; color: var(--navy); line-height: 1.15; }
h1 { font-size: clamp(2rem, 4.2vw, 3.3rem); letter-spacing: -.01em; }
h2 { font-size: clamp(1.5rem, 2.8vw, 2.1rem); margin: 0 0 .5rem; }
h3 { font-size: 1.22rem; margin: 0 0 .35rem; }
p { margin: 0 0 1rem; }
a { color: var(--navy-2); text-decoration: none; }
a:hover { text-decoration: underline; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.center { text-align: center; }
.muted { color: var(--muted); }
.small { font-size: .86rem; }

/* ---- buttons ---- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  font: inherit; font-weight: 600; cursor: pointer;
  padding: .7rem 1.4rem; border-radius: var(--radius);
  border: 1px solid transparent; transition: background .15s, border-color .15s, color .15s;
  text-decoration: none; white-space: nowrap; line-height: 1.2;
}
.mast .actions .btn { padding: .58rem 1.05rem; font-size: .92rem; }
.btn:hover { text-decoration: none; }
.btn-gold { background: var(--gold); color: #2a2206; border-color: var(--gold); }
.btn-gold:hover { background: var(--gold-2); border-color: var(--gold-2); }
.btn-navy { background: var(--navy); color: #fff; border-color: var(--navy); }
.btn-navy:hover { background: var(--navy-2); border-color: var(--navy-2); }
.btn-ghost { background: transparent; color: var(--navy); border-color: var(--line-2); }
.btn-ghost:hover { background: var(--mist); }
.btn-block { width: 100%; }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .6; cursor: not-allowed; }

/* ---- top utility bar ---- */
.util {
  background: var(--navy-3); color: #c9d4e2; font-size: .82rem;
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.util .wrap { display: flex; align-items: center; gap: 20px; height: 38px; }
.util a { color: #c9d4e2; }
.util a:hover { color: #fff; }
.util .spacer { flex: 1; }
.util .seg { display: inline-flex; gap: 2px; background: rgba(255,255,255,.06); border-radius: 3px; padding: 2px; }
.util .seg a { padding: 2px 10px; border-radius: 2px; }
.util .seg a.on { background: var(--gold); color: #2a2206; font-weight: 600; }
.util .phone { color: #fff; font-weight: 600; }

/* ---- masthead ---- */
.mast { background: var(--paper); border-bottom: 1px solid var(--line); }
.mast .wrap { display: flex; align-items: center; gap: 28px; min-height: 84px; }
.brand { display: flex; align-items: center; gap: 13px; }
.brand svg { height: 46px; width: auto; flex: none; }
.brand .word { display: flex; flex-direction: column; line-height: 1; }
.brand .name { font-family: "Playfair Display", Georgia, serif; font-weight: 600; font-size: 1.5rem; color: var(--navy); letter-spacing: .02em; }
.brand .tag { font-size: .62rem; letter-spacing: .34em; text-transform: uppercase; color: var(--gold); margin-top: 5px; }
.mast nav { display: flex; gap: 22px; margin-left: auto; }
.mast nav a { color: var(--ink); font-weight: 600; font-size: .96rem; padding: 6px 0; border-bottom: 2px solid transparent; }
.mast nav a:hover { color: var(--navy); border-color: var(--gold); text-decoration: none; }
.mast .actions { display: flex; align-items: center; gap: 12px; margin-left: 8px; }

/* ---- hero ---- */
.hero { background: linear-gradient(180deg, var(--navy) 0%, var(--navy-3) 100%); color: #eaf0f7; position: relative; overflow: hidden; }
.hero::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(900px 400px at 85% -10%, rgba(182,145,47,.22), transparent 60%);
  pointer-events: none;
}
.hero .wrap { display: grid; grid-template-columns: 1.3fr .9fr; gap: 48px; padding-top: 64px; padding-bottom: 64px; align-items: center; position: relative; z-index: 1; }
.hero h1 { color: #fff; margin: 0 0 .6rem; }
.hero .kicker { color: var(--gold-2); font-weight: 700; letter-spacing: .18em; text-transform: uppercase; font-size: .76rem; margin-bottom: 1rem; }
.hero p.lede { font-size: 1.16rem; color: #c7d3e2; max-width: 34ch; }
.hero .cta { display: flex; gap: 14px; margin-top: 1.6rem; flex-wrap: wrap; }

/* login card on hero */
.loginbox { background: var(--paper); color: var(--ink); border-radius: 6px; box-shadow: var(--shadow); border-top: 4px solid var(--gold); overflow: hidden; }
.loginbox .hd { background: var(--mist); padding: 14px 20px; border-bottom: 1px solid var(--line); font-family: "Playfair Display", serif; color: var(--navy); font-size: 1.12rem; font-weight: 600; }
.loginbox form { padding: 20px; }
.loginbox .lock { color: var(--muted); font-size: .8rem; display: flex; align-items: center; gap: 6px; margin-top: 12px; justify-content: center; }

/* ---- forms ---- */
label { display: block; font-weight: 600; font-size: .9rem; margin: 0 0 5px; color: var(--ink); }
.field { margin-bottom: 14px; }
input[type=text], input[type=password], input[type=email], input[type=tel], input[type=number], select, textarea {
  width: 100%; font: inherit; color: var(--ink);
  padding: .62rem .7rem; border: 1px solid var(--line-2); border-radius: var(--radius);
  background: #fff; transition: border-color .15s, box-shadow .15s;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--navy-2); box-shadow: 0 0 0 3px rgba(22,57,94,.12); }
textarea { min-height: 130px; resize: vertical; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.check { display: flex; align-items: center; gap: 8px; font-weight: 400; font-size: .92rem; }
.check input { width: auto; }
.hint { font-size: .82rem; color: var(--muted); margin-top: 4px; }

/* alert banners (for the fail states) */
.alert { border-radius: var(--radius); padding: .8rem 1rem; margin-bottom: 1rem; font-size: .92rem; display: flex; gap: 10px; align-items: flex-start; }
.alert-bad { background: #fbeceb; border: 1px solid #e7c3c0; color: #7e2019; }
.alert-bad strong { color: #7e2019; }
.alert svg { flex: none; margin-top: 2px; }
[hidden] { display: none !important; }

/* ---- generic sections ---- */
.section { padding: 64px 0; }
.section.mist { background: var(--mist); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section .head { max-width: 62ch; margin: 0 auto 2.4rem; text-align: center; }
.section .head p { color: var(--muted); font-size: 1.05rem; }
.eyebrow { color: var(--gold); font-weight: 700; letter-spacing: .16em; text-transform: uppercase; font-size: .74rem; }
.rule { width: 54px; height: 3px; background: var(--gold); margin: 10px auto 18px; border: 0; }
.rule.left { margin-left: 0; }

/* trust strip */
.trust { background: var(--mist-2); border-bottom: 1px solid var(--line); }
.trust .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 14px 40px; padding: 16px 24px; }
.trust .item { display: flex; align-items: center; gap: 9px; color: var(--navy); font-weight: 600; font-size: .9rem; }
.trust .item svg { color: var(--gold); flex: none; }
.trust .sep { width: 1px; height: 22px; background: var(--line-2); }

/* cards */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.card { background: #fff; border: 1px solid var(--line); border-radius: 6px; padding: 28px; transition: box-shadow .15s, transform .15s, border-color .15s; }
.card:hover { box-shadow: var(--shadow); border-color: var(--line-2); transform: translateY(-2px); }
.card .ico { width: 46px; height: 46px; border-radius: 50%; background: var(--navy); color: var(--gold-2); display: flex; align-items: center; justify-content: center; margin-bottom: 16px; }
.card a.more { font-weight: 700; color: var(--navy-2); display: inline-flex; align-items: center; gap: 5px; }
.card a.more::after { content: "\2192"; transition: transform .15s; }
.card:hover a.more::after { transform: translateX(3px); }

/* rates table */
.rates { width: 100%; border-collapse: collapse; background: #fff; border: 1px solid var(--line); border-radius: 6px; overflow: hidden; }
.rates th, .rates td { padding: 14px 18px; text-align: left; border-bottom: 1px solid var(--line); }
.rates thead th { background: var(--navy); color: #fff; font-weight: 600; font-size: .86rem; letter-spacing: .02em; }
.rates tbody tr:last-child td { border-bottom: 0; }
.rates .apy { font-family: "Playfair Display", serif; font-size: 1.5rem; color: var(--navy); font-weight: 600; }
.rates td .term { color: var(--muted); font-size: .86rem; }

/* heritage stat band */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; text-align: center; }
.stats .n { font-family: "Playfair Display", serif; font-size: 2.4rem; color: var(--gold); line-height: 1; }
.stats .l { color: var(--muted); font-size: .9rem; margin-top: 6px; }

/* split feature */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.split .art { border-radius: 8px; overflow: hidden; box-shadow: var(--shadow); }
.split .art svg, .split .art img { display: block; width: 100%; height: auto; }

/* cta band */
.ctaband { background: var(--navy); color: #fff; }
.ctaband .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 40px 24px; flex-wrap: wrap; }
.ctaband h2 { color: #fff; margin: 0; }
.ctaband p { color: #c7d3e2; margin: .3rem 0 0; }

/* page header (interior pages) */
.phead { background: linear-gradient(180deg, var(--navy) 0%, var(--navy-2) 100%); color: #fff; padding: 46px 0; }
.phead h1 { color: #fff; margin: 0; }
.phead p { color: #c7d3e2; margin: .5rem 0 0; max-width: 60ch; }
.phead .crumbs { font-size: .82rem; color: #9fb2c7; margin-bottom: .7rem; }
.phead .crumbs a { color: #c9d9ea; }

/* product list rows */
.prod { display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: center; background: #fff; border: 1px solid var(--line); border-radius: 6px; padding: 24px 28px; margin-bottom: 18px; }
.prod h3 { margin-bottom: .25rem; }
.prod .feat { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 10px; color: var(--muted); font-size: .9rem; }
.prod .feat span { display: inline-flex; align-items: center; gap: 6px; }
.prod .feat svg { color: var(--gold); }

/* auth page */
.authpage { background: var(--mist); min-height: 60vh; padding: 56px 0; }
.authcard { max-width: 430px; margin: 0 auto; background: #fff; border: 1px solid var(--line); border-top: 4px solid var(--gold); border-radius: 6px; box-shadow: var(--shadow); }
.authcard .hd { padding: 22px 28px 0; }
.authcard .bd { padding: 8px 28px 28px; }
.authcard .ft { background: var(--mist); border-top: 1px solid var(--line); padding: 16px 28px; font-size: .88rem; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }

/* contact layout */
.contactgrid { display: grid; grid-template-columns: 1.3fr .9fr; gap: 48px; align-items: start; }
.infocard { background: var(--mist); border: 1px solid var(--line); border-radius: 6px; padding: 26px; }
.infocard .line { display: flex; gap: 12px; margin-bottom: 16px; }
.infocard .line svg { color: var(--gold); flex: none; margin-top: 3px; }
.infocard .line b { color: var(--navy); display: block; }

/* ---- footer ---- */
footer.site { background: var(--navy-3); color: #aebdce; font-size: .9rem; }
footer.site .cols { display: grid; grid-template-columns: 1.4fr repeat(4, 1fr); gap: 32px; padding: 48px 0 36px; }
footer.site h4 { color: #fff; font-family: "Source Sans 3", sans-serif; font-size: .82rem; letter-spacing: .12em; text-transform: uppercase; margin: 0 0 14px; }
footer.site a { color: #aebdce; display: block; padding: 4px 0; }
footer.site a:hover { color: #fff; }
footer.site .fbrand { display: flex; align-items: center; gap: 11px; margin-bottom: 14px; }
footer.site .fbrand svg { height: 38px; }
footer.site .fbrand .name { font-family: "Playfair Display", serif; font-size: 1.2rem; color: #fff; }
footer.site .badges { display: flex; gap: 16px; align-items: center; margin-top: 18px; color: #8a9bb0; }
footer.site .badges svg { color: var(--gold); }
footer.site .legal { border-top: 1px solid rgba(255,255,255,.08); padding: 22px 0 36px; color: #7e8ea2; font-size: .8rem; line-height: 1.7; }
footer.site .legal a { display: inline; color: #9fb0c4; }

/* ---- responsive ---- */
@media (max-width: 920px) {
  .hero .wrap, .split, .contactgrid { grid-template-columns: 1fr; }
  .cards, .stats { grid-template-columns: 1fr 1fr; }
  footer.site .cols { grid-template-columns: 1fr 1fr; }
  .mast nav { display: none; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .cards, .stats, .row2, footer.site .cols { grid-template-columns: 1fr; }
  .util .wrap { gap: 12px; overflow-x: auto; }
  .util .hide-sm { display: none; }
  .section { padding: 44px 0; }
  .prod { grid-template-columns: 1fr; }
  .mast .wrap { gap: 14px; }
  .mast .actions .btn-gold { display: none; }   /* keep just Log In; no horizontal overflow */
  .brand .name { font-size: 1.28rem; }
  .brand svg { height: 40px; }
  .hero .wrap { padding-top: 40px; padding-bottom: 40px; }
}
