/* Canadohta Security Group, Route B "Live from the Lake". Mobile first.
   Night/paper base; channel colors CH1 cyan, CH2 amber, CH3 red are used on night only
   (on paper they appear only as solid chips/buttons with night text, or as decorative rules). */
:root {
  --night: #0A1418;
  --night-2: #11222A;
  --night-line: #2A3E46;
  --paper: #F3F5F4;
  --white: #FFFFFF;
  --steel: #8A9BA3;      /* small labels on night, 6.5:1 */
  --mist: #C5D0D4;       /* body text on night, 11.9:1 */
  --ink-muted: #44555C;  /* small labels on paper, 7.1:1 */
  --err: #A3161A;        /* form errors on paper/white, 7.4:1 */
  --cyan: #40F5F0;
  --amber: #FFB020;
  --red: #FF4D4D;
  --ch: var(--cyan);
  --focus: var(--cyan);
  --display: "Barlow Condensed", "Arial Narrow", sans-serif;
  --sans: "IBM Plex Sans", system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
  --gutter: 20px;
  --callbar-h: 72px;
}
.ch-1 { --ch: var(--cyan); }
.ch-2 { --ch: var(--amber); }
.ch-3 { --ch: var(--red); }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--night); color: var(--paper);
  font: 400 17px/1.55 var(--sans);
  padding-bottom: calc(var(--callbar-h) + env(safe-area-inset-bottom));
}
img { max-width: 100%; display: block; }
a { color: inherit; text-underline-offset: 3px; }
p { margin: 0 0 1em; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }
.band-paper :focus-visible, .quote-form :focus-visible { --focus: var(--night); }

.wrap { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 var(--gutter); }
.narrow { max-width: 760px; }
.skip { position: absolute; left: -9999px; top: 8px; z-index: 100; background: var(--paper); color: var(--night); padding: 10px 14px; font-weight: 600; }
.skip:focus { left: 8px; }

/* type */
.h1, .h2, .h3, .wordmark, .btn, .door-name { font-family: var(--display); text-transform: uppercase; }
.h1 { font-weight: 700; font-size: clamp(46px, 13vw, 104px); line-height: .92; letter-spacing: .005em; margin: 0 0 .3em; }
.h2 { font-weight: 700; font-size: clamp(34px, 8vw, 60px); line-height: .98; margin: 0 0 .4em; }
.h3 { font-weight: 600; font-size: 28px; line-height: 1.05; margin: 0 0 .4em; }
.lede { font-size: 19px; color: var(--mist); max-width: 40ch; }
.lede a { color: var(--paper); }
.lede-dark { font-size: 19px; color: var(--night); max-width: 52ch; }
.label, .hours, .cam-tag, .cam-time, .cam-note, .chip, .tile-caption, figcaption, .hint, .callbar-hours {
  font-family: var(--mono); font-weight: 500; letter-spacing: .06em;
}
.label { font-size: 13px; text-transform: uppercase; color: var(--steel); margin: 0 0 18px; }
.band-paper .label { color: var(--ink-muted); }
.hours { font-size: 14px; color: var(--steel); margin: 12px 0 0; }
.muted { color: var(--steel); }

/* live dot */
.dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--red); flex: none; animation: pulse 1.6s ease-in-out infinite; }
@keyframes pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(255,77,77,.6); } 50% { box-shadow: 0 0 0 7px rgba(255,77,77,0); } }
@media (prefers-reduced-motion: reduce) { .dot { animation: none; } * { scroll-behavior: auto !important; transition: none !important; } }

/* buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; min-height: 52px; padding: 10px 22px;
  font-weight: 700; font-size: 22px; letter-spacing: .03em; text-decoration: none; border: 2px solid transparent;
  border-radius: 2px; cursor: pointer; line-height: 1;
}
.btn-lg { min-height: 60px; font-size: 26px; padding: 12px 28px; }
.btn-sm { min-height: 44px; font-size: 19px; padding: 8px 16px; }
.btn-cyan, .btn-ch1 { background: var(--cyan); color: var(--night); }
.btn-ch2 { background: var(--amber); color: var(--night); }
.btn-ch3 { background: var(--red); color: var(--night); }
.btn-paper { background: var(--paper); color: var(--night); }
.btn-night { background: var(--night); color: var(--paper); }
.btn-ghost { background: transparent; color: var(--paper); border-color: var(--paper); }
.btn:hover { filter: brightness(1.08); }
.btn-ghost:hover { background: rgba(243,245,244,.08); }
.btn.is-disabled { opacity: .55; cursor: not-allowed; filter: none; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 8px; }
.arrow-link { display: inline-block; margin-top: 18px; font-weight: 600; color: var(--paper); padding: 6px 0; }
.arrow-link::after { content: " →"; }

/* chips (channel labels): solid channel color, night text, so they pass on night and paper */
.chip { display: inline-block; font-size: 13px; padding: 4px 8px; background: var(--ch); color: var(--night); text-transform: uppercase; border-radius: 2px; line-height: 1.2; }
.chip-1 { background: var(--cyan); } .chip-2 { background: var(--amber); } .chip-3 { background: var(--red); }
.chip-lg { font-size: 14px; padding: 6px 10px; margin-bottom: 18px; }

/* header */
.site-header { position: sticky; top: 0; z-index: 40; background: var(--night); border-bottom: 1px solid var(--night-line); }
.header-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 60px; flex-wrap: wrap; }
.wordmark { font-weight: 700; font-size: 20px; letter-spacing: .03em; text-decoration: none; padding: 8px 0; }
.menu-btn { font: 500 14px var(--mono); text-transform: uppercase; letter-spacing: .08em; color: var(--paper); background: transparent; border: 1px solid var(--steel); padding: 8px 12px; min-height: 44px; border-radius: 2px; cursor: pointer; }
.site-nav { display: none; width: 100%; }
.nav-open .site-nav { display: block; }
.site-nav ul { list-style: none; margin: 0; padding: 4px 0 16px; }
.site-nav a { display: block; padding: 12px 0; text-decoration: none; font-weight: 600; font-size: 18px; border-top: 1px solid var(--night-line); }
.site-nav a[aria-current="page"] { color: var(--cyan); }
.ch-2 .site-nav a[aria-current="page"] { color: var(--amber); }
.ch-3 .site-nav a[aria-current="page"] { color: var(--red); }
.header-actions { display: none; }

/* sticky call bar (phones) */
.callbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 50; display: grid; grid-template-columns: 1.35fr 1fr; gap: 8px;
  padding: 8px 10px calc(8px + env(safe-area-inset-bottom)); background: var(--night); border-top: 1px solid var(--night-line);
}
.callbar a { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 56px; text-decoration: none; border-radius: 2px; text-align: center; }
.callbar-call { background: var(--paper); color: var(--night); }
.callbar-num { font: 700 21px/1 var(--display); text-transform: uppercase; letter-spacing: .02em; }
.callbar-hours { font-size: 11px; letter-spacing: .02em; margin-top: 4px; color: var(--ink-muted); }
.callbar-quote { border: 2px solid var(--paper); color: var(--paper); font: 700 20px/1 var(--display); text-transform: uppercase; }

/* bands */
.band { padding: 56px 0; }
.band-night { background: var(--night); color: var(--paper); }
.band-paper { background: var(--paper); color: var(--night); }

/* camera surfaces */
.cam { position: relative; overflow: hidden; background-color: var(--night-2);
  background-image: repeating-linear-gradient(0deg, rgba(255,255,255,.025) 0 1px, transparent 1px 4px); }
.cam-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; animation: fadein .6s ease; }
@keyframes fadein { from { opacity: 0; } to { opacity: 1; } }
.cam-tag { position: absolute; z-index: 3; top: 12px; left: 12px; margin: 0; display: inline-flex; align-items: center; gap: 8px;
  font-size: 12px; text-transform: uppercase; color: var(--paper); background: rgba(10,20,24,.82); padding: 6px 10px; border-radius: 2px; }
.cam-time { position: absolute; z-index: 3; top: 14px; right: 12px; margin: 0; font-size: 12px; color: var(--paper); background: rgba(10,20,24,.82); padding: 4px 8px; border-radius: 2px; }
.cam-time:empty, .cam-note:empty { display: none; }
.cam-note { position: absolute; z-index: 3; left: 12px; right: 12px; top: 52px; margin: 0; font-size: 13px; color: var(--paper); }
.cam[data-state="stale"] .dot, .cam[data-state="offline"] .dot { background: var(--steel); animation: none; }
.cam[data-state="stale"] .cam-img { filter: grayscale(1) brightness(.8); }

/* hero */
.hero { position: relative; min-height: calc(100svh - 61px - var(--callbar-h)); display: flex; align-items: flex-end; }
.cam-hero { position: absolute; inset: 0; }
.cam-scrim { position: absolute; inset: 0; z-index: 2;
  background: linear-gradient(180deg, rgba(10,20,24,.15) 0%, rgba(10,20,24,.3) 35%, rgba(10,20,24,.8) 70%, rgba(10,20,24,.95) 100%); }
.hero-body { position: relative; z-index: 4; padding-top: 120px; padding-bottom: 36px; }
.hero .h1 { max-width: 9ch; }
.hero .lede { color: var(--paper); }
.hero .hours { color: var(--mist); }
/* text backing: the scrim stays light over the picture; this keeps the hero text at AA even over a bright still
   (worst case, pure white under it: headline 5.2:1, lede 10:1, hours 10:1) */
.hero-body::before { content: ""; position: absolute; z-index: -1; top: 80px; bottom: 0; left: 0; right: 0;
  background: rgba(10,20,24,.55);
  -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 40px); mask-image: linear-gradient(180deg, transparent 0, #000 40px); }

/* doors */
.doors { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.door a { display: flex; flex-direction: column; gap: 10px; padding: 22px 20px 20px; background: var(--night-2); border-top: 4px solid var(--ch); text-decoration: none; height: 100%; }
.door-1 { --ch: var(--cyan); } .door-2 { --ch: var(--amber); } .door-3 { --ch: var(--red); }
.door .chip { align-self: flex-start; }
.door-name { font-weight: 700; font-size: 34px; line-height: 1; }
.door-text { color: var(--mist); }
.door-link { color: var(--ch); font-weight: 600; margin-top: auto; }
.door-link::after { content: " →"; }
.door a:hover .door-link { text-decoration: underline; }

/* promise */
.promise .h2 { max-width: 16ch; }
.promise { border-top: 6px solid var(--night); }
.promise + .band-paper { padding-top: 0; }

/* testimonials */
.quotes { display: grid; gap: 18px; }
.quote { margin: 0; background: var(--white); padding: 24px 22px; border-left: 4px solid var(--night); }
.quote-ch1 { border-left-color: var(--cyan); } .quote-ch2 { border-left-color: var(--amber); } .quote-ch3 { border-left-color: var(--red); }
.quote blockquote { margin: 0 0 14px; font-size: 18px; }
.quote blockquote p::before { content: "“"; font: 700 52px/0 var(--display); vertical-align: -18px; margin-right: 4px; }
.quote figcaption { font-size: 13px; text-transform: uppercase; color: var(--ink-muted); }

/* live teaser */
.teaser-grid { display: grid; gap: 28px; align-items: center; }
.label-live { display: flex; align-items: center; gap: 10px; color: var(--paper); }

/* company pages */
.co-hero { padding: 48px 0 56px; border-top: 6px solid var(--ch); }
body:not([class*="ch-"]) .co-hero { border-top-color: var(--night-line); }
.svcs { display: grid; gap: 16px; }
.svc { background: var(--white); padding: 24px 22px 10px; border-left: 4px solid var(--ch); }
.svc p { max-width: 60ch; }
.portal .h2 { font-size: clamp(30px, 6vw, 44px); }
.cta { border-top: 1px solid var(--night-line); }
.cta .h2 { margin-bottom: 20px; }

/* live cameras page (also the Home "Live now" tiles) */
.multiview-grid { list-style: none; margin: 28px 0 0; padding: 0; display: grid; gap: 20px; }
.tile { margin: 0; }
.multiview-home { margin: 0; grid-template-columns: 1fr 1fr; gap: 12px; }
.multiview-home .cam-tag { top: 6px; left: 6px; font-size: 10px; padding: 4px 6px; gap: 6px; }
.multiview-home .cam-tag .dot { width: 7px; height: 7px; }
.multiview-home .cam-time { display: none; }
.multiview-home .tile-caption { font-size: 12px; margin-top: 6px; }
.cam-tile { display: block; width: 100%; aspect-ratio: 16/9; padding: 0; border: 1px solid var(--night-line); cursor: zoom-in; color: inherit; font: inherit; text-align: left; }
.cam-tile:hover { border-color: var(--steel); }
.cam-tile .cam-time { top: auto; bottom: 10px; right: 10px; }
.tile-caption { margin: 10px 0 0; font-size: 14px; text-transform: uppercase; color: var(--steel); }
.tile-down { margin: 6px 0 0; font-size: 15px; color: var(--mist); }
.cam-dialog { width: min(1100px, 100vw - 24px); max-width: none; padding: 0; border: 1px solid var(--night-line); background: var(--night); color: var(--paper); }
.cam-dialog::backdrop { background: rgba(5,10,12,.85); }
.cam-dialog-bar { display: flex; justify-content: space-between; align-items: center; padding: 8px 8px 8px 0; }
.cam-dialog-bar .cam-tag { position: static; }
.cam-dialog-close { background: transparent; color: var(--paper); border: 1px solid var(--steel); width: 44px; height: 44px; font-size: 26px; line-height: 1; cursor: pointer; border-radius: 2px; }
.cam-dialog-frame { aspect-ratio: 16/9; background: var(--night-2); }
.cam-dialog-frame iframe { width: 100%; height: 100%; border: 0; display: block; }

/* form */
.quote-form { margin-top: 24px; background: var(--white); padding: 24px 20px; color: var(--night); }
.field { margin: 0 0 20px; border: 0; padding: 0; }
.field > label, .field legend { display: block; font-weight: 600; margin-bottom: 6px; padding: 0; }
.hint { font-size: 13px; color: var(--ink-muted); margin: -2px 0 6px; letter-spacing: .02em; }
.quote-form input:not([type="radio"]), .quote-form select, .quote-form textarea {
  width: 100%; min-height: 48px; padding: 10px 12px; font: 400 17px var(--sans); color: var(--night);
  background: var(--white); border: 2px solid var(--ink-muted); border-radius: 2px; }
.quote-form [aria-invalid="true"] { border-color: var(--err); }
.radio { display: inline-flex; align-items: center; gap: 8px; margin-right: 22px; min-height: 44px; font-weight: 400; }
.radio input { width: 22px; height: 22px; accent-color: var(--night); }
.err { color: var(--err); font-weight: 600; font-size: 15px; margin: 6px 0 0; }
.quote-form .btn { width: 100%; margin-bottom: 12px; }

/* footer */
.site-footer { background: var(--night); border-top: 1px solid var(--night-line); padding: 44px 0 20px; font-size: 15px; }
.footer-grid { display: grid; gap: 24px; }
.footer-group { font: 700 24px var(--display); text-transform: uppercase; letter-spacing: .03em; margin-bottom: 12px; }
.footer-cos, .footer-links { list-style: none; margin: 0; padding: 0; }
.footer-cos li, .footer-links li { padding: 6px 0; }
.footer-cos a { text-decoration: none; display: inline-flex; gap: 10px; align-items: center; }
.footer-cos a:hover, .footer-links a:hover { text-decoration: underline; }
.pending-link { color: var(--steel); }
.footer-base { border-top: 1px solid var(--night-line); margin-top: 28px; padding-top: 16px; color: var(--steel); display: flex; flex-wrap: wrap; gap: 4px 24px; font-size: 13px; }
.footer-base p { margin: 0; }

/* larger screens */
@media (min-width: 640px) {
  :root { --gutter: 32px; }
  .wordmark { font-size: 24px; }
  .doors { grid-template-columns: repeat(3, 1fr); }
  .quotes { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
  .svcs { grid-template-columns: 1fr 1fr; }
  .multiview-grid { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1.3fr 1fr 1fr; }
  .quote-form { padding: 32px; }
  .quote-form .btn { width: auto; }
}
@media (min-width: 960px) {
  body { padding-bottom: 0; }
  .callbar { display: none; }
  .menu-btn { display: none; }
  .header-row { padding-top: 10px; }
  .header-actions { display: flex; gap: 10px; }
  .site-nav { display: block; order: 3; }
  .site-nav ul { display: flex; gap: 26px; padding: 0; }
  .site-nav a { border: 0; font-size: 15px; padding: 10px 0 12px; border-bottom: 3px solid transparent; }
  .site-nav a[aria-current="page"] { border-bottom-color: currentColor; }
  .hero { min-height: min(86vh, 860px); }
  .hero-body { padding-bottom: 72px; }
  .hero-body::before { left: calc(50% - 50vw); right: auto; width: calc(50vw - 50% + 760px);
    background: linear-gradient(90deg, rgba(10,20,24,.55) 0, rgba(10,20,24,.55) 70%, rgba(10,20,24,0) 100%); }
  .band { padding: 88px 0; }
  .co-hero { padding: 80px 0 88px; }
  .teaser-grid { grid-template-columns: 1fr 1fr; gap: 56px; }
  .cam-tag { font-size: 13px; top: 18px; left: 18px; }
}
