/* Ricardo Cidale — personal market page
   Tokens locked. Anti-slop: editorial letter + portfolio.
   Pack v2.1 craft · SITE_COPY_MARKETING_v2 */

:root {
  --bg: #f7f6f3;
  --surface: #ffffff;
  --ink: #1a1a1a;
  --ink-muted: #4a4a4a;
  --rule: #d8d4cc;
  --accent: #0b3d2e;
  --accent-soft: #e6efeb;
  --max: 40rem;
  --max-wide: 52rem;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
}

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

html {
  font-size: 18px;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 400;
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover {
  text-decoration-thickness: 2px;
}

a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* —— Header —— */
.site-header {
  border-bottom: 1px solid var(--rule);
  padding: 1.15rem 1.5rem 1rem;
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(8px);
  background: color-mix(in srgb, var(--bg) 92%, transparent);
}

.site-header-inner {
  max-width: var(--max-wide);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem 1.5rem;
}

.site-mark {
  font-family: var(--sans);
  font-weight: 650;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  color: var(--ink);
  text-decoration: none;
}

.site-mark:hover {
  color: var(--accent);
  text-decoration: none;
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.25rem;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 500;
}

.site-nav a {
  color: var(--ink-muted);
  text-decoration: none;
  padding: 0.15rem 0;
  border-bottom: 2px solid transparent;
}

.site-nav a:hover {
  color: var(--ink);
  border-bottom-color: var(--accent);
}

/* —— Main —— */
.site-main {
  flex: 1;
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 3rem 1.5rem 4rem;
}

.section {
  margin-bottom: 3.5rem;
}

.section:last-child {
  margin-bottom: 0;
}

.hero {
  padding-top: 0.75rem;
  margin-bottom: 4rem;
}

h1 {
  font-family: var(--sans);
  font-size: clamp(1.85rem, 4.5vw, 2.4rem);
  font-weight: 650;
  line-height: 1.18;
  letter-spacing: -0.025em;
  margin: 0 0 1.15rem;
  color: var(--ink);
  max-width: 16em;
}

h2 {
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 650;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 1.15rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--rule);
}

h3 {
  font-family: var(--sans);
  font-size: 1.05rem;
  font-weight: 650;
  letter-spacing: -0.01em;
  margin: 0 0 0.65rem;
  line-height: 1.3;
  color: var(--ink);
}

p {
  margin: 0 0 1rem;
  color: var(--ink);
}

p:last-child {
  margin-bottom: 0;
}

.lede {
  font-family: var(--serif);
  font-size: 1.22rem;
  line-height: 1.45;
  color: var(--ink);
  margin-bottom: 1.25rem;
  max-width: 34em;
}

.market {
  font-size: 1.02rem;
  color: var(--ink-muted);
  margin-bottom: 1.75rem;
  max-width: 38em;
}

.market em {
  font-style: italic;
}

/* —— Story cards —— */
.story-grid {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.story-card {
  background: var(--surface);
  padding: 1.5rem 1.4rem 1.4rem;
  border-radius: 2px;
  box-shadow: 0 0 0 1px var(--rule);
}

.story-card p {
  color: var(--ink-muted);
  font-size: 0.95rem;
  line-height: 1.55;
  margin: 0;
}

/* —— Contact —— */
.contact-list {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0 1.25rem;
}

.contact-list li {
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--rule);
}

.contact-list li:last-child {
  margin-bottom: 0;
}

.contact-list .label {
  display: block;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--ink-muted);
  margin-bottom: 0.3rem;
}

.contact-list a {
  font-size: 1.05rem;
  font-weight: 500;
  text-decoration: none;
}

.contact-list a:hover {
  text-decoration: underline;
  text-decoration-thickness: 1px;
}

.resume-note {
  font-size: 0.9rem;
  margin-top: 0.5rem;
}

/* —— CTAs —— */
.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
  align-items: center;
}

.btn {
  display: inline-block;
  font-family: var(--sans);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  padding: 0.7rem 1.25rem;
  background: var(--accent);
  color: #fff;
  text-decoration: none;
  border: 2px solid var(--accent);
  border-radius: 2px;
}

.btn:hover {
  background: #072a20;
  border-color: #072a20;
  text-decoration: none;
}

.btn-ghost {
  background: transparent;
  color: var(--accent);
}

.btn-ghost:hover {
  background: var(--accent-soft);
  color: var(--accent);
  border-color: var(--accent);
}

/* —— Footer —— */
.site-footer {
  margin-top: auto;
  border-top: 1px solid var(--rule);
}

.site-footer-meta {
  max-width: var(--max-wide);
  margin: 0 auto;
  padding: 1rem 1.5rem 1.5rem;
  font-size: 0.75rem;
  color: var(--ink-muted);
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  justify-content: space-between;
}

.site-footer-meta a {
  color: var(--ink-muted);
  text-decoration: none;
}

.site-footer-meta a:hover {
  color: var(--accent);
  text-decoration: underline;
}

@media (max-width: 560px) {
  html {
    font-size: 17px;
  }

  .site-main {
    padding: 2rem 1.25rem 3rem;
  }

  .hero {
    margin-bottom: 3rem;
  }

  .section {
    margin-bottom: 2.75rem;
  }

  .site-header-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .lede {
    font-size: 1.1rem;
  }

  .story-card {
    padding: 1.25rem 1.1rem;
  }
}

@media print {
  .site-header,
  .cta-row {
    display: none !important;
  }

  body {
    background: #fff;
  }

  .site-main {
    max-width: none;
    padding: 0;
  }

  .story-card {
    box-shadow: none;
    border: 1px solid #ccc;
  }
}
