/* ========================================
   Rock Island Watch — velorete.com
   Page-specific overrides layered on cao.css
   ======================================== */

/* Hero title — large dollar contrast, since "$1.29 vs. $80" is the pitch */
#hero .hero-title {
  font-size: clamp(3rem, 9vw, 6rem);
  letter-spacing: -0.02em;
}

/* Hero meeting-date callout */
.hero-meeting {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  padding: 1rem 1.75rem;
  margin-bottom: 1.75rem;
  background: rgba(0, 212, 255, 0.06);
  border: 1px solid rgba(0, 212, 255, 0.25);
  border-radius: var(--radius-sm);
}
.hero-meeting-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--accent);
  font-weight: 600;
}
.hero-meeting-date {
  font-size: clamp(1rem, 2vw, 1.2rem);
  font-weight: 700;
  color: var(--text-primary);
}
.hero-meeting-sub {
  font-size: 0.82rem;
  color: var(--text-secondary);
}

/* ---------- Price Comparison Cards ---------- */
.price-comparison {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.25rem;
  margin: 2.5rem 0 2rem;
}

.price-card {
  padding: 1.75rem 1.5rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.price-card.highlight {
  border-color: rgba(255, 159, 67, 0.35);
  background: rgba(255, 159, 67, 0.04);
}

.price-card-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: 0.02em;
}

.price-card-where {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-top: 0.35rem;
  margin-bottom: 1rem;
}

.price-card-amount {
  font-size: clamp(2.4rem, 5vw, 3.4rem);
  font-weight: 800;
  line-height: 1;
  margin-bottom: 0.4rem;
}

.price-card-amount span {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-muted);
  margin-left: 0.2rem;
}

.price-card-amount.red    { color: var(--red); }
.price-card-amount.green  { color: var(--green); }
.price-card-amount.amber  { color: var(--amber); }

.price-card-annual {
  font-size: 0.82rem;
  color: var(--text-secondary);
}

/* ---------- Schedule R Table ---------- */
.schedule-r-table {
  padding: 0;
  overflow: hidden;
  margin-bottom: 0.5rem;
}

.sr-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 1rem;
  padding: 1rem 1.5rem;
  border-bottom: 1px solid var(--glass-border);
  align-items: center;
}

.sr-row:last-child {
  border-bottom: none;
}

.sr-header {
  background: rgba(0, 212, 255, 0.06);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
  font-weight: 600;
  padding: 0.85rem 1.5rem;
}

.sr-key {
  background: rgba(0, 212, 255, 0.05);
}

.sr-row > div:first-child {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.5;
}

.sr-row.sr-key > div:first-child {
  color: var(--text-primary);
}

.sr-type {
  color: var(--text-muted);
  font-size: 0.78rem;
  font-weight: 400;
  margin-left: 0.25rem;
}

.sr-amount {
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text-primary);
  white-space: nowrap;
}

.sr-amount.accent {
  color: var(--accent);
  font-size: 1.1rem;
}

.sr-footnote {
  font-size: 0.78rem;
  color: var(--text-muted);
  font-style: italic;
  margin-bottom: 2rem;
}

/* ---------- Critical Calculation Block ---------- */
.critical-calc {
  padding: 2rem 2.25rem;
  max-width: 560px;
  margin-top: 1rem;
}

.critical-calc h3 {
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent);
  margin-bottom: 1.25rem;
  font-weight: 600;
}

.calc-line {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 0.5rem 0;
  color: var(--text-secondary);
  font-size: 0.92rem;
}

.calc-label {
  color: var(--text-secondary);
}

.calc-value {
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  color: var(--text-primary);
}

.calc-divider {
  height: 1px;
  background: var(--glass-border);
  margin: 0.5rem 0;
}

.calc-line.calc-result {
  padding: 0.85rem 0 0.5rem;
  font-size: 1.05rem;
}

.calc-line.calc-result .calc-label {
  color: var(--text-primary);
  font-weight: 600;
}

.calc-line.calc-result .calc-value {
  font-size: 1.5rem;
  font-weight: 800;
}

.calc-value.accent {
  color: var(--accent);
}

.calc-note {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--glass-border);
}

.calc-note strong {
  color: var(--text-primary);
}

/* ---------- GM Admissions ---------- */
.admissions-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.25rem;
  margin-top: 2rem;
}

.admission-card {
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  border-left: 3px solid var(--amber);
}

.admission-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  padding: 0.3rem 0.75rem;
  background: rgba(255, 159, 67, 0.12);
  border: 1px solid rgba(255, 159, 67, 0.3);
  border-radius: 6px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--amber);
}

.admission-card p {
  color: var(--text-secondary);
  font-size: 0.92rem;
  line-height: 1.7;
  margin: 0;
}

.admission-card p strong {
  color: var(--text-primary);
}

/* ---------- Context / clarification notes ---------- */
/* Using a higher-specificity selector (p.context-note) and explicit
   override so that .highlight-box p (which sets --text-primary in
   cao.css) doesn't win the cascade for context notes inside a
   highlight box. */
p.context-note,
.context-note {
  display: block;
  font-size: 0.78rem;
  color: var(--text-muted) !important;
  line-height: 1.6;
  margin-top: 0.85rem;
  padding: 0.55rem 0.85rem 0.55rem 0.95rem;
  border-left: 2px solid rgba(0, 212, 255, 0.28);
  background: rgba(0, 212, 255, 0.03);
  border-radius: 0 6px 6px 0;
  max-width: 680px;
}
.context-note strong {
  color: var(--text-secondary);
  font-weight: 600;
}
.context-note::before {
  content: "NOTE \00a0 ";
  font-size: 0.72em;
  font-weight: 800;
  letter-spacing: 0.1em;
  color: var(--accent);
}

/* ---------- Inline source pills ---------- */
.src {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  font-size: 0.6rem;
  line-height: 1;
  padding: 3px 7px 3px 8px;
  margin: 0 1px 0 4px;
  vertical-align: 0.12em;
  background: rgba(0, 212, 255, 0.09);
  border: 1px solid rgba(0, 212, 255, 0.24);
  border-radius: 999px;
  color: var(--accent);
  text-decoration: none;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  transition: background 0.15s, border-color 0.15s, transform 0.15s;
}
.src:hover {
  background: rgba(0, 212, 255, 0.2);
  border-color: rgba(0, 212, 255, 0.45);
  transform: translateY(-1px);
  opacity: 1;
}
.src::after {
  content: "↗";
  font-size: 0.85em;
  font-weight: 600;
  opacity: 0.75;
  margin-left: 1px;
}
.src + .src {
  margin-left: 2px;
}

/* ---------- Correspondence / Message cards ---------- */
.msg-card {
  margin-bottom: 1.75rem;
  padding: 0;
  overflow: hidden;
  scroll-margin-top: 90px;
}

.msg-card .msg-header {
  padding: 1.25rem 1.75rem 1rem;
  border-bottom: 1px solid var(--glass-border);
  background: rgba(255, 255, 255, 0.015);
}

.msg-card.msg-member .msg-header {
  border-left: 3px solid var(--accent);
}
.msg-card.msg-gm .msg-header {
  border-left: 3px solid var(--amber);
}

.msg-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 1.25rem;
  margin-bottom: 0.6rem;
  font-size: 0.82rem;
}

.msg-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  background: rgba(0, 212, 255, 0.1);
  border: 1px solid rgba(0, 212, 255, 0.22);
  border-radius: 6px;
  color: var(--accent);
  font-weight: 700;
  font-size: 0.72rem;
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
}
.msg-gm .msg-num {
  background: rgba(255, 159, 67, 0.1);
  border-color: rgba(255, 159, 67, 0.25);
  color: var(--amber);
}

.msg-from {
  color: var(--text-primary);
  font-weight: 600;
}
.msg-email {
  color: var(--text-muted);
  font-weight: 400;
  font-size: 0.78rem;
}
.msg-to {
  color: var(--text-secondary);
  font-size: 0.78rem;
}
.msg-date {
  color: var(--text-muted);
  font-size: 0.76rem;
  margin-left: auto;
  font-variant-numeric: tabular-nums;
}

.msg-subject {
  font-size: 0.92rem;
  color: var(--text-primary);
  font-weight: 500;
}

.msg-body {
  padding: 1.5rem 1.75rem 1.75rem;
  max-width: 720px;
}

.msg-body p,
.msg-body li {
  color: var(--text-secondary);
  font-size: 0.94rem;
  line-height: 1.75;
}

.msg-body p {
  margin-bottom: 1rem;
}

.msg-body p:last-child {
  margin-bottom: 0;
}

.msg-body ul,
.msg-body ol {
  margin: 0 0 1rem 1.25rem;
  padding-left: 0.5rem;
}

.msg-body li {
  margin-bottom: 0.4rem;
}

.msg-body strong {
  color: var(--text-primary);
}

.msg-body a {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

.msg-body mark {
  background: rgba(0, 212, 255, 0.12);
  color: var(--text-primary);
  padding: 0.1em 0.25em;
  border-radius: 3px;
  border-bottom: 2px solid rgba(0, 212, 255, 0.45);
}

.msg-gm .msg-body mark {
  background: rgba(255, 159, 67, 0.14);
  border-bottom-color: rgba(255, 159, 67, 0.5);
}

/* Anchor-linked quote highlight: when a quote is linked to by
   fragment (e.g. #quote-undermine), scroll it into view with room
   for the sticky nav and briefly pulse its background so the reader
   sees exactly which sentence the link was for. */
.msg-body mark[id] {
  scroll-margin-top: 100px;
}
.msg-body mark[id]:target {
  animation: mark-pulse 2.4s ease-out 1;
  background: rgba(0, 212, 255, 0.28);
  box-shadow: 0 0 0 6px rgba(0, 212, 255, 0.18);
}
.msg-gm .msg-body mark[id]:target {
  background: rgba(255, 159, 67, 0.32);
  box-shadow: 0 0 0 6px rgba(255, 159, 67, 0.2);
}
@keyframes mark-pulse {
  0%   { background: rgba(0, 212, 255, 0.55); box-shadow: 0 0 0 10px rgba(0, 212, 255, 0.3); }
  40%  { background: rgba(0, 212, 255, 0.35); }
  100% { background: rgba(0, 212, 255, 0.28); box-shadow: 0 0 0 6px rgba(0, 212, 255, 0.18); }
}

@media (max-width: 700px) {
  .msg-card .msg-header,
  .msg-body {
    padding-left: 1.25rem;
    padding-right: 1.25rem;
  }
  .msg-date {
    margin-left: 0;
    width: 100%;
  }
}

/* ---------- Responsive ---------- */
@media (max-width: 700px) {
  .price-comparison {
    grid-template-columns: 1fr;
  }
  .admissions-list {
    grid-template-columns: 1fr;
  }
  .sr-row {
    grid-template-columns: 1fr;
    gap: 0.4rem;
    padding: 0.9rem 1.25rem;
  }
  .sr-amount {
    text-align: left;
  }
  .critical-calc {
    padding: 1.5rem;
  }
}
