/* ============================================================
   page-corporate.css — For organisations, the green room (WP-14, the her-site wave
   stage 2; design brief § 5.3, plan § 7.2). Loaded by SiteLayout after the frame
   and the parts sheets, on /corporate.html and /zh/corporate.html only.
   Every colour, face and size is a token from chishan.css :root; no hex here.
   Classes are this page's own (.orgs-…); the shared parts are only placed.
   ============================================================ */

/* ---- Chinese headings, ledes and one-line texts break at her punctuation, never inside
   a word: 茶文化 and 参与者 were split across two lines at some widths, and a line could
   end on one character alone. keep-all leaves the breaks after ，、。 and spaces;
   overflow-wrap still breaks a clause too long for the line, so nothing overflows.
   A paragraph read at length (her answer in the closing band) keeps ordinary Chinese
   breaking: phrase breaks there leave a ragged column of short lines ---- */
:is(.orgs-hero, .orgs-events, .orgs-close, .orgs-faq) :is(h1, h2, h3, .label, .lede, .faq-q-text, .story-summary, .orgs-track-line, .orgs-cta-note):lang(zh) {
  word-break: keep-all; overflow-wrap: anywhere;
}
.orgs-close-a .lede:lang(zh) { word-break: normal; }

/* ---- 1. The hero: her deep green, and in it her photograph (the shine pass,
   2026-11-20). Her words on columns 1–7: label, h1, lede, then her three tracks and
   the call under them; the photograph on columns 8–12, its top level with the h1 and
   its foot on the call's line. A little less air than a section ---- */
.orgs-hero { padding-block: clamp(var(--s-7), 4.5vw, var(--s-8)); }
.orgs-hero-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  grid-template-rows: auto 1fr;
  column-gap: var(--grid-gap);
  align-items: start;
}
.orgs-hero-head { grid-column: 1 / 8; grid-row: 1; max-width: none; margin-bottom: 0; padding-right: var(--s-6); }
.orgs-hero-head .sh-title { max-width: 11em; }
.orgs-hero-head .sh-lede { margin-top: var(--s-6); }

.orgs-hero-offer { grid-column: 1 / 8; grid-row: 2; margin-top: var(--s-6); padding-right: var(--s-6); }
/* With the photograph the call stays inside a 900 px tall first screen at 1440: a step
   less air above the hero, the lede and the tracks */
.orgs-hero:has(.orgs-hero-photo) { padding-top: var(--s-7); }
.orgs-hero-grid:has(.orgs-hero-photo) .orgs-hero-head .sh-lede { margin-top: var(--s-5); }
/* Without a photograph the tracks keep their place beside the head, level with the h1 */
.orgs-hero-grid:not(:has(.orgs-hero-photo)) .orgs-hero-offer {
  grid-column: 8 / 13; grid-row: 1; margin-top: 0; padding-right: 0;
  padding-top: calc(var(--t-label) * var(--lh-label) + var(--s-4));
}
/* The photograph: down by the label's line and its gap, so its top meets the h1's */
.orgs-hero-photo {
  grid-column: 8 / 13; grid-row: 1 / span 2;
  padding-top: calc(var(--t-label) * var(--lh-label) + var(--s-4));
}
/* Her caption (the story's title) and its label: on one line where they fit, else the
   label on the next line, each whole, never broken mid-phrase in a narrow column */
.orgs-hero-photo .photo-cap { flex-wrap: wrap; row-gap: var(--s-1); }
.orgs-hero-photo :is(.photo-cap-text, .photo-cap-end) { flex: 0 0 auto; max-width: 100%; }
.orgs-tracks { list-style: none; border-bottom: 1px solid var(--line-on-green); }
.orgs-track { padding: var(--s-3) 0 var(--s-4); border-top: 1px solid var(--line-on-green); }
.orgs-track-name {
  font-family: var(--display);
  font-size: var(--t-h3); line-height: var(--lh-h3); font-weight: var(--w-h3);
  color: var(--paper);
}
.orgs-track-line {
  margin-top: var(--s-2);
  max-width: var(--measure);
  font-size: var(--t-small); line-height: var(--lh-small);
  color: var(--on-green-soft);
}
.orgs-hero-act { margin-top: var(--s-5); }
.orgs-cta-note {
  margin-top: var(--s-4);
  max-width: var(--measure);
  font-size: var(--t-small); line-height: var(--lh-small);
  color: var(--on-green-soft);
}

/* ---- 2. Past events: three tiles at 4/5, four columns each, hanging level. The
   photographs follow the green at once: a step less air above them than a section ---- */
.orgs-events { padding-top: clamp(var(--s-8), 6vw, var(--s-9)); }
.orgs-tiles {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  column-gap: var(--grid-gap);
  row-gap: var(--s-7);
  align-items: start;
}
/* A label or title that wraps breaks where the sense breaks, never leaving "· 2024"
   or one word alone on a line (the tiles are narrow between 761 and 1079) */
.orgs-tile :is(.story-label, .story-title) { text-wrap: balance; }
/* Two (the hero holds the third): a pair hung at their own shapes, the portrait on five
   columns, the landscape on seven, the PHOTOGRAPHS' feet on one line. Each tile is a
   subgrid of the row's two rows (photo, words), so a longer text under one never lifts
   its photo; without subgrid a tile is a plain stack. */
.orgs-tiles--n2 { grid-template-columns: repeat(12, minmax(0, 1fr)); grid-template-rows: auto auto; row-gap: 0; }
.orgs-tiles--n2 .orgs-tile { display: grid; grid-template-rows: subgrid; grid-row: span 2; row-gap: 0; }
.orgs-tiles--n2 .orgs-tile > .story-media { align-self: end; }
.orgs-tiles--n2 .orgs-tile--tall { grid-column: span 5; }
.orgs-tiles--n2 .orgs-tile--wide { grid-column: span 7; }
.orgs-tiles--n2:not(:has(.orgs-tile--tall)) .orgs-tile,
.orgs-tiles--n2:not(:has(.orgs-tile--wide)) .orgs-tile { grid-column: span 6; }
.orgs-more { margin-top: var(--s-6); }

/* ---- 3. The ending: her question as the closing band's heading on columns 1–7, her
   answer under it; the call and her channels on 9–12 (the .eb grid, chishan-frame.css).
   The question is one voice, at the h2 size, so the band reads as one sentence asked
   and answered, then the button ---- */
.orgs-close-q { max-width: 15em; }
:lang(zh) .orgs-close-q { max-width: none; }
.orgs-close-a { margin-top: var(--s-5); max-width: var(--measure); }
.orgs-close-a .lede { text-wrap: pretty; }
.orgs-close-a .lede + .lede { margin-top: var(--s-4); }

/* ---- 3, the fallback (more than one question): the questions' own section on the
   band directly above the closing band, no padding below it, so the band's own top
   padding is the one gap and the two read as one closing region ---- */
.orgs-faq { padding-bottom: 0; }
.orgs-faq-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--grid-gap);
  align-items: start;
}
.orgs-faq-head { grid-column: 1 / 5; max-width: none; margin-bottom: 0; }
.orgs-faq-list { grid-column: 6 / 13; }
/* Placement only: the band that follows her question starts one spacing step (64 px)
   below it rather than a full section's padding, so the question and the band's call
   read as one closing region (at 390 this is the section padding already) */
.orgs-faq + .eb { padding-top: var(--s-8); }

/* ---- Between the phone and the wide layout ---- */
@media (max-width: 1079px) {
  .orgs-hero-head { grid-column: 1 / -1; padding-right: 0; }
  .orgs-hero-head .sh-title { max-width: none; }
  .orgs-hero-grid:not(:has(.orgs-hero-photo)) .orgs-hero-offer,
  .orgs-hero-offer { grid-column: 1 / 10; grid-row: 2; padding-top: 0; padding-right: 0; margin-top: var(--s-7); }
  /* The head across the top; under it the tracks and the call on seven columns and the
     photograph on five, its top on the first track's line */
  .orgs-hero-grid:has(.orgs-hero-photo) .orgs-hero-offer { grid-column: 1 / 8; }
  .orgs-hero-photo { grid-column: 8 / 13; grid-row: 2; padding-top: 0; margin-top: var(--s-7); }
  /* The events head takes the width it needs: at seven columns her lede ran to four
     short lines over the tiles (it keeps its 34em measure) */
  .orgs-events .sh { max-width: none; }
  /* The ending stacks: at five columns her call wrapped onto two lines in its button.
     The question and answer above, the call and her channels under them */
  .orgs-close .eb-grid { row-gap: var(--s-6); }
  .orgs-close :is(.eb-head, .eb-act) { grid-column: 1 / -1; }
}

/* ---- The phone (≤ 760): one column ---- */
@media (max-width: 760px) {
  .orgs-hero-grid, .orgs-faq-grid { grid-template-columns: minmax(0, 1fr); }
  .orgs-hero-grid:not(:has(.orgs-hero-photo)) .orgs-hero-offer,
  .orgs-hero-head, .orgs-hero-offer, .orgs-faq-head, .orgs-faq-list { grid-column: 1; }
  .orgs-hero-grid:has(.orgs-hero-photo) .orgs-hero-offer { grid-column: 1; }
  .orgs-hero-offer { margin-top: var(--s-6); }
  .orgs-hero-head .sh-lede { margin-top: var(--s-5); }
  .orgs-hero-btn { display: flex; width: 100%; }
  /* The photograph closes the green, edge to edge at 4/3 (Photo's bleedPhone), after
     her words and the button, so the first screen stays hers */
  .orgs-hero-photo { grid-column: 1; grid-row: 3; margin-top: var(--s-7); }
  .orgs-events { padding-top: var(--section-y); }
  .orgs-tiles, .orgs-tiles--n2 { grid-template-columns: minmax(0, 1fr); row-gap: var(--s-7); }
  .orgs-tiles--n2 .orgs-tile, .orgs-tiles--n2 .orgs-tile--tall, .orgs-tiles--n2 .orgs-tile--wide { display: block; grid-column: 1; grid-row: auto; }
  .orgs-faq-head { margin-bottom: var(--s-5); }
}
