/* Kenkobo Development — site styles */

:root {
  --bg:          #050507;
  --bg-elev:     #0b0a10;
  --ink:         #e8e6e1;
  --ink-dim:     rgba(232, 230, 225, 0.62);
  --ink-faint:   rgba(232, 230, 225, 0.32);
  --accent:      rgb(255, 45, 35);
  --accent-soft: rgba(255, 50, 40, 0.25);
  --accent-glow: rgba(255, 70, 50, 0.55);
  --grid:        rgba(0, 0, 0, 0.04);
  --line:        rgba(232, 230, 225, 0.08);

  --font-mono: 'Courier New', ui-monospace, SFMono-Regular, Menlo, monospace;
  --font-body: ui-sans-serif, -apple-system, BlinkMacSystemFont, 'Inter', 'Helvetica Neue', Arial, sans-serif;

  --max:  1480px;
  --pad:  clamp(20px, 5vw, 96px);

  /* Fluid type scale — clamp(min, viewport-relative, max).
     Tuned so 1280px viewport sits ~mid-range; 1920px hits caps. */
  --fs-eyebrow:  clamp(13px, 0.95vw + 4px, 16px);
  --fs-body:     clamp(15px, 0.55vw + 11px, 19px);
  --fs-lede:     clamp(17px, 0.95vw + 11px, 23px);
  --fs-h3:       clamp(19px, 0.7vw + 13px, 24px);
  --fs-h2:       clamp(30px, 2.6vw + 8px, 56px);
  --fs-h1:       clamp(42px, 5.8vw + 8px, 96px);
  --fs-mono-sm:  clamp(11px, 0.55vw + 6px, 14px);
  --fs-mono-md:  clamp(13px, 0.7vw + 6px, 16px);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: 1.6;
  font-feature-settings: "ss01", "cv11";
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100vh;
  opacity: 0;
  transition: opacity 0.6s ease-out;
  background-image:
    radial-gradient(ellipse at top, rgba(255, 50, 40, 0.055), transparent 55%),
    repeating-linear-gradient(0deg, var(--grid) 0 1px, transparent 1px 3px);
  background-attachment: fixed;
}
body.loaded { opacity: 1; }

a { color: var(--ink); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--accent); }

/* ───────────────────────── header ───────────────────────── */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(5, 5, 7, 0.78);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--accent-soft);
}
.site-header .inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(14px, 1.1vw + 6px, 22px) var(--pad);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(20px, 2vw, 36px);
}
.brand {
  display: inline-flex;
  align-items: center;
  line-height: 0;
  position: relative;
}
.brand canvas { display: block; }
.brand:hover canvas { filter: drop-shadow(0 0 6px var(--accent-glow)); }

.nav {
  display: flex;
  gap: clamp(16px, 2.4vw, 38px);
  font-family: var(--font-mono);
  font-size: var(--fs-mono-md);
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.nav a {
  color: var(--ink-dim);
  padding: 8px 0;
  border-bottom: 1px solid transparent;
}
.nav a:hover { color: var(--ink); border-bottom-color: var(--accent); }

@media (max-width: 640px) {
  .nav { letter-spacing: 0.1em; gap: 14px; }
  .nav a:nth-child(2), .nav a:nth-child(3) { display: none; } /* keep Services + Contact */
}

/* ───────────────────────── section scaffolding ───────────────────────── */

section {
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(64px, 9vw + 16px, 144px) var(--pad);
  position: relative;
}
section + section { border-top: 1px solid var(--line); }

.eyebrow {
  font-family: var(--font-mono);
  font-size: var(--fs-eyebrow);
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: rgb(255, 90, 75);
  text-shadow: 0 0 14px rgba(255, 70, 50, 0.35);
  margin-bottom: clamp(18px, 1.5vw + 8px, 30px);
  display: inline-flex;
  align-items: center;
  gap: 14px;
}
.eyebrow::before {
  content: '';
  width: clamp(22px, 2vw, 36px);
  height: 2px;
  background: var(--accent);
  box-shadow: 0 0 8px var(--accent-glow);
}

h2 {
  font-size: var(--fs-h2);
  font-weight: 500;
  letter-spacing: -0.015em;
  margin-bottom: clamp(14px, 1vw + 8px, 22px);
  line-height: 1.1;
}

h3 {
  font-size: var(--fs-h3);
  font-weight: 500;
  letter-spacing: 0.01em;
  margin-bottom: 14px;
  color: var(--ink);
}

p { color: var(--ink-dim); font-size: var(--fs-body); line-height: 1.65; }
section > p { max-width: 60ch; font-size: var(--fs-lede); }

/* ───────────────────────── hero ───────────────────────── */

.hero {
  padding-top: clamp(80px, 12vw + 8px, 200px);
  padding-bottom: clamp(80px, 12vw + 8px, 180px);
  max-width: var(--max);
}
.hero h1 {
  font-size: var(--fs-h1);
  line-height: 1.04;
  font-weight: 500;
  letter-spacing: -0.025em;
  max-width: 18ch;
  margin-bottom: clamp(22px, 2vw + 8px, 40px);
  color: var(--ink);
}
.hero h1 .accent { color: var(--accent); }
.hero .lede {
  font-size: var(--fs-lede);
  color: var(--ink-dim);
  max-width: 56ch;
  margin-bottom: clamp(32px, 3vw + 8px, 56px);
  line-height: 1.55;
}
.cta {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: clamp(14px, 1vw + 8px, 20px) clamp(22px, 1.6vw + 12px, 32px);
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--accent);
  font-family: var(--font-mono);
  font-size: var(--fs-mono-md);
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  transition: background 0.25s, color 0.25s, box-shadow 0.25s;
}
.cta:hover {
  background: var(--accent);
  color: var(--bg);
  box-shadow: 0 0 24px var(--accent-glow);
}
.cta .arrow { transition: transform 0.25s; }
.cta:hover .arrow { transform: translateX(4px); }

/* ───────────────────────── services ───────────────────────── */

.services-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  margin-top: clamp(32px, 3vw + 12px, 64px);
}
@media (min-width: 720px) {
  .services-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 980px) {
  .services-grid { grid-template-columns: repeat(3, 1fr); }
}
.services-grid article {
  background: var(--bg);
  padding: clamp(28px, 2.5vw + 12px, 52px) clamp(24px, 2vw + 12px, 44px);
  transition: background 0.25s;
  position: relative;
}
.services-grid article:hover { background: var(--bg-elev); }
.services-grid article::before {
  content: attr(data-tag);
  position: absolute;
  top: clamp(18px, 1.4vw + 6px, 28px);
  right: clamp(22px, 1.6vw + 8px, 34px);
  font-family: var(--font-mono);
  font-size: var(--fs-mono-md);
  font-weight: 600;
  letter-spacing: 0.2em;
  color: var(--accent);
  opacity: 0.7;
}
.services-grid article h3 {
  margin-top: clamp(22px, 2vw + 8px, 40px);
  margin-bottom: 16px;
}
.services-grid article p { font-size: var(--fs-body); line-height: 1.65; }

/* ───────────────────────── track record ───────────────────────── */

.track {
  list-style: none;
  margin-top: clamp(28px, 2.5vw + 8px, 56px);
  display: grid;
  gap: 1px;
  background: var(--line);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.track li {
  background: var(--bg);
  padding: clamp(20px, 1.6vw + 10px, 36px) clamp(22px, 1.8vw + 10px, 40px);
  display: grid;
  grid-template-columns: clamp(120px, 11vw, 180px) 1fr;
  gap: clamp(24px, 2.4vw, 48px);
  align-items: baseline;
  color: var(--ink-dim);
  font-size: var(--fs-body);
  line-height: 1.6;
}
.track .metric {
  font-family: var(--font-mono);
  color: var(--accent);
  font-size: var(--fs-mono-md);
  font-weight: 600;
  letter-spacing: 0.06em;
  font-variant-numeric: tabular-nums;
  text-shadow: 0 0 10px rgba(255, 70, 50, 0.3);
}
.track li strong { color: var(--ink); font-weight: 500; }
@media (max-width: 640px) {
  .track li { grid-template-columns: 1fr; gap: 8px; }
}

/* ───────────────────────── leadership ───────────────────────── */

.creds-list {
  list-style: none;
  margin-top: clamp(32px, 3vw + 8px, 60px);
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--line);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.creds-list li {
  background: var(--bg);
  padding: clamp(20px, 1.7vw + 8px, 36px) clamp(22px, 2vw + 8px, 40px);
  display: grid;
  grid-template-columns: clamp(100px, 9vw, 140px) 1fr;
  gap: clamp(16px, 1.6vw, 28px);
  align-items: baseline;
  color: var(--ink);
  font-size: var(--fs-body);
  line-height: 1.5;
}
.creds-list .badge {
  font-family: var(--font-mono);
  color: var(--accent);
  font-size: var(--fs-mono-md);
  font-weight: 600;
  letter-spacing: 0.04em;
  font-variant-numeric: tabular-nums;
  filter: drop-shadow(0 0 6px rgba(255, 70, 50, 0.45));
}
@media (max-width: 880px) {
  .creds-list { grid-template-columns: 1fr; }
}
@media (max-width: 540px) {
  .creds-list li { grid-template-columns: 1fr; gap: 6px; }
}

.community {
  margin-top: clamp(24px, 2vw + 8px, 40px);
  font-style: italic;
  color: var(--ink-faint);
  font-size: var(--fs-body);
  max-width: 70ch;
}

/* ───────────────────────── contact ───────────────────────── */

.contact-grid {
  margin-top: clamp(28px, 2.5vw + 8px, 52px);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.contact-grid .cell {
  background: var(--bg);
  padding: clamp(22px, 2vw + 10px, 40px);
}
.contact-grid .label {
  font-family: var(--font-mono);
  font-size: var(--fs-mono-sm);
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: clamp(10px, 0.8vw + 4px, 18px);
  opacity: 0.85;
}
.contact-grid .value {
  font-size: var(--fs-h3);
  color: var(--ink);
  word-break: break-word;
  font-weight: 500;
}
.contact-grid a.value { border-bottom: 1px solid transparent; transition: border-color 0.2s, color 0.2s; }
.contact-grid a.value:hover { color: var(--accent); border-bottom-color: var(--accent); }

.contact-cta {
  margin-top: clamp(36px, 3.5vw + 8px, 72px);
  display: flex;
  justify-content: flex-start;
}

/* ───────────────────────── footer ───────────────────────── */

.site-footer {
  border-top: 1px solid var(--line);
  padding: clamp(28px, 2.4vw + 12px, 56px) var(--pad);
  text-align: center;
  font-family: var(--font-mono);
  font-size: var(--fs-mono-sm);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-dim);
}
.site-footer .sep { color: var(--accent); margin: 0 12px; opacity: 0.6; }

/* ───────────────────────── dialog (contact form) ───────────────────────── */

.dialog {
  background: var(--bg-elev);
  color: var(--ink);
  border: 1px solid var(--accent-soft);
  border-radius: 0;
  max-width: 560px;
  width: calc(100% - 32px);
  padding: 0;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.7), 0 0 80px rgba(255, 70, 50, 0.08);
  position: fixed;
  inset: 0;
  margin: auto;
}
.dialog::backdrop {
  background: rgba(5, 5, 7, 0.86);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.dialog-content,
.dialog-success {
  padding: 48px 52px;
  position: relative;
}

.dialog-close {
  position: absolute;
  top: 14px;
  right: 16px;
  background: transparent;
  color: var(--ink-dim);
  border: none;
  font: 400 28px/1 'Courier New', monospace;
  cursor: pointer;
  padding: 8px 12px;
  transition: color 0.2s;
  z-index: 1;
}
.dialog-close:hover { color: var(--accent); }

.dialog-eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 14px;
}
.dialog h3 {
  font-size: 28px;
  font-weight: 500;
  letter-spacing: -0.01em;
  margin-bottom: 14px;
  color: var(--ink);
  line-height: 1.15;
}
.dialog-lede {
  color: var(--ink-dim);
  font-size: 16px;
  line-height: 1.6;
  margin-bottom: 32px;
}

#contact-form {
  display: grid;
  gap: 22px;
}
#contact-form label {
  display: grid;
  gap: 8px;
}
#contact-form .field-label {
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent);
  opacity: 0.85;
}
#contact-form .field-label em {
  text-transform: none;
  letter-spacing: 0.04em;
  font-style: italic;
  color: var(--ink-faint);
  font-weight: 400;
  margin-left: 6px;
}
#contact-form input,
#contact-form textarea {
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  letter-spacing: 0.005em;
  padding: 10px 0;
  outline: none;
  transition: border-color 0.2s;
  width: 100%;
  resize: vertical;
  min-height: 0;
}
#contact-form textarea { font-family: var(--font-body); line-height: 1.55; }
#contact-form input::placeholder,
#contact-form textarea::placeholder {
  color: var(--ink-faint);
  opacity: 1;
}
#contact-form input:focus,
#contact-form textarea:focus {
  border-bottom-color: var(--accent);
}
#contact-form button[type="submit"] {
  justify-self: start;
  margin-top: 8px;
  cursor: pointer;
  background: transparent;
  font-family: var(--font-mono);
}

.dialog-success {
  text-align: center;
  padding: 64px 52px;
}
.dialog-success .check {
  font-size: 64px;
  color: var(--accent);
  text-shadow: 0 0 28px var(--accent-glow);
  margin-bottom: 18px;
  line-height: 1;
}
.dialog-success .cta {
  margin: 8px auto 0;
  cursor: pointer;
  background: transparent;
}

@media (max-width: 540px) {
  .dialog-content { padding: 38px 28px; }
  .dialog-success { padding: 52px 28px; }
  .dialog h3 { font-size: 24px; }
}

/* ───────────────────────── reduced motion ───────────────────────── */

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
  body { opacity: 1; }
}
