/* Varazza website base styles and components (SITE-5). Uses only tokens.css values. */

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

html {
  /* Focused or linked-to items stop below the sticky header, never under it */
  scroll-padding-top: calc(var(--header-h) + var(--space-16));
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: var(--text-base) / var(--leading-body) var(--font-body);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 { font-family: var(--font-heading); color: var(--text); margin: 0; }
h1 { font-size: var(--text-4xl); line-height: var(--leading-tight); font-weight: 700; letter-spacing: -0.02em; }
h2 { font-size: var(--text-3xl); line-height: var(--leading-tight); font-weight: 700; letter-spacing: -0.02em; }
h3 { font-size: var(--text-xl); line-height: var(--leading-snug); font-weight: 600; letter-spacing: -0.01em; }
p { margin: 0; }
.lead { font-size: var(--text-lg); color: var(--muted); }
.muted { color: var(--muted); }
.eyebrow { font: 600 var(--text-sm) / 1.4 var(--font-heading); color: var(--selected-text); }
code { font-family: var(--font-mono); font-size: 0.9em; }

a { color: var(--link); text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }

:focus-visible { outline: var(--focus-ring); outline-offset: var(--focus-offset); }

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

.container { width: 100%; max-width: var(--page-max); margin: 0 auto; padding: 0 var(--gutter); }
.section { padding: var(--space-64) 0; }
.band { background: var(--sunken); }

/* Header: sticky, the logo slot, links, Log in and Sign up */
.site-header {
  position: sticky; top: 0; z-index: 50;
  height: var(--header-h);
  background: color-mix(in srgb, var(--surface) 92%, transparent);
  border-bottom: 1px solid var(--border);
  backdrop-filter: saturate(1.4) blur(8px);
}
.site-header .container { height: 100%; display: flex; align-items: center; gap: var(--space-24); }
.wordmark { font: 700 var(--text-xl) / 1 var(--font-heading); color: var(--text); text-decoration: none; letter-spacing: -0.02em; }
.nav { display: flex; gap: var(--space-4); margin-right: auto; }
.nav a { padding: var(--space-8) var(--space-12); color: var(--muted); text-decoration: none; border-radius: var(--radius-sm); font-weight: 500; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--text); background: var(--sunken); }
.header-actions { display: flex; gap: var(--space-8); }
@media (max-width: 720px) {
  .nav { display: none; }
  .site-header .container { gap: var(--space-8); }
  .wordmark { margin-right: auto; }
  .header-actions { gap: var(--space-4); }
  .header-actions .btn { padding: var(--space-8) var(--space-12); }
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--space-8);
  min-height: 40px; padding: var(--space-8) var(--space-16);
  font: 600 var(--text-sm) / 1.2 var(--font-body);
  color: var(--text); background: var(--surface);
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: background-color var(--ease), border-color var(--ease), transform var(--ease);
}
.btn:hover { background: var(--sunken); }
.btn:active { transform: translateY(0.5px); }
.btn-primary { background: var(--primary); border-color: var(--primary); color: var(--primary-text); }
.btn-primary:hover { background: color-mix(in srgb, var(--primary) 88%, var(--text)); }
.btn-ghost { background: transparent; border-color: transparent; }
.btn-lg { min-height: 48px; padding: var(--space-12) var(--space-24); font-size: var(--text-base); }

/* Cards and feature tiles */
.card {
  padding: var(--space-24); background: var(--surface);
  border: 1px solid var(--card-border); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
}
.card h3 { margin-bottom: var(--space-8); }
a.card { display: block; color: inherit; text-decoration: none; transition: box-shadow var(--ease), transform var(--ease); }
a.card:hover { box-shadow: var(--shadow-card-hover); transform: translateY(-2px); }
.grid { display: grid; gap: var(--space-16); grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.icon {
  width: 40px; height: 40px; display: grid; place-items: center; margin-bottom: var(--space-16);
  background: var(--selected); color: var(--selected-text); border-radius: var(--radius);
}
.icon svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }

/* Tag */
.tag {
  display: inline-block; padding: 2px var(--space-8);
  font: 600 var(--text-xs) / 1.6 var(--font-body);
  color: var(--selected-text); background: var(--selected); border-radius: var(--radius-pill);
}

/* Pricing */
.price-card { display: flex; flex-direction: column; gap: var(--space-16); }
.price-card.featured { border: 2px solid var(--accent); }
.price { font: 700 var(--text-3xl) / 1 var(--font-heading); }
.price small { font: 400 var(--text-sm) / 1 var(--font-body); color: var(--muted); }
.checks { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-8); }
.checks li { padding-left: 24px; position: relative; }
.checks li::before { content: ""; position: absolute; left: 2px; top: 0.45em; width: 10px; height: 6px; border: 2px solid var(--pass); border-top: 0; border-right: 0; transform: rotate(-45deg); }

/* Form */
.field { display: grid; gap: var(--space-4); }
.field label { font-weight: 500; font-size: var(--text-sm); }
.input {
  min-height: 44px; padding: var(--space-8) var(--space-12);
  font: inherit; color: var(--text); background: var(--surface);
  border: 1px solid var(--border); border-radius: var(--radius-sm);
}
.input::placeholder { color: var(--muted); }
.input:focus-visible { border-color: var(--accent); }
.field-error { color: var(--danger); font-size: var(--text-sm); }
.field-ok { color: var(--pass); font-size: var(--text-sm); }

/* Quote */
.quote { font: 500 var(--text-xl) / var(--leading-snug) var(--font-heading); }
.quote cite { display: block; margin-top: var(--space-12); font: 400 var(--text-sm) / 1.4 var(--font-body); color: var(--muted); font-style: normal; }

/* Footer */
.site-footer { padding: var(--space-48) 0; border-top: 1px solid var(--border); color: var(--muted); font-size: var(--text-sm); }
.site-footer .cols { display: grid; gap: var(--space-24); grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); }
.site-footer h4 { font-size: var(--text-sm); margin-bottom: var(--space-8); }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-4); }
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: var(--text); text-decoration: underline; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}
