/* ============================================
   ALEX MORGAN — VALIDATION CONSULTANT
   style.css
   ============================================ */

/* ── VARIABLES ── */
:root {
  --navy:    #0d1b2a;
  --steel:   #1c3144;
  --accent:  #4fc3c3;
  --accent2: #c8f0ef;
  --offwhite:#f4f1eb;
  --text:    #e8e4dc;
  --muted:   #8a9bb0;
  --rule:    rgba(78,195,195,0.18);
}

/* ── RESET ── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html { scroll-behavior: smooth; }

body {
  background-color: var(--navy);
  color: var(--text);
  font-family: 'DM Sans', sans-serif;
  font-weight: 300;
  line-height: 1.7;
  overflow-x: hidden;
}

/* ── NAV ── */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.2rem 5vw;
  background: rgba(13,27,42,0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--rule);
}

.nav-logo {
  font-family: 'DM Mono', monospace;
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  color: var(--accent);
  text-transform: uppercase;
  white-space: nowrap;
}

nav ul {
  list-style: none;
  display: flex;
  gap: 2.5rem;
}

nav a {
  font-family: 'DM Mono', monospace;
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s;
}

nav a:hover { color: var(--accent); }

/* Hamburger — hidden on desktop */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 4px;
  background: none;
  border: none;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--accent);
  transition: transform 0.3s, opacity 0.3s;
}

/* ── HERO ── */
#hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 6rem 5vw 4rem;
  position: relative;
  overflow: hidden;
}

.hero-grid-bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--rule) 1px, transparent 1px),
    linear-gradient(90deg, var(--rule) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 40%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 40%, transparent 100%);
}

.hero-accent-line {
  position: absolute;
  top: 38%;
  right: -80px;
  width: 420px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  opacity: 0.5;
}

.hero-content {
  position: relative;
  max-width: 820px;
}

.hero-tag {
  font-family: 'DM Mono', monospace;
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.4rem;
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.hero-tag::before {
  content: '';
  display: inline-block;
  width: 32px;
  height: 1px;
  background: var(--accent);
  flex-shrink: 0;
}

h1 {
  font-family: 'DM Serif Display', serif;
  font-size: clamp(3rem, 7vw, 6.5rem);
  line-height: 1.05;
  color: var(--offwhite);
  margin-bottom: 1.8rem;
}

h1 em {
  font-style: italic;
  color: var(--accent);
}

.hero-sub {
  font-size: 1.05rem;
  color: var(--muted);
  max-width: 540px;
  margin-bottom: 2.8rem;
  line-height: 1.8;
}

.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

/* ── BUTTONS ── */
.btn {
  display: inline-block;
  padding: 0.85rem 2.2rem;
  font-family: 'DM Mono', monospace;
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  border: 1px solid var(--accent);
  color: var(--accent);
  transition: background 0.2s, color 0.2s;
  cursor: pointer;
  background: transparent;
}

.btn:hover {
  background: var(--accent);
  color: var(--navy);
}

.btn-ghost {
  border-color: var(--muted);
  color: var(--muted);
}

.btn-ghost:hover {
  background: var(--muted);
  color: var(--navy);
}

/* ── SECTIONS SHARED ── */
section {
  padding: 7rem 5vw;
  border-top: 1px solid var(--rule);
}

.section-label {
  font-family: 'DM Mono', monospace;
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 3rem;
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.section-label::after {
  content: '';
  flex: 1;
  max-width: 60px;
  height: 1px;
  background: var(--accent);
  opacity: 0.4;
}

h2 {
  font-family: 'DM Serif Display', serif;
  font-size: clamp(2rem, 4vw, 3.2rem);
  line-height: 1.15;
  color: var(--offwhite);
  margin-bottom: 1.5rem;
}

/* ── ABOUT ── */
.about-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6rem;
  align-items: start;
}

.about-text p {
  color: var(--muted);
  margin-bottom: 1.2rem;
  font-size: 1rem;
}

.about-text p strong {
  color: var(--text);
  font-weight: 500;
}

.about-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  padding-top: 1rem;
}

.stat {
  border-left: 2px solid var(--accent);
  padding-left: 1.2rem;
}

.stat-number {
  font-family: 'DM Serif Display', serif;
  font-size: 2.6rem;
  color: var(--offwhite);
  line-height: 1;
}

.stat-label {
  font-family: 'DM Mono', monospace;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 0.3rem;
}

/* ── SERVICES ── */
#services { background: var(--steel); }

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 2px;
  margin-top: 1rem;
}

.service-card {
  background: var(--navy);
  padding: 2.5rem;
  position: relative;
  overflow: hidden;
  transition: transform 0.2s;
}

.service-card:hover { transform: translateY(-4px); }

.service-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--accent), transparent);
  opacity: 0;
  transition: opacity 0.2s;
}

.service-card:hover::before { opacity: 1; }

.service-icon {
  font-size: 1.8rem;
  margin-bottom: 1.2rem;
}

.service-card h3 {
  font-family: 'DM Serif Display', serif;
  font-size: 1.35rem;
  color: var(--offwhite);
  margin-bottom: 0.8rem;
}

.service-card p {
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.75;
}

/* ── EXPERIENCE ── */
.timeline {
  max-width: 720px;
}

.timeline-item {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 2.5rem;
  padding-bottom: 3rem;
  position: relative;
}

.timeline-item::after {
  content: '';
  position: absolute;
  left: 159px;
  top: 8px;
  bottom: 0;
  width: 1px;
  background: var(--rule);
}

.timeline-item:last-child::after { display: none; }

.timeline-date {
  font-family: 'DM Mono', monospace;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  color: var(--accent);
  text-align: right;
  padding-top: 0.2rem;
  line-height: 1.5;
}

.timeline-dot {
  position: absolute;
  left: 153px;
  top: 7px;
  width: 13px;
  height: 13px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  background: var(--navy);
  flex-shrink: 0;
}

.timeline-body h3 {
  font-family: 'DM Sans', sans-serif;
  font-weight: 500;
  font-size: 1rem;
  color: var(--offwhite);
  margin-bottom: 0.2rem;
}

.timeline-company {
  font-family: 'DM Mono', monospace;
  font-size: 0.72rem;
  color: var(--muted);
  letter-spacing: 0.06em;
  margin-bottom: 0.7rem;
}

.timeline-body p {
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.75;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.8rem;
}

.tag {
  font-family: 'DM Mono', monospace;
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  border: 1px solid var(--rule);
  padding: 0.25rem 0.65rem;
}

/* ── CONTACT ── */
#contact { background: var(--steel); }

.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6rem;
  align-items: start;
}

.contact-info p {
  color: var(--muted);
  font-size: 0.95rem;
  margin-bottom: 2rem;
  line-height: 1.8;
}

.contact-links {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact-link {
  display: flex;
  align-items: center;
  gap: 1rem;
  text-decoration: none;
  color: var(--muted);
  font-size: 0.9rem;
  transition: color 0.2s;
  word-break: break-all;
}

.contact-link:hover { color: var(--accent); }

.contact-link-icon {
  width: 36px;
  height: 36px;
  border: 1px solid var(--rule);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  flex-shrink: 0;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

label {
  font-family: 'DM Mono', monospace;
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

input, textarea {
  background: var(--navy);
  border: 1px solid var(--rule);
  color: var(--text);
  font-family: 'DM Sans', sans-serif;
  font-size: 0.9rem;
  padding: 0.8rem 1rem;
  outline: none;
  transition: border-color 0.2s;
  resize: vertical;
  width: 100%;
  /* Prevent iOS zoom on input focus */
  font-size: 16px;
}

input:focus, textarea:focus {
  border-color: var(--accent);
}

textarea { min-height: 120px; }

/* ── FOOTER ── */
footer {
  padding: 2.5rem 5vw;
  border-top: 1px solid var(--rule);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.8rem;
}

footer p {
  font-family: 'DM Mono', monospace;
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  color: var(--muted);
}

/* ── FADE IN ANIMATION ── */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: none;
}

/* ============================================
   RESPONSIVE — TABLET (max 900px)
   ============================================ */
@media (max-width: 900px) {
  .about-layout {
    grid-template-columns: 1fr;
    gap: 3.5rem;
  }

  .contact-layout {
    grid-template-columns: 1fr;
    gap: 3.5rem;
  }
}

/* ============================================
   RESPONSIVE — MOBILE (max 640px)
   ============================================ */
@media (max-width: 640px) {

  /* Nav: show hamburger, hide links by default */
  .nav-toggle {
    display: flex;
  }

  nav ul {
    display: none;
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(13,27,42,0.98);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2.5rem;
    z-index: 99;
  }

  nav ul.open {
    display: flex;
  }

  nav ul li a {
    font-size: 1.1rem;
    letter-spacing: 0.15em;
  }

  /* Close icon when open */
  nav.open .nav-toggle span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
  }
  nav.open .nav-toggle span:nth-child(2) {
    opacity: 0;
  }
  nav.open .nav-toggle span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
  }

  /* Hero */
  #hero {
    padding: 7rem 5vw 4rem;
    min-height: 100svh;
  }

  .hero-tag { font-size: 0.65rem; }

  .hero-sub { font-size: 0.95rem; }

  .hero-buttons {
    flex-direction: column;
    align-items: flex-start;
  }

  .btn { width: 100%; text-align: center; }

  /* Sections */
  section { padding: 4.5rem 5vw; }

  /* About stats — 2 col still works fine on mobile */
  .about-stats { gap: 1.5rem; }

  .stat-number { font-size: 2rem; }

  /* Timeline — stack vertically */
  .timeline-item {
    grid-template-columns: 1fr;
    gap: 0.4rem;
    padding-bottom: 2.5rem;
    padding-left: 1.2rem;
    border-left: 1px solid var(--rule);
  }

  .timeline-item::after { display: none; }

  .timeline-dot {
    display: block;
    position: absolute;
    left: -7px;
    top: 4px;
    width: 12px;
    height: 12px;
  }

  .timeline-date {
    text-align: left;
    font-size: 0.68rem;
  }

  /* Footer */
  footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.4rem;
  }
}
