/* CSS Custom Properties (Variables) - Design system colors and values */
:root {
    --primary: #d61f26; /* deep red - main brand color */
    --primary-700: #b0191f; /* darker red variant */
    --primary-900: #7b0f14; /* darkest red variant */
    --text: #eaeaea; /* main text color */
    --muted: #b3b3b3; /* secondary/muted text color */
    --light-bg: #0f0f0f; /* dark section background */
    --surface: #151515; /* cards/nav surface color */
    --border: #262626; /* border color for cards and elements */
    --white: #ffffff; /* pure white for contrast */
  }
  
  /* Global reset and base styles */
  * {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
  }
  html, body { height: 100%; }
  
  /* Base body styling with dark theme */
  body {
    font-family: "Inter", "Segoe UI", Tahoma, sans-serif;
    color: var(--text);
    line-height: 1.6;
    background: #000000;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
  }

  /* Section typography styling */
  section {
    color: var(--text);
  }
  section p {
    color: var(--muted);
  }
  section h2, section h3 {
    color: #ffffff;
  }

  /* Navigation bar styling */
  .site-nav {
    background: transparent;
    border-bottom: 1px solid rgba(255,255,255,0.18);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 0;
  }
  .site-nav .brand {
    color: var(--white);
    text-decoration: none;
    font-weight: 700;
    letter-spacing: 0.2px;
  }
  .site-nav .logo-link {
    display: inline-flex;
    align-items: center;
    justify-content: flex-start;
    transition: opacity 200ms ease, transform 200ms ease;
  }
  .site-nav .logo-link:hover {
    opacity: 0.9;
    transform: scale(1.02);
  }
  .site-nav .logo-img {
    display: block;
    height: auto;
    width: 120px;
    max-width: 100%;
    margin: 0;
    padding: 0;
    object-fit: contain;
    filter: brightness(1) contrast(1.1);
    transition: filter 200ms ease;
  }
  .site-nav .logo-link:hover .logo-img {
    filter: brightness(1.05) contrast(1.15);
  }
  .site-nav ul {
    list-style: none;
    display: flex;
    gap: 1.25rem;
  }
  .site-nav a {
    color: rgba(255,255,255,0.92);
    text-decoration: none;
  }
  .site-nav a:hover {
    color: #fff;
  }
  /* Highlight current page link */
  .site-nav a.active {
    color: var(--primary);
    position: relative;
    font-weight: 700;
  }
  .site-nav a.active::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -8px;
    height: 2px;
    background: var(--primary);
    border-radius: 2px;
  }
  
  /* Container layout - responsive width with max-width */
  .container {
    width: 90%;
    max-width: 1100px;
    margin: auto;
    text-align: center;
  }
  
  /* Hero section styling */
  .hero {
    background: #000000;
    color: var(--white);
    padding: 4rem 0;
    min-height: 60vh;
  }
  /* Compact hero variant for inner pages */
  .hero.hero--compact {
    padding: 1.25rem 0 1.25rem 0;
    min-height: auto;
  }

  .hero .site-nav {
    padding-top: 1rem;
    padding-bottom: 1rem;
  }

  .hero-body {
    padding-top: 4rem;
    background: transparent;
    color: white;
    text-align: left;
  }

  .hero-body .container {
    text-align: left;
  }
  

  .hero h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
  }
  
  .hero p {
    font-size: 1.2rem;
    margin-bottom: 1.5rem;
  }

  .hero-body p {
    font-size: 1.2rem;
    margin-bottom: 1.5rem;
  }

  .hero-body .tagline {
    font-size: 3rem;
    font-weight: 700;
    letter-spacing: 0.2px;
    line-height: 1.35;
    margin-bottom: 0.75rem;
    max-width: 800px;
    margin-left: 0;
    margin-right: 0;
    text-align: left;
  }

  .hero-body .tagline-desc {
    font-size: 1.05rem;
    color: rgba(255, 255, 255, 0.92);
    line-height: 1.6;
    margin-bottom: 1.75rem;
    max-width: 860px;
    margin-left: 0;
    margin-right: 0;
    text-align: left;
  }

  .hero-body .cta-button {
    display: inline-block;
    margin-top: 0.25rem;
  }
  
  .cta-button {
    background: var(--white);
    color: var(--primary-900);
    padding: 0.75rem 1.5rem;
    border-radius: 4px;
    text-decoration: none;
    font-weight: bold;
    border: 1px solid rgba(0,0,0,0.05);
  }
  .cta-button:hover { background: #f8f8f8; }
  /* Emphasize hero CTA with the same red as numbered badges */
  .hero .cta-button {
    background: linear-gradient(180deg, var(--primary), var(--primary-700));
    color: #ffffff;
    border: 1px solid rgba(214,31,38,0.45);
    box-shadow: 0 4px 14px rgba(214,31,38,0.25);
  }
  .hero .cta-button:hover {
    background: linear-gradient(180deg, var(--primary-700), var(--primary-900));
  }
  
  /* Main content sections - consistent padding and background */
  .about, .services, .why-us, .contact {
    padding: 3rem 0;
    background: #000000;
  }
  /* Reduce top spacing when services directly follows a compact hero */
  .hero.hero--compact + .services {
    padding-top: 1.25rem;
  }
  /* Section separators */
  .about, .why-us { position: relative; }
  .about::before {
    content: "";
    position: absolute;
    left: 50%;
    top: 30px;
    height: 1px;
    background: rgba(255,255,255,0.18);
    transform: translateX(-50%);
    width: 90%;
    max-width: 1100px; /* match .container */
  }
  .why-us::before {
    content: "";
    position: absolute;
    left: 50%;
    top: 0;
    height: 1px;
    background: rgba(255,255,255,0.18);
    transform: translateX(-50%);
    width: 90%;
    max-width: 1100px; /* match .container */
  }
  .about-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.25rem;
    margin-top: 1.25rem;
    align-items: start;
    position: relative;
  }
  .about-left {
    text-align: left;
  }
  .about-badge {
    display: inline-block;
    background: transparent;
    color: var(--primary);
    border: none;
    border-radius: 0;
    padding: 0;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    box-shadow: none;
    font-size: 0.85rem;
  }
  .about-left .tagline {
    font-size: 3rem;
    font-weight: 700;
    letter-spacing: 0.2px;
    line-height: 1.35;
    margin-top: 0.75rem;
    color: #fff;
  }
  .about-right {
    text-align: left;
    position: relative; /* anchor dotted connector */
  }
  .about-right { counter-reset: about-step; }
  .about-point {
    position: relative;
    z-index: 2; /* keep cards above the connector line */
    color: #ddd;
    margin-bottom: 0.9rem;
    line-height: 1.7;
    background: transparent;
    border: none;
    border-radius: 0;
    padding: 0.9rem 1rem 0.9rem 3.25rem;
    box-shadow: none;
  }
  .about-point::before {
    counter-increment: about-step;
    content: counter(about-step);
    position: absolute;
    left: 0.9rem;
    top: 50%;
    transform: translateY(-50%);
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
    color: #fff;
    background: linear-gradient(180deg, var(--primary), var(--primary-700));
    box-shadow: 0 2px 8px rgba(0,0,0,0.25), 0 0 0 2px rgba(214,31,38,0.18);
    z-index: 3; /* badge above connector line */
  }
  /* Dotted connector aligning with badge centers */
  .about-right::before {
    content: "";
    position: absolute;
    top: calc(0.9rem + 14px); /* from first card top to badge center */
    bottom: calc(0.9rem + 14px + 0.9rem); /* to last card badge center incl. its bottom margin */
    left: calc(0.9rem + 32px); /* nudge right to true badge center */
    width: 2px;
    background: repeating-linear-gradient(
      to bottom,
      rgba(255,255,255,0.9) 0 8px,  /* longer dash */
      rgba(255,255,255,0) 8px 18px  /* longer gap */
    );
    z-index: 1; /* under cards and badges, but visible in left gutter */
  }
  @media (min-width: 900px) {
    .about-grid {
      grid-template-columns: 1fr 1.4fr;
      gap: 2rem;
    }
    .about-grid::after {
      content: "";
      position: absolute;
      top: 0;
      bottom: 0;
      width: 2px;
      background: linear-gradient(180deg, rgba(255,255,255,0.08), rgba(255,255,255,0.02));
      border-radius: 1px;
      z-index: 0; /* keep behind dotted connector and content */
      left: calc(41.6667% + 1rem); /* center within the 2rem gap */
    }
    .about-right {
      padding-left: 1.25rem; /* space between divider and content */
    }
  }
  .why-us {
    background: #000000;
  }
  .about .about-points {
    list-style: none;
    margin-top: 1rem;
    text-align: left;
    max-width: 860px;
    margin-left: auto;
    margin-right: auto;
  }
  .about .about-points li {
    position: relative;
    color: var(--muted);
    padding-left: 1.75rem;
    margin-bottom: 0.75rem;
    line-height: 1.6;
  }
  .about .about-points li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.6rem;
    width: 8px;
    height: 8px;
    background: var(--primary);
    border-radius: 2px;
    box-shadow: 0 0 0 2px rgba(214,31,38,0.2);
  }
  
  /* Service grid layout */
  .service-grid {
    display: grid;
    gap: 1rem;
    margin-top: 2rem;
  }
  
  /* Service card styling */
  .service-card {
    background: transparent;
    padding-top: 1.5rem;
    padding-bottom: 1.5rem;
    border-radius: 0;
    border: none;
    color: #ddd;
    text-align: left;
  }
  .service-card h3 { color: #fff; }

  /* Services header styles */
  .services .section-badge {
    display: inline-block;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-weight: 700;
    font-size: 0.85rem;
    margin-bottom: 0.5rem;
  }
  .services .section-caption {
    font-size: 1.9rem;
    letter-spacing: 0.2px;
    margin-bottom: 0.5rem;
    color: #fff;
  }
  .services .section-desc {
    font-size: 1rem;
    color: var(--muted);
    margin: 0 auto 1.5rem auto;
    max-width: 860px;
  }

  /* Responsive grid layout - 2 columns on medium screens, 4 on large screens */
  @media (min-width: 768px) {
    .service-grid {
      grid-template-columns: repeat(2, 1fr);
      gap: 1.25rem;
    }
  }
  @media (min-width: 1100px) {
    .service-grid {
      grid-template-columns: repeat(4, 1fr);
      gap: 1.25rem;
      position: relative;
    }
    /* horizontal divider between row 1 (left 4 cards) and row 2 (right 4 cards) */
    .service-grid::after {
      content: "";
      position: absolute;
      left: 0;
      right: 0;
      top: calc(50% - 0.5px);
      height: 1px;
      background: linear-gradient(90deg, rgba(255,255,255,0.08), rgba(255,255,255,0.02));
    }
  }

  /* Team page: center and offset grid within team section */
  .services.team .service-grid {
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
    margin-top: 1rem;
    /* use default gaps; no horizontal offset */
  }
  @media (min-width: 768px) {
    .services.team .service-grid {
      grid-template-columns: repeat(2, 1fr);
      /* use default gaps; no horizontal offset */
    }
  }
  @media (min-width: 1100px) {
    .services.team .service-grid::after { display: none; }
  }

  /* Card title with icon */
  .service-card .card-title {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.6rem;
    margin-bottom: 0.5rem;
  }
  .service-card .box-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    color: var(--primary);
    flex: 0 0 40px;
  }
  .service-card .box-icon svg { display: block; }
  .service-card .box-icon i { font-size: 1.1rem; line-height: 1; }
  .service-card h3 {
    font-size: 1.15rem;
    line-height: 1.35;
  }
  .service-card p {
    font-size: 0.95rem;
    line-height: 1.55;
    color: var(--muted);
  }

  /* Contact page */
  .contact { text-align: center; }
  .contact .contact-grid {
    /* display: grid; */
    grid-template-columns: 1fr;
    gap: 1.25rem;
    margin-top: 1.25rem;
    max-width: 600px;
    margin: auto;
  }
  @media (max-width: 900px) {
    .contact .contact-grid {
      grid-template-columns: 1.1fr 1fr;
      gap: 2rem;
    }
  }
  .contact  h2 { color: #fff; margin-bottom: 0.5rem; }
  .contact  p { color: var(--muted); }
  .contact .contact-list {
    list-style: none;
    margin-top: 1rem;
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
    text-align: left;
  }
  .contact .contact-list li {
    display: grid;
    grid-template-columns: 36px 1fr;
    gap: 0.75rem;
    align-items: start;
    padding: 0.75rem 0;
    border-top: 1px solid var(--border);
  }
  .contact .contact-list li:first-child { border-top: none; }
  .contact .contact-list .item-title { color: #fff; font-weight: 700; margin-bottom: 0.15rem; }
  .contact .contact-list a { color: rgba(255,255,255,0.92); text-decoration: none; }
  .contact .contact-list a:hover { color: #fff; text-decoration: underline; }
  .contact .contact-list .box-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: linear-gradient(180deg, var(--surface), #101010);
    border: 1px solid var(--border);
    color: var(--primary);
    box-shadow: 0 2px 8px rgba(0,0,0,0.25), inset 0 0 0 2px rgba(214,31,38,0.12);
  }
  .contact .contact-form-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1rem;
    box-shadow: 0 2px 12px rgba(0,0,0,0.25);
  }
  @media (min-width: 900px) { .contact .contact-form-card { padding: 1.25rem; } }
  .contact .contact-card{
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.25);
    max-width: 600px;
    text-align: left;
  }
  @media (min-width: 900px) { .contact .contact-card { padding: 1.25rem; } }
  .contact .card-title-heading {
    color: #fff;
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
  }
  .contact .contact-form .form-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
    padding-top: 1rem;
  }
  @media (min-width: 768px) {
    .contact .contact-form .form-row { grid-template-columns: 1fr 1fr; gap: 0.9rem; }
  }
  .contact .contact-form .form-field { display: flex; flex-direction: column; }
  .contact .contact-form label { font-weight: 600; color: #fff; margin-bottom: 0.35rem; }
  .contact .contact-form input,
  .contact .contact-form textarea {
    background: #0b0b0b;
    border: 1px solid var(--border);
    border-radius: 8px;
    color: #fff;
    padding: 0.65rem 0.75rem;
    outline: none;
  }
  .contact .contact-form textarea { resize: vertical; }
  .contact .contact-form input:focus,
  .contact .contact-form textarea:focus {
    border-color: rgba(214,31,38,0.55);
    box-shadow: 0 0 0 3px rgba(214,31,38,0.18);
  }
  .contact .contact-form .cta-button { margin-top: 0.75rem; }

  @media (min-width: 900px) {
    .service-card .box-icon { width: 44px; height: 44px; flex-basis: 44px; }
    .service-card .box-icon i { font-size: 1.25rem; }
    .service-card h3 { font-size: 1.25rem; }
    .service-card p { font-size: 0.93rem; }
  }
  
  .why-us .container {
    text-align: center;
  }
  .why-us h2 {
    font-size: 1.9rem;
    letter-spacing: 0.2px;
    margin-bottom: 1.25rem;
  }
  .why-us .section-tagline {
    font-size: 1.25rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 0.25rem;
  }
  .why-us .section-desc {
    font-size: 0.98rem;
    color: var(--muted);
    margin-bottom: 1.25rem;
  }
  .why-us ul {
    list-style: none;
    margin-top: 1.5rem;
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  .why-us li {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 1.25rem 1rem;
    text-align: left;
    color: #ddd;
    position: relative;
    transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
    box-shadow: 0 2px 12px rgba(0,0,0,0.25);
    min-height: 96px;
  }
  .why-us .item-title {
    font-weight: 700;
    color: #fff;
    margin-bottom: 0.25rem;
    font-size: 1.05rem;
    line-height: 1.35;
  }
  .why-us .item-title {
    display: flex;
    align-items: center;
    gap: 0.5rem;
  }
  .why-us .item-title .box-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 6px;
    background: linear-gradient(180deg, var(--surface), #101010);
    border: 1px solid var(--border);
    color: var(--primary);
    box-shadow: 0 2px 8px rgba(0,0,0,0.25), inset 0 0 0 2px rgba(214,31,38,0.12);
    flex: 0 0 28px;
  }
  .why-us .item-title .box-icon svg {
    display: block;
  }
  .why-us .item-desc {
    color: var(--muted);
    font-size: 0.95rem;
    line-height: 1.5;
  }
  .why-us li::after {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--primary-700));
    border-top-left-radius: 10px;
    border-top-right-radius: 10px;
    opacity: 0.5;
  }
  .why-us li:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.35);
    border-color: rgba(214,31,38,0.5);
  }
  .why-us li strong, .why-us li b {
    color: #fff;
  }

  @media (min-width: 768px) {
    .why-us ul {
      grid-template-columns: repeat(2, 1fr);
    }
  }
  
  /* Footer styling with sticky positioning */
  footer {
    background: #000000;
    color: rgba(255,255,255,0.9);
    padding: 1rem 0;
    font-size: 0.9rem;
    margin-top: auto; /* push footer to bottom */
  }
  footer p { margin: 0; }
  
  /* Team cards */
  .service-card .team-photo {
    display: block;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 0.75rem;
    border: 1px solid var(--border);
    box-shadow: 0 2px 10px rgba(0,0,0,0.35);
  }
  .service-card .short-bio {
    margin-top: 0.4rem;
    color: var(--muted);
  }

  /* Team page */
  .team { padding: 2.25rem 0 3rem 0; background: #000000;}
  .team .container { text-align: center; }
  .team .team-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-top: 1.25rem;
    justify-items: center;
  }
  @media (min-width: 768px) {
    .team .team-grid { grid-template-columns: repeat(2, 1fr); gap: 1.75rem; }
  }
  @media (min-width: 1100px) {
    .team .team-grid { gap: 2rem; }
  }
  .team-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 1.25rem 1rem 1.25rem 1rem;
    box-shadow: 0 2px 12px rgba(0,0,0,0.25);
    max-width: 520px;
    width: 100%;
    text-align: center;
  }
  .team-card .team-photo {
    display: block;
    width: 140px;
    height: 140px;
    border-radius: 50%;
    object-fit: cover;
    margin: 0 auto 0.75rem auto;
    border: 1px solid var(--border);
    box-shadow: 0 2px 10px rgba(0,0,0,0.35);
  }
  .team-card .team-name { color: #fff; font-size: 1.25rem; margin-top: 0.25rem; }
  .team-card .team-role { color: var(--primary); font-weight: 700; margin: 0.15rem 0 0.5rem 0; }
  .team-card .short-bio { color: var(--muted); }
  .team-section-badge {
    display: inline-block;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-weight: 700;
    font-size: 0.85rem;
    margin-bottom: 0.5rem;
  }
  .team-section-caption {
    font-size: 1.9rem;
    letter-spacing: 0.2px;
    margin-bottom: 0.5rem;
    color: #fff;
  }
  .team-section-desc {
    font-size: 1rem;
    color: var(--muted);
    margin: 0 auto 1.5rem auto;
    max-width: 860px;
  }
  .contact-section-badge {
    display: inline-block;
    color: var(--primary);
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-weight: 700;
    font-size: 0.85rem;
    margin-bottom: 0.5rem;
  }
  .contact-section-caption {
    font-size: 1.9rem;
    letter-spacing: 0.2px; 
    margin-bottom: 0.5rem;
    color: #fff;
  }
  .contact-section-desc {
    font-size: 1rem;
    color: var(--muted);
    margin: 0 auto 1.5rem auto;
    max-width: 860px;
  }
  .contact-cta-button {
    display: inline-block;
    margin-top: 0.25rem;
  }
  
  .contact-cta-button {
    background: var(--white);
    color: var(--primary-900);
    padding: 0.75rem 1.5rem;
    border-radius: 4px;
    text-decoration: none;
    font-weight: bold;
    border: 1px solid rgba(0,0,0,0.05);
  }
  .contact-cta-button:hover { background: #f8f8f8; }
  /* Emphasize hero CTA with the same red as numbered badges */
  .contact-cta-button {
    background: linear-gradient(180deg, var(--primary), var(--primary-700));
    color: #ffffff;
    border: 1px solid rgba(214,31,38,0.45);
    box-shadow: 0 4px 14px rgba(214,31,38,0.25);
  }
  .contact-cta-button:hover {
    background: linear-gradient(180deg, var(--primary-700), var(--primary-900));
  }
  .ai { color: red; }
