/* ============================================================
   RIAWORKS — Páginas internas (dark) · Sob Medida + Contato
   Reusa tokens de hero.css e footer/cards de prova-cta.css.
   Superfície de card: #161b1ea3 translúcido + borda rgba(46,50,54,0.15)
   + bracket laranja (regra 0). Inter + JetBrains Mono só.
   Revelação vive sob .io.live (JS); sem JS/reduced-motion = estático.
   ============================================================ */

/* ---------- container base de seção interna ---------- */
.section {
  position: relative;
  max-width: 1280px;
  margin: 0 auto;
  padding: clamp(3.5rem, 8vh, 6rem) clamp(1.2rem, 4vw, 4rem);
}
.section-head { max-width: 60ch; margin-bottom: clamp(2.2rem, 5vh, 3.4rem); }
.section-head.center { text-align: center; margin-left: auto; margin-right: auto; }
.section-head h2 {
  font-size: clamp(1.7rem, 2.6vw, 2.4rem);
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-top: 1.1rem;
}
.section-lead {
  color: var(--ink-dim);
  font-size: 1.02rem;
  line-height: 1.75;
  margin-top: 1.1rem;
  max-width: 62ch;
}
.section-head.center .section-lead { margin-left: auto; margin-right: auto; }

/* malha de engenharia suave (assinatura visual das seções) */
.engine::before {
  content: '';
  position: absolute; inset: 0;
  pointer-events: none;
  background:
    repeating-linear-gradient(0deg,  rgba(255,255,255,0.02) 0 1px, transparent 1px 96px),
    repeating-linear-gradient(90deg, rgba(255,255,255,0.02) 0 1px, transparent 1px 96px);
  -webkit-mask-image: radial-gradient(80% 80% at 50% 45%, #000 30%, transparent 90%);
          mask-image: radial-gradient(80% 80% at 50% 45%, #000 30%, transparent 90%);
}

/* ---------- page hero (topo das internas) ---------- */
.page-hero {
  position: relative;
  z-index: 1;
  max-width: 1280px;
  margin: 0 auto;
  padding: clamp(2rem, 5vh, 4rem) clamp(1.2rem, 4vw, 4rem) clamp(2.5rem, 6vh, 4.5rem);
}
.page-hero.split {
  display: grid;
  grid-template-columns: minmax(420px, 52%) 1fr;
  align-items: center;
  gap: clamp(1.5rem, 4vw, 3rem);
  min-height: min(66vh, 620px);
}
.page-hero .kicker { margin-bottom: 1.4rem; }
.page-hero h1 {
  font-size: clamp(2rem, 3.2vw, 3rem);
  font-weight: 600;
  line-height: 1.18;
  letter-spacing: -0.015em;
  margin-bottom: 1.3rem;
}
.page-hero h1 .hl { color: var(--orange); }
.page-hero .sub {
  color: var(--ink-dim);
  font-size: 1.05rem;
  line-height: 1.75;
  max-width: 56ch;
}
.page-hero-art {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 320px;
}
.page-hero-art .art-halo {
  position: absolute;
  left: 50%; top: 50%;
  width: 70%; aspect-ratio: 1;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle,
    rgba(250,93,25,0.14) 0%, rgba(250,93,25,0.05) 40%, transparent 70%);
  pointer-events: none;
}
.page-hero-art img {
  position: relative;
  width: min(78%, 360px);
  height: auto;
  filter: drop-shadow(0 26px 30px rgba(0,0,0,0.55));
  animation: island-idle 6s ease-in-out infinite;
}
@media (prefers-reduced-motion: reduce) {
  .page-hero-art img { animation: none; }
}

/* ---------- grid de recursos "O que construímos" ---------- */
.feat-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.1rem;
}
.feat-card {
  position: relative;
  background: #161b1ea3;
  border: 1px solid rgba(46,50,54,0.15);
  border-radius: 16px;
  padding: 1.6rem 1.4rem 1.5rem;
  transition: border-color .35s ease, transform .35s ease, box-shadow .35s ease;
}
.feat-card:hover {
  border-color: rgba(250,93,25,0.45);
  transform: translateY(-4px);
  box-shadow: 0 18px 40px rgba(0,0,0,0.4), 0 0 24px rgba(250,93,25,0.08);
}
.feat-card::after {
  content: '';
  position: absolute; right: 12px; bottom: 12px;
  width: 14px; height: 14px;
  border-right: 2px solid rgba(250,93,25,0.55);
  border-bottom: 2px solid rgba(250,93,25,0.55);
  border-radius: 0 0 4px 0;
}
.feat-label {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--orange);
  margin-bottom: 0.9rem;
}
.feat-card h3 {
  font-size: 1.14rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.3;
  margin-bottom: 0.6rem;
}
.feat-card p {
  font-size: 0.9rem;
  line-height: 1.7;
  color: #b3b8be;
}

/* ---------- passos "Como trabalhamos" ---------- */
.step-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.1rem;
}
.step {
  position: relative;
  background: #161b1ea3;
  border: 1px solid rgba(46,50,54,0.15);
  border-radius: 16px;
  padding: 1.5rem 1.3rem 1.4rem;
}
.step-num {
  font-family: var(--font-mono);
  font-size: 1.5rem;
  font-weight: 500;
  color: var(--orange);
  letter-spacing: 0.02em;
}
.step-tick {
  width: 26px; height: 2px;
  margin: 0.85rem 0 0.9rem;
  background: linear-gradient(90deg, var(--orange), rgba(250,93,25,0.2));
  border-radius: 2px;
}
.step h3 {
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 0.5rem;
}
.step p {
  font-size: 0.88rem;
  line-height: 1.7;
  color: #b3b8be;
}

/* ---------- faixa de credencial (reusa .stat-tile de prova-cta) ---------- */
.cred-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.1rem;
}

/* ---------- CTA interno ---------- */
.inner-cta { text-align: center; }
.inner-cta h2 {
  font-size: clamp(1.8rem, 2.8vw, 2.5rem);
  font-weight: 600;
  letter-spacing: -0.01em;
  margin-bottom: 1rem;
}
.inner-cta p {
  color: var(--ink-dim);
  font-size: 1.02rem;
  line-height: 1.7;
  max-width: 48ch;
  margin: 0 auto 2rem;
}

/* ---------- contato: grid form + canais ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 1.4rem;
  align-items: start;
}
.contact-form,
.channels {
  position: relative;
  background: #161b1ea3;
  border: 1px solid rgba(46,50,54,0.15);
  border-radius: 16px;
  padding: clamp(1.6rem, 3vw, 2.4rem);
}
.field { margin-bottom: 1.1rem; }
.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.1rem;
}
.field label {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin-bottom: 0.5rem;
}
.field .req { color: var(--orange); }
.field input,
.field select,
.field textarea {
  width: 100%;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  color: var(--ink);
  background: #101215;
  border: 1px solid rgba(46,50,54,0.4);
  border-radius: 10px;
  padding: 0.8rem 0.95rem;
  transition: border-color .25s ease, box-shadow .25s ease;
  -webkit-appearance: none;
     -moz-appearance: none;
          appearance: none;
}
.field textarea { min-height: 130px; resize: vertical; line-height: 1.6; }
.field select {
  background-image:
    linear-gradient(45deg, transparent 50%, var(--orange) 50%),
    linear-gradient(135deg, var(--orange) 50%, transparent 50%);
  background-position:
    calc(100% - 20px) calc(1.15rem),
    calc(100% - 14px) calc(1.15rem);
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  padding-right: 2.4rem;
}
.field input::placeholder,
.field textarea::placeholder { color: #5b6066; }
.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: rgba(250,93,25,0.6);
  box-shadow: 0 0 0 3px rgba(250,93,25,0.12);
}
.field input.invalid,
.field select.invalid,
.field textarea.invalid { border-color: #e0574f; }
.field-error {
  display: none;
  font-size: 0.78rem;
  color: #e88a84;
  margin-top: 0.4rem;
}
.field.show-error .field-error { display: block; }

.form-submit {
  display: inline-block;
  width: 100%;
  font-family: var(--font-sans);
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
  cursor: pointer;
  border: 0;
  background: linear-gradient(135deg, var(--orange), #e04e12);
  padding: 1rem 2rem;
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(250,93,25,0.28);
  transition: transform .3s ease, box-shadow .3s ease;
  margin-top: 0.3rem;
}
.form-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 38px rgba(250,93,25,0.38);
}
.form-note {
  font-size: 0.8rem;
  color: #5b6066;
  line-height: 1.6;
  margin-top: 1rem;
}

/* estado de sucesso (placeholder — sem backend) */
.form-success {
  display: none;
  text-align: center;
  padding: 1.5rem 0.5rem;
}
.form-success.show { display: block; }
.form-success .ok-mark {
  width: 56px; height: 56px;
  margin: 0 auto 1.2rem;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: rgba(250,93,25,0.12);
  border: 1px solid rgba(250,93,25,0.5);
}
.form-success .ok-mark svg { width: 26px; height: 26px; stroke: var(--orange); fill: none; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.form-success h3 { font-size: 1.3rem; font-weight: 600; margin-bottom: 0.6rem; }
.form-success p { color: var(--ink-dim); font-size: 0.95rem; line-height: 1.7; }

/* ---------- card de canais ---------- */
.channels h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 1.4rem;
}
.channel {
  display: flex;
  align-items: flex-start;
  gap: 0.9rem;
  padding: 0.95rem 0;
  border-top: 1px solid rgba(46,50,54,0.35);
  text-decoration: none;
  color: inherit;
}
.channel:first-of-type { border-top: 0; }
.channel-ico {
  flex: 0 0 34px;
  width: 34px; height: 34px;
  border-radius: 9px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(250,93,25,0.1);
  border: 1px solid rgba(250,93,25,0.35);
}
.channel-ico svg { width: 17px; height: 17px; stroke: var(--orange-soft); fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.channel-txt .ch-label {
  font-family: var(--font-mono);
  font-size: 0.58rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin-bottom: 0.25rem;
}
.channel-txt .ch-value {
  font-size: 0.98rem;
  font-weight: 500;
  color: var(--ink);
}
a.channel:hover .ch-value { color: var(--orange-soft); }

/* ---------- revelação sob .io.live ---------- */
.io.live .reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity .8s cubic-bezier(.22,1,.36,1), transform .8s cubic-bezier(.22,1,.36,1);
  transition-delay: var(--d, 0s);
}
.io.live .reveal.in { opacity: 1; transform: none; }

/* ---------- responsivo ---------- */
@media (max-width: 1024px) {
  .feat-grid { grid-template-columns: repeat(2, 1fr); }
  .step-grid { grid-template-columns: repeat(2, 1fr); }
  .cred-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 960px) {
  .page-hero.split { grid-template-columns: 1fr; min-height: unset; }
  .page-hero-art { min-height: 240px; order: -1; }
  .page-hero-art img { width: min(56%, 260px); }
  .contact-grid { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .feat-grid, .step-grid, .cred-grid { grid-template-columns: 1fr; }
  .field-row { grid-template-columns: 1fr; gap: 0; }
}
