/* Orivam - public surface.
   One stylesheet, no framework, no build step. Institutional-research look:
   near-black ink, hairline rules, generous whitespace, tabular figures, and a
   single accent used sparingly, so that where it does appear it means something
   (a link, a primary action, a positive number).

   Every colour is a token. The price chart is inline SVG painted with the
   same variables, so it follows the theme without a line of its own.

   Type is Inter where the CDN answers and the system UI stack where it does
   not; no part of the layout depends on the webfont arriving. */

:root {
  color-scheme: light;   /* light only - the product is a white surface */

  /* ink */
  --ink:        #0b1220;
  --ink-soft:   #5a6478;
  /* 5.3:1 on white, 5.0:1 on a card, 4.8:1 on a sunken well -- AA on all
     three surfaces it actually appears on. The original #8b94a6 measured
     2.9:1, which fails badly for the small text this is used on:
     timestamps, captions, the byline under a note. Picked to be read rather
     than to look delicate. */
  --ink-faint:  #626b80;

  /* surfaces */
  --bg:         #ffffff;
  --bg-soft:    #f7f8fa;
  --bg-sunken:  #f1f3f7;

  /* lines */
  --line:        #e4e7ee;
  --line-strong: #cfd4de;

  /* accent - deep institutional green. Dark enough that white text sits on
     it at 7.6:1, which is why `--on-accent` is white here and near-black in
     the dark theme: the button text has to follow the button. */
  --accent:        #0d5c3b;
  --accent-hover:  #0a4a2f;
  --accent-bright: #18a06a;
  --accent-wash:   #eef6f1;
  --on-accent:     #ffffff;

  /* semantics */
  --positive: #10714b;
  --negative: #a32330;
  --neutral:  #5a6478;
  --high:     #8a5300;
  --info:     #1e40af;

  /* washes behind status pills. Tokens rather than literals: these were
     twenty-five pastel hexes spread across two stylesheets, every one a
     theme assumption that had to be found by hand. Keeping them as tokens is
     what made going black, and coming back, a single block. */
  --wash-positive: #edf8f3;  --edge-positive: #b9e2ce;
  --wash-negative: #fdf0f1;  --edge-negative: #f0c4c8;
  --wash-high:     #fdf6e7;  --edge-high:     #eedcb0;
  --wash-info:     #eef3ff;  --edge-info:     #bfd0f7;

  --radius:    10px;
  --radius-sm: 6px;
  --radius-lg: 16px;

  --shadow:    0 1px 2px rgba(11, 18, 32, .06), 0 8px 24px -12px rgba(11, 18, 32, .18);
  --shadow-lg: 0 2px 4px rgba(11, 18, 32, .05), 0 24px 56px -24px rgba(11, 18, 32, .28);

  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  --shell: 1120px;   /* nav, footer, wide pages */
  --read:  760px;    /* anything meant to be read as prose */

  /* icons, inline so the page makes no extra requests, stroked in the ink
     colours so they follow the theme rather than assuming one */
  --icon-search: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235a6478' stroke-width='2.2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='M20 20l-3.5-3.5'/%3E%3C/svg%3E");
  --icon-check: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230d5c3b' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6L9 17l-5-5'/%3E%3C/svg%3E");
  --icon-lock: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23626b80' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='4' y='10' width='16' height='11' rx='2'/%3E%3Cpath d='M8 10V7a4 4 0 018 0v3'/%3E%3C/svg%3E");
}

*, *::before, *::after { box-sizing: border-box; }

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

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

/* Figures line up in columns wherever they appear. */
time, .isin, .tile-value, .stat-value, .numbers .value, .right, .tabular {
  font-variant-numeric: tabular-nums;
}

a { color: var(--accent); text-underline-offset: 2px; }
a:hover { color: var(--accent-hover); }

h1, h2, h3, h4 { letter-spacing: -0.021em; line-height: 1.22; margin: 0; font-weight: 640; }

::selection { background: var(--accent); color: var(--on-accent); }

:focus-visible { outline: 2px solid var(--accent-bright); outline-offset: 2px; border-radius: 3px; }

main { max-width: var(--shell); margin: 0 auto; padding: 2.25rem 1.5rem 4.5rem; }
main.reading { max-width: var(--read); }

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--accent); color: var(--on-accent); padding: .7rem 1.1rem;
  border-radius: 0 0 var(--radius) 0; font-weight: 600; text-decoration: none;
}
.skip-link:focus { left: 0; color: var(--on-accent); }

/* ---------------------------- header ---------------------------- */

header.site {
  position: sticky; top: 0; z-index: 40;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}
@supports (backdrop-filter: blur(1px)) {
  header.site {
    background: color-mix(in srgb, var(--bg) 86%, transparent);
    backdrop-filter: saturate(180%) blur(14px);
  }
}
.site-inner {
  max-width: var(--shell); margin: 0 auto;
  display: flex; align-items: center; gap: 1.25rem;
  padding: .85rem 1.5rem;
}

.brand { text-decoration: none; color: inherit; display: flex; align-items: baseline; gap: .55rem; flex: 0 0 auto; }
.brand-name { font-size: 1.32rem; font-weight: 700; letter-spacing: -0.035em; color: var(--ink); }
.brand-name::after {
  content: ""; display: inline-block;
  width: 5px; height: 5px; border-radius: 50%;
  background: var(--accent-bright); margin-left: 3px; vertical-align: 3px;
}
.brand-tag { font-size: .74rem; color: var(--ink-faint); font-weight: 500; white-space: nowrap; }
@media (max-width: 900px) { .brand-tag { display: none; } }

form.search { display: flex; flex: 1 1 auto; max-width: 420px; position: relative; }
form.search input {
  width: 100%; padding: .55rem .85rem .55rem 2.2rem; font: inherit; font-size: .9rem;
  border: 1px solid var(--line); border-radius: 999px;
  background: var(--bg-soft); color: var(--ink); transition: border-color .15s, background .15s;
}
form.search input::placeholder { color: var(--ink-faint); }
form.search input:focus { background: var(--bg); border-color: var(--line-strong); }
form.search::before {
  content: ""; position: absolute; left: .8rem; top: 50%; width: 15px; height: 15px;
  transform: translateY(-50%); pointer-events: none; opacity: .5; background: currentColor;
  -webkit-mask: var(--icon-search) center / contain no-repeat;
  mask: var(--icon-search) center / contain no-repeat;
}
form.search button {
  position: absolute; right: 4px; top: 50%; transform: translateY(-50%);
  padding: .32rem .8rem; font: inherit; font-size: .8rem; font-weight: 600; cursor: pointer;
  border: 0; border-radius: 999px; background: var(--ink); color: var(--bg);
}
form.search button:hover { background: var(--accent); color: var(--on-accent); }

.public-nav { display: flex; gap: 1.35rem; align-items: center; margin-left: auto; }
.public-nav a {
  color: var(--ink-soft); text-decoration: none; font-size: .875rem; font-weight: 550; white-space: nowrap;
}
.public-nav a:hover { color: var(--ink); }
.public-nav a.cta {
  color: var(--on-accent); background: var(--accent); border-radius: 999px;
  padding: .48rem 1.05rem; box-shadow: var(--shadow);
  transition: background .15s, transform .15s;
}
.public-nav a.cta:hover { background: var(--accent-hover); color: var(--on-accent); transform: translateY(-1px); }

@media (max-width: 760px) {
  .site-inner { flex-wrap: wrap; row-gap: .75rem; }
  form.search { order: 3; flex-basis: 100%; max-width: none; }
  .public-nav { gap: 1rem; }
}

/* ---------------------------- buttons ---------------------------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .45rem;
  font: inherit; font-size: .925rem; font-weight: 600; line-height: 1;
  padding: .78rem 1.4rem; border-radius: var(--radius); cursor: pointer;
  text-decoration: none; border: 1px solid transparent;
  transition: background .15s, border-color .15s, transform .15s, color .15s;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: var(--on-accent); box-shadow: var(--shadow); }
.btn-primary:hover { background: var(--accent-hover); color: var(--on-accent); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line-strong); }
.btn-ghost:hover { border-color: var(--ink); color: var(--ink); }
.btn-light { background: var(--accent); color: var(--on-accent); box-shadow: var(--shadow); }
.btn-light:hover { background: var(--accent-hover); color: var(--on-accent); }
.btn-block { width: 100%; }

button.primary, button.ghost {
  font-family: inherit; font-size: .925rem; font-weight: 600; line-height: 1;
  padding: .72rem 1.3rem; border-radius: var(--radius); cursor: pointer;
  border: 1px solid transparent; transition: background .15s, border-color .15s;
}
button.primary { background: var(--accent); color: var(--on-accent); }
button.primary:hover { background: var(--accent-hover); }
button.ghost { background: transparent; color: var(--ink); border-color: var(--line-strong); }
button.ghost:hover { border-color: var(--ink); }
button:disabled { opacity: .45; cursor: not-allowed; }

/* ---------------------------- hero ---------------------------- */

.hero {
  background: var(--bg); color: var(--ink);
  border-bottom: 1px solid var(--line);
  position: relative; overflow: hidden;
}
/* Depth on a white page comes from one very faint accent wash, not a dark
   panel. Anything stronger than this and the white stops reading as white. */
.hero::after {
  content: ""; position: absolute; inset: -45% -12% auto auto;
  width: 720px; height: 720px; border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle, rgba(13, 92, 59, .07), transparent 64%);
}
.hero-inner {
  position: relative; z-index: 1;
  max-width: var(--shell); margin: 0 auto; padding: 4.5rem 1.5rem 3.75rem;
  display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr);
  gap: 3.5rem; align-items: start;
}
@media (max-width: 940px) {
  .hero-inner { grid-template-columns: 1fr; gap: 2.5rem; padding: 3.25rem 1.5rem 2.75rem; }
}

.eyebrow {
  display: inline-flex; align-items: center; gap: .5rem;
  font-size: .73rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase;
  color: var(--accent); margin: 0 0 1.35rem;
}
.eyebrow::before {
  content: ""; width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent-bright); box-shadow: 0 0 0 3px rgba(24, 160, 106, .22);
}

.hero h1 {
  font-size: clamp(2.1rem, 5.2vw, 3.35rem);
  line-height: 1.07; letter-spacing: -0.04em; font-weight: 680;
  margin: 0 0 1.25rem; color: var(--ink); max-width: 15ch;
}
.hero h1 em { font-style: normal; color: var(--accent); }
.hero-lede {
  font-size: 1.075rem; line-height: 1.65; color: var(--ink-soft);
  margin: 0 0 2rem; max-width: 52ch;
}

.hero-points { list-style: none; margin: 0; padding: 0; display: grid; gap: .6rem; }
.hero-points li {
  display: flex; gap: .65rem; align-items: flex-start;
  font-size: .925rem; color: var(--ink-soft);
}
.hero-points li::before {
  content: ""; flex: 0 0 auto; width: 16px; height: 16px; margin-top: .22rem;
  background: var(--accent);
  -webkit-mask: var(--icon-check) center / contain no-repeat;
  mask: var(--icon-check) center / contain no-repeat;
}

/* the capture card - the whole point of the homepage */
.capture {
  background: var(--bg);
  border: 1px solid var(--line-strong);
  border-top: 3px solid var(--accent);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  box-shadow: var(--shadow-lg);
}
.capture h2 {
  font-size: 1.15rem; color: var(--ink); margin: 0 0 .4rem;
  border: 0; padding: 0; text-transform: none; letter-spacing: -0.02em;
}
.capture p.sub { font-size: .885rem; color: var(--ink-soft); margin: 0 0 1.25rem; }
.capture form { display: grid; gap: .7rem; }
.capture input[type=email] {
  width: 100%; padding: .8rem .95rem; font: inherit; font-size: .95rem;
  border-radius: var(--radius); color: var(--ink);
  border: 1px solid var(--line-strong); background: var(--bg);
}
.capture input[type=email]::placeholder { color: var(--ink-faint); }
.capture input[type=email]:focus {
  border-color: var(--accent); outline: none;
  box-shadow: 0 0 0 3px var(--accent-wash);
}
.capture .fineprint {
  font-size: .76rem; color: var(--ink-faint); margin: .35rem 0 0; line-height: 1.5;
}

.trust {
  display: flex; flex-wrap: wrap; gap: 1rem 1.6rem;
  margin: 1.6rem 0 0; padding: 1.25rem 0 0;
  border-top: 1px solid var(--line); list-style: none;
}
.trust li { font-size: .78rem; color: var(--ink-faint); }
.trust strong { display: block; color: var(--ink); font-size: 1.05rem; font-weight: 660; letter-spacing: -0.02em; }

/* ---------------------------- stat band ---------------------------- */

.stat-band { border-bottom: 1px solid var(--line); background: var(--bg-soft); }
.stat-band-inner {
  max-width: var(--shell); margin: 0 auto; padding: 1.5rem;
  display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 1.5rem;
}
.stat { display: flex; flex-direction: column; gap: .1rem; }
.stat-label {
  font-size: .7rem; text-transform: uppercase; letter-spacing: .09em;
  color: var(--ink-faint); font-weight: 600;
}
.stat-value { font-size: 1.7rem; font-weight: 680; letter-spacing: -0.035em; }
.stat-note { font-size: .78rem; color: var(--ink-soft); }

/* ---------------------------- section furniture ---------------------------- */

.section { margin: 3.5rem 0 0; }
.section:first-child { margin-top: 0; }

.section-head {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 1rem; flex-wrap: wrap;
  border-bottom: 1px solid var(--line); padding-bottom: .7rem; margin-bottom: 1.4rem;
}
.section-head h2 {
  font-size: .78rem; text-transform: uppercase; letter-spacing: .1em;
  color: var(--ink-faint); font-weight: 650; border: 0; padding: 0; margin: 0;
}
.section-head .more { font-size: .84rem; font-weight: 600; text-decoration: none; }
.section-head .more:hover { text-decoration: underline; }

h2 {
  font-size: .78rem; text-transform: uppercase; letter-spacing: .1em;
  color: var(--ink-faint); font-weight: 650;
  border-bottom: 1px solid var(--line); padding-bottom: .7rem; margin: 3rem 0 1.4rem;
}

.lede { font-size: 1.05rem; color: var(--ink-soft); margin: 0 0 1.75rem; max-width: 62ch; }

.steps {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.25rem; list-style: none; padding: 0; margin: 0;
}
.step {
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.35rem; background: var(--bg);
}
.step-n {
  font-size: .7rem; font-weight: 700; letter-spacing: .1em;
  color: var(--accent); margin-bottom: .6rem; display: block;
}
.step h3 { font-size: 1rem; margin: 0 0 .4rem; }
.step p { margin: 0; font-size: .89rem; color: var(--ink-soft); line-height: 1.6; }

/* ---------------------------- filings ---------------------------- */

.timeline { display: grid; gap: .85rem; }

.filing {
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.15rem 1.25rem; background: var(--bg);
  transition: border-color .15s, box-shadow .15s;
}
.filing:hover { border-color: var(--line-strong); box-shadow: var(--shadow); }
.filing-head {
  display: flex; flex-wrap: wrap; gap: .4rem; align-items: center;
  font-size: .775rem; color: var(--ink-faint); margin-bottom: .55rem;
}
.filing-head time { margin-right: .3rem; font-weight: 550; }
.filing-company { margin: 0 0 .25rem; font-weight: 650; font-size: .95rem; }
.filing-company a { text-decoration: none; color: var(--ink); }
.filing-company a:hover { color: var(--accent); }
.filing-headline { font-size: 1.02rem; font-weight: 620; margin: 0 0 .55rem; line-height: 1.4; }
.summary { margin: 0 0 .6rem; color: var(--ink); }
.pending { margin: 0 0 .5rem; color: var(--ink-faint); font-size: .875rem; }
.analysis-meta { margin: .55rem 0 0; font-size: .78rem; color: var(--ink-faint); }
.caveats { margin: .5rem 0 0; font-size: .85rem; color: var(--ink-soft); }
.caveats strong { color: var(--ink); }
.flag { color: var(--high); font-weight: 650; }

.numbers {
  list-style: none; margin: .7rem 0 0; padding: 0;
  display: flex; flex-wrap: wrap; gap: .45rem;
}
.numbers li {
  border: 1px solid var(--line); border-radius: var(--radius-sm);
  padding: .35rem .65rem; font-size: .81rem; background: var(--bg-soft);
  display: flex; align-items: baseline; gap: .4rem;
}
.numbers .label { color: var(--ink-faint); }
.numbers .value { font-weight: 650; }
.numbers .yoy { color: var(--positive); font-weight: 600; }

/* ---------------------------- badges ---------------------------- */

.badge {
  display: inline-flex; align-items: center; padding: .16rem .55rem;
  border-radius: 999px; font-size: .7rem; font-weight: 650; letter-spacing: .015em;
  border: 1px solid var(--line); background: var(--bg-soft); color: var(--ink-soft);
  white-space: nowrap; line-height: 1.5;
}
.badge.exchange.nse { color: var(--info); border-color: var(--edge-info); background: var(--wash-info); }
.badge.exchange.bse { color: var(--high); border-color: var(--edge-high); background: var(--wash-high); }
.badge.sentiment.positive { color: var(--positive); border-color: var(--edge-positive); background: var(--wash-positive); }
.badge.sentiment.negative { color: var(--negative); border-color: var(--edge-negative); background: var(--wash-negative); }
.badge.sentiment.neutral  { color: var(--neutral); }
.badge.materiality.high   { color: var(--high); border-color: var(--edge-high); background: var(--wash-high); }
.badge.flagged   { color: var(--negative); border-color: var(--edge-negative); background: var(--wash-negative); }
.badge.duplicate { color: var(--ink-faint); border-style: dashed; background: transparent; }

/* ---------------------------- filing actions ---------------------------- */

.filing-actions {
  display: flex; flex-wrap: wrap; gap: 1.1rem; align-items: baseline;
  margin-top: .9rem; padding-top: .8rem; border-top: 1px solid var(--line);
  font-size: .83rem;
}
.filing-text summary {
  cursor: pointer; color: var(--ink-soft); font-weight: 600; list-style: none;
}
.filing-text summary::-webkit-details-marker { display: none; }
.filing-text summary::before { content: "\25B8\00a0\00a0"; color: var(--ink-faint); }
.filing-text[open] summary::before { content: "\25BE\00a0\00a0"; }
.filing-text summary:hover { color: var(--accent); }
.text-body {
  margin: .7rem 0 0; padding: .95rem; max-height: 24rem; overflow: auto;
  white-space: pre-wrap; word-break: break-word;
  font-family: var(--mono); font-size: .78rem; line-height: 1.6;
  background: var(--bg-sunken); border: 1px solid var(--line);
  border-radius: var(--radius-sm); color: var(--ink-soft);
}
.pdf { font-weight: 600; text-decoration: none; }
.pdf:hover { text-decoration: underline; }

/* ---------------------------- cards and forms ---------------------------- */

.card {
  border: 1px solid var(--line); border-radius: var(--radius-lg);
  background: var(--bg); padding: 1.75rem; box-shadow: var(--shadow);
}
.card.narrow { max-width: 440px; }
.auth-wrap { max-width: 440px; margin: 1.5rem auto; }
.auth-wrap h1 { font-size: 1.6rem; margin: 0 0 .5rem; }

form.stacked { display: grid; gap: 1rem; margin-top: 1.4rem; }
label { display: flex; flex-direction: column; gap: .35rem; font-size: .82rem; font-weight: 620; color: var(--ink-soft); }
label.check {
  flex-direction: row; align-items: flex-start; gap: .55rem;
  font-weight: 500; color: var(--ink); font-size: .89rem; line-height: 1.45;
}
label.check input { margin-top: .18rem; flex: 0 0 auto; accent-color: var(--accent); width: 16px; height: 16px; }
.hint { font-weight: 500; font-size: .78rem; color: var(--ink-faint); }

input[type=text], input[type=email], input[type=password], input[type=number],
input[type=search], select {
  padding: .7rem .85rem; font-family: inherit; font-size: .95rem;
  border: 1px solid var(--line-strong); border-radius: var(--radius);
  background: var(--bg); color: var(--ink);
  transition: border-color .15s, box-shadow .15s;
}
input:focus, select:focus {
  border-color: var(--accent); outline: none;
  box-shadow: 0 0 0 3px var(--accent-wash);
}

.muted { color: var(--ink-soft); }
.small { font-size: .84rem; }
.empty {
  color: var(--ink-soft); background: var(--bg-soft);
  border: 1px dashed var(--line-strong); border-radius: var(--radius);
  padding: 1.75rem; text-align: center;
}

.flash {
  padding: .8rem 1.05rem; border-radius: var(--radius); font-size: .89rem; font-weight: 550;
  border: 1px solid var(--accent); background: var(--accent-wash); color: var(--accent);
  margin: 0 0 1.5rem;
}
.flash.error { border-color: var(--negative); color: var(--negative); background: var(--wash-negative); }
.flash.warn  { border-color: var(--high); color: var(--high); background: var(--wash-high); }
/* ---------------------------- daily brief ---------------------------- */

.brief-head { border-bottom: 1px solid var(--line); padding-bottom: 1.5rem; margin-bottom: 2rem; }
.brief-date {
  font-size: .72rem; text-transform: uppercase; letter-spacing: .1em;
  color: var(--accent); font-weight: 650; margin: 0 0 .7rem;
}
.brief-head h1 {
  font-size: clamp(1.7rem, 3.6vw, 2.35rem); line-height: 1.18;
  letter-spacing: -0.035em; margin: 0 0 .85rem; max-width: 24ch;
}
.brief-stats { color: var(--ink-faint); font-size: .84rem; margin: 0; }

.wrap p { font-size: 1.08rem; line-height: 1.75; margin: 0 0 1.15rem; }

.entry {
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.35rem; margin-bottom: .95rem; background: var(--bg);
}
.entry h3 {
  margin: 0 0 .55rem; font-size: 1.08rem;
  display: flex; flex-wrap: wrap; gap: .55rem; align-items: center;
}
.entry h3 a { text-decoration: none; color: var(--ink); }
.entry h3 a:hover { color: var(--accent); }
.entry .own { margin: 0 0 .85rem; }
.views { list-style: none; margin: 0; padding: .8rem 0 0; border-top: 1px solid var(--line); }
.views li { font-size: .89rem; margin-bottom: .55rem; color: var(--ink-soft); line-height: 1.6; }
.views li:last-child { margin-bottom: 0; }
.views .publisher { color: var(--ink); font-weight: 650; }
.views a { font-size: .82rem; font-weight: 600; white-space: nowrap; }

/* the gate - the single most important component on the site */
.gate {
  position: relative; margin: 1.5rem 0 2rem;
  border: 1px solid var(--line); border-radius: var(--radius-lg);
  background: var(--bg); overflow: hidden; box-shadow: var(--shadow);
}
/* A real peek at what is behind the gate: the companies covered, rendered for
   real, then faded out. Nothing gated is in the HTML - only the names, which
   are listed publicly anyway. */
.gate-peek { padding: 1.35rem 1.35rem 0; position: relative; }
.gate-peek::after {
  content: ""; position: absolute; inset: auto 0 0 0; height: 75%;
  background: linear-gradient(to bottom, transparent, var(--bg) 88%);
  pointer-events: none;
}
.peek-row {
  display: flex; align-items: center; gap: .6rem; flex-wrap: wrap;
  padding: .7rem 0; border-bottom: 1px solid var(--line);
}
.peek-row:last-child { border-bottom: 0; }
.peek-name { font-weight: 620; font-size: .97rem; }
.peek-bar {
  flex: 1 1 120px; min-width: 80px; height: 9px; border-radius: 999px;
  background: linear-gradient(90deg, var(--bg-sunken), var(--bg-soft));
}

.gate-body { position: relative; z-index: 1; margin-top: -1.5rem; padding: 0 1.75rem 1.9rem; text-align: center; }
.gate-lock {
  width: 38px; height: 38px; margin: 0 auto .85rem;
  display: grid; place-items: center; border-radius: 50%;
  background: var(--accent-wash); color: var(--accent); border: 1px solid var(--accent);
}
.gate-lock::before {
  content: ""; width: 17px; height: 17px; background: currentColor;
  -webkit-mask: var(--icon-lock) center / contain no-repeat;
  mask: var(--icon-lock) center / contain no-repeat;
}
.gate h2 {
  border: 0; margin: 0 0 .55rem; padding: 0; font-size: 1.3rem;
  text-transform: none; letter-spacing: -0.028em; color: var(--ink); font-weight: 660;
}
.gate p { color: var(--ink-soft); margin: 0 auto 1.35rem; max-width: 46ch; font-size: .95rem; }
.gate .fineprint { font-size: .79rem; color: var(--ink-faint); margin: .95rem auto 0; }

/* share row - free reach, so it gets real estate */
.share {
  display: flex; flex-wrap: wrap; gap: .55rem; align-items: center;
  margin: 2.5rem 0 0; padding-top: 1.35rem; border-top: 1px solid var(--line);
}
.share-label {
  font-size: .72rem; text-transform: uppercase; letter-spacing: .09em;
  color: var(--ink-faint); font-weight: 650; margin-right: .3rem;
}
.share a, .share button {
  font: inherit; font-size: .82rem; font-weight: 600; cursor: pointer;
  padding: .42rem .85rem; border-radius: 999px; text-decoration: none;
  border: 1px solid var(--line-strong); background: var(--bg); color: var(--ink-soft);
  transition: border-color .15s, color .15s;
}
.share a:hover, .share button:hover { border-color: var(--accent); color: var(--accent); }

.brief-list { list-style: none; padding: 0; margin: 0; }
.brief-list li { padding: 1.1rem 0; border-bottom: 1px solid var(--line); }
.brief-list a { font-weight: 620; text-decoration: none; color: var(--ink); font-size: 1.02rem; }
.brief-list a:hover { color: var(--accent); }
.brief-list .when {
  font-size: .72rem; color: var(--ink-faint); display: block; margin-bottom: .25rem;
  text-transform: uppercase; letter-spacing: .08em; font-weight: 600;
}

/* ---------------------------- search and stock ---------------------------- */

.results { list-style: none; padding: 0; margin: 0; }
.results li {
  display: flex; flex-wrap: wrap; gap: .6rem; align-items: center;
  padding: .85rem 0; border-bottom: 1px solid var(--line);
}
.results a { font-weight: 620; text-decoration: none; color: var(--ink); }
.results a:hover { color: var(--accent); }
.isin { font-size: .76rem; color: var(--ink-faint); margin-left: auto; }
.result-count { color: var(--ink-soft); font-size: .9rem; }

.stock-head { border-bottom: 1px solid var(--line); padding-bottom: 1.4rem; margin-bottom: .5rem; }
.stock-head h1 { font-size: clamp(1.5rem, 3.2vw, 2.1rem); margin: 0 0 .7rem; }
.stock-head .tickers { display: flex; flex-wrap: wrap; gap: .45rem; align-items: center; margin: 0 0 .7rem; }
.counts { color: var(--ink-faint); font-size: .86rem; margin: 0; }
.unlinked { color: var(--ink-faint); font-weight: 500; font-style: italic; }

.pager { display: flex; gap: 1.5rem; margin-top: 1.5rem; }
.pager a { font-weight: 600; text-decoration: none; font-size: .9rem; }

code { background: var(--bg-sunken); padding: .12rem .38rem; border-radius: 4px; font-size: .86em; font-family: var(--mono); }

/* ---------------------------- closing CTA and footer ---------------------------- */

.cta-band {
  margin: 4rem 0 0; padding: 2.75rem 2rem; text-align: center;
  border-radius: var(--radius-lg); color: var(--ink);
  background: var(--accent-wash); border: 1px solid var(--line);
  position: relative; overflow: hidden;
}
.cta-band::after {
  content: ""; position: absolute; inset: auto -10% -60% auto;
  width: 520px; height: 520px; border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle, rgba(13, 92, 59, .08), transparent 62%);
}
.cta-band > * { position: relative; z-index: 1; }
.cta-band h2 {
  border: 0; padding: 0; margin: 0 0 .7rem; color: var(--ink);
  font-size: clamp(1.35rem, 3vw, 1.85rem); text-transform: none;
  letter-spacing: -0.03em; font-weight: 660;
}
.cta-band p { color: var(--ink-soft); margin: 0 auto 1.6rem; max-width: 50ch; }

footer.site { border-top: 1px solid var(--line); background: var(--bg-soft); margin-top: 4rem; }
.foot-inner {
  max-width: var(--shell); margin: 0 auto; padding: 2.25rem 1.5rem;
  color: var(--ink-soft); font-size: .85rem;
}
.foot-top {
  display: flex; flex-wrap: wrap; gap: 1.5rem; justify-content: space-between;
  align-items: flex-start; padding-bottom: 1.5rem; margin-bottom: 1.5rem;
  border-bottom: 1px solid var(--line);
}
.foot-links { display: flex; flex-wrap: wrap; gap: 1.25rem; }
.foot-links a { color: var(--ink-soft); text-decoration: none; font-weight: 550; }
.foot-links a:hover { color: var(--accent); }
.disclaimer { margin: 0 0 .8rem; line-height: 1.6; max-width: 78ch; font-size: .82rem; color: var(--ink-faint); }
.disclaimer strong { color: var(--ink-soft); }
footer .meta { margin: 0; font-size: .8rem; color: var(--ink-faint); }

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}

/* Visible to screen readers only - labels for inputs whose placeholder already
   says what they are. */
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}


/* ---------------------------- price chart ---------------------------- */

.chart-panel {
  border: 1px solid var(--line); border-radius: var(--radius-lg);
  background: var(--bg); margin: 1.75rem 0 0; overflow: hidden;
}

.chart-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; flex-wrap: wrap; padding: 1.1rem 1.35rem .5rem;
}
.chart-price { display: flex; align-items: baseline; gap: .6rem; flex-wrap: wrap; }
.chart-last {
  font-size: 1.75rem; font-weight: 690; letter-spacing: -0.035em;
  font-variant-numeric: tabular-nums;
}
.chart-change { font-size: .95rem; font-weight: 650; font-variant-numeric: tabular-nums; }
.chart-change.up   { color: var(--positive); }
.chart-change.down { color: var(--negative); }
.chart-span { font-size: .8rem; }

.chart-ranges { display: flex; gap: .2rem; }
.chart-ranges a {
  padding: .3rem .7rem; border-radius: 999px; text-decoration: none;
  font-size: .8rem; font-weight: 620; color: var(--ink-soft);
  font-variant-numeric: tabular-nums;
}
.chart-ranges a:hover { background: var(--bg-soft); color: var(--ink); }
.chart-ranges a.here { background: var(--accent-wash); color: var(--accent); }

.chart-frame { position: relative; padding: 0 1.35rem 1rem; }
.chart-svg { width: 100%; height: 300px; display: block; overflow: visible; }

.chart-svg .grid { stroke: var(--line); stroke-width: 1; vector-effect: non-scaling-stroke; }
.chart-svg .axis-y, .chart-svg .axis-x {
  fill: var(--ink-faint); font-size: 11px; font-family: var(--sans);
  font-variant-numeric: tabular-nums;
}
.chart-svg .axis-x { text-anchor: middle; }

.chart-svg .line {
  fill: none; stroke-width: 1.8; vector-effect: non-scaling-stroke;
  stroke-linejoin: round; stroke-linecap: round;
}
.chart-svg .line.up   { stroke: var(--positive); }
.chart-svg .line.down { stroke: var(--negative); }
.chart-svg .area { stroke: none; opacity: .09; }
.chart-svg .area.up   { fill: var(--positive); }
.chart-svg .area.down { fill: var(--negative); }

/* Markers. Filled = an exchange timestamp, accurate to the minute.
   Hollow + dashed stem = a broker PDF, date known, time not. */
.marker-group { cursor: pointer; }
.marker-hit { fill: transparent; }
.chart-svg .marker-stem {
  stroke: var(--ink-faint); stroke-width: 1; opacity: .42;
  vector-effect: non-scaling-stroke;
}
.chart-svg .marker-stem.dateonly { stroke-dasharray: 3 3; }
.chart-svg .marker {
  stroke-width: 2; vector-effect: non-scaling-stroke;
  transition: r .12s;
}
.chart-svg .marker.exact    { fill: var(--accent); stroke: var(--bg); }
.chart-svg .marker.dateonly { fill: var(--bg); stroke: var(--accent); }
.chart-svg .marker.positive { fill: var(--positive); stroke: var(--bg); }
.chart-svg .marker.negative { fill: var(--negative); stroke: var(--bg); }
.chart-svg .marker.dateonly.positive { fill: var(--bg); stroke: var(--positive); }
.chart-svg .marker.dateonly.negative { fill: var(--bg); stroke: var(--negative); }
.marker-group:hover .marker, .marker-group:focus .marker { r: 8; }
.marker-group:focus { outline: none; }
.marker-group:focus .marker-stem { opacity: 1; }

.chart-tip {
  position: absolute; z-index: 5; max-width: 300px; pointer-events: none;
  background: var(--bg); border: 1px solid var(--line-strong);
  border-radius: var(--radius); padding: .7rem .85rem;
  box-shadow: var(--shadow-lg); font-size: .82rem; line-height: 1.5;
}
.chart-tip[hidden] { display: none; }
.chart-tip .tip-when {
  font-size: .72rem; color: var(--ink-faint); font-weight: 650;
  text-transform: uppercase; letter-spacing: .06em; display: block; margin-bottom: .25rem;
}
.chart-tip .tip-title { font-weight: 620; color: var(--ink); margin: 0 0 .3rem; }
.chart-tip .tip-meta { color: var(--ink-soft); margin: 0; font-size: .78rem; }

/* the news list under the chart */
.chart-events {
  list-style: none; margin: 0; padding: 0;
  border-top: 1px solid var(--line);
}
.chart-event {
  display: grid; grid-template-columns: 190px minmax(0, 1fr); gap: 1.1rem;
  padding: 1rem 1.35rem; border-bottom: 1px solid var(--line);
}
.chart-event:last-child { border-bottom: 0; }
.chart-event:target { background: var(--accent-wash); }
@media (max-width: 680px) {
  .chart-event { grid-template-columns: 1fr; gap: .35rem; }
}

.ce-when { display: flex; align-items: center; gap: .5rem; }
.ce-when time {
  font-size: .78rem; color: var(--ink-soft); font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.ce-dot {
  width: 9px; height: 9px; border-radius: 50%; flex: 0 0 auto;
  border: 2px solid var(--accent); background: var(--accent);
}
.ce-dot.dateonly { background: var(--bg); }
.ce-dot.positive { border-color: var(--positive); background: var(--positive); }
.ce-dot.negative { border-color: var(--negative); background: var(--negative); }
.ce-dot.dateonly.positive, .ce-dot.dateonly.negative { background: var(--bg); }

.ce-title { margin: 0 0 .35rem; font-weight: 620; line-height: 1.45; }
.ce-title a { color: var(--ink); text-decoration: none; }
.ce-title a:hover { color: var(--accent); text-decoration: underline; }
.ce-meta { margin: 0; display: flex; flex-wrap: wrap; gap: .35rem; align-items: center; }
.ce-detail { margin: .5rem 0 0; color: var(--ink-soft); font-size: .89rem; }

.badge.reaction { font-variant-numeric: tabular-nums; }
.badge.reaction.up   { color: var(--positive); border-color: var(--edge-positive); background: var(--wash-positive); }
.badge.reaction.down { color: var(--negative); border-color: var(--edge-negative); background: var(--wash-negative); }

.chart-note { padding: .9rem 1.35rem 1.1rem; margin: 0; border-top: 1px solid var(--line); }

/* --- research rows on the homepage ---------------------------------------
   The exchange-filing row carried a category chip and an analysis stage; a
   broker note needs neither. What matters here is who published it, when, and
   which companies it covers. */
.research-row {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 1.1rem 1.25rem;
  box-shadow: var(--shadow);
}
.research-meta {
  display: flex; align-items: center; gap: .6rem;
  flex-wrap: wrap; margin-bottom: .45rem;
}
.research-title {
  font-size: 1.02rem; line-height: 1.45; margin: 0 0 .4rem;
  font-weight: 600; color: var(--ink);
}
.research-companies {
  margin: 0 0 .6rem; color: var(--ink-soft); font-size: .92rem;
}
.research-link {
  font-size: .9rem; font-weight: 600; color: var(--accent);
  text-decoration: none;
}
.research-link:hover { text-decoration: underline; }

/* --- one extracted note ---------------------------------------------------
   The summary is the page, not the link: broker PDFs get taken down and a
   reader arriving later should still learn what the house said. */
.note { max-width: 44rem; }
.note h1 { margin: .2rem 0 .6rem; }
.note h1 a { color: inherit; text-decoration: none; }
.note h1 a:hover { text-decoration: underline; }
.attribution { font-size: 1rem; color: var(--accent); margin: 0 0 1.25rem; }
.note-body {
  font-size: 1.12rem; line-height: 1.75; color: var(--ink);
  margin: 0 0 2rem;
}
.note-source {
  border-top: 1px solid var(--line); padding-top: 1.25rem;
}
.note-source .hint { font-size: .86rem; color: var(--ink-faint); margin-top: .75rem; }
.btn-quiet {
  display: inline-block; border: 1px solid var(--line-strong);
  border-radius: 999px; padding: .5rem 1.1rem; font-size: .92rem;
  font-weight: 600; color: var(--ink); text-decoration: none;
}
.btn-quiet:hover { border-color: var(--accent); color: var(--accent); }
.research-summary {
  margin: 0 0 .7rem; color: var(--ink-soft); line-height: 1.65;
}
.tag.rating { color: var(--accent); font-weight: 700; }

/* --- search suggestions --------------------------------------------------- */
.search { position: relative; }
.suggestions {
  position: absolute; top: calc(100% + 6px); left: 0; right: 0;
  z-index: 60; margin: 0; padding: .3rem; list-style: none;
  background: var(--bg); border: 1px solid var(--line);
  border-radius: var(--radius-lg); box-shadow: var(--shadow);
  max-height: 20rem; overflow-y: auto;
}
.suggestions li {
  display: flex; align-items: center; justify-content: space-between;
  gap: .75rem; padding: .5rem .7rem; border-radius: 8px;
  cursor: pointer; font-size: .93rem;
}
.suggestions li.is-active, .suggestions li:hover { background: var(--bg-sunken); }
.suggest-name { color: var(--ink); overflow: hidden; text-overflow: ellipsis;
                white-space: nowrap; }
.suggest-tag { color: var(--accent); font-weight: 700; font-size: .82rem;
               flex-shrink: 0; }

/* --- filter chips --------------------------------------------------------- */
.filters { margin: 1.25rem 0 .75rem; display: grid; gap: .5rem; }
.filter-row { display: flex; flex-wrap: wrap; gap: .4rem; }
.chip {
  display: inline-block; padding: .32rem .8rem; border-radius: 999px;
  border: 1px solid var(--line); background: var(--bg);
  font-size: .86rem; color: var(--ink-soft); text-decoration: none;
  white-space: nowrap;
}
.chip:hover { border-color: var(--line-strong); color: var(--ink); }
.chip.is-on {
  background: var(--accent); border-color: var(--accent);
  color: var(--on-accent); font-weight: 600;
}
.result-count { margin: .25rem 0 1.25rem; font-size: .9rem; }

/* --- custom date range ---------------------------------------------------- */
.range-form {
  display: flex; flex-wrap: wrap; align-items: flex-end; gap: .6rem;
  padding: .85rem; border: 1px solid var(--line);
  border-radius: var(--radius-lg); background: var(--bg-soft);
}
.range-form label {
  display: grid; gap: .25rem; font-size: .82rem; color: var(--ink-soft);
  font-weight: 600;
}
.range-form input[type="datetime-local"] {
  padding: .42rem .55rem; border: 1px solid var(--line-strong);
  border-radius: 8px; background: var(--bg); color: var(--ink);
  font: inherit; font-size: .9rem;
}
.range-form button { padding: .5rem 1.1rem; font-size: .9rem; }
.range-form .hint { font-size: .8rem; color: var(--ink-faint); }

/* --- published calls, and what happened next ----------------------------- */
/* A record of what a house said, never a view on it. The outcome pill reuses
   the semantic washes so "hit" and "missed" read the same way everywhere. */
.grid.calls td { vertical-align: middle; }
.grid.calls .up   { color: var(--positive); }
.grid.calls .down { color: var(--negative); }

.state.open    { color: var(--ink-soft); border-color: var(--line-strong); background: var(--bg-sunken); }
.state.hit     { color: var(--positive); border-color: var(--edge-positive); background: var(--wash-positive); }
.state.missed  { color: var(--negative); border-color: var(--edge-negative); background: var(--wash-negative); }
.state.stopped { color: var(--high);     border-color: var(--edge-high);     background: var(--wash-high); }
.state.void    { color: var(--ink-faint); border-color: var(--line); background: var(--bg-soft); }

/* The note itself, in the chart's hover card. Wider and taller than the rest
   of the card because it is a sentence rather than a label -- the card used
   to hold only a headline and badges, and a reader hovering a marker learned
   nothing about what the house had said. */
.chart-tip { max-width: 22rem; }
.tip-detail {
  margin: .45rem 0 0;
  padding-top: .45rem;
  border-top: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: .82rem;
  line-height: 1.45;
  /* Long notes are clipped rather than allowed to grow a card taller than
     the chart it is pointing at. The full text is in the list below. */
  display: -webkit-box;
  -webkit-line-clamp: 5;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* --- crosshair and span selection ---------------------------------------- */
/* Hovering a chart and being told the price is the first thing anyone tries.
   The line is hairline and the band barely tinted: this sits on top of a price
   series that is the actual content, and a heavy overlay reads as the subject
   rather than as a pointer. */
.chart-frame { position: relative; cursor: crosshair; }

.xh-line {
  stroke: var(--ink-faint);
  stroke-width: 1;
  stroke-dasharray: 3 3;
  vector-effect: non-scaling-stroke;
  pointer-events: none;
}
.xh-dot {
  fill: var(--bg);
  stroke: var(--ink);
  stroke-width: 2;
  vector-effect: non-scaling-stroke;
  pointer-events: none;
}
.xh-band {
  fill: var(--ink);
  opacity: .06;
  pointer-events: none;
}

.chart-readout {
  position: absolute;
  top: .25rem;
  z-index: 3;
  display: flex;
  align-items: baseline;
  gap: .5rem;
  padding: .3rem .6rem;
  background: var(--bg);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  font-size: .82rem;
  white-space: nowrap;
  /* The pointer must never land on the readout: it would fire mouseleave on
     the frame and the crosshair would flicker as it chased itself. */
  pointer-events: none;
}
.chart-readout .ro-price { font-weight: 650; font-variant-numeric: tabular-nums; }
.chart-readout .ro-when  { color: var(--ink-faint); }
.chart-readout .ro-change { font-weight: 650; font-variant-numeric: tabular-nums; }
.chart-readout .ro-change.up   { color: var(--positive); }
.chart-readout .ro-change.down { color: var(--negative); }
