/* =========================
   Shiny Glint AI Governance
   style.css — playful_dynamic theme
   Mobile-first, flexbox-only, brand-aligned
   ========================= */

/* ===== CSS RESET & NORMALIZE ===== */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
img, svg { display: block; max-width: 100%; height: auto; }
a { text-decoration: none; color: inherit; }
ul, ol { margin: 0; padding: 0 0 0 0; list-style: none; }
button { background: none; border: 0; padding: 0; font: inherit; cursor: pointer; }
:focus-visible { outline: 3px solid #FFD166; outline-offset: 2px; }

/* ===== THEME VARIABLES ===== */
:root {
  /* Brand core */
  --brand-primary: #0B2B4C; /* deep navy */
  --brand-secondary: #1E7F74; /* jade */
  --brand-accent: #F4F7FB; /* light */
  --ink: #0A1E33; /* body text on light */
  --ink-soft: #3A5168;
  --surface: #FFFFFF;

  /* Playful dynamic pops (complementary, used as accents only) */
  --pop-pink: #FF5DA2;
  --pop-sun: #FFD166;
  --pop-violet: #7C4DFF;
  --pop-cyan: #17C3B2;

  /* Effects */
  --shadow-1: 0 4px 14px rgba(11,43,76,0.08);
  --shadow-2: 0 10px 24px rgba(11,43,76,0.12);
  --radius-s: 10px;
  --radius-m: 16px;
  --radius-l: 22px;

  /* Spacing scale */
  --space-4: 4px; --space-8: 8px; --space-12: 12px; --space-16: 16px;
  --space-20: 20px; --space-24: 24px; --space-32: 32px; --space-40: 40px; --space-60: 60px;
}

/* ===== BASE TYPOGRAPHY ===== */
body {
  font-family: Arial, Helvetica, sans-serif;
  color: var(--ink);
  font-size: 16px;
  line-height: 1.65;
  background: var(--surface);
  display: flex; /* flexbox for full-height layout */
  flex-direction: column;
  min-height: 100vh;
}

h1, h2, h3, h4, h5, h6 { font-family: "Trebuchet MS", Arial, Helvetica, sans-serif; color: var(--brand-primary); margin: 0 0 10px 0; line-height: 1.25; }

h1 { font-size: 36px; }
h2 { font-size: 28px; }
h3 { font-size: 22px; }
.subheadline { color: var(--ink-soft); font-size: 18px; margin: 10px 0 0 0; }

p { margin: 0 0 14px 0; }
strong { color: var(--brand-primary); }

/* Playful underline for text links */
a { color: var(--brand-secondary); position: relative; }
a:hover { color: var(--brand-secondary); }
a:not(.button)::after { content: ""; position: absolute; left: 0; bottom: -2px; height: 3px; width: 0%; background: var(--pop-sun); transition: width 220ms ease; }
a:not(.button):hover::after { width: 100%; }

/* ===== LAYOUT WRAPPERS (FLEX ONLY) ===== */
.container {
  display: flex; /* flex container */
  width: 100%;
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 20px;
  justify-content: center;
}
.content-wrapper {
  display: flex; /* flex column */
  flex-direction: column;
  gap: 20px;
  width: 100%;
  align-items: flex-start;
}
main { display: flex; flex-direction: column; gap: 30px; flex: 1; }
section { display: flex; padding: 40px 0; }

/* ===== MANDATORY SPACING & ALIGNMENT PATTERNS ===== */
.section { margin-bottom: 60px; padding: 40px 20px; display: flex; }
.card-container { display: flex; flex-wrap: wrap; gap: 24px; }
.card { margin-bottom: 20px; position: relative; display: flex; flex-direction: column; }
.content-grid { display: flex; flex-wrap: wrap; gap: 20px; justify-content: space-between; }
.text-image-section { display: flex; align-items: center; gap: 30px; flex-wrap: wrap; }
.testimonial-card { display: flex; align-items: center; gap: 20px; padding: 20px; }
.feature-item { display: flex; flex-direction: column; align-items: flex-start; gap: 15px; }

/* ===== HEADER & NAV ===== */
header { position: sticky; top: 0; background: var(--surface); box-shadow: var(--shadow-1); z-index: 50; }
header .container { align-items: center; }
header .content-wrapper { flex-direction: row; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 0; }
.brand { display: flex; align-items: center; gap: 10px; }
.brand img { height: 36px; width: auto; }

.main-nav { display: none; align-items: center; gap: 14px; flex-wrap: wrap; }
.main-nav a { color: var(--brand-primary); padding: 8px 10px; border-radius: 999px; transition: transform 160ms ease, background-color 160ms ease; }
.main-nav a:hover { background: var(--brand-accent); transform: translateY(-1px); }

/* Mobile menu toggle */
.mobile-menu-toggle { font-size: 26px; width: 44px; height: 44px; border-radius: 10px; background: var(--brand-accent); color: var(--brand-primary); display: flex; align-items: center; justify-content: center; box-shadow: var(--shadow-1); transition: transform 160ms ease, background-color 160ms ease; }
.mobile-menu-toggle:hover { transform: scale(1.05) rotate(-3deg); background: #EAF0F8; }

/* ===== MOBILE MENU (slide-in) ===== */
.mobile-menu { position: fixed; inset: 0; background: var(--surface); display: flex; flex-direction: column; transform: translateX(100%); transition: transform 260ms ease; z-index: 100; box-shadow: var(--shadow-2); }
.mobile-menu.open, .mobile-menu.active, .mobile-menu.is-open { transform: translateX(0); }
.mobile-menu-close { font-size: 26px; align-self: flex-end; margin: 16px; width: 44px; height: 44px; border-radius: 10px; background: var(--brand-accent); color: var(--brand-primary); display: flex; align-items: center; justify-content: center; box-shadow: var(--shadow-1); }
.mobile-nav { display: flex; flex-direction: column; gap: 14px; padding: 0 20px 30px 20px; }
.mobile-nav a { padding: 14px 16px; border-radius: 14px; background: var(--brand-accent); color: var(--brand-primary); box-shadow: var(--shadow-1); transition: transform 160ms ease, background-color 160ms ease; }
.mobile-nav a:hover { background: #EAF0F8; transform: translateX(4px); }

/* ===== HERO ===== */
.hero { background: var(--brand-accent); position: relative; overflow: hidden; }
.hero .content-wrapper { padding: 20px 0 10px 0; }
.hero h1 { font-size: 34px; }
.hero .cta-row { margin-top: 6px; }

/* Playful confetti dots (decorative only) */
.hero::before, .hero::after {
  content: ""; position: absolute; z-index: 0; opacity: 0.15; border-radius: 999px;
}
.hero::before { width: 220px; height: 220px; left: -60px; top: -60px; background: var(--pop-pink); animation: floaty 8s ease-in-out infinite; }
.hero::after { width: 180px; height: 180px; right: -40px; bottom: -40px; background: var(--pop-sun); animation: floaty 9s ease-in-out infinite reverse; }
.hero .container, .hero .content-wrapper, .hero * { position: relative; z-index: 1; }

@keyframes floaty { 0%,100% { transform: translateY(0) } 50% { transform: translateY(-10px) } }

/* ===== TEXT & LISTS ===== */
.text-section { display: flex; flex-direction: column; gap: 10px; }
.text-section ul, .text-section ol { display: flex; flex-direction: column; gap: 10px; }

/* Fun list bullets */
.text-section ul li, .text-section ol li { display: flex; align-items: flex-start; gap: 10px; }
.text-section ul li::before { content: ""; flex: 0 0 10px; height: 10px; border-radius: 4px; background: var(--pop-cyan); margin-top: 8px; }
.text-section ul li:nth-child(2)::before { background: var(--pop-pink); }
.text-section ul li:nth-child(3)::before { background: var(--pop-sun); }
.text-section ul li:nth-child(4)::before { background: var(--pop-violet); }
.text-section ol { counter-reset: num; }
.text-section ol li { counter-increment: num; }
.text-section ol li::before { content: counter(num) "."; color: var(--brand-secondary); font-weight: bold; margin-top: 0; }

/* ===== CTA ROW ===== */
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* ===== BUTTONS ===== */
.button { display: inline-flex; align-items: center; justify-content: center; padding: 12px 18px; border-radius: 999px; font-weight: bold; letter-spacing: 0.2px; transition: transform 160ms ease, box-shadow 160ms ease, background-color 160ms ease, color 160ms ease; box-shadow: var(--shadow-1); }
.button:hover { transform: translateY(-2px); box-shadow: var(--shadow-2); }
.button:active { transform: translateY(0); box-shadow: var(--shadow-1); }

.button.primary { background: var(--brand-secondary); color: #FFFFFF; }
.button.primary:hover { background: #169081; }
.button.secondary { background: #FFFFFF; color: var(--brand-primary); border: 2px solid var(--brand-primary); }
.button.secondary:hover { background: var(--brand-accent); }

/* Extra playful micro-badge on important CTAs */
.button.primary::after {
  content: "✨"; margin-left: 8px; transform: translateY(-2px); transition: transform 160ms ease;
}
.button.primary:hover::after { transform: translateY(-2px) rotate(15deg); }

/* ===== TESTIMONIALS (high contrast) ===== */
.testimonial-card { background: var(--brand-accent); border: 2px solid #E3EAF4; border-radius: var(--radius-m); color: var(--brand-primary); box-shadow: var(--shadow-1); }
.testimonial-card p { margin: 0; font-style: italic; color: var(--brand-primary); }
.testimonial-card .text-section { margin-left: auto; }

/* ===== FOOTER ===== */
footer { background: #0C2947; color: #EAF0F8; }
footer .content-wrapper { flex-direction: row; align-items: center; justify-content: space-between; gap: 20px; padding: 20px 0; }
.footer-nav nav { display: flex; flex-wrap: wrap; gap: 10px 16px; }
.footer-nav a { color: #EAF0F8; padding: 6px 10px; border-radius: 10px; transition: background-color 160ms ease; }
.footer-nav a:hover { background: rgba(255,255,255,0.08); }
.brand-badge img { height: 30px; filter: brightness(1.15); }

/* ===== CARDS (generic) ===== */
.card { background: var(--surface); border: 1px solid #E7EDF5; border-radius: var(--radius-m); padding: 20px; box-shadow: var(--shadow-1); }
.card:hover { box-shadow: var(--shadow-2); }

/* ===== IMAGES & ICONS IN TEXT ===== */
.text-section img { display: inline-block; width: 20px; height: 20px; margin-right: 8px; vertical-align: -3px; }
.text-section p { display: flex; align-items: center; gap: 8px; }

/* ===== UTILITIES ===== */
.hidden { display: none !important; }
.center { display: flex; align-items: center; justify-content: center; }
.row { display: flex; flex-direction: row; gap: 12px; }
.col { display: flex; flex-direction: column; gap: 12px; }

/* ===== COOKIE CONSENT BANNER ===== */
.cookie-banner { position: fixed; left: 0; right: 0; bottom: -200px; display: flex; justify-content: center; z-index: 110; transition: transform 260ms ease, bottom 260ms ease; }
.cookie-banner .bar { display: flex; flex-direction: column; gap: 12px; width: 100%; max-width: 980px; margin: 0 20px 20px 20px; background: #FFFFFF; border: 2px solid #E3EAF4; border-radius: var(--radius-l); box-shadow: var(--shadow-2); padding: 16px; }
.cookie-banner.show { bottom: 0; }
.cookie-banner h4 { margin: 0; font-size: 18px; color: var(--brand-primary); }
.cookie-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.cookie-actions .accept { background: var(--brand-secondary); color: #fff; }
.cookie-actions .reject { background: var(--brand-accent); color: var(--brand-primary); border: 2px solid var(--brand-primary); }
.cookie-actions .settings { background: var(--surface); color: var(--brand-secondary); border: 2px dashed var(--brand-secondary); }
.cookie-actions .button { padding: 10px 14px; }

/* Cookie modal */
.cookie-modal-overlay { position: fixed; inset: 0; background: rgba(11,43,76,0.35); display: none; z-index: 120; }
.cookie-modal-overlay.open { display: flex; align-items: center; justify-content: center; }
.cookie-modal { display: flex; flex-direction: column; gap: 14px; width: 92%; max-width: 720px; background: #fff; border-radius: var(--radius-l); box-shadow: var(--shadow-2); padding: 20px; border: 2px solid #E3EAF4; }
.cookie-modal .modal-header { display: flex; align-items: center; justify-content: space-between; }
.cookie-modal .modal-body { display: flex; flex-direction: column; gap: 12px; }
.cookie-category { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px; border: 1px solid #E7EDF5; border-radius: 12px; background: var(--brand-accent); }
.cookie-toggle { display: flex; align-items: center; gap: 8px; }
/* Simple switch */
.switch { width: 44px; height: 26px; border-radius: 20px; background: #CBD7E6; position: relative; display: flex; align-items: center; padding: 3px; transition: background-color 160ms ease; }
.switch::after { content: ""; width: 20px; height: 20px; border-radius: 50%; background: #fff; transform: translateX(0); transition: transform 160ms ease; box-shadow: var(--shadow-1); }
.switch.on { background: var(--brand-secondary); }
.switch.on::after { transform: translateX(18px); }
.cookie-modal .modal-actions { display: flex; justify-content: flex-end; gap: 10px; }

/* ===== RESPONSIVE ===== */
@media (min-width: 540px) {
  h1 { font-size: 40px; }
  h2 { font-size: 30px; }
}

@media (min-width: 768px) {
  .main-nav { display: flex; }
  .mobile-menu-toggle { display: none; }

  .hero h1 { font-size: 48px; }
  .cta-row { flex-direction: row; }
  .text-image-section { flex-direction: row; }
  .content-wrapper { gap: 24px; }
}

@media (min-width: 1024px) {
  h1 { font-size: 56px; }
  h2 { font-size: 36px; }
}

/* ===== PAGE-SPECIFIC TWEAKS ===== */
/* General sections spacing using flex and gaps */
section .content-wrapper > h2 { margin-top: 4px; }

/* Executive-feel yet playful headings: add subtle color bar */
h2 { position: relative; padding-left: 14px; }
h2::before { content: ""; position: absolute; left: 0; top: 4px; bottom: 4px; width: 6px; background: var(--pop-pink); border-radius: 6px; }

/* Alternate color bars for variety */
section:nth-of-type(3) h2::before { background: var(--pop-sun); }
section:nth-of-type(4) h2::before { background: var(--pop-cyan); }
section:nth-of-type(5) h2::before { background: var(--pop-violet); }

/* Ensure minimum spacing between content blocks */
.content-wrapper > * + * { margin-top: 6px; }

/* ===== ACCESSIBILITY & PRINTABLE CONTRAST FOR TESTIMONIALS ===== */
/* Ensure text contrast on light backgrounds */
.testimonial-card, .testimonial-card * { color: var(--brand-primary); }

/* ===== PREVENT OVERLAP & Z-INDEX HYGIENE ===== */
.hero::before, .hero::after { z-index: 0; }
header, .mobile-menu, .cookie-modal-overlay, .cookie-banner { z-index: 50; }
.mobile-menu { z-index: 100; }
.cookie-modal-overlay { z-index: 120; }
.cookie-banner { z-index: 110; }

/* ===== FLEXBOX LAYOUT DEFINITIONS FOR COMMON GROUPS ===== */
/* content-grid already defined; ensure children respect gaps without overlap */
.content-grid > * { flex: 1 1 260px; min-width: 240px; }
.card-container > .card { flex: 1 1 300px; min-width: 260px; }

/* ===== DESKTOP NAV BUTTONS (Book & Demo) ===== */
.main-nav .button.primary { padding: 10px 16px; }
.main-nav .button.secondary { padding: 10px 16px; border-width: 2px; }

/* ===== PLAYFUL MICRO-ANIMATIONS ===== */
@keyframes wiggle { 0%,100% { transform: rotate(0) } 25% { transform: rotate(2deg) } 75% { transform: rotate(-2deg) } }
.button:hover { animation: wiggle 380ms ease-in-out; }

/* ===== MISC: Ensure all layout wrappers use flex ===== */
footer .footer-nav { display: flex; }
footer .brand-badge { display: flex; align-items: center; }

/* ===== ENSURE GAPS BETWEEN CARDS/SECTIONS (20px min) ===== */
section + section { border-top: 0 solid transparent; }
.content-wrapper > .testimonial-card { margin-bottom: 20px; }
.content-wrapper > .text-section + .text-section { margin-top: 20px; }

/* ===== SAFETY: No grid/columns used; flex-wrap for responsiveness ===== */
/* END */
