/* ==========================================================================
   Techspire Summits - base layer
   Typography, focus, and the accessibility affordances every page needs.
   Loads after the vendor theme so it wins on the elements it claims.
   ========================================================================== */

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

html {
  -webkit-text-size-adjust: 100%;   /* keep landscape text at author size */
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--ts-bg);
  color: var(--ts-text);
  font-family: var(--ts-font-body);
  font-size: var(--ts-text-base);
  line-height: var(--ts-leading-normal);
  font-weight: var(--ts-weight-regular);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  /* Long URLs, IDs and pasted user content reflow instead of forcing the
     page to scroll sideways. Prose still breaks on word boundaries. */
  overflow-wrap: break-word;
}

/* --------------------------------------------------------------------------
   Headings. Display face, tight leading, and balanced wrapping so a short
   heading does not leave one word stranded on its own line. text-wrap is a
   progressive hint - browsers without it simply wrap normally.
   -------------------------------------------------------------------------- */
h1, h2, h3, h4, h5, h6,
.ts-h1, .ts-h2, .ts-h3, .ts-h4 {
  margin: 0 0 var(--ts-space-4);
  font-family: var(--ts-font-display);
  font-weight: var(--ts-weight-semibold);
  line-height: var(--ts-leading-tight);
  letter-spacing: var(--ts-tracking-tight);
  color: var(--ts-text);
  text-wrap: balance;
}

h1, .ts-h1 { font-size: var(--ts-text-4xl); }
h2, .ts-h2 { font-size: var(--ts-text-3xl); }
h3, .ts-h3 { font-size: var(--ts-text-2xl); }
h4, .ts-h4 { font-size: var(--ts-text-xl); }
h5         { font-size: var(--ts-text-lg); }
h6         { font-size: var(--ts-text-base); }

p { margin: 0 0 var(--ts-space-4); }
p:last-child { margin-bottom: 0; }

/* Keep long-form copy inside a readable measure wherever it is used. */
.ts-prose { max-width: var(--ts-measure); }
.ts-prose p { line-height: var(--ts-leading-relaxed); color: var(--ts-text-muted); }

.ts-lead {
  font-size: var(--ts-text-lg);
  line-height: var(--ts-leading-relaxed);
  color: var(--ts-text-muted);
  max-width: var(--ts-measure);
}

.ts-eyebrow {
  display: inline-block;
  font-family: var(--ts-font-display);
  font-size: var(--ts-text-xs);
  font-weight: var(--ts-weight-semibold);
  letter-spacing: var(--ts-tracking-wide);
  text-transform: uppercase;
  color: var(--ts-accent);
  margin-bottom: var(--ts-space-3);
}

/* Prices, counts, timers and table figures stop jittering as digits change. */
.ts-tabular, .ts-price, td.ts-num, th.ts-num { font-variant-numeric: tabular-nums; }

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

hr { border: 0; border-top: 1px solid var(--ts-divider); margin: var(--ts-space-8) 0; }

img, svg, video { max-width: 100%; height: auto; }

/* --------------------------------------------------------------------------
   Focus. A visible ring on every keyboard-focused control, never removed.
   :focus-visible so a mouse click does not leave a ring behind.
   -------------------------------------------------------------------------- */
:focus-visible {
  outline: 3px solid var(--ts-ring);
  outline-offset: 2px;
  border-radius: var(--ts-radius-sm);
}
/* Only suppress the default ring where the rule above provides its own. */
:focus:not(:focus-visible) { outline: none; }

/* Sticky headers must not cover the control the keyboard just moved to. */
[id], :target { scroll-margin-top: calc(var(--ts-header-h, 72px) + var(--ts-space-4)); }

/* --------------------------------------------------------------------------
   Skip link - first tab stop on the page, visible only once focused.
   -------------------------------------------------------------------------- */
.ts-skip-link {
  position: absolute;
  left: var(--ts-space-4);
  top: -100px;
  z-index: var(--ts-z-toast);
  padding: var(--ts-space-3) var(--ts-space-5);
  background: var(--ts-accent);
  color: var(--ts-text-on-accent);
  font-weight: var(--ts-weight-semibold);
  border-radius: var(--ts-radius);
  box-shadow: var(--ts-shadow-lg);
  transition: top var(--ts-dur-fast) var(--ts-ease);
}
.ts-skip-link:focus { top: var(--ts-space-4); color: var(--ts-text-on-accent); }

/* Visually hidden but still announced. */
.ts-sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0;
}

/* --------------------------------------------------------------------------
   Layout helpers
   -------------------------------------------------------------------------- */
.ts-container {
  width: 100%;
  max-width: var(--ts-container);
  margin-inline: auto;
  padding-inline: var(--ts-gutter);
}
.ts-container--wide { max-width: 1400px; }
.ts-container--narrow { max-width: 820px; }

.ts-section { padding-block: var(--ts-section-y); }
.ts-section--tight { padding-block: calc(var(--ts-section-y) * .6); }
.ts-section--alt { background: var(--ts-bg-subtle); }
.ts-section--ink { background: var(--ts-surface-inverse); color: var(--ts-text-inverse); }
.ts-section--ink h1, .ts-section--ink h2,
.ts-section--ink h3, .ts-section--ink h4 { color: var(--ts-text-inverse); }
.ts-section--ink p { color: rgba(255,255,255,.78); }

.ts-stack > * + * { margin-top: var(--ts-space-4); }
.ts-stack-lg > * + * { margin-top: var(--ts-space-8); }

.ts-grid { display: grid; gap: var(--ts-space-6); }
.ts-grid--2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); }
.ts-grid--3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); }
.ts-grid--4 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); }

/* Wide content scrolls inside its own box; the page body never does. */
.ts-scroll-x { overflow-x: auto; -webkit-overflow-scrolling: touch; }

.ts-section-head { margin-bottom: var(--ts-space-10); max-width: var(--ts-measure); }
.ts-section-head p { color: var(--ts-text-muted); font-size: var(--ts-text-lg); }

/* --------------------------------------------------------------------------
   Reduced motion. Honour the system setting: cut transforms and long
   transitions, keep instantaneous state feedback so the UI still responds.
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
  .ts-reveal { opacity: 1 !important; transform: none !important; }
}

/* Windows high-contrast mode: keep borders that are otherwise painted. */
@media (forced-colors: active) {
  .ts-btn, .ts-card, .ts-input, .ts-badge { border: 1px solid ButtonBorder; }
  :focus-visible { outline: 3px solid Highlight; }
}

/* ==========================================================================
   Technology partner credit
   --------------------------------------------------------------------------
   The one component every surface shares -- hub footer, conference-site
   footer, admin panel -- so it lives in base.css, which all three layouts
   load. Restrained by design: a partner credit is an attribution, not a
   second brand competing with the conference's own.
   ========================================================================== */
.ts-techpartner {
  display: flex;
  align-items: center;
  gap: var(--ts-space-3);
  flex-wrap: wrap;
}

.ts-techpartner__label {
  font-family: var(--ts-font-display);
  font-size: var(--ts-text-xs);
  font-weight: var(--ts-weight-medium);
  letter-spacing: var(--ts-tracking-wide);
  text-transform: uppercase;
  white-space: nowrap;
}

/* A hairline rule between the label and the mark. Cleaner than a bullet or a
   slash, and it disappears when the pair wraps onto two lines. */
.ts-techpartner--inline .ts-techpartner__label::after {
  content: "";
  display: inline-block;
  width: 1px;
  height: 1em;
  margin-left: var(--ts-space-3);
  vertical-align: -0.15em;
  background: currentColor;
  opacity: .35;
}

.ts-techpartner__link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;              /* it is a link people tap */
  text-decoration: none;
  color: inherit;
  border-radius: var(--ts-radius-sm);
  transition: opacity var(--ts-dur-fast) var(--ts-ease);
}
.ts-techpartner__link:hover { opacity: 1; }
.ts-techpartner__link:focus-visible { outline: 3px solid currentColor; outline-offset: 3px; }

.ts-techpartner__logo {
  height: 26px;
  width: auto;
  display: block;
}

.ts-techpartner__name {
  font-family: var(--ts-font-display);
  font-size: var(--ts-text-sm);
  font-weight: var(--ts-weight-semibold);
  letter-spacing: .06em;
}

/* ---- tone ---------------------------------------------------------------
   The artwork is a dark navy lockup. On a dark footer it has to be lifted to
   white; on a light surface it is used as supplied. */
.ts-techpartner--dark { color: rgba(255,255,255,.62); }
.ts-techpartner--dark .ts-techpartner__logo {
  filter: brightness(0) invert(1);
  opacity: .78;
  transition: opacity var(--ts-dur-fast) var(--ts-ease);
}
.ts-techpartner--dark .ts-techpartner__link:hover .ts-techpartner__logo { opacity: 1; }

.ts-techpartner--light { color: var(--ts-text-subtle); }
.ts-techpartner--light .ts-techpartner__logo {
  opacity: .72;
  transition: opacity var(--ts-dur-fast) var(--ts-ease);
}
.ts-techpartner--light .ts-techpartner__link:hover .ts-techpartner__logo { opacity: 1; }

/* ---- alignment ---------------------------------------------------------- */
.ts-techpartner--center {
  flex-direction: column;
  align-items: center;
  gap: var(--ts-space-2);
  text-align: center;
}
.ts-techpartner--center .ts-techpartner__label::after { display: none; }

@media (max-width: 480px) {
  /* Stack rather than let the label and mark wrap into an awkward L shape. */
  .ts-techpartner--inline { flex-direction: column; align-items: flex-start; gap: var(--ts-space-2); }
  .ts-techpartner--inline .ts-techpartner__label::after { display: none; }
}

/* Registered company address, under the bottom bar of both footers. Plain,
   small and centred: it is there to be found, not to compete with the links. */
.ts-company-address {
  margin: var(--ts-space-4) 0 0;
  font-style: normal;
  font-size: var(--ts-text-xs, .8125rem);
  line-height: 1.6;
  color: rgba(255,255,255,.55);
  text-align: center;
  overflow-wrap: anywhere;
}
.ts-company-address strong { color: rgba(255,255,255,.75); font-weight: 600; }
