/* ============================================
   YOOSTUDIO V2 — BASE STYLES
   Reset, body, typography, global utilities
   ============================================ */

/* --- Reset & Box Model --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-primary);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.6;
  color: var(--color-silver);
  background-color: var(--color-obsidian);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

/* --- Noise Texture Overlay --- */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 9999;
  pointer-events: none;
  opacity: 0.03;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 200px 200px;
}

/* --- Typography Base --- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-primary);
  font-weight: 700;
  line-height: 1.2;
  color: var(--color-white);
  letter-spacing: -0.02em;
}

h1 { font-size: 48px; }
h2 { font-size: 36px; }
h3 { font-size: 28px; }
h4 { font-size: 22px; }
h5 { font-size: 18px; }
h6 { font-size: 16px; }

p {
  font-family: var(--font-primary);
  font-size: 16px;
  line-height: 1.7;
  color: var(--color-silver);
}

a {
  color: var(--color-cyan);
  text-decoration: none;
  transition: color var(--duration-fast);
}

a:hover {
  color: var(--color-cyan-light);
}

strong, b {
  font-weight: 700;
  color: var(--color-off-white);
}

code, pre {
  font-family: var(--font-mono);
  font-size: 14px;
}

ul, ol {
  list-style: none;
}

img, video {
  max-width: 100%;
  display: block;
}

button, input, select, textarea {
  font-family: var(--font-primary);
  font-size: 16px;
}

/* --- Focus Styles --- */
:focus-visible {
  outline: 2px solid var(--color-cyan);
  outline-offset: 3px;
  border-radius: var(--radius-tooltip);
}

/* --- Scrollbar --- */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: var(--color-surface-2);
}

::-webkit-scrollbar-thumb {
  background: var(--color-ghost);
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--color-zinc);
}

/* --- Selection --- */
::selection {
  background: rgba(0, 229, 204, 0.2);
  color: var(--color-white);
}

/* --- Global Layout Utilities --- */
.yoo-container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--content-padding-desktop);
}

.yoo-container--narrow {
  max-width: 800px;
}

/* --- Section Base --- */
.yoo-section {
  padding: var(--space-7xl) 0;
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 500ms var(--ease-smooth), transform 500ms var(--ease-smooth);
}

.yoo-section.yoo-visible {
  opacity: 1;
  transform: translateY(0);
}

.yoo-section--elevated {
  background: var(--color-surface-1);
  border-top: 1px solid var(--color-glass-border);
  border-bottom: 1px solid var(--color-glass-border);
}

.yoo-section__header {
  margin-bottom: var(--space-4xl);
}

.yoo-section__header--center {
  text-align: center;
}

.yoo-section__title {
  font-family: var(--font-display);
  font-size: 44px;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--color-white);
  margin: var(--space-sm) 0 var(--space-base);
}

.yoo-section__desc {
  font-size: 17px;
  line-height: 1.7;
  color: var(--color-silver);
  max-width: var(--body-max-width);
}

/* --- Overline / Label --- */
.yoo-overline {
  display: inline-block;
  font-family: var(--font-primary);
  font-size: 13px;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-cyan);
}

/* --- Gradient Text --- */
.yoo-text-gradient {
  background: var(--gradient-prism);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* --- Grid Utilities --- */
.yoo-grid {
  display: grid;
  gap: var(--space-xl);
}

.yoo-grid--2col {
  grid-template-columns: repeat(2, 1fr);
}

.yoo-grid--3col {
  grid-template-columns: repeat(3, 1fr);
}

/* --- Body Text Utility --- */
.yoo-body {
  font-size: 16px;
  line-height: 1.7;
  color: var(--color-silver);
  margin-bottom: var(--space-base);
}

.yoo-body a {
  color: var(--color-cyan);
}

/* --- Reduced Motion --- */
@media (prefers-reduced-motion: reduce) {
  .yoo-section {
    opacity: 1;
    transform: none;
    transition: none;
  }

  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* --- Responsive Layout --- */
@media (max-width: 1024px) {
  .yoo-grid--3col {
    grid-template-columns: repeat(2, 1fr);
  }

  .yoo-section__title {
    font-size: 36px;
  }
}

@media (max-width: 640px) {
  .yoo-container {
    padding: 0 var(--content-padding-mobile);
  }

  .yoo-grid--2col,
  .yoo-grid--3col {
    grid-template-columns: 1fr;
  }

  .yoo-section {
    padding: var(--space-5xl) 0;
  }

  .yoo-section__title {
    font-size: 28px;
  }
}

/* ============================================
   YOO LOGO BANNER — top-center overlay
   Stacks YL2_text.png over bg-logo-text.png
   ============================================ */
.yoo-logo-banner {
  position: fixed;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9000;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  width: auto;
}

.yoo-logo-banner__bg {
  display: block;
  height: 26px;
  width: auto;
  opacity: 0.55;
}

.yoo-logo-banner__overlay {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  height: 10px;
  width: auto;
  opacity: 1;
  filter: drop-shadow(0 2px 8px rgba(0,0,0,0.7));
}

/* ============================================
   YOO LICENSE NOTICE — bottom-right corner
   ============================================ */
.yoo-license-notice {
  position: fixed;
  bottom: 12px;
  right: 14px;
  z-index: 8999;
  font-family: var(--font-primary, 'Satoshi', sans-serif);
  font-size: 10px;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.45);
  text-align: right;
  pointer-events: none;
  max-width: 280px;
}

.yoo-license-notice strong {
  display: block;
  color: rgba(255, 255, 255, 0.6);
  font-weight: 600;
  margin-bottom: 2px;
  pointer-events: none;
}

.yoo-license-notice a {
  color: rgba(0, 229, 204, 0.7);
  text-decoration: none;
  pointer-events: auto;
  transition: color 0.2s;
}

.yoo-license-notice a:hover {
  color: rgba(0, 229, 204, 1);
}

/* Push the header / hero section down so content sits ~30px below the banner */
.yoo-header {
  margin-top: 48px;
}

.yoo-hero {
  padding-top: calc(var(--space-5xl, 96px) + 30px);
}

/* For panel-layout pages (sims / theory): shift panel header */
#panel #header h1,
#panel #header {
  padding-top: 52px;
}

/* For introList (iframe): shift the wrapper */
.intro-wrapper {
  padding-top: calc(48px + 30px) !important;
}
