:root {
  --brand-purple: #7A3FF5;
  --text-dark: #111111;
  --text-muted: #666666;
  --text-light: #ffffff;
  --grey-dark: #151515;
  --background: #ffffff;
  --border-subtle: #e2e2e2;
  --radius-md: 10px;
  --radius-lg: 16px;
  --shadow-soft: 0 18px 45px rgba(0, 0, 0, 0.12);
  --transition-fast: 0.2s ease;
  --transition-med: 0.3s ease;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  padding: 0;
  font-family: 'Poppins', sans-serif;
  color: var(--text-dark);
  background-color: var(--background);
  line-height: 1.6;
}

/* LAYOUT ALIGNMENT */
.container,
.section-inner {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* HEADER */
.site-header {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 999;
  padding: 1rem 0;
  background-color: transparent;
  transition: background-color var(--transition-med), box-shadow var(--transition-med);
}

.site-header.nav-scrolled {
  background-color: rgba(17, 17, 17, 0.96);
  backdrop-filter: blur(10px);
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo-img {
  height: 42px;
  width: auto;
}

/* NAVIGATION */
.nav {
  display: flex;
  align-items: center;
}

.nav-list {
  display: flex;
  list-style: none;
  gap: 2rem;
  padding: 0;
  margin: 0;
}

.nav-link {
  color: var(--text-light);
  text-decoration: none;
  font-weight: 400;
  position: relative;
  transition: color var(--transition-fast);
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 0;
  height: 2px;
  background: var(--brand-purple);
  transition: width var(--transition-fast);
}

.nav-link:hover {
  color: var(--brand-purple);
}

.nav-link:hover::after {
  width: 100%;
}

/* MOBILE NAV */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  width: 40px;
  height: 32px;
  border: none;
  background: transparent;
  cursor: pointer;
}

.nav-toggle-line {
  width: 100%;
  height: 2px;
  background: var(--text-light);
  border-radius: 100px;
}

/* HERO SECTION */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  color: var(--text-light);
  background-image: url('../img/Hero-fallback.webp');
  background-size: cover;
  background-position: center;
}

.hero-media {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}

.hero-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, rgba(0,0,0,0.6), rgba(8,8,20,0.65));
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  padding: 7rem 0 5rem;  /* top/right/left/bottom, left/right come from .container */
}

/* HERO TEXT BLOCK (controlled line length + left alignment) */
.hero-title,
.hero-subtitle,
.hero-actions {
  max-width: 600px;
  margin-left: 0 !important;   /* kill any auto-centering */
  margin-right: 0;
}

.hero-title {
  font-size: 2.6rem;
  line-height: 1.15;
  margin: 0 0 1rem;
  font-weight: 600;
}

.hero-subtitle {
  color: rgba(255,255,255,0.9);
  margin-bottom: 1.5rem;
  font-size: 1.05rem;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;  /* left text, right image space */
  align-items: center;
  max-width: 1120px;
  margin: 0 auto;
  padding: 7rem 1.5rem 5rem;
  position: relative;
  z-index: 2;
}

.hero-left {
  max-width: 600px;
}

.hero-right {
  /* empty: acts as a balancing column so text appears visually centered-left */
}

/* BUTTONS (square-ish) */
.btn {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  padding: 0.75rem 1.6rem;
  border-radius: 12px;
  font-size: 0.95rem;
  font-weight: 500;
  border: 1px solid transparent;
  text-decoration: none;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-primary {
  background: var(--brand-purple);
  color: var(--text-light);
  box-shadow: 0 10px 30px rgba(122,63,245,0.4);
}

.btn-primary:hover {
  background: #6a36e0;
  transform: translateY(-1px);
}

/* SECTIONS */
.section {
  padding: 4.5rem 0;
}

.section-header {
  margin-bottom: 2.5rem;
}

.section-header--center {
  text-align: center;
}

.section-subtitle {
  max-width: 640px;
  margin: 0.5rem auto 2.5rem;
  color: var(--text-muted);
  font-size: 1rem;
}

/* ABOUT SECTION */
.section-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 3rem;
  align-items: center;
}

.about-image-wrapper {
  max-width: 440px;
  margin-left: auto;
  margin-right: 0;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-soft);
}

.about-image {
  width: 100%;
  height: auto;
  object-fit: cover;
  display: block;
}

/* SERVICES */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.75rem;
}

.service-card {
  background: #fff;
  border-radius: var(--radius-md);
  padding: 1.6rem;
  border: 1px solid var(--border-subtle);
  box-shadow: 0 10px 30px rgba(0,0,0,0.06);
  transition: all var(--transition-fast);
}

.service-card:hover {
  transform: translateY(-4px);
  border-color: rgba(122,63,245,0.5);
}

/* CONTACT */
.section-contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2.5rem;
  align-items: start;
}

.contact-text {
  max-width: 540px;        /* same readable line-length as hero text */
  margin-left: 0;          /* left-align within the grid */
  font-size: 1rem;
  color: var(--text-dark);
}

.contact-form {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  border: 1px solid var(--border-subtle);
  box-shadow: var(--shadow-soft);
}

.form-row {
  margin-bottom: 1rem;
}

.form-row label {
  display: block;
  margin-bottom: 0.35rem;
  font-size: 0.9rem;
  font-weight: 500;
}

.form-row input,
.form-row textarea {
  width: 100%;
  border-radius: 14px;
  border: 1px solid #d4d4d4;
  padding: 0.65rem 0.9rem;
  font-family: inherit;
  font-size: 0.95rem;
  transition: all var(--transition-fast);
}

.form-row textarea {
  resize: vertical;
  min-height: 120px;
}

.form-row input:focus,
.form-row textarea:focus {
  border-color: var(--brand-purple);
  box-shadow: 0 0 0 2px rgba(122,63,245,0.25);
}

.form-status {
  margin-top: 1rem;
  font-size: 0.95rem;
}


/* FOOTER */
.site-footer {
  border-top: 1px solid var(--border-subtle);
  padding: 1.4rem 0;
  text-align: center;
  font-size: 0.9rem;
  color: var(--text-muted);
}

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

.fade-in.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* RESPONSIVE */
@media (max-width: 992px) {
  .section-grid {
    grid-template-columns: 1fr;
  }

  .section-contact-grid {
    grid-template-columns: 1fr;
  }

  .services-grid {
    grid-template-columns: 1fr 1fr;
  }

  .about-image-wrapper {
    margin: 2rem auto 0;
  }
}

@media (max-width: 768px) {
  .nav-toggle {
    display: flex;
  }

  .nav {
    position: fixed;
    inset: 0;
    top: 60px;
    background: rgba(10,10,15,0.97);
    transform: translateY(-100%);
    transition: transform var(--transition-med);
  }

  .nav.open {
    transform: translateY(0);
  }

  .nav-list {
    flex-direction: column;
    padding: 1.5rem;
    gap: 1.25rem;
  }

  .services-grid {
    grid-template-columns: 1fr;
  }

  .hero-video {
    display: none;
  }

  .hero-content {
    padding-top: 7rem;
  }
}

/* ============================================
   EXTRA RESPONSIVE FIXES (SAFE FOR DESKTOP)
   ============================================ */

/* -------- TABLET: max-width 992px -------- */
@media (max-width: 992px) {
  
  /* Hero spacing slightly tighter */
  .hero-inner {
    grid-template-columns: 1fr; /* stack */
    padding-top: 6rem;
    padding-bottom: 4rem;
  }

  .hero-left {
    max-width: 600px; /* maintains your desktop width */
  }

  .hero-right {
    display: none;
  }

  /* About section */
  .section-grid {
    grid-template-columns: 1fr;
    text-align: left;
  }

  .about-image-wrapper {
    margin: 2rem auto 0;
  }

  /* Services becomes 2-column */
  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  /* Contact becomes 1-column */
  .section-contact-grid {
    grid-template-columns: 1fr;
  }
}

/* -------- MOBILE: max-width 768px -------- */
@media (max-width: 768px) {

  /* --- Hamburger --- */
  .nav-toggle {
    display: flex;
  }

  .nav {
    position: fixed;
    top: 60px;
    left: 0;
    right: 0;
    background: rgba(10,10,15,0.97);
    transform: translateY(-120%);
    transition: transform var(--transition-med);
    padding-bottom: 2rem;
  }

  .nav.nav-open {
    transform: translateY(0);
  }

  .nav-list {
    flex-direction: column;
    gap: 1.2rem;
    padding: 1.5rem;
  }

  /* Hide hero video on mobile */
  .hero-video {
    display: none;
  }

  /* Hero layout */
  .hero-inner {
    grid-template-columns: 1fr;
  }

  .hero-title {
    font-size: 2rem;
    max-width: 90%; /* safe wrap, but desktop unaffected */
  }

  .hero-subtitle {
    font-size: 1rem;
  }

  .hero-actions {
    max-width: 90%;
  }

  /* Services: 1 column */
  .services-grid {
    grid-template-columns: 1fr;
  }

  /* Contact form spacing */
  .contact-form {
    padding: 1.4rem;
  }
}

/* -------- SMALL MOBILE: max-width 480px -------- */
@media (max-width: 480px) {

  .hero-title {
    font-size: 1.75rem;
  }

  .hero-inner {
    padding-top: 6rem;
  }

  .btn {
    padding: 0.7rem 1.3rem;
    font-size: 0.9rem;
  }

  .service-card {
    padding: 1.3rem;
  }
}
