/* InnerVara Nexus — shell styles.
   Page bodies live in pages.css (generated from the design export by build.py).
   Everything here is hand-written: nav, footer, photo slots, form. */

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: 'Libre Franklin', system-ui, -apple-system, sans-serif;
  color: #0B1B30;
  background: #fff;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main { flex: 1; }

::selection { background: #EE7B23; color: #0B1B30; }

img { max-width: 100%; }

@keyframes ivFadeUp { from { transform: translateY(16px); } to { transform: none; } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
}

.iv-sr {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.iv-skip {
  position: absolute; left: -9999px; top: 0; z-index: 200;
  background: #0B1B30; color: #fff; padding: 12px 20px;
  font-size: 15px; font-weight: 600; text-decoration: none;
  border-radius: 0 0 8px 0;
}
.iv-skip:focus { left: 0; }

/* ============================================================ header / nav */

.iv-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,0.86);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid #E6ECF3;
}

.iv-nav {
  max-width: 1160px; margin: 0 auto; padding: 0 28px;
  min-height: 88px;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}

.iv-brand {
  display: flex; align-items: center; gap: 14px;
  text-decoration: none; padding: 8px 0; flex-shrink: 0;
}
.iv-brand-mark {
  width: 58px; height: 58px; flex-shrink: 0; display: block; object-fit: contain;
  filter: drop-shadow(0 2px 10px rgba(11,27,48,0.28));
}
.iv-brand-text {
  display: flex; flex-direction: column; align-items: flex-start; gap: 4px;
  text-align: left;
}
.iv-wordmark {
  font-family: 'Cinzel', Georgia, serif; font-weight: 700;
  font-size: 23px; line-height: 1; letter-spacing: .005em;
  background: linear-gradient(96deg,#16375C 0%,#2B639C 28%,#3E82BC 46%,#B8781C 78%,#DFA038 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: #1E5FA8;
}
.iv-subwordmark {
  font-family: 'Cinzel', Georgia, serif; font-size: 11.5px; line-height: 1;
  letter-spacing: .17em; text-transform: uppercase; color: #B0771D; font-weight: 600;
  white-space: nowrap;
}
.iv-pipe { color: #C9C3B6; }

.iv-menu { display: flex; align-items: center; gap: 6px; }
.iv-menu-links { display: flex; align-items: center; gap: 6px; }

/* text-align:center restores what these had as <button> in the design.
   No .is-active styling: the design highlights nothing, so the current page is
   marked with aria-current only. (Add a rule here if you ever want it shown.) */
.iv-navlink {
  font-size: 14.5px; font-weight: 500; color: #3A4A5E;
  padding: 9px 14px; border-radius: 8px; text-decoration: none;
  text-align: center; transition: background .15s, color .15s;
}
.iv-navlink:hover { background: #F4F7FB; color: #0B1B30; }

.iv-support {
  margin-left: 10px; background: #EE7B23;
  font-size: 14.5px; font-weight: 600; color: #0B1B30;
  padding: 11px 22px; border-radius: 999px; text-decoration: none;
  text-align: center; white-space: nowrap; transition: background .15s;
}
.iv-support:hover { background: #F2A53C; }

.iv-burger {
  display: none; width: 46px; height: 46px; padding: 11px;
  background: none; border: 1px solid #E0E8F1; border-radius: 10px;
  cursor: pointer; flex-direction: column; justify-content: space-between;
}
.iv-burger span {
  display: block; height: 2px; width: 100%; background: #0B1B30; border-radius: 2px;
  transition: transform .2s, opacity .2s;
}
.iv-burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(9px) rotate(45deg); }
.iv-burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.iv-burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-9px) rotate(-45deg); }

@media (max-width: 900px) {
  .iv-nav { min-height: 72px; padding: 0 20px; flex-wrap: wrap; }
  .iv-brand-mark { width: 46px; height: 46px; }
  .iv-wordmark { font-size: 19px; }
  .iv-subwordmark { font-size: 10px; letter-spacing: .14em; }
  .iv-burger { display: flex; }
  .iv-menu {
    display: none; width: 100%; flex-direction: column; align-items: stretch;
    gap: 4px; padding: 8px 0 18px; border-top: 1px solid #E6ECF3;
  }
  .iv-menu.is-open { display: flex; }
  .iv-menu-links { flex-direction: column; align-items: stretch; gap: 2px; }
  .iv-navlink { padding: 14px 12px; font-size: 16px; }
  .iv-support { margin: 10px 0 0; text-align: center; padding: 15px 22px; font-size: 16px; }
}

@media (max-width: 380px) {
  .iv-subwordmark { display: none; }
}

/* ================================================================== footer */

.iv-footer { background: #0B1B30; color: #B9C6D6; }
.iv-footer-grid {
  max-width: 1160px; margin: 0 auto; padding: 64px 28px 40px;
  display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 48px;
}
.iv-footer-logo {
  width: 236px; max-width: 100%; mix-blend-mode: screen;
  display: block; margin: -16px 0 2px -24px;
}
.iv-footer-wordmark {
  font-family: 'Cinzel', Georgia, serif; font-weight: 700; font-size: 26px;
  line-height: 1.1; color: #fff; margin-bottom: 12px;
}
/* Design has margin:0 on the first note and margin-top:8px on the second —
   a trailing bottom margin here made the footer 8px taller than the design. */
.iv-footer-note {
  margin: 0; font-size: 13.5px; line-height: 1.6;
  max-width: 320px; color: #8FA0B4;
}
.iv-footer-note + .iv-footer-note { margin-top: 8px; }
.iv-footer-head {
  font-size: 12px; letter-spacing: .12em; text-transform: uppercase;
  color: #5E718A; font-weight: 600; margin-bottom: 16px;
}
.iv-footer-col { display: flex; flex-direction: column; gap: 11px; align-items: flex-start; }
/* The Connect column in the design has no align-items, so its links stretch
   the column width and stay hoverable across the whole row. */
.iv-footer-col.is-stretch { align-items: stretch; }
.iv-footer-col.is-stretch > a:first-child { align-self: flex-start; }
.iv-flink {
  font-size: 14px; color: #B9C6D6; text-decoration: none; transition: color .15s;
}
.iv-flink:hover { color: #2BA8E0; }
/* A not-yet-configured link looks exactly like a live one — the design shows
   these at full colour — but doesn't navigate; site.js explains why on click. */
.iv-flink.is-pending { cursor: default; }
/* Explore links were <button>s in the design (centred); the Connect column's
   first item was a <button> with text-align:left, the rest are plain <a>. */
.iv-footer-col:not(.is-stretch) > .iv-flink { text-align: center; }
.iv-footer-col.is-stretch > .iv-flink:first-child { text-align: left; }
.iv-footer-bar { border-top: 1px solid rgba(255,255,255,0.08); }
.iv-footer-bar-inner {
  max-width: 1160px; margin: 0 auto; padding: 20px 28px;
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px;
  font-size: 12.5px; color: #5E718A;
}

@media (max-width: 900px) {
  .iv-footer-grid { grid-template-columns: 1fr 1fr; gap: 36px; }
  .iv-footer-grid > div:first-child { grid-column: 1 / -1; }
  .iv-footer-logo { margin-left: -18px; width: 200px; }
}
@media (max-width: 560px) {
  .iv-footer-grid { grid-template-columns: 1fr; padding: 48px 24px 32px; }
}

/* ========================================================= photo slots */
/* <image-slot> in the design export becomes a real <img> with a captioned
   empty state, so a missing photo reads as "not supplied yet" rather than a
   broken-image icon. Drop a file at assets/photos/<slot-id>.jpg to fill one. */

.iv-slot {
  margin: 0; position: relative; overflow: hidden; display: block;
}
.iv-slot img { width: 100%; height: 100%; display: block; }
.iv-slot.is-empty img { display: none; }

/* The empty state reproduces image-slot.js's own, so a slot with no photo
   looks exactly as it does in the design: 4% black fill, 1.5px dashed ring,
   the picture glyph, and the slot's caption. (The runtime's "or browse files"
   sub-line only shows inside the editor, so it is correctly absent here.) */
.iv-slot.is-empty {
  background: rgba(0, 0, 0, .04);
  font: 13px/1.3 system-ui, -apple-system, sans-serif;
  color: rgba(0, 0, 0, .55);
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 6px; text-align: center; padding: 12px;
}
.iv-slot.is-empty::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  border: 1.5px dashed rgba(0, 0, 0, .25); border-radius: inherit;
}
.iv-slot-icon { flex: none; opacity: .45; }
.iv-slot-cap {
  margin: 0; max-width: 90%; font-weight: 500; letter-spacing: .01em;
}

/* ==================================================== pending / share links */

/* Renders identically to the design (which had a dead href="#" here) but does
   not navigate — site.js intercepts the click. Fill the URL in links.json and
   it becomes a normal link. */
[data-pending] { cursor: default; }

.iv-toast {
  position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%) translateY(12px);
  background: #0B1B30; color: #fff; padding: 13px 22px; border-radius: 999px;
  font-size: 14.5px; font-weight: 500; z-index: 300;
  box-shadow: 0 12px 32px rgba(11,27,48,.28);
  opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s;
}
.iv-toast.is-on { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ================================================================ the form */
/* Selected-card styling is driven by an .is-on class toggled in site.js rather
   than :has(input:checked), so it also works on Safari < 15.4 and Firefox < 121.
   The !important is needed either way: the generated .sNNN classes carry the
   design's `border`/`background` shorthands. */

.iv-opt { transition: border-color .12s, background .12s; }
.iv-opt:hover { border-color: #2BA8E0 !important; background: #FAFCFE !important; }
.iv-opt.is-on { border-color: #1E5FA8 !important; background: #F5F9FD !important; }
.iv-opt:focus-within { outline: 2px solid #2BA8E0; outline-offset: 2px; }

.iv-field:focus { border-color: #2BA8E0; outline: 2px solid #2BA8E0; outline-offset: 1px; }
.iv-field.is-bad { border-color: #C2410C; }

.iv-err { margin: 7px 0 0; font-size: 14px; line-height: 1.5; color: #C2410C; }
.iv-err[hidden] { display: none; }

.iv-send { transition: background .15s; }
.iv-send:hover:not(:disabled) { background: #F2A53C; }
.iv-send:disabled { background: #B9C2CC; cursor: default; }
.iv-send:focus-visible { outline: 2px solid #2BA8E0; outline-offset: 2px; }

@media (max-width: 640px) {
  .iv-form-card { padding: 26px 20px 24px !important; }
}
