/* yourside.ai — base styles (reset + typography + component base)
 * Depends on: tokens.css
 */

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

html, body { margin: 0; padding: 0; }

body {
  font-family: var(--font-sans);
  font-size: var(--fs-body);
  line-height: var(--lh-normal);
  color: var(--text);
  background: var(--bg);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 { margin: 0 0 var(--space-3); color: var(--text); }

h1 { font-size: var(--fs-h1); font-weight: 700; line-height: var(--lh-tight); }
h2 { font-size: var(--fs-h2); font-weight: 600; line-height: var(--lh-snug); }
h3 { font-size: var(--fs-h3); font-weight: 600; line-height: var(--lh-snug); }

p { margin: 0 0 var(--space-4); }

a {
  color: var(--accent);
  text-decoration: none;
}
a:hover { text-decoration: underline; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

/* Layout helper */
.container {
  width: min(var(--container), calc(100% - 2rem));
  margin-inline: auto;
}
.container-wide {
  width: min(var(--container-wide), calc(100% - 2rem));
  margin-inline: auto;
}

/* Skip link */
.skip-link {
  position: absolute;
  top: -60px;
  left: 8px;
  padding: 8px 12px;
  background: var(--surface);
  color: var(--text);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow);
  z-index: 100;
}
.skip-link:focus { top: 8px; }

/* Buttons */
.btn, .btn-primary, .btn-secondary, .btn-ghost, button.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  min-height: 44px;
  padding: 0.625rem 1.5rem;
  border-radius: var(--radius-pill);
  border: 1px solid transparent;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  line-height: 1;
  transition: background-color 120ms ease, border-color 120ms ease, color 120ms ease;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.btn-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); text-decoration: none; }

.btn-secondary {
  background: var(--surface);
  color: var(--text);
  border-color: var(--border);
}
.btn-secondary:hover { background: var(--surface-raised); text-decoration: none; }

.btn-ghost {
  background: transparent;
  color: var(--accent);
  border-color: transparent;
  padding-inline: 0.5rem;
}
.btn-ghost:hover { text-decoration: underline; }

/* Card */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: var(--space-5);
  box-shadow: var(--shadow-sm);
}

/* Callouts */
.callout {
  border-radius: var(--radius);
  padding: var(--space-3) var(--space-4);
  line-height: 1.55;
  border-left: 4px solid var(--accent);
  background: var(--accent-soft);
  color: var(--text);
}
.callout--warning { border-left-color: var(--warning); background: var(--warning-soft); }
.callout--note    { border-left-color: var(--accent);  background: var(--accent-soft); }
.callout--ok,
.callout--reassurance { border-left-color: var(--success); background: var(--success-soft); }
.callout--danger  { border-left-color: var(--danger);  background: var(--danger-soft); }

/* Form inputs */
input[type="text"],
input[type="email"],
input[type="search"],
input[type="number"],
input[type="url"],
input[type="tel"],
textarea,
select {
  width: 100%;
  min-height: 44px;
  padding: 0.625rem 0.75rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font: inherit;
  line-height: 1.4;
}

textarea { min-height: 96px; resize: vertical; padding: 0.625rem 0.75rem; }

label { display: block; font-weight: 600; margin-bottom: var(--space-1); font-size: var(--fs-small); color: var(--text); }

/* Badges */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-pill);
  background: var(--accent-soft);
  color: var(--accent);
  font-size: var(--fs-tiny);
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}
.badge--category { background: var(--accent-soft); color: var(--accent); }
.badge--status   { background: var(--surface-raised); color: var(--muted); border: 1px solid var(--border); }

/* Eyebrow / kicker */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: var(--fs-tiny);
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent);
}

/* Site header / footer base */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: color-mix(in srgb, var(--bg) 94%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 64px;
  gap: var(--space-4);
}
.logo {
  color: var(--text);
  font-weight: 800;
  font-size: 1.125rem;
  text-decoration: none;
}
.logo span { color: var(--accent); }
.site-nav {
  display: flex;
  gap: var(--space-3);
}
.site-nav a {
  color: var(--text-secondary);
  padding: 0.4rem 0.7rem;
  border-radius: var(--radius-pill);
  font-weight: 500;
  font-size: var(--fs-small);
}
.site-nav a:hover {
  color: var(--text);
  background: var(--accent-soft);
  text-decoration: none;
}

.site-footer {
  border-top: 1px solid var(--border);
  padding: var(--space-8) 0 var(--space-10);
  color: var(--muted);
  font-size: var(--fs-small);
}

/* Utility */
.muted { color: var(--muted); }
.text-secondary { color: var(--text-secondary); }
.mono { font-family: var(--font-mono); }

@media (max-width: 640px) {
  .site-nav { gap: var(--space-1); }
  .site-nav a { padding: 0.4rem 0.55rem; font-size: var(--fs-tiny); }
}
