/* === OpenClaw landing — neubrutalist dark theme === */
/* Aligned with sambarbosa.tech: monochrome, sharp edges, bold type */

:root {
  --bg: #000;
  --bg-alt: #0d0d0d;
  --fg: #fff;
  --muted: rgba(255, 255, 255, 0.6);
  --border: rgba(255, 255, 255, 0.15);
  --border-strong: rgba(255, 255, 255, 0.4);
  --focus: #ffd166;
  --font: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --mono: ui-monospace, 'SF Mono', Menlo, monospace;
  --max: 52rem;
  --header-h: 4rem;
}

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

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .btn,
  .openclaw-tip::after {
    transition: none;
  }
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.05rem;
  line-height: 1.65;
  color: var(--fg);
  background: var(--bg);
}

/* --- Skip link --- */
.skip-link {
  position: absolute;
  left: -9999px;
  z-index: 999;
  padding: 0.5rem 1rem;
  background: var(--fg);
  color: var(--bg);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.85rem;
}
.skip-link:focus {
  left: 1rem;
  top: 1rem;
}

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

.section {
  padding-block: clamp(3rem, 7vw, 5rem);
  scroll-margin-top: calc(var(--header-h) + 0.5rem);
}

.section-alt {
  background: var(--bg-alt);
}

/* --- Typography — brutalist --- */
h1,
h2,
h3 {
  line-height: 1.1;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: -0.02em;
}

h1 {
  font-size: clamp(2rem, 5vw, 3rem);
}

h2 {
  font-size: clamp(1.4rem, 3vw, 1.85rem);
  margin-block: 0 1.25rem;
  padding-bottom: 0.75rem;
  border-bottom: 4px solid var(--border-strong);
}

h3 {
  font-size: 1rem;
  margin-block: 0 0.5rem;
}

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

a {
  color: var(--fg);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}
a:hover {
  text-decoration-thickness: 2px;
}
a:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

/* --- Header --- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--bg);
  border-bottom: 2px solid var(--border-strong);
}

.header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
  min-height: var(--header-h);
  padding-block: 0.75rem;
}

.brand {
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 0.9rem;
  color: var(--fg);
}
.brand-link {
  text-decoration: none;
  color: inherit;
}
.brand-link:hover {
  text-decoration: underline;
}

.nav-main {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
}
.nav-main a {
  color: var(--muted);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
  text-decoration: none;
}
.nav-main a:hover {
  color: var(--fg);
}

.header-actions {
  margin-left: auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
}

/* --- Locale switcher --- */
.locale-switch {
  display: inline-flex;
  border: 2px solid var(--border-strong);
  overflow: hidden;
}
.locale-switch button {
  font: inherit;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.35rem 0.65rem;
  border: none;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}
.locale-switch button[aria-pressed='true'] {
  background: var(--fg);
  color: var(--bg);
}
.locale-switch button:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: -2px;
}

/* --- Buttons — sharp, inverted --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1.1rem;
  font: inherit;
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  text-decoration: none;
  border: 2px solid var(--fg);
  cursor: pointer;
  transition: background 0.1s, color 0.1s;
}
.btn-primary {
  background: var(--fg);
  color: var(--bg);
}
.btn-primary:hover {
  background: transparent;
  color: var(--fg);
}
.btn-ghost {
  background: transparent;
  color: var(--fg);
}
.btn-ghost:hover {
  background: var(--fg);
  color: var(--bg);
}
.btn:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}
.btn-lg {
  padding: 0.8rem 1.5rem;
  font-size: 0.95rem;
}

/* --- Hero --- */
.hero {
  padding-block: clamp(4rem, 10vw, 6rem);
}
.hero-sub,
.hero-openclaw {
  max-width: 42rem;
}
.hero-openclaw {
  color: var(--fg);
  font-size: 1rem;
  font-family: var(--mono);
}
/* --- OpenClaw tooltip --- */
.openclaw-tip {
  text-decoration: underline;
  text-decoration-style: dashed;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
  cursor: help;
  position: relative;
  font-style: normal;
  color: var(--fg);
}
.openclaw-tip::after {
  content: attr(title);
  position: absolute;
  bottom: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%);
  padding: 0.5rem 0.75rem;
  background: var(--fg);
  color: var(--bg);
  font-size: 0.8rem;
  font-weight: 400;
  text-transform: none;
  letter-spacing: normal;
  line-height: 1.4;
  width: max-content;
  max-width: 280px;
  white-space: normal;
  border: 2px solid var(--fg);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.15s;
  z-index: 10;
}
.openclaw-tip:hover::after,
.openclaw-tip:focus::after {
  opacity: 1;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 2rem;
}

/* --- Fallback message --- */
.fallback-msg {
  padding: 0.75rem 1rem;
  border: 2px solid #c94c4c;
  background: rgba(201, 76, 76, 0.12);
  color: #f0b4b4;
  margin-bottom: 1rem;
}

/* --- Prose --- */
.prose p:last-child {
  margin-bottom: 0;
}

/* --- Card grid --- */
.card-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
}
@media (min-width: 640px) {
  .card-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.process-grid {
  grid-template-columns: 1fr;
}
@media (min-width: 900px) {
  .process-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* --- Cards — hard border, no radius --- */
.card {
  padding: 1.25rem;
  border: 2px solid var(--border-strong);
  background: transparent;
}
.card:hover {
  border-color: var(--fg);
}

/* --- Proof list --- */
.proof-list {
  margin: 0;
  padding-left: 1.25rem;
  color: var(--muted);
}
.proof-list li + li {
  margin-top: 0.5rem;
}

/* --- FAQ — brutalist details --- */
.faq-list details {
  border: 2px solid var(--border-strong);
  padding: 0.75rem 1rem;
  margin-bottom: 0.5rem;
}
.faq-list summary {
  cursor: pointer;
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  color: var(--fg);
}
.faq-list summary:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}
.faq-list p {
  margin-top: 0.75rem;
  margin-bottom: 0;
  text-transform: none;
  font-weight: 400;
}

/* --- CTA block --- */
.cta-block {
  text-align: center;
}
.cta-inner {
  padding-block: 2rem;
}

/* --- Footer --- */
.site-footer {
  border-top: 2px solid var(--border-strong);
  padding-block: 2rem;
  font-size: 0.9rem;
}
.footer-inner {
  color: var(--muted);
}
.footer-inner a {
  color: var(--fg);
}
.footer-tagline {
  color: var(--fg);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* --- Noscript --- */
.noscript-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 0.75rem;
  background: var(--bg-alt);
  border-top: 2px solid var(--border-strong);
  text-align: center;
  font-size: 0.85rem;
  color: var(--muted);
}

/* --- Privacy page --- */
.privacy-main h1 {
  margin-bottom: 0.5rem;
}
.privacy-updated {
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
  color: var(--muted);
}

/* --- Mobile nav --- */
@media (max-width: 768px) {
  .nav-main {
    width: 100%;
    order: 3;
  }
  .header-actions {
    margin-left: 0;
  }
}
