/* ============================================================
   ASHWA RACING — CONTACT PAGE
   System: Barlow Condensed + Barlow · dark motorsport-editorial
   ============================================================ */

/* ─── Tokens ────────────────────────────────────────────────── */
:root {
  --red:          #e8001d;
  --red-dark:     #b5001a;
  --black:        #0a0a0a;
  --charcoal:     #141414;
  --dark-grey:    #1c1c1c;
  --mid-grey:     #2a2a2a;
  --off-white:    #f7f6f4;
  --white:        #ffffff;
  --text-muted:   #888;
  --font-display: 'Barlow Condensed', sans-serif;
  --font-body:    'Barlow', sans-serif;
  --ease-expo:    cubic-bezier(0.16, 1, 0.3, 1);
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { font-family: var(--font-body); background: var(--charcoal); color: var(--white); overflow-x: hidden; }

/* ─── Shared ─────────────────────────────────────────────────── */
.ct-section-label {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-display);
  font-size: 0.62rem; letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--red); margin-bottom: 20px;
}
.label-dash { display: block; width: 22px; height: 2px; background: var(--red); flex-shrink: 0; }

.reveal {
  opacity: 0; transform: translateY(24px);
  transition:
    opacity 0.55s var(--ease-expo) var(--delay, 0s),
    transform 0.55s var(--ease-expo) var(--delay, 0s);
}
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ═══════════════════════════════════════════════════════════════
   HERO
═══════════════════════════════════════════════════════════════ */
.ct-hero {
  position: relative;
  height: 60svh; min-height: 420px; max-height: 660px;
  background: var(--black);
  overflow: hidden;
  display: flex; flex-direction: column; justify-content: flex-end;
}

.ct-hero-bg {
  position: absolute; inset: 0;
  background: url('../../images/team/Costwin.jpg') center 30% / cover no-repeat;
  filter: brightness(0.2) saturate(0.6);
  transform: scale(1.04);
  transition: transform 8s var(--ease-expo);
}
.ct-hero:hover .ct-hero-bg { transform: scale(1.0); }

.ct-hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.95) 0%, rgba(0,0,0,0.35) 55%, rgba(0,0,0,0.05) 100%);
}

.ct-hero-grid {
  position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(rgba(255,255,255,0.022) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.022) 1px, transparent 1px);
  background-size: 64px 64px;
}

.ct-hero-stripe {
  position: absolute; top: 0; right: 9%; z-index: 2;
  width: 3px; height: 100%;
  background: var(--red);
}
.ct-hero-stripe::before {
  content: '';
  position: absolute; top: 0; left: -14px;
  width: 1px; height: 100%;
  background: var(--red); opacity: 0.28;
}

.ct-hero-content {
  position: relative; z-index: 3;
  padding: 0 7% 52px; max-width: 660px;
}

.ct-eyebrow {
  display: flex; align-items: center; gap: 14px;
  font-family: var(--font-display);
  font-size: 0.75rem; letter-spacing: 0.2em; text-transform: uppercase;
  color: rgba(255,255,255,0.4); margin-bottom: 14px;
}
.eyebrow-dash { display: block; width: 28px; height: 2px; background: var(--red); flex-shrink: 0; }

.ct-hero-title {
  font-family: var(--font-display);
  font-size: clamp(4rem, 11vw, 8.5rem);
  font-weight: 800; line-height: 0.86;
  letter-spacing: -0.02em; text-transform: uppercase;
  color: var(--white); margin-bottom: 18px;
}
.ct-hero-title em { font-style: italic; color: var(--red); display: block; }

.ct-hero-desc {
  font-size: clamp(0.88rem, 1.3vw, 1rem);
  line-height: 1.7; color: rgba(255,255,255,0.5);
  font-weight: 300; max-width: 440px;
}

/* ═══════════════════════════════════════════════════════════════
   MAIN SPLIT
═══════════════════════════════════════════════════════════════ */
.ct-main {
  display: grid;
  grid-template-columns: 380px 1fr;
  min-height: 70vh;
  background: var(--charcoal);
}

/* ─── Left column ─────────────────────────────────────────────── */
.ct-left {
  background: var(--black);
  padding: 64px 48px;
  display: flex; flex-direction: column;
  gap: 48px;
  border-right: 1px solid rgba(255,255,255,0.06);
}

/* Contact detail rows */
.ct-detail {
  display: flex; align-items: flex-start; gap: 16px;
  margin-bottom: 20px;
}
.ct-detail:last-child { margin-bottom: 0; }

.ct-detail-icon {
  width: 38px; height: 38px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  background: rgba(232,0,29,0.1);
  border: 1px solid rgba(232,0,29,0.2);
  border-radius: 4px;
  font-size: 0.9rem; color: var(--red);
}

.ct-detail-label {
  font-family: var(--font-display);
  font-size: 0.6rem; letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--text-muted); margin-bottom: 4px;
}

.ct-detail-value {
  font-size: 0.88rem; line-height: 1.6;
  color: rgba(255,255,255,0.7); font-weight: 300;
  text-decoration: none;
  transition: color 0.2s ease;
}
a.ct-detail-value:hover { color: var(--red); }

/* Enquiry type pills */
.ct-enquiry-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.ct-eq-btn {
  padding: 9px 14px;
  background: var(--dark-grey);
  border: 1px solid rgba(255,255,255,0.08);
  color: rgba(255,255,255,0.35);
  font-family: var(--font-display);
  font-size: 0.78rem; font-weight: 700;
  letter-spacing: 0.08em; text-transform: uppercase;
  border-radius: 3px; cursor: pointer;
  transition: all 0.2s ease;
  text-align: center;
}
.ct-eq-btn:hover { color: var(--white); border-color: rgba(255,255,255,0.25); }
.ct-eq-btn.active {
  background: var(--red); border-color: var(--red); color: var(--white);
}

/* Socials */
.ct-socials {
  display: flex; gap: 8px;
}
.ct-socials a {
  width: 38px; height: 38px;
  display: flex; align-items: center; justify-content: center;
  background: var(--dark-grey);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 4px; color: rgba(255,255,255,0.35);
  font-size: 0.9rem; text-decoration: none;
  transition: all 0.2s ease;
}
.ct-socials a:hover {
  background: var(--red); border-color: var(--red); color: var(--white);
  transform: translateY(-3px);
}

/* ─── Right column: form ──────────────────────────────────────── */
.ct-right {
  padding: 64px 60px;
  display: flex; flex-direction: column;
}

.ct-form-header { margin-bottom: 40px; }

.ct-form-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800; line-height: 0.9;
  text-transform: uppercase; letter-spacing: -0.01em;
  color: var(--white);
}
.ct-form-title em { font-style: italic; color: var(--red); display: block; }

/* Form layout */
.ct-form { display: flex; flex-direction: column; gap: 20px; }

.ct-form-row {
  display: grid; grid-template-columns: 1fr 1fr; gap: 16px;
}

/* Field */
.ct-field { display: flex; flex-direction: column; gap: 7px; }

.ct-field label {
  font-family: var(--font-display);
  font-size: 0.65rem; letter-spacing: 0.16em; text-transform: uppercase;
  color: rgba(255,255,255,0.4); font-weight: 700;
}
.req { color: var(--red); }
.ct-optional { color: var(--text-muted); font-weight: 400; letter-spacing: 0; text-transform: none; }

.ct-field input,
.ct-field textarea {
  width: 100%;
  background: var(--dark-grey);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 3px;
  padding: 13px 16px;
  font-family: var(--font-body);
  font-size: 0.9rem; font-weight: 300;
  color: var(--white);
  outline: none;
  transition: border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
  resize: none;
}
.ct-field input::placeholder,
.ct-field textarea::placeholder { color: rgba(255,255,255,0.2); }

.ct-field input:focus,
.ct-field textarea:focus {
  border-color: var(--red);
  background: #202020;
  box-shadow: 0 0 0 3px rgba(232,0,29,0.1);
}

/* Error */
.ct-field.has-error input,
.ct-field.has-error textarea {
  border-color: #ff4444;
  box-shadow: 0 0 0 3px rgba(255,68,68,0.12);
}

.ct-field-error {
  font-size: 0.72rem; color: #ff6666;
  min-height: 16px; letter-spacing: 0.02em;
}

/* Char count */
.ct-char-count {
  text-align: right;
  font-size: 0.68rem; color: var(--text-muted);
  margin-top: 4px;
}

/* Submit button */
.ct-submit {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 12px;
  padding: 15px 32px;
  background: var(--red); color: var(--white);
  border: 2px solid var(--red); border-radius: 3px;
  font-family: var(--font-display);
  font-size: 1rem; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase;
  cursor: pointer; width: 100%;
  transition: all 0.25s ease;
  position: relative;
}
.ct-submit:hover:not([disabled]) {
  background: var(--red-dark); border-color: var(--red-dark);
  transform: translateY(-2px);
  box-shadow: 0 10px 28px rgba(232,0,29,0.3);
}
.ct-submit[disabled] { opacity: 0.5; cursor: not-allowed; transform: none; }

.ct-submit-icon { transition: transform 0.2s ease; }
.ct-submit:hover .ct-submit-icon { transform: translateX(4px); }

/* Success state */
.ct-success {
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  flex: 1; gap: 16px; text-align: center;
  padding: 60px 20px;
}

.ct-success-icon {
  width: 64px; height: 64px; border-radius: 50%;
  background: rgba(232,0,29,0.08);
  border: 2px solid rgba(232,0,29,0.25);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.6rem; color: var(--red);
  animation: successPop 0.5s var(--ease-expo) both;
}
@keyframes successPop {
  from { transform: scale(0.5); opacity: 0; }
  to   { transform: scale(1);   opacity: 1; }
}

.ct-success h3 {
  font-family: var(--font-display);
  font-size: 2rem; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.04em;
  color: var(--white);
}

.ct-success p {
  font-size: 0.9rem; line-height: 1.7;
  color: rgba(255,255,255,0.4); max-width: 360px;
}

.ct-reset-btn {
  margin-top: 8px; padding: 10px 24px;
  font-family: var(--font-display);
  font-size: 0.82rem; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase;
  background: transparent; color: var(--red);
  border: 1px solid var(--red); border-radius: 3px;
  cursor: pointer; transition: all 0.2s ease;
}
.ct-reset-btn:hover { background: var(--red); color: var(--white); }

/* ─── Accessibility ──────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
  .reveal { opacity: 1; transform: none; }
}

/* ─── Responsive ─────────────────────────────────────────────── */
@media (max-width: 960px) {
  .ct-main { grid-template-columns: 1fr; }
  .ct-left {
    flex-direction: row; flex-wrap: wrap; gap: 36px;
    padding: 48px 5%; border-right: none;
    border-bottom: 1px solid rgba(255,255,255,0.06);
  }
  .ct-info-block, .ct-enquiry-block, .ct-social-block { flex: 1 1 260px; }
  .ct-right { padding: 48px 5%; }
}

@media (max-width: 640px) {
  .ct-hero-content { padding: 0 5% 44px; }
  .ct-form-row { grid-template-columns: 1fr; }
  .ct-left { padding: 40px 5%; gap: 28px; }
  .ct-right { padding: 40px 5%; }
  .ct-enquiry-grid { grid-template-columns: 1fr 1fr; }
}