/* =========================================================
   Multi-page additions: inner-page hero, nav dropdown,
   service/hub pages, FAQ, CTA band, contact form extras.
   Loaded last, after style.css / extras.css / hero-dark.css.
   ========================================================= */

/* Intro animation plays once per session (see main.js). */
.no-intro #preloader { display: none !important; }

.text-link {
  color: var(--color-accent);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ---------- Inner-page hero (keeps id="hero" for header logic) ---------- */
#hero.page-hero {
  min-height: 0;
  align-items: flex-end;
}

#hero.page-hero .hero-bg {
  background:
    radial-gradient(ellipse 70% 90% at 80% 0%, rgba(61, 143, 151, 0.35) 0%, transparent 60%),
    linear-gradient(160deg, #0B1226 0%, #080C18 100%);
}

#hero.page-hero .hero-content {
  padding: 150px 0 72px;
  max-width: 860px;
}

#hero.page-hero .hero-title {
  font-size: clamp(34px, 4.8vw, 62px);
  margin-bottom: 22px;
}

#hero.page-hero .hero-description {
  margin-bottom: 0;
  max-width: 640px;
}

#hero.page-hero .hero-actions { margin-top: 36px; }
#hero.page-hero .hero-badge { margin-bottom: 22px; }

/* Inner pages animate in without the inline hidden state used on the home hero */
.js .page-hero .hero-animate {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 22px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.55);
}

.breadcrumbs a {
  color: rgba(255, 255, 255, 0.75);
  transition: color 0.2s ease;
}

.breadcrumbs a:hover { color: #8FE3E1; }
.breadcrumbs [aria-current] { color: rgba(255, 255, 255, 0.55); }

/* ---------- Header dropdown (Services) ---------- */
.nav-item {
  position: relative;
  display: flex;
  align-items: center;
}

.nav-caret {
  font-size: 9px;
  margin-left: 4px;
  opacity: 0.7;
  transition: transform 0.25s ease;
}

.has-dropdown:hover .nav-caret,
.has-dropdown:focus-within .nav-caret { transform: rotate(180deg); }

/* invisible bridge so the menu doesn't close when moving the mouse down */
.has-dropdown::after {
  content: '';
  position: absolute;
  left: -12px;
  right: -12px;
  top: 100%;
  height: 22px;
}

.nav-dropdown {
  position: absolute;
  top: calc(100% + 18px);
  left: 50%;
  min-width: 290px;
  padding: 8px;
  background: #0C1224;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.4);
  opacity: 0;
  visibility: hidden;
  transform: translate(-50%, 8px);
  transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
  z-index: 10;
}

.has-dropdown:hover .nav-dropdown,
.has-dropdown:focus-within .nav-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
}

#header .header-nav .nav-dropdown a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 14px;
  border-radius: 10px;
  font-size: 13.5px;
  color: rgba(255, 255, 255, 0.88);
  transition: background 0.2s ease, color 0.2s ease;
}

#header .header-nav .nav-dropdown a::after { display: none; }

#header .header-nav .nav-dropdown a i {
  width: 18px;
  text-align: center;
  color: #69C8C7;
}

#header .header-nav .nav-dropdown a:hover {
  background: rgba(105, 200, 199, 0.12);
  color: #fff;
}

#header .header-nav .nav-dropdown .nav-dropdown-all {
  margin-top: 6px;
  padding-top: 13px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0 0 10px 10px;
  color: #8FE3E1;
  font-weight: 600;
}

/* ---------- Mobile menu sub-links ---------- */
.menu-overlay-nav a.menu-sub-link {
  font-size: 17px;
  font-weight: 500;
  padding: 9px 0 9px 20px;
  color: var(--color-text-muted);
}

/* ---------- Service cards ---------- */
.service-icon i {
  font-size: 20px;
  color: var(--color-accent);
}

.services-grid-2 { grid-template-columns: repeat(2, 1fr); }

.service-card-link {
  display: flex;
  flex-direction: column;
}

.service-card-link .service-tags { margin-bottom: 22px; }

.service-more {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
  color: var(--color-accent);
}

.service-more i { transition: transform 0.25s ease; }
.service-card-link:hover .service-more i { transform: translateX(5px); }

/* ---------- Services hub ---------- */
.hub-list {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.hub-card {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 32px;
  padding: 40px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  transition: var(--transition);
}

.hub-card:hover {
  border-color: rgba(21, 143, 141, 0.35);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.08);
}

.hub-card-head {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 18px;
}

.hub-card-head .service-number { position: static; }

.hub-icon {
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  border-radius: 16px;
  font-size: 24px;
  color: #fff;
  background: linear-gradient(135deg, var(--color-accent), var(--color-accent-2));
}

.hub-title {
  font-family: var(--font-heading);
  font-size: clamp(24px, 2.6vw, 32px);
  letter-spacing: -0.02em;
  color: var(--color-text-primary);
  margin-bottom: 12px;
}

.hub-desc {
  max-width: 680px;
  color: var(--color-text-secondary);
  line-height: 1.75;
  margin-bottom: 22px;
}

.hub-offerings {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 28px;
  margin-bottom: 28px;
  list-style: none;
  padding: 0;
}

.hub-offerings li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 15px;
  color: var(--color-text-primary);
}

.hub-offerings i {
  font-size: 12px;
  color: var(--color-accent);
}

/* ---------- Deliverables checklist ---------- */
.split-block {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 64px;
  align-items: center;
}

.check-list {
  display: grid;
  gap: 14px;
  list-style: none;
  padding: 0;
}

.check-list li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 18px 20px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  color: var(--color-text-primary);
  line-height: 1.5;
}

.check-list i {
  flex: none;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  margin-top: 1px;
  border-radius: 50%;
  font-size: 11px;
  color: #fff;
  background: linear-gradient(135deg, var(--color-accent), var(--color-accent-2));
}

/* ---------- FAQ ---------- */
.faq-layout {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 64px;
  align-items: start;
}

.faq-list {
  display: grid;
  gap: 12px;
}

.faq-item {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  transition: border-color 0.25s ease;
}

.faq-item[open] { border-color: rgba(21, 143, 141, 0.4); }

.faq-item summary {
  position: relative;
  padding: 20px 56px 20px 22px;
  font-family: var(--font-heading);
  font-size: 17px;
  font-weight: 600;
  color: var(--color-text-primary);
  cursor: pointer;
  list-style: none;
}

.faq-item summary::-webkit-details-marker { display: none; }

.faq-item summary::after {
  content: '+';
  position: absolute;
  right: 22px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 24px;
  font-weight: 400;
  color: var(--color-accent);
  transition: transform 0.25s ease;
}

.faq-item[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq-item summary:focus-visible { outline: 2px solid var(--color-accent); outline-offset: 2px; border-radius: var(--radius-md); }

.faq-item p {
  padding: 0 22px 22px;
  color: var(--color-text-secondary);
  line-height: 1.75;
}

/* ---------- Related services ---------- */
.related-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-top: 32px;
}

.related-card {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 26px 28px;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  transition: var(--transition);
}

.related-card:hover {
  border-color: rgba(21, 143, 141, 0.4);
  transform: translateY(-3px);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.08);
}

.related-icon {
  flex: none;
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 14px;
  color: var(--color-accent);
  background: var(--color-accent-light);
  border: 1px solid rgba(21, 143, 141, 0.18);
}

.related-body { flex: 1; }

.related-body strong {
  display: block;
  font-family: var(--font-heading);
  font-size: 18px;
  color: var(--color-text-primary);
  margin-bottom: 4px;
}

.related-body span {
  font-size: 14px;
  line-height: 1.6;
  color: var(--color-text-secondary);
}

.related-arrow {
  color: var(--color-accent);
  transition: transform 0.25s ease;
}

.related-card:hover .related-arrow { transform: translateX(5px); }

/* ---------- About: beliefs ---------- */
.beliefs-section { background: var(--color-surface); }

.beliefs-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-top: 48px;
}

.belief-card {
  padding: 28px;
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
}

.belief-icon {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  margin-bottom: 18px;
  border-radius: 12px;
  color: var(--color-accent);
  background: var(--color-accent-light);
}

.belief-card h3 {
  font-family: var(--font-heading);
  font-size: 19px;
  color: var(--color-text-primary);
  margin-bottom: 10px;
}

.belief-card p {
  font-size: 14.5px;
  line-height: 1.7;
  color: var(--color-text-secondary);
}

/* ---------- Closing CTA band (dark in both themes) ---------- */
.cta-band { padding: 0 0 96px; }

.cta-band-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  padding: 56px 60px;
  border-radius: 28px;
  background:
    radial-gradient(ellipse 60% 120% at 100% 0%, rgba(105, 200, 199, 0.28) 0%, transparent 60%),
    linear-gradient(135deg, #0B1226 0%, #101A33 100%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 24px 64px rgba(8, 12, 24, 0.25);
}

.cta-band-title {
  font-family: var(--font-heading);
  font-size: clamp(26px, 3.2vw, 40px);
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: #fff;
  margin-bottom: 12px;
}

.cta-band-text {
  max-width: 560px;
  color: rgba(255, 255, 255, 0.72);
  line-height: 1.7;
}

.cta-band .btn-primary { flex: none; padding: 16px 34px; font-size: 15px; }

/* ---------- Contact form extras ---------- */
.contact-info-value a { color: inherit; }
.contact-info-value a:hover { color: var(--color-accent); }

.form-optional {
  font-weight: 400;
  color: var(--color-text-muted);
}

/* Honeypot: off-screen, not display:none (bots skip display:none fields less often) */
.form-hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.field-error {
  display: block;
  min-height: 0;
  margin-top: 6px;
  font-size: 13px;
  color: #C0392B;
}

.field-error:empty { display: none; }

.form-error {
  display: none;
  padding: 16px 20px;
  margin-top: 16px;
  border-radius: 12px;
  font-size: 14.5px;
  font-weight: 500;
  color: #A93226;
  background: rgba(192, 57, 43, 0.07);
  border: 1px solid rgba(192, 57, 43, 0.25);
}

.form-error.show { display: block; }

.form-success.show { margin: 0 0 20px; }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .beliefs-grid { grid-template-columns: repeat(2, 1fr); }
  .split-block,
  .faq-layout { grid-template-columns: 1fr; gap: 36px; }
  .hub-card { grid-template-columns: 1fr; gap: 20px; padding: 32px; }
  .hub-card-head { flex-direction: row; align-items: center; }
  .cta-band-inner { flex-direction: column; align-items: flex-start; padding: 44px 36px; }
}

@media (max-width: 768px) {
  #hero.page-hero .hero-content { padding: 120px 0 56px; }
  .services-grid-2,
  .related-grid,
  .beliefs-grid,
  .hub-offerings { grid-template-columns: 1fr; }
  .hub-card { padding: 26px 22px; }
  .cta-band { padding-bottom: 64px; }
  .cta-band-inner { padding: 36px 24px; border-radius: 22px; }
}

@media (prefers-reduced-motion: reduce) {
  .js .page-hero .hero-animate { transition: none; }
  .nav-dropdown { transition: none; }
}

.split-block .section-subtitle,
.faq-layout .section-subtitle { margin-top: 18px; }

/* ---------- Skip link ---------- */
.skip-link {
  position: fixed;
  left: 16px;
  top: -64px;
  z-index: 3000;
  padding: 12px 20px;
  border-radius: 999px;
  font-weight: 600;
  color: #fff;
  background: var(--color-accent-2);
  transition: top 0.2s ease;
}

.skip-link:focus { top: 16px; }

/* =========================================================
   Mobile / touch refinements
   ========================================================= */

/* Touch screens have no hover, so portfolio captions and the link button must
   be visible without it. */
@media (hover: none) {
  .portfolio-overlay { opacity: 1; background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.15) 55%, transparent 100%); }
  .portfolio-link { opacity: 1; transform: scale(1); width: 44px; height: 44px; }
  .portfolio-name { color: #fff; }
}

@media (max-width: 768px) {
  /* Header: the quote CTA lives in the hero, menu and footer, so on phones keep
     the bar to logo + menu button (the button was wrapping onto two lines). */
  .header-cta .btn-outline { display: none; }

  /* Hamburger was white-on-white over the dark hero. */
  #header.over-hero .hamburger-btn {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.4);
  }
  #header.over-hero .hamburger-btn span { background: #fff; }
  .hamburger-btn { width: 44px; height: 44px; }

  /* Home hero: clear the fixed header, and drop the scroll cue that collided
     with the stats. */
  #hero:not(.page-hero) .hero-content { padding-top: 124px; padding-bottom: 56px; }
  .hero-scroll-indicator { display: none; }
  .hero-badge { font-size: 11.5px; letter-spacing: 0.06em; }

  /* Comfortable tap targets */
  .footer-links { gap: 0; }
  .footer-links a { display: inline-block; padding: 11px 0; }
  .footer-bottom-links { gap: 20px; flex-wrap: wrap; }
  .footer-bottom-links a { display: inline-block; padding: 10px 0; }
  .menu-overlay-social a { display: inline-block; padding: 12px 0; }
  .breadcrumbs a { display: inline-block; padding: 6px 0; }
  .menu-overlay-nav a.menu-sub-link { padding-top: 12px; padding-bottom: 12px; }
  .faq-item summary { min-height: 56px; display: flex; align-items: center; }

  /* 16px inputs stop iOS Safari zooming the page when a field is focused. */
  .form-input,
  .form-select,
  .form-textarea { font-size: 16px; padding: 14px 16px; }
  .form-submit { flex-direction: column; align-items: stretch; }
  .form-submit .btn-primary { justify-content: center; padding: 15px 28px; }

  .hero-btn-secondary { padding: 14px 4px; }
}

@media (max-width: 560px) {
  /* Four narrow columns of centred text read poorly; stack the steps. */
  .process-steps { grid-template-columns: 1fr; gap: 28px; }
  .process-steps::before { display: none; }
  .hero-stats { margin-top: 48px; padding-top: 28px; }
}

/* Legibility of captions that sit on photos (touch screens always show them) */
@media (hover: none) {
  .portfolio-overlay { background: linear-gradient(to top, rgba(0,0,0,0.92) 0%, rgba(0,0,0,0.62) 45%, transparent 88%); }
  .portfolio-category { color: #8FE3E1; }
  .team-card-overlay { background: linear-gradient(to top, rgba(0,0,0,0.88) 0%, rgba(0,0,0,0.5) 60%, transparent 100%); }
  .team-role { color: #8FE3E1; }
}

@media (max-width: 768px) {
  .contact-info-value a { display: inline-block; padding: 8px 0; }
}

/* Tablets and narrow laptops: logo + five links + CTA don't fit comfortably
   below ~900px, so use the menu button there too. */
@media (max-width: 900px) {
  .header-nav { display: none; }
  .hamburger-btn { display: flex; width: 44px; height: 44px; }
  .header-cta .btn-outline { display: none; }
  #header.over-hero .hamburger-btn {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.4);
  }
}

/* Mobile menu panel: sit above the fixed header (it was showing through),
   scroll on short screens, and let the social links wrap instead of overflowing. */
#menu-overlay {
  z-index: 1100;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.menu-overlay-social { flex-wrap: wrap; gap: 4px 22px; }

/* The "scroll" cue crowds the stats row on shorter laptop screens. */
@media (max-height: 960px) {
  .hero-scroll-indicator { display: none; }
}
