/* ==========================================================================
   MJR Technology Solutions — Black / Gold / Green dark system
   Inspired by supabase.com's bento-grid dark aesthetic + Apple-style
   restraint, rebuilt in brand colors. Loaded after theme.json base.
   ========================================================================== */

:root {
  --mjrts-ease: cubic-bezier(0.22, 1, 0.36, 1);
  --mjrts-gold: #C9A227;
  --mjrts-gold-bright: #E8C874;
  --mjrts-emerald: #2FA866;
  --mjrts-void: #0A0C0B;
  --mjrts-surface: #14180F;
  --mjrts-surface-raised: #1C2117;
  --mjrts-line: #2A3026;
}

/* ---- Signature dot-grid texture on dark surfaces ---- */
.mjrts-texture {
  position: relative;
  isolation: isolate;
}
.mjrts-texture::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image: radial-gradient(currentColor 1px, transparent 1px);
  background-size: 28px 28px;
  opacity: 0.06;
}
.mjrts-texture--light::before,
.mjrts-texture--dark::before { color: var(--mjrts-gold-bright); }
.mjrts-texture > * { position: relative; z-index: 1; }

/* ---- Ambient glow blobs behind hero/feature sections (Supabase signature) ---- */
.mjrts-glow {
  position: relative;
  isolation: isolate;
  overflow: hidden;
}
.mjrts-glow::after {
  content: "";
  position: absolute;
  top: -20%;
  left: 50%;
  width: 900px;
  height: 500px;
  transform: translateX(-50%);
  background: radial-gradient(ellipse at center, rgba(201,162,39,0.16) 0%, rgba(47,168,102,0.08) 45%, transparent 72%);
  z-index: 0;
  pointer-events: none;
  filter: blur(10px);
}
.mjrts-glow > * { position: relative; z-index: 1; }

/* ---- Hero network graphic wrapper ---- */
.mjrts-hero-graphic {
  position: absolute;
  top: 0;
  right: 0;
  height: 100%;
  width: min(46%, 560px);
  pointer-events: none;
  opacity: 0.9;
}
@media (max-width: 782px) {
  .mjrts-hero-graphic { display: none; }
}

/* ---- Gold "brushed metal" gradient for stat numbers & hero accents ---- */
.mjrts-gold-gradient-text {
  background: linear-gradient(115deg, var(--mjrts-gold) 10%, var(--mjrts-gold-bright) 45%, var(--mjrts-gold) 75%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ---- Bento card system (dark surface, subtle border, gold-glow on hover) ---- */
.mjrts-card {
  background: var(--mjrts-surface);
  border: 1px solid var(--mjrts-line);
  border-radius: 12px;
  box-shadow: 0 1px 0 rgba(255,255,255,0.03) inset, 0 12px 30px -18px rgba(0,0,0,0.6);
  transition: transform 320ms var(--mjrts-ease), box-shadow 320ms var(--mjrts-ease), border-color 320ms var(--mjrts-ease);
  will-change: transform;
}
.mjrts-card:hover {
  transform: translateY(-4px);
  border-color: rgba(201,162,39,0.35);
  box-shadow: 0 1px 0 rgba(255,255,255,0.04) inset, 0 20px 44px -18px rgba(201,162,39,0.18), 0 24px 48px -20px rgba(0,0,0,0.65);
}
.mjrts-card .mjrts-icon-badge { margin-bottom: 1rem; }

/* ---- Stat tile (Results section) ---- */
.mjrts-stat-tile {
  background: var(--mjrts-surface);
  border: 1px solid var(--mjrts-line);
  border-radius: 12px;
  box-shadow: 0 1px 0 rgba(255,255,255,0.03) inset, 0 14px 32px -18px rgba(0,0,0,0.6);
  transition: transform 320ms var(--mjrts-ease), border-color 320ms var(--mjrts-ease);
}
.mjrts-stat-tile:hover {
  transform: translateY(-3px) scale(1.01);
  border-color: rgba(201,162,39,0.35);
}
.mjrts-stat-number {
  font-family: var(--wp--preset--font-family--editorial);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.01em;
}

/* ---- Buttons: purposeful, fast micro-interaction only ---- */
.wp-block-button__link {
  transition: transform 180ms var(--mjrts-ease), box-shadow 180ms var(--mjrts-ease), background-color 180ms var(--mjrts-ease), color 180ms var(--mjrts-ease);
  box-shadow: 0 1px 2px rgba(0,0,0,0.4);
}
.wp-block-button__link:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 22px -8px rgba(201,162,39,0.45);
}
.wp-block-button__link:active { transform: translateY(0); }

.wp-block-button.is-style-outline .wp-block-button__link {
  border: 1px solid var(--mjrts-line);
  color: var(--wp--preset--color--text-primary);
  background: transparent;
}
.wp-block-button.is-style-outline .wp-block-button__link:hover {
  border-color: var(--mjrts-gold);
  color: var(--mjrts-gold-bright);
}

/* ---- 3D icon badges: gradient + bevel + inner glow, replaces flat line icons ---- */
.mjrts-icon-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  position: relative;
  line-height: 0;
}
.mjrts-icon-badge svg { display: block; position: relative; z-index: 1; }

.mjrts-icon-badge--gold {
  background: linear-gradient(155deg, #3a2f10 0%, #1a1608 70%);
  border: 1px solid rgba(201,162,39,0.35);
  box-shadow: inset 0 1px 0 rgba(232,200,116,0.25), inset 0 -6px 12px rgba(0,0,0,0.35), 0 8px 20px -10px rgba(201,162,39,0.4);
  color: var(--mjrts-gold-bright);
}
.mjrts-icon-badge--emerald {
  background: linear-gradient(155deg, #12321f 0%, #081a10 70%);
  border: 1px solid rgba(47,168,102,0.35);
  box-shadow: inset 0 1px 0 rgba(79,200,130,0.25), inset 0 -6px 12px rgba(0,0,0,0.35), 0 8px 20px -10px rgba(47,168,102,0.35);
  color: #6FD79A;
}

.mjrts-icon--sm { width: 40px; height: 40px; }
.mjrts-icon--sm svg { width: 18px; height: 18px; }
.mjrts-icon--md { width: 56px; height: 56px; }
.mjrts-icon--md svg { width: 26px; height: 26px; }
.mjrts-icon--lg { width: 72px; height: 72px; }
.mjrts-icon--lg svg { width: 34px; height: 34px; }

/* small inline variant for list rows (no badge box, just a tinted circle) */
.mjrts-icon-inline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: rgba(47,168,102,0.12);
  color: var(--mjrts-emerald);
  flex-shrink: 0;
}
.mjrts-icon-inline svg { width: 15px; height: 15px; }

/* ---- Section reveal on scroll: opacity/translate only, respects reduced motion ---- */
.mjrts-reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 650ms var(--mjrts-ease), transform 650ms var(--mjrts-ease);
}
.mjrts-reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}
@media (prefers-reduced-motion: reduce) {
  .mjrts-reveal { opacity: 1; transform: none; transition: none; }
  .mjrts-card, .mjrts-stat-tile, .wp-block-button__link { transition: none; }
}

/* ---- Divider: subtle fade instead of a flat rule ---- */
.mjrts-fade-divider {
  height: 1px;
  border: none;
  background: linear-gradient(90deg, transparent, var(--mjrts-gold) 50%, transparent);
  opacity: 0.4;
}

/* ---- Partners / "trusted by" band: muted grayscale logos, brighten on hover ---- */
.mjrts-partners-band {
  background: var(--mjrts-surface);
  border-top: 1px solid var(--mjrts-line);
  border-bottom: 1px solid var(--mjrts-line);
}
.mjrts-partner-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 1.25rem 1rem;
  color: var(--wp--preset--color--text-muted);
  filter: grayscale(1);
  opacity: 0.65;
  transition: opacity 220ms var(--mjrts-ease), filter 220ms var(--mjrts-ease), color 220ms var(--mjrts-ease);
  font-family: var(--wp--preset--font-family--editorial);
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: 0.02em;
}
.mjrts-partner-badge:hover {
  filter: grayscale(0);
  opacity: 1;
  color: var(--mjrts-gold-bright);
}

/* ---- Footer texture: faint gold node pattern on void background ---- */
.mjrts-footer {
  position: relative;
  isolation: isolate;
}
.mjrts-footer::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background-image: radial-gradient(var(--mjrts-gold) 1px, transparent 1px);
  background-size: 32px 32px;
  opacity: 0.05;
  pointer-events: none;
}
.mjrts-footer > * { position: relative; z-index: 1; }

/* ---- Sticky header, Apple/Supabase-style ---- */
.mjrts-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10,12,11,0.82);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--mjrts-line);
}

/* ---- Image treatment on dark backgrounds ---- */
.mjrts-photo {
  border-radius: 12px;
  border: 1px solid var(--mjrts-line);
  overflow: hidden;
}
