/* ==========================================================================
   Protocol 42 — Theme Styles
   White-glossy · black accents · electric cyan / magenta / lime spikes
   All classes here are usable from the WordPress block editor ("Additional
   CSS class(es)") and from Elementor (Advanced → CSS Classes).
   ========================================================================== */

:root {
  --p42-white: #ffffff;
  --p42-offwhite: #f7f7f9;
  --p42-mist: #eef0f4;
  --p42-black: #0a0a0c;
  --p42-ink: #16161a;
  --p42-grey: #5c5f68;
  --p42-cyan: #00e0ff;
  --p42-magenta: #ff2e9e;
  --p42-lime: #b8f425;
  --p42-violet: #7c3aed;
  --p42-grad: linear-gradient(120deg, var(--p42-cyan), var(--p42-violet) 45%, var(--p42-magenta));
  --p42-radius: 20px;
  --p42-shadow-soft: 0 2px 6px rgba(10,10,12,.05), 0 18px 44px -18px rgba(10,10,12,.18);
  --p42-shadow-lift: 0 4px 10px rgba(10,10,12,.06), 0 34px 70px -24px rgba(10,10,12,.28);
  --p42-glass-edge: inset 0 1px 0 rgba(255,255,255,.85);
  --p42-font-display: "Space Grotesk", "Inter", -apple-system, sans-serif;
  --p42-font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --p42-ease: cubic-bezier(.22, 1, .36, 1);
}

/* ---------- Base ---------- */
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--p42-white);
  color: var(--p42-ink);
  font-family: var(--p42-font-body);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3, h4, h5 {
  font-family: var(--p42-font-display);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.08;
  color: var(--p42-black);
  margin: 0 0 .5em;
}
h1 { font-size: clamp(2.6rem, 6.5vw, 5rem); }
h2 { font-size: clamp(2rem, 4vw, 3.2rem); }
h3 { font-size: clamp(1.3rem, 2.2vw, 1.7rem); }
p { margin: 0 0 1.2em; }
a { color: inherit; }
img { max-width: 100%; height: auto; }

.p42-container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* ---------- Header / Nav ---------- */
.p42-header {
  position: fixed; inset: 0 0 auto 0; z-index: 900;
  padding: 14px 0;
  transition: all .4s var(--p42-ease);
}
.p42-header.is-scrolled {
  background: rgba(255,255,255,.78);
  backdrop-filter: blur(18px) saturate(1.4);
  -webkit-backdrop-filter: blur(18px) saturate(1.4);
  box-shadow: 0 1px 0 rgba(10,10,12,.06), 0 12px 30px -18px rgba(10,10,12,.18);
}
.p42-header .p42-container { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.p42-logo {
  font-family: var(--p42-font-display);
  font-weight: 700; font-size: 1.25rem; letter-spacing: -.02em;
  text-decoration: none; color: var(--p42-black);
  display: inline-flex; align-items: baseline; gap: 2px;
}
.p42-logo .p42-logo-42 {
  background: var(--p42-grad);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.p42-nav ul { list-style: none; display: flex; gap: 28px; margin: 0; padding: 0; }
.p42-nav a {
  text-decoration: none; font-size: .92rem; font-weight: 500; color: var(--p42-ink);
  position: relative; padding: 4px 0;
}
.p42-nav a::after {
  content: ""; position: absolute; left: 0; bottom: -2px; height: 2px; width: 0;
  background: var(--p42-grad); border-radius: 2px; transition: width .35s var(--p42-ease);
}
.p42-nav a:hover::after, .p42-nav .current-menu-item a::after { width: 100%; }
/* Custom logo (Appearance > Customize > Site Identity) — always constrained */
.p42-header .custom-logo-link,
.p42-footer .custom-logo-link { display: inline-flex; align-items: center; line-height: 0; }
.p42-header img.custom-logo,
.p42-header .custom-logo-link img {
  max-height: 48px !important; width: auto !important; height: auto;
  max-width: 260px; object-fit: contain;
}
.p42-footer img.custom-logo,
.p42-footer .custom-logo-link img {
  max-height: 40px !important; width: auto !important; max-width: 220px; object-fit: contain;
}
@media (max-width: 880px) {
  .p42-header img.custom-logo, .p42-header .custom-logo-link img { max-height: 38px !important; max-width: 190px; }
}

.p42-nav-toggle { display: none; background: none; border: 0; cursor: pointer; padding: 8px; }
.p42-nav-toggle span { display: block; width: 22px; height: 2px; background: var(--p42-black); margin: 5px 0; border-radius: 2px; transition: .3s; }

@media (max-width: 880px) {
  .p42-nav-toggle { display: block; }
  .p42-nav { position: fixed; inset: 0; background: rgba(255,255,255,.96); backdrop-filter: blur(20px);
    display: none; align-items: center; justify-content: center; }
  .p42-nav.is-open { display: flex; }
  .p42-nav ul { flex-direction: column; text-align: center; gap: 20px; }
  .p42-nav a { font-size: 1.4rem; }
}

/* ---------- Buttons ---------- */
.p42-btn, .p42-btn-dark a, .p42-btn-light a,
.wp-block-button.p42-btn-dark .wp-block-button__link,
.wp-block-button.p42-btn-light .wp-block-button__link {
  display: inline-block;
  padding: 15px 34px;
  border-radius: 999px;
  font-weight: 600; font-size: .95rem;
  text-decoration: none;
  transition: transform .35s var(--p42-ease), box-shadow .35s var(--p42-ease);
  will-change: transform;
}
.p42-btn-dark a, .wp-block-button.p42-btn-dark .wp-block-button__link {
  background: linear-gradient(180deg, #1d1d22, var(--p42-black));
  color: #fff !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.18), 0 14px 30px -12px rgba(10,10,12,.5);
}
.p42-btn-dark a:hover, .wp-block-button.p42-btn-dark .wp-block-button__link:hover {
  transform: translateY(-2px);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.18), 0 20px 44px -14px rgba(10,10,12,.55), 0 0 0 3px rgba(0,224,255,.25);
}
.p42-btn-light a, .wp-block-button.p42-btn-light .wp-block-button__link {
  background: linear-gradient(180deg, #ffffff, #f2f3f6);
  color: var(--p42-black) !important;
  box-shadow: var(--p42-glass-edge), 0 2px 4px rgba(10,10,12,.08), 0 14px 30px -14px rgba(10,10,12,.22);
  border: 1px solid rgba(10,10,12,.08);
}
.p42-btn-light a:hover, .wp-block-button.p42-btn-light .wp-block-button__link:hover {
  transform: translateY(-2px);
  box-shadow: var(--p42-glass-edge), 0 4px 8px rgba(10,10,12,.08), 0 22px 44px -16px rgba(255,46,158,.35);
}

/* ---------- Sections ---------- */
.p42-section { padding: 110px 0; position: relative; }
.p42-section-tight { padding: 70px 0; }
.p42-section-offwhite { background: var(--p42-offwhite); }
.p42-section-dark { background: var(--p42-black); color: #d9dae0; }
.p42-section-dark h1, .p42-section-dark h2, .p42-section-dark h3 { color: #fff; }

/* Eyebrow label */
.p42-eyebrow {
  display: inline-block;
  font-family: var(--p42-font-display);
  font-size: .78rem; font-weight: 600;
  letter-spacing: .18em; text-transform: uppercase;
  color: var(--p42-grey);
  padding: 8px 18px; border-radius: 999px;
  background: linear-gradient(180deg, #fff, #f4f5f8);
  border: 1px solid rgba(10,10,12,.08);
  box-shadow: var(--p42-glass-edge), 0 6px 16px -8px rgba(10,10,12,.15);
  margin-bottom: 26px;
}
.p42-section-dark .p42-eyebrow {
  background: rgba(255,255,255,.06); border-color: rgba(255,255,255,.12);
  color: #b9bac2; box-shadow: inset 0 1px 0 rgba(255,255,255,.08);
}

/* Gradient text spike */
.p42-gradient-text {
  background: var(--p42-grad);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ---------- Hero ---------- */
.p42-hero {
  min-height: 92vh;
  display: flex; align-items: center;
  padding: 160px 0 120px;
  position: relative; overflow: hidden;
}
.p42-hero-inner { position: relative; z-index: 2; max-width: 900px; }
.p42-hero .p42-sub {
  font-size: clamp(1.05rem, 1.6vw, 1.3rem);
  color: var(--p42-grey); max-width: 620px; margin-bottom: 40px;
}

/* ---------- Glossy cards ---------- */
.p42-card {
  background: linear-gradient(165deg, #ffffff 0%, #fbfbfd 60%, #f4f5f8 100%);
  border: 1px solid rgba(10,10,12,.07);
  border-radius: var(--p42-radius);
  padding: 40px 34px;
  box-shadow: var(--p42-glass-edge), var(--p42-shadow-soft);
  transition: transform .5s var(--p42-ease), box-shadow .5s var(--p42-ease);
  position: relative; overflow: hidden;
}
.p42-card::before {
  content: ""; position: absolute; inset: 0 0 auto 0; height: 3px;
  background: var(--p42-grad); opacity: 0; transition: opacity .4s;
}
.p42-card:hover { transform: translateY(-6px); box-shadow: var(--p42-glass-edge), var(--p42-shadow-lift); }
.p42-card:hover::before { opacity: 1; }
.p42-card h3 { margin-top: .4em; }
.p42-card .p42-card-icon {
  width: 52px; height: 52px; border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.4rem; font-family: var(--p42-font-display); font-weight: 700; color: #fff;
  box-shadow: 0 10px 22px -8px rgba(10,10,12,.35);
}
.p42-icon-cyan { background: linear-gradient(135deg, var(--p42-cyan), #0077ff); }
.p42-icon-magenta { background: linear-gradient(135deg, var(--p42-magenta), var(--p42-violet)); }
.p42-icon-lime { background: linear-gradient(135deg, var(--p42-lime), #21c064); color: var(--p42-black) !important; }

/* accent glow variants (colored shadow on hover) */
.p42-glow-cyan:hover { box-shadow: var(--p42-glass-edge), 0 4px 10px rgba(10,10,12,.05), 0 34px 70px -24px rgba(0,224,255,.45); }
.p42-glow-magenta:hover { box-shadow: var(--p42-glass-edge), 0 4px 10px rgba(10,10,12,.05), 0 34px 70px -24px rgba(255,46,158,.45); }
.p42-glow-lime:hover { box-shadow: var(--p42-glass-edge), 0 4px 10px rgba(10,10,12,.05), 0 34px 70px -24px rgba(140,200,20,.5); }

/* ---------- Stats band ---------- */
.p42-stat { text-align: center; }
.p42-stat .p42-stat-number {
  font-family: var(--p42-font-display);
  font-size: clamp(2.4rem, 4.4vw, 3.6rem); font-weight: 700; letter-spacing: -.03em;
  color: var(--p42-black); display: block; line-height: 1;
}
.p42-stat .p42-stat-label {
  font-size: .82rem; letter-spacing: .14em; text-transform: uppercase; color: var(--p42-grey);
  margin-top: 10px; display: block;
}
.p42-section-dark .p42-stat .p42-stat-number { color: #fff; }
.p42-section-dark .p42-stat .p42-stat-label { color: #8f919b; }

/* ---------- Process steps ---------- */
.p42-step { position: relative; padding: 34px 30px 30px; }
.p42-step .p42-step-num {
  font-family: var(--p42-font-display); font-weight: 700;
  font-size: 3rem; line-height: 1;
  background: var(--p42-grad);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  display: block; margin-bottom: 14px;
}

/* ---------- Marquee rows (styled here, animated by P42 Effects) ---------- */
.p42-marquee {
  overflow: hidden; white-space: nowrap;
  padding: 26px 0;
  border-top: 1px solid rgba(10,10,12,.07);
  border-bottom: 1px solid rgba(10,10,12,.07);
  background: var(--p42-white);
}
.p42-marquee .p42-marquee-track { display: inline-block; }
.p42-marquee span {
  font-family: var(--p42-font-display); font-weight: 700;
  font-size: clamp(1.4rem, 3vw, 2.4rem); letter-spacing: -.02em;
  color: var(--p42-black); margin-right: 64px;
}
.p42-marquee span.p42-mq-alt { -webkit-text-stroke: 1.4px var(--p42-black); color: transparent; }

/* ---------- Portfolio / OddsEdge mockup ---------- */
.p42-browser-mock {
  background: #101418; border-radius: 18px; overflow: hidden;
  box-shadow: 0 2px 0 rgba(255,255,255,.06) inset, 0 40px 80px -30px rgba(10,10,12,.5);
  border: 1px solid rgba(255,255,255,.08);
  font-family: var(--p42-font-display);
}
.p42-browser-bar { display: flex; gap: 7px; padding: 13px 16px; background: #181d23; }
.p42-browser-bar i { width: 11px; height: 11px; border-radius: 50%; background: #2c333b; }
.p42-browser-bar i:nth-child(1) { background: #ff5f57; } .p42-browser-bar i:nth-child(2) { background: #febc2e; } .p42-browser-bar i:nth-child(3) { background: #28c840; }
.p42-mock-body { padding: 38px 34px 42px; color: #e8f9ef; }
.p42-mock-pill {
  display: inline-block; font-size: .68rem; letter-spacing: .16em; font-weight: 600;
  color: #52e8a4; background: rgba(82,232,164,.12); border: 1px solid rgba(82,232,164,.3);
  padding: 6px 14px; border-radius: 999px; margin-bottom: 16px; text-transform: uppercase;
}
.p42-mock-body h4 { color: #fff; font-size: clamp(1.5rem, 2.6vw, 2.2rem); margin: 0 0 10px; letter-spacing: -.02em; }
.p42-mock-body p { color: #9fb3a9; font-size: .95rem; margin: 0 0 22px; }
.p42-mock-stats { display: flex; gap: 26px; flex-wrap: wrap; }
.p42-mock-stats b { display: block; color: #52e8a4; font-size: 1.25rem; }
.p42-mock-stats small { color: #7d8f86; font-size: .72rem; letter-spacing: .1em; text-transform: uppercase; }

/* ---------- Manifesto / prose ---------- */
.p42-manifesto p {
  font-size: clamp(1.15rem, 1.9vw, 1.45rem);
  line-height: 1.7; color: var(--p42-ink);
}
.p42-manifesto .p42-lede {
  font-family: var(--p42-font-display);
  font-size: clamp(1.5rem, 2.6vw, 2.1rem); font-weight: 600; letter-spacing: -.02em; line-height: 1.35;
}
.p42-underline-draw {
  background-image: linear-gradient(120deg, rgba(184,244,37,.55), rgba(0,224,255,.45));
  background-repeat: no-repeat; background-size: 100% 38%; background-position: 0 88%;
  padding: 0 2px;
}

/* ---------- Footer ---------- */
.p42-footer {
  background: var(--p42-black); color: #9a9ca6;
  padding: 80px 0 36px; font-size: .92rem;
}
.p42-footer h4 { color: #fff; font-size: .85rem; letter-spacing: .16em; text-transform: uppercase; margin-bottom: 18px; }
.p42-footer a { color: #9a9ca6; text-decoration: none; transition: color .25s; }
.p42-footer a:hover { color: var(--p42-cyan); }
.p42-footer ul { list-style: none; margin: 0; padding: 0; }
.p42-footer li { margin-bottom: 10px; }
.p42-footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 40px; margin-bottom: 60px; }
.p42-footer-bottom { border-top: 1px solid rgba(255,255,255,.09); padding-top: 28px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; }
@media (max-width: 880px) { .p42-footer-grid { grid-template-columns: 1fr 1fr; } }

/* ---------- Forms ---------- */
.p42-form input[type="text"], .p42-form input[type="email"], .p42-form textarea, .p42-form select,
.wp-block-search__input {
  width: 100%; box-sizing: border-box;
  padding: 15px 18px; border-radius: 14px;
  border: 1px solid rgba(10,10,12,.12);
  background: linear-gradient(180deg, #fff, #fafafc);
  font: inherit; color: var(--p42-ink);
  box-shadow: var(--p42-glass-edge), inset 0 2px 4px rgba(10,10,12,.03);
  transition: border-color .3s, box-shadow .3s;
}
.p42-form input:focus, .p42-form textarea:focus {
  outline: none; border-color: var(--p42-cyan);
  box-shadow: var(--p42-glass-edge), 0 0 0 4px rgba(0,224,255,.18);
}

/* ---------- Fine print / disclaimers ---------- */
.p42-disclaimer {
  font-size: .78rem;
  line-height: 1.6;
  color: var(--p42-grey);
  max-width: 860px;
  margin: 34px auto 0;
  padding-top: 22px;
  border-top: 1px solid rgba(10,10,12,.08);
}
.p42-section-dark .p42-disclaimer { color: #7e808a; border-top-color: rgba(255,255,255,.1); }

/* ---------- Utility ---------- */
.p42-text-center { text-align: center; }
/* Centre buttons inside centred sections (block editor, Elementor, previews) */
.p42-text-center .wp-block-buttons { display: flex; justify-content: center !important; }
.p42-text-center .elementor-widget-button { text-align: center; }
.p42-max-720 { max-width: 720px; margin-left: auto; margin-right: auto; }
.p42-mt-0 { margin-top: 0; } .p42-mb-0 { margin-bottom: 0; }

/* Grid helper for block editor columns parity */
.p42-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.p42-grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; }
.p42-grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 44px; align-items: center; }
@media (max-width: 980px) {
  .p42-grid-3, .p42-grid-4 { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .p42-grid-2, .p42-grid-3, .p42-grid-4 { grid-template-columns: 1fr; }
  .p42-section { padding: 70px 0; }
}

/* Respect reduced motion at the theme level too */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
