/* Derbawka Law — site styles (v4)
   Layout concept: architectural and editorial. One brand typeface at large scale,
   generous white space, fine rules instead of boxes, a black-and-white portrait.
   Navy and aqua appear only in the wordmark and a few fine accents. */

@font-face { font-family: "Hanken Grotesk"; src: url("../fonts/hanken-grotesk-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Hanken Grotesk"; src: url("../fonts/hanken-grotesk-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "Hanken Grotesk"; src: url("../fonts/hanken-grotesk-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: swap; }

:root {
  /* Colour */
  --warm: #f7f7f5;
  --white: #ffffff;
  --ink: #234b78;           /* text: brand navy (was #111111) */
  --charcoal: #2f5079;      /* body text: navy, a touch softer than headings */
  --grey: #5b6f8a;          /* small labels: muted navy, passes 4.5:1 on warm white */
  --rule: #d9d9d6;
  --rule-dark: #2c2c2c;
  --navy: #234b78;          /* brand identifier: lightened from #12263f so it reads as navy, not black */
  --aqua: #38bfc3;          /* brand identifier, never for running text */

  /* Type: Aptos is the brand face; Hanken Grotesk (SIL OFL) is the served substitute */
  --sans: "Aptos", "Aptos Display", "Hanken Grotesk", "Segoe UI", Arial, sans-serif;
  --fs-hero: clamp(3.4rem, 7vw, 7rem);
  --fs-h1: clamp(2.8rem, 5vw, 5rem);
  --fs-h2: clamp(2rem, 3vw, 3.25rem);
  --fs-h3: clamp(1.25rem, 1.1rem + 0.5vw, 1.5rem);
  --fs-lead: clamp(1.2rem, 1.1rem + 0.45vw, 1.45rem);
  --fs-body: clamp(1.0625rem, 1rem + 0.25vw, 1.1875rem);
  --fs-label: 0.8125rem;

  /* Layout */
  --maxw: 1280px;
  --gutter: clamp(20px, 4.5vw, 64px);
  --pad-l: max(var(--gutter), env(safe-area-inset-left, 0px));
  --pad-r: max(var(--gutter), env(safe-area-inset-right, 0px));
  --section: clamp(52px, 6vw, 92px);
  --col-gap: clamp(16px, 2.4vw, 32px);

  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--white);
  color: var(--charcoal);
  font-family: var(--sans);
  font-size: var(--fs-body);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, picture { display: block; max-width: 100%; height: auto; }
p { margin: 0; }
h1, h2, h3 { margin: 0; color: var(--ink); font-weight: 500; text-wrap: balance; }
h1 { font-size: var(--fs-h1); line-height: 1; letter-spacing: -0.025em; }
h2 { font-size: var(--fs-h2); line-height: 1.08; letter-spacing: -0.02em; }
h3 { font-size: var(--fs-h3); line-height: 1.25; letter-spacing: -0.005em; }
ul { margin: 0; padding: 0; list-style: none; }
a { color: inherit; }
a:focus-visible, button:focus-visible { outline: 2px solid var(--navy); outline-offset: 4px; }

.skip-link { position: absolute; left: 12px; top: -60px; z-index: 30; background: var(--ink); color: var(--white); padding: 10px 16px; text-decoration: none; }
.skip-link:focus { top: 12px; }

.container {
  max-width: calc(var(--maxw) + 2 * var(--gutter));
  margin-inline: auto;
  padding-left: var(--pad-l);
  padding-right: var(--pad-r);
}
.grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--col-gap); }
.grid > * { min-width: 0; }

.label {
  font-size: var(--fs-label);
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--grey);
  line-height: 1.4;
}
.lead { font-size: var(--fs-lead); line-height: 1.55; color: var(--charcoal); }
.measure { max-width: 36em; }
.stack { display: flex; flex-direction: column; gap: 24px; }
.uppercase { text-transform: uppercase; }

/* Understated text links */
.text-link {
  display: inline-block;
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink);
  text-decoration: none;
  padding-bottom: 6px;
  background: linear-gradient(var(--ink), var(--ink)) 0 100% / 100% 1px no-repeat;
  transition: background-size 0.35s ease, color 0.2s ease;
}
.text-link:hover { background-image: linear-gradient(var(--aqua), var(--aqua)); background-size: 100% 2px; }
.links { display: flex; flex-wrap: wrap; gap: 14px 36px; }

.placeholder {
  background: #fff4c2;
  color: var(--ink);
  padding: 0 0.25em;
  font-style: normal;
}
.draft-note { border: 1px dashed #b9b9b4; padding: 16px 20px; font-size: 0.95rem; color: var(--charcoal); background: var(--warm); }

/* ——— Header ——— */
.site-header { background: var(--white); border-bottom: 1px solid var(--rule); }
.site-header .container { display: flex; align-items: center; justify-content: space-between; gap: 16px 40px; padding-block: 24px; }
.wordmark { text-decoration: none; font-size: 1.55rem; font-weight: 600; letter-spacing: -0.01em; line-height: 1; white-space: nowrap; }
.wordmark .w1 { color: var(--navy); }
.wordmark .w2 { color: var(--aqua); }
.nav { display: flex; gap: 6px 30px; font-size: 0.92rem; }
.nav a { color: var(--charcoal); text-decoration: none; padding-block: 8px; border-bottom: 1px solid transparent; transition: color 0.2s ease, border-color 0.2s ease; }
.nav a:hover { color: var(--ink); border-bottom-color: var(--rule); }
.nav a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--aqua); }
.menu-button { display: none; font: inherit; font-size: 0.85rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink); background: none; border: 1px solid var(--ink); padding: 10px 16px; min-height: 44px; cursor: pointer; }

/* ——— Home hero ——— */
.hero { background: var(--warm); }
.hero .container { padding-block: clamp(56px, 7vw, 104px) clamp(64px, 8vw, 120px); }
.hero__grid { display: grid; grid-template-columns: minmax(0, 56fr) minmax(0, 44fr); gap: clamp(32px, 5vw, 80px); align-items: center; }
.hero__text { display: flex; flex-direction: column; gap: 32px; }
.hero__label { display: flex; align-items: center; gap: 14px; }
.hero__label::before { content: ""; width: 28px; height: 2px; background: var(--aqua); flex: none; }
.hero h1 { font-size: var(--fs-hero); font-weight: 600; line-height: 1; letter-spacing: -0.03em; }
.hero h1 span { display: block; }
.hero__support { font-size: var(--fs-lead); line-height: 1.55; max-width: 31em; color: var(--charcoal); }
.hero__plate { margin: 0; }
.hero__plate img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; object-position: 50% 22%; background: #d6d6d3; }
/* Home hero with the Vancouver skyline as a full-width background */
.hero--city { position: relative; isolation: isolate; overflow: hidden; background: #1a1a1a; color: var(--white);
  min-height: min(88vh, 860px); display: flex; align-items: flex-end; }
.hero--city > .container { width: 100%; }
.hero__bg { position: absolute; inset: 0; z-index: -1; }
.hero__bg picture, .hero__bg img { display: block; width: 100%; height: 100%; }
.hero__bg img { object-fit: cover; object-position: 50% 52%; }
.hero__bg::after { content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(0,0,0,.74) 0%, rgba(0,0,0,.52) 45%, rgba(0,0,0,.12) 80%),
              linear-gradient(0deg, rgba(0,0,0,.45) 0%, rgba(0,0,0,0) 45%); }
.hero--city .hero__grid { grid-template-columns: minmax(0, 1fr); }
.hero--city .hero__text { max-width: 760px; }
.hero--city .label { color: rgba(255,255,255,.82); }
.hero--city h1 { color: var(--white); }
.hero--city .hero__support { color: rgba(255,255,255,.9); }
.hero--city .text-link { color: var(--white); background-image: linear-gradient(var(--white), var(--white)); }
.hero--city .text-link:hover { background-image: linear-gradient(var(--aqua), var(--aqua)); }
@media (max-width: 860px) {
  .hero--city { min-height: 0; }
  .hero--city > .container { padding-top: clamp(220px, 58vw, 360px); }
  .hero__bg img { object-position: 55% 50%; }
  .hero__bg::after { background: linear-gradient(0deg, rgba(0,0,0,.82) 0%, rgba(0,0,0,.66) 55%, rgba(0,0,0,.1) 85%); }
}
.plate-caption { display: flex; justify-content: space-between; gap: 12px; padding-top: 14px; margin-top: 16px; border-top: 1px solid var(--ink); font-size: 0.85rem; color: var(--grey); }
.plate-caption strong { color: var(--ink); font-weight: 500; }

@media (prefers-reduced-motion: no-preference) {
  .rise { animation: rise 1s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
  .rise--2 { animation-delay: 0.12s; }
  .rise--3 { animation-delay: 0.24s; }
}
@keyframes rise { from { opacity: 0.3; transform: translateY(12px); } }

/* ——— Sections ——— */
.section { padding-block: var(--section); }
.section--warm { background: var(--warm); }
.section--ink { background: #16304f; color: #dde4ee; }
.section--ink h2, .section--ink h3 { color: var(--white); }
.section--ink .label { color: #a9b8cc; }
.section--ink .text-link { color: var(--white); background-image: linear-gradient(var(--white), var(--white)); }

/* Large editorial statement: heading wide, copy offset to the right */
.statement { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--col-gap); row-gap: 24px; align-items: start; }
.statement h2 { grid-column: 1 / span 6; font-size: clamp(2.1rem, 1.3rem + 2.8vw, 3.8rem); line-height: 1.02; letter-spacing: -0.03em; }
.statement .copy { grid-column: 7 / span 6; padding-top: 6px; }
.statement .copy p { font-size: var(--fs-lead); line-height: 1.6; }

/* Three columns separated by fine rules */
.columns { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--ink); }
.columns > * { min-width: 0; padding: 28px clamp(20px, 2.6vw, 40px) 4px; border-left: 1px solid var(--rule); display: flex; flex-direction: column; gap: 16px; }
.columns > *:first-child { border-left: 0; padding-left: 0; }
.columns h3 { font-size: clamp(1.3rem, 1.1rem + 0.7vw, 1.75rem); font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; }
.columns p { color: var(--charcoal); }

.section-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px 40px; margin-bottom: clamp(24px, 3vw, 40px); }
.section-head .stack { gap: 14px; }

/* Two-part layout: heading left, copy right */
.split { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--col-gap); row-gap: 32px; }
.split > :first-child { grid-column: 1 / span 5; }
.split > :last-child { grid-column: 7 / span 6; }

.tagline { display: flex; flex-direction: column; gap: 2px; margin-top: 12px; }
.tagline span { font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2.25rem); font-weight: 500; line-height: 1.2; letter-spacing: -0.015em; color: var(--navy); }
.section--ink .tagline span { color: var(--white); }

/* ——— Inner page heads ——— */
.page-head { background: var(--warm); border-bottom: 1px solid var(--rule); }
.page-head .container { padding-block: clamp(44px, 5vw, 76px) clamp(36px, 4vw, 60px); display: flex; flex-direction: column; gap: 22px; }
.page-head h1 { font-weight: 600; letter-spacing: -0.025em; max-width: 18ch; }
.page-head h1 span { display: block; }
.page-head .lead { max-width: 40em; }

/* Rows separated by fine rules */
.rows { border-top: 1px solid var(--ink); }
.rows > li, .rows > div { padding-block: 20px; border-bottom: 1px solid var(--rule); }
.rows--text > li { font-size: var(--fs-lead); line-height: 1.45; color: var(--ink); }
.rows--table > li { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 10fr); column-gap: var(--col-gap); row-gap: 6px; align-items: baseline; }
.rows--table .when { font-size: 0.95rem; font-weight: 500; color: var(--ink); font-variant-numeric: tabular-nums; }
.rows--table .what { display: flex; flex-direction: column; gap: 4px; }
.rows--table .what strong { color: var(--ink); font-weight: 500; font-size: var(--fs-lead); line-height: 1.35; }
.rows--table .what span { color: var(--grey); font-size: 0.95rem; }

/* Matters: three columns of short items */
.matters { columns: 3; column-gap: clamp(24px, 3vw, 56px); border-top: 1px solid var(--ink); padding-top: 8px; }
.matters li { break-inside: avoid; padding-block: 14px; border-bottom: 1px solid var(--rule); color: var(--ink); }
.small-note { font-size: 0.95rem; color: var(--grey); }

/* Janet Derbawka page */
.section--ruled { border-block: 1px solid var(--rule); }
#areas-title { color: var(--navy); }
/* Home: practice-area boxes: soft grey panels with navy titles */
.area-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(14px, 1.6vw, 22px); }
.area-card { background: #eceef0; border-top: 2px solid var(--navy); padding: clamp(28px, 3.2vw, 44px); display: flex; flex-direction: column; gap: 16px; }
.area-card h3 { color: var(--navy); font-size: clamp(1.2rem, 1.05rem + 0.6vw, 1.55rem); font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; }
.area-card p { color: var(--charcoal); flex: 1; max-width: 40em; }
.area-card .text-link { align-self: flex-start; margin-top: 8px; }
.area-card .text-link, .text-link--aqua { color: var(--aqua); font-weight: 600; background-image: linear-gradient(var(--aqua), var(--aqua)); }
.area-card .text-link:hover, .text-link--aqua:hover { color: var(--navy); background-image: linear-gradient(var(--navy), var(--navy)); }
@media (max-width: 700px) { .area-cards { grid-template-columns: minmax(0, 1fr); } }

/* Heading on the left, bulleted list on the right */
.listing { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--col-gap); row-gap: 20px; align-items: start; }
.listing h2 { grid-column: 1 / span 4; font-size: clamp(1.9rem, 1.3rem + 1.8vw, 3rem); line-height: 1.1; letter-spacing: -0.02em; }
.listing__body { grid-column: 5 / span 8; display: flex; flex-direction: column; gap: 18px; padding-top: 6px; }
.listing__body > p { font-size: var(--fs-lead); line-height: 1.5; color: var(--ink); }
.bullets { margin: 0; padding-left: 1.6em; list-style: disc; display: flex; flex-direction: column; gap: 6px; }
.bullets li { font-size: var(--fs-lead); line-height: 1.5; color: var(--ink); padding-left: 0.2em; }
.bullets li::marker { color: var(--ink); }
.bullets--spaced { gap: 22px; }
@media (max-width: 860px) {
  .listing h2, .listing__body { grid-column: 1 / -1; }
}
.profile { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--col-gap); row-gap: 32px; align-items: start; }
.profile__plate { grid-column: 8 / span 5; grid-row: 1; margin: 0; }
.profile__plate img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; object-position: 50% 30%; }
.profile__body { grid-column: 1 / span 6; grid-row: 1; display: flex; flex-direction: column; gap: 22px; padding-top: 8px; }
.profile__body p:first-child { font-size: var(--fs-lead); line-height: 1.55; color: var(--ink); }

.facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: var(--col-gap); border-top: 1px solid var(--ink); }
.facts > div { padding-block: 24px; display: flex; flex-direction: column; gap: 12px; }
.facts > div + div { border-left: 1px solid var(--rule); padding-left: clamp(20px, 2.6vw, 40px); }
.facts dl { margin: 0; display: flex; flex-direction: column; gap: 14px; }
.facts dt { color: var(--ink); font-weight: 500; }
.facts .facts__sub { margin-top: 18px; }
.facts dd { margin: 0; color: var(--charcoal); }

/* Contact */
.contact { border-top: 1px solid var(--ink); }
.contact > div { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 9fr); column-gap: var(--col-gap); row-gap: 6px; padding-block: 26px; border-bottom: 1px solid var(--rule); align-items: baseline; }
.contact dt { }
.contact dd { margin: 0; font-size: var(--fs-lead); line-height: 1.45; color: var(--ink); overflow-wrap: anywhere; }
.contact dd a { text-decoration: none; border-bottom: 1px solid var(--rule); }
.contact dd a:hover { border-bottom-color: var(--aqua); }
.notice { font-size: 0.95rem; color: var(--grey); max-width: 42em; }

/* Legal pages */
.prose { max-width: 40em; display: flex; flex-direction: column; gap: 18px; }
.prose h2 { font-size: var(--fs-h3); font-weight: 600; margin-top: 20px; }
.prose h3 { font-size: 1.1rem; font-weight: 600; letter-spacing: 0; text-transform: none; margin-top: 8px; }

/* Recognition badges: hidden until properly licensed artwork is added */
.badges { display: flex; flex-wrap: wrap; gap: 24px; margin-top: 40px; }
.badges:empty { display: none; }
.badges img { height: 120px; width: auto; }

/* ——— Footer ——— */
.site-footer { background: var(--warm); color: var(--charcoal); font-size: 0.92rem; border-top: 1px solid var(--rule); }
.site-footer .container { padding-block: 52px 32px; display: flex; flex-direction: column; gap: 36px; }
.footer-top { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--col-gap); row-gap: 36px; }
.footer-brand { grid-column: 1 / span 5; display: flex; flex-direction: column; gap: 14px; }
.footer-col { grid-column: span 3; display: flex; flex-direction: column; gap: 8px; }
.footer-col:last-child { grid-column: span 4; }
.site-footer a { color: var(--ink); text-decoration: none; }
.site-footer a:hover { text-decoration: underline; text-decoration-color: var(--aqua); text-underline-offset: 4px; }
.site-footer .label { color: var(--grey); margin-bottom: 6px; }
.site-footer address { font-style: normal; }
.footer-legal { border-top: 1px solid var(--rule); padding-top: 24px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 32px; font-size: 0.82rem; color: var(--grey); }
.footer-legal nav { display: flex; gap: 24px; }

/* ——— Responsive ——— */
@media (max-width: 1100px) {
  .nav { gap: 6px 22px; font-size: 0.88rem; }
}
@media (max-width: 960px) {
  .js .menu-button { display: inline-block; }
  .site-header .container { flex-wrap: wrap; }
  .js .nav { display: none; }
  .js .nav.is-open { display: flex; }
  .nav { flex-basis: 100%; flex-direction: column; gap: 0; border-top: 1px solid var(--rule); margin-top: 8px; }
  .nav a { padding-block: 15px; border-bottom: 1px solid var(--rule); font-size: 1.05rem; }
  .nav a[aria-current="page"] { border-bottom-color: var(--rule); font-weight: 600; }
}
@media (max-width: 860px) {
  .hero__grid { grid-template-columns: minmax(0, 1fr); }
  .hero__plate { max-width: 520px; }
  .statement h2, .statement .copy, .split > :first-child, .split > :last-child,
  .profile__plate, .profile__body, .footer-brand, .footer-col, .footer-col:last-child { grid-column: 1 / -1; }
  .profile__plate { max-width: 520px; }
  .profile__plate, .profile__body { grid-row: auto; }
  .columns { grid-template-columns: minmax(0, 1fr); }
  .columns > * { border-left: 0; padding-left: 0; padding-right: 0; border-bottom: 1px solid var(--rule); padding-bottom: 32px; }
  .matters { columns: 2; }
  .facts { grid-template-columns: minmax(0, 1fr); }
  .facts > div + div { border-left: 0; padding-left: 0; border-top: 1px solid var(--rule); }
  .rows--table > li, .contact > div { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 560px) {
  .matters { columns: 1; }
  .wordmark { font-size: 1.35rem; }
  body { font-size: 1.0625rem; }
}
