/* reset */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg-page);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, video, svg { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; background: none; border: 0; color: inherit; padding: 0; }
ul, ol { list-style: none; padding: 0; margin: 0; }

main, header, footer, section { position: relative; z-index: 1; }

/* typography */
h1, h2, h3, h4, .display {
  font-family: var(--font-display);
  letter-spacing: -0.025em;
  font-weight: 600;
  margin: 0 0 var(--space-5);
  color: var(--text);
}
h1 { font-size: clamp(2.4rem, 5vw, 4rem); line-height: 1.04; letter-spacing: -0.035em; }
h2 { font-size: clamp(1.75rem, 3vw, 2.5rem); line-height: 1.12; }
h3 { font-size: 1.25rem; line-height: 1.3; font-weight: 600; }
h4 { font-size: 1.05rem; line-height: 1.3; font-weight: 600; }
p { margin: 0 0 var(--space-4); color: var(--text-dim); }
strong { color: var(--text); font-weight: 600; }

.gradient-text {
  background: linear-gradient(135deg, var(--accent) 0%, var(--asrock-hi) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.gradient-text-green {
  background: linear-gradient(135deg, var(--asrock-hi) 0%, var(--asrock) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.gradient-text-amber {
  background: linear-gradient(135deg, #d97706 0%, #f59e0b 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.eyebrow {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--asrock-dark);
  padding: 0.35rem 0.8rem;
  border-radius: var(--radius-full);
  background: var(--asrock-tint);
  border: 1px solid rgba(133, 194, 38, 0.28);
  margin-bottom: var(--space-5);
}
.eyebrow-mono {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-muted);
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.wrap { max-width: var(--max-w); margin: 0 auto; padding: 0 1.5rem; }
.wrap-wide { max-width: var(--max-w-wide); margin: 0 auto; padding: 0 1.5rem; }
section { padding: var(--space-16) 0; }
@media (min-width: 768px) { section { padding: var(--space-20) 0; } }

/* accessibility */
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* ---------- bento grid primitives ---------- */
.bento {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: var(--space-4);
  grid-auto-rows: minmax(120px, auto);
}
@media (min-width: 720px) { .bento { gap: var(--space-5); } }

.bento-cell {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: var(--space-6);
  overflow: hidden;
  grid-column: span 12;
  transition: transform var(--dur-base) var(--ease-out), border-color var(--dur-base), box-shadow var(--dur-base);
}
.bento-cell:hover { border-color: var(--border-strong); }
.bento-cell.is-interactive:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }

@media (min-width: 720px) {
  .bento-cell { padding: var(--space-8); }
  .col-span-3  { grid-column: span 3; }
  .col-span-4  { grid-column: span 4; }
  .col-span-5  { grid-column: span 5; }
  .col-span-6  { grid-column: span 6; }
  .col-span-7  { grid-column: span 7; }
  .col-span-8  { grid-column: span 8; }
  .col-span-9  { grid-column: span 9; }
  .col-span-12 { grid-column: span 12; }
  .row-span-2  { grid-row: span 2; }
  .row-span-3  { grid-row: span 3; }
}

/* dark variants */
.bento-cell.is-dark {
  background: var(--bg-dark);
  color: var(--text-on-dark);
  border-color: var(--border-on-dark);
}
.bento-cell.is-dark h1,
.bento-cell.is-dark h2,
.bento-cell.is-dark h3,
.bento-cell.is-dark h4 { color: var(--text-on-dark); }
.bento-cell.is-dark p { color: var(--text-on-dark-dim); }
.bento-cell.is-blue { background: var(--accent); color: white; border-color: transparent; }
.bento-cell.is-blue h1, .bento-cell.is-blue h2, .bento-cell.is-blue h3, .bento-cell.is-blue h4 { color: white; }
.bento-cell.is-blue p { color: rgba(255, 255, 255, 0.85); }
.bento-cell.is-violet { background: var(--violet); color: white; border-color: transparent; }
.bento-cell.is-violet h1, .bento-cell.is-violet h2, .bento-cell.is-violet h3, .bento-cell.is-violet h4 { color: white; }
.bento-cell.is-violet p { color: rgba(255, 255, 255, 0.88); }
.bento-cell.is-tint-blue   { background: var(--bg-card-tint-blue); }
.bento-cell.is-tint-violet { background: var(--bg-card-tint-violet); }
.bento-cell.is-tint-amber  { background: var(--bg-card-tint-amber); }
.bento-cell.is-tint-emerald{ background: var(--bg-card-tint-emerald); }
.bento-cell.is-tint-green  { background: var(--bg-card-tint-green); border-color: rgba(133, 194, 38, 0.25); }
.bento-cell.is-green { background: var(--asrock); color: var(--bg-dark); border-color: transparent; }
.bento-cell.is-green h1, .bento-cell.is-green h2, .bento-cell.is-green h3, .bento-cell.is-green h4 { color: var(--bg-dark); }
.bento-cell.is-green p { color: rgba(15, 23, 42, 0.85); }
.bento-cell.is-alt { background: var(--bg-card-alt); }
