@import url("../../../css/section-home.css");

/* Local preview styles; other regimental pages keep their existing layout. */
[hidden] { display: none !important; }
.breadcrumbs { margin: 0 6px 20px; color: var(--muted); line-height: 1.8; }
.breadcrumbs a { color: var(--accent); }
.timeline-hero { display: grid; grid-template-columns: minmax(0, 1fr) 240px; gap: 36px; align-items: center; padding: 42px; border: 1px solid var(--line); border-radius: 28px; background: linear-gradient(125deg, #0a2336, #132d3a); box-shadow: var(--shadow); }
.timeline-hero h1 { max-width: 18ch; font-size: clamp(2.3rem, 4vw, 3.8rem); line-height: 1.05; }
.hero-subtitle { margin: 20px 0 0; color: var(--accent); font-size: 1.3rem; }
.timeline-hero .hero-text { margin-top: 10px; }
.regiment-mark { margin: 0; }
.regiment-mark img { width: 100%; height: auto; max-height: 180px; object-fit: contain; padding: 12px; border-radius: 14px; background: #fff; }
.regiment-mark figcaption { margin-top: 10px; color: var(--muted); font-size: .8rem; text-align: center; }
.summary-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 24px 0; }
.summary-card { display: grid; gap: 10px; padding: 22px; border: 1px solid var(--line); border-radius: 18px; background: var(--panel); }
.summary-card strong { font-size: 1.1rem; }
.summary-card > span:last-child { color: var(--muted); font-size: .85rem; line-height: 1.5; }
.summary-label { color: var(--accent); font-size: .72rem; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; }
.reading-note { margin: 30px 0; padding-left: 22px; border-left: 3px solid var(--accent); max-width: 100ch; }
.reading-note h2 { font-size: 1.25rem; }
.reading-note p, .panel p { line-height: 1.7; }
.panel { padding: 28px; margin: 28px 0; border: 1px solid var(--line); border-radius: 20px; background: var(--panel); }
.section-heading { display: flex; gap: 20px; justify-content: space-between; align-items: end; }
.section-heading h2, .date-explorer h2 { margin: 0; font-size: 1.7rem; }
.section-heading p { margin: 0; color: var(--muted); font-size: .88rem; }
.section-heading .eyebrow { color: var(--accent); margin-bottom: 10px; }
.section-heading a { color: var(--accent); }
.chart-help { color: var(--muted); font-size: .87rem; }
.chart-scroll { overflow-x: auto; padding: 8px 3px 16px; }
.timeline-chart { min-width: 1050px; }
.chart-row { display: grid; grid-template-columns: 165px 1fr; gap: 12px; align-items: center; margin: 14px 0; }
.chart-label { font-size: .86rem; font-weight: 700; }
.chart-track { position: relative; height: 48px; border-radius: 6px; background: rgba(255,255,255,.035); }
.axis .chart-track { height: 24px; background: transparent; }
.axis-tick { position: absolute; transform: translateX(-50%); color: var(--muted); font-size: .73rem; }
.axis-tick:first-child { transform: none; }
.axis-tick:last-child { transform: translateX(-100%); }
.chart-segment { position: absolute; top: 0; bottom: 0; border: 1px solid #07141f; padding: 0; color: #07141f; font: inherit; font-size: .76rem; font-weight: 700; cursor: pointer; overflow: hidden; }
.chart-segment:hover, .chart-segment:focus-visible { z-index: 2; outline: 3px solid #fff; outline-offset: 1px; }
.chart-segment.inactive { color: #fff; }
.chart-after { position: absolute; left: 40%; right: 5px; top: 13px; color: var(--muted); font-size: .78rem; }
.first { --division: #ed9f87; }
.eighth { --division: #e7c15c; }
.second { --division: #88bbec; }
.airborne { --division: #b6a4e0; }
.training { --division: #82baa3; }
.division { --division: #60b7ad; }
.separate { --division: #d8a978; }
.inactive { --division: #60747f; }
.unknown, .reported { --division: #b7bdc1; }
.chart-segment, .swatch { background: var(--division); }
.chart-segment.unknown, .chart-segment.reported, .swatch.unknown { background: repeating-linear-gradient(135deg, #c4c9cb 0 5px, #98a1a5 5px 10px); }
.legend { display: flex; gap: 14px 22px; flex-wrap: wrap; margin: 12px 0 0; padding: 0; list-style: none; font-size: .8rem; }
.legend li { display: flex; align-items: center; gap: 8px; }
.swatch { display: inline-block; width: 14px; height: 14px; border-radius: 3px; flex-shrink: 0; }
.date-explorer { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.date-control label { display: block; margin-bottom: 10px; font-size: .85rem; }
input, select, button { font: inherit; }
input[type="date"], select { max-width: 100%; padding: 11px; background: #f8efdd; border: 1px solid #b7bdc1; border-radius: 8px; color: #07141f; }
.date-control button { display: block; margin-top: 10px; padding: 8px 0; background: none; border: 0; text-decoration: underline; text-underline-offset: 3px; color: var(--accent); cursor: pointer; }
.date-results { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 12px; }
.date-result { border-left: 4px solid var(--division); padding: 14px 18px; background: rgba(255,255,255,.04); border-radius: 0 10px 10px 0; }
.date-result strong, .date-result span { display: block; }
.date-result span { margin: 8px 0; font-size: .85rem; color: var(--muted); }
.date-result a { color: var(--accent); font-size: .85rem; }
.chronology { margin-top: 38px; }
.timeline-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin: 22px 0 12px; }
.timeline-controls label { font-weight: 700; }
#filter-status { margin: 0; color: var(--muted); font-size: .85rem; }
.date-convention { max-width: 85ch; color: var(--muted); font-size: .87rem; line-height: 1.6; }
.period-list { padding: 0; list-style: none; }
.period { position: relative; display: grid; grid-template-columns: 190px minmax(0,1fr); gap: 28px; padding-bottom: 22px; scroll-margin-top: 24px; }
.period::before { content: ""; position: absolute; left: 202px; top: 12px; bottom: -12px; width: 2px; background: #345060; }
.period:last-child::before { bottom: 40px; }
.period::after { content: ""; position: absolute; left: 197px; top: 25px; width: 12px; height: 12px; border-radius: 50%; background: var(--division); border: 2px solid #07141f; }
.period-date { padding-top: 24px; color: var(--accent); font-weight: 700; font-size: .9rem; line-height: 1.6; }
.period-card { border-left: 5px solid var(--division); border-radius: 0 16px 16px 0; padding: 22px 26px; background: #f2d18b; color: #10212d; }
.unit-label { margin: 0 0 9px; color: #5b491f; font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.period h3 { margin: 0; font-size: 1.45rem; }
.period-note { margin: 12px 0; line-height: 1.65; }
.period-sources { margin: 0; font-size: .8rem; }
.period-sources a { color: #173f55; text-underline-offset: 3px; }
.period:target .period-card { outline: 3px solid #fff; outline-offset: 3px; }
.research li { line-height: 1.7; margin: 12px 0; }
.sources { padding-left: 22px; }
.sources a { color: var(--accent); overflow-wrap: anywhere; }
.sources li { scroll-margin-top: 25px; }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, .chart-scroll:focus-visible { outline: 3px solid #82baa3; outline-offset: 4px; }
.skip-link { position: absolute; top: -80px; left: 12px; padding: 12px; background: var(--accent); color: #07141f; z-index: 10; }
.skip-link:focus { top: 12px; }
@media(max-width: 800px) {
  .timeline-hero { grid-template-columns: 1fr; padding: 28px; }
  .regiment-mark { max-width: 180px; }
  .summary-grid { grid-template-columns: 1fr; }
  .section-heading { align-items: start; flex-direction: column; }
  .date-explorer, .date-results { grid-template-columns: 1fr; }
  .period { grid-template-columns: 1fr; gap: 10px; padding: 0 0 22px 22px; }
  .period::before { left: 5px; top: 16px; }
  .period::after { left: 0; top: 12px; }
  .period-date { padding-top: 6px; }
  .period-card { padding: 20px; }
  .panel { padding: 20px; }
}
@media(prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
@media print {
  body { background: white; color: black; }
  .site-shell { width: 100%; margin: 0; }
  .timeline-hero, .summary-card, .panel { background: white; color: black; box-shadow: none; border-color: #999; }
  .overview, .date-explorer, .timeline-controls, .skip-link, .regiment-mark { display: none !important; }
  .period[hidden] { display: grid !important; }
  .period { break-inside: avoid; }
  .period-card { background: #f7f1e4; border: 1px solid #999; }
  .period-date, a, .breadcrumbs, .eyebrow, .hero-text, .hero-subtitle, .summary-label, .summary-card > span:last-child, .date-convention { color: black !important; }
  .footer-panel { background: white; box-shadow: none; }
}

/* Division identification and partially documented battalions. */
.deployment-intro { color: var(--muted); line-height: 1.7; max-width: 95ch; }
.deployments { margin-top: 22px; padding-top: 18px; border-top: 1px solid rgba(16,33,45,.25); }
.deployments h4 { margin: 0 0 16px; font-size: 1rem; }
.deployment-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.deployment { padding: 16px 18px; border-left: 3px solid #276a78; background: rgba(255,255,255,.35); border-radius: 0 10px 10px 0; scroll-margin-top: 24px; }
.deployment h5 { margin: 4px 0 8px; font-size: 1.13rem; }
.deployment p { margin: 8px 0; line-height: 1.6; font-size: .9rem; }
.deployment .deployment-date { margin-top: 0; color: #174c5a; font-weight: 700; }
.deployment .deployment-unit { font-size: .8rem; font-weight: 700; }
.deployment a { color: #173f55; font-size: .8rem; overflow-wrap: anywhere; }
.deployment:target, .deployment:focus { outline: 3px solid #276a78; outline-offset: 3px; }
.deployment-track { height: 72px; background: transparent; }
.deployment-row .chart-label { color: var(--accent); font-size: .75rem; }
.deployment-marker { position: absolute; transform: translateX(-50%); width: 28px; height: 30px; border: 1px solid #82c6d4; border-radius: 5px; background: #123846; color: #a9e5ed; cursor: pointer; }
.deployment-marker:hover, .deployment-marker:focus-visible { background: #276a78; z-index: 2; }
@media print { .deployment { break-inside: avoid; } }
.patch-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.patch-key { display: flex; align-items: center; gap: 16px; padding: 18px; border: 1px solid var(--line); border-radius: 12px; color: var(--accent); text-decoration: none; }
.patch-key img, .division-patch { object-fit: contain; flex-shrink: 0; }
.patch-key:hover { background: rgba(255,255,255,.06); }
.division-heading { display: flex; align-items: center; gap: 18px; }
.chart-evidence { color: var(--accent); padding: 12px; border: 1px dashed var(--line); border-radius: 6px; font-size: .85rem; }
.timeline-index-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 20px; margin: 28px 0; }
.timeline-index-card { display: block; padding: 24px; border: 1px solid var(--line); border-radius: 16px; background: rgba(255,255,255,.04); color: var(--text); text-decoration: none; }
.timeline-index-card h2 { color: var(--accent); font-size: 1.35rem; }
.timeline-index-card p { line-height: 1.7; color: var(--muted); }
.timeline-index-card > span:last-child { color: var(--accent); }
.timeline-index-card:hover { background: rgba(255,255,255,.08); }
.footer-panel nav { line-height: 2; }
.battalion-evidence { scroll-margin-top: 24px; }
.battalion-evidence a { color: var(--accent); }
@media(max-width: 1100px) { .patch-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media(max-width: 550px) { .patch-key { flex-direction: column; text-align: center; padding: 12px; font-size: .85rem; } .division-heading { gap: 12px; } .period h3 { font-size: 1.2rem; } }
@media print { .battalion-evidence[hidden] { display: block !important; } .patch-key, .battalion-evidence a { color: black; } }
