/* ============================================================
   MAHESH LANAROL — PORTFOLIO WEBSITE
   Complete Stylesheet v2 — fixes invisible-text bug
   and pushes visual quality closer to zannavanderaa.com
   ============================================================ */

/* ── Google Fonts ────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=DM+Serif+Display:ital@0;1&family=Inter:wght@300;400;500;600;700;800&display=swap');

/* ── CSS Variables ───────────────────────────────────────── */
:root {
  --primary-navy:    #1B3A5C;
  --secondary-navy:  #2D5986;
  --gold-accent:     #C9A452;
  --gold-light:      #e8c97a;
  --light-bg:        #F4F6F9;
  --muted-gray:      #E4E8F0;
  --dark-text:       #1C1C1C;
  --medium-gray:     #4A5568;
  --white:           #FFFFFF;

  --font-display:    'DM Serif Display', Georgia, serif;
  --font-body:       'Inter', -apple-system, sans-serif;

  --section-pad:     8rem 0;
  --container-max:   1280px;
  --container-pad:   0 2.5rem;
}

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

html { scroll-behavior: smooth; font-size: 16px; }

body {
  font-family: var(--font-body);
  color: var(--dark-text);
  background: var(--white);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }

/* ── Typography ──────────────────────────────────────────── */
h1 {
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 6.5vw, 5.2rem);
  line-height: 1.08;
  color: var(--primary-navy);
  font-weight: 400;
  letter-spacing: -0.02em;
}

h2 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4.2vw, 3.2rem);
  line-height: 1.15;
  color: var(--primary-navy);
  font-weight: 400;
  letter-spacing: -0.01em;
  margin-bottom: 1.75rem;
}

h3 {
  font-family: var(--font-body);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--primary-navy);
  margin-bottom: 0.85rem;
  line-height: 1.35;
}

h4 {
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--primary-navy);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.5rem;
}

p {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--medium-gray);
  margin-bottom: 1.25rem;
}

p:last-child { margin-bottom: 0; }

/* ── Layout Containers ───────────────────────────────────── */
.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: var(--container-pad);
}

.section { padding: var(--section-pad); }
.section-light { background: var(--light-bg); }
.section-navy { background: var(--primary-navy); }
.section-navy h2 { color: var(--white); }
.section-navy p  { color: rgba(255,255,255,0.7); }
.text-center { text-align: center; }

/* ── Label / Eyebrow Text ────────────────────────────────── */
.label {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--gold-accent);
  margin-bottom: 1.5rem;
}

/* ── Navbar ──────────────────────────────────────────────── */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  padding: 1.5rem 0;
  background: linear-gradient(to bottom, rgba(15,30,48,0.55) 0%, rgba(15,30,48,0) 100%);
  transition: background 0.4s ease, padding 0.4s ease, box-shadow 0.4s ease;
}

/* Always-on scrim ensures the white logo/nav text never sits
   directly on a light background (e.g. About page's white
   hero) with no contrast — this is on at all scroll positions,
   not just before .scrolled is applied. */

.navbar.scrolled {
  background: var(--primary-navy);
  padding: 1rem 0;
  box-shadow: 0 2px 30px rgba(0,0,0,0.25);
}

.navbar .container { display: flex; align-items: center; justify-content: space-between; }

.logo-container { display: flex; flex-direction: column; gap: 0.15rem; text-decoration: none; }

.logo-text {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 400;
  color: var(--white);
  letter-spacing: 0.01em;
  line-height: 1;
}

.logo-creds {
  font-size: 0.62rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--gold-accent);
  line-height: 1;
}

.nav-links { display: flex; gap: 2.75rem; align-items: center; }

.nav-links a {
  font-size: 0.82rem;
  font-weight: 500;
  color: rgba(255,255,255,0.85);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  position: relative;
  transition: color 0.2s;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -4px; left: 0;
  width: 0; height: 1px;
  background: var(--gold-accent);
  transition: width 0.3s ease;
}

.nav-links a:hover { color: var(--white); }
.nav-links a:hover::after { width: 100%; }

.hamburger { display: none; color: var(--white); font-size: 1.7rem; cursor: pointer; line-height: 1; }

/* ── Mobile Menu ─────────────────────────────────────────── */
.mobile-menu {
  position: fixed; inset: 0; background: var(--primary-navy); z-index: 2000;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 2.5rem; opacity: 0; pointer-events: none; transition: opacity 0.35s ease;
}

.mobile-menu.open { opacity: 1; pointer-events: all; }

.mobile-menu a { font-family: var(--font-display); font-size: 2.4rem; color: var(--white); transition: color 0.2s; }
.mobile-menu a:hover { color: var(--gold-accent); }

.mobile-menu-close {
  position: absolute; top: 2rem; right: 2rem; font-size: 2.5rem; color: var(--white);
  cursor: pointer; line-height: 1; opacity: 0.7; transition: opacity 0.2s;
}
.mobile-menu-close:hover { opacity: 1; }

/* ── Buttons ─────────────────────────────────────────────── */
.btn {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  padding: 1rem 2.4rem;
  border-radius: 2px;
  cursor: pointer;
  transition: all 0.25s ease;
  border: 1.5px solid transparent;
  text-decoration: none;
}

.btn-gold { background: var(--gold-accent); color: var(--primary-navy); border-color: var(--gold-accent); }
.btn-gold:hover { background: var(--gold-light); border-color: var(--gold-light); transform: translateY(-2px); box-shadow: 0 8px 25px rgba(201,164,82,0.35); }

.btn-outline-white { background: transparent; color: var(--white); border-color: rgba(255,255,255,0.55); }
.btn-outline-white:hover { background: rgba(255,255,255,0.1); border-color: var(--white); }

.btn-ghost { background: transparent; color: rgba(255,255,255,0.7); border-color: transparent; padding-left: 0.5rem; }
.btn-ghost:hover { color: var(--white); }

.btn-outline-navy { background: transparent; color: var(--primary-navy); border-color: var(--primary-navy); }
.btn-outline-navy:hover { background: var(--primary-navy); color: var(--white); }

.btn-submit { width: 100%; padding: 1.05rem; font-size: 0.85rem; }

/* ── Hero Section ────────────────────────────────────────── */
.hero {
  position: relative;
  background: var(--primary-navy);
  min-height: 100svh;
  display: flex;
  align-items: center;
  overflow: hidden;
}

/* Shorter hero variant for inner-page headers (Contact, etc.)
   — same visual treatment as the Home hero, but a fixed
   banner height instead of full viewport. */
.hero-short {
  min-height: auto;
}

.hero-short .container {
  padding-top: 8.5rem;
  padding-bottom: 4.5rem;
}

.hero-short .hero-img-container {
  height: 100%;
  width: 38%;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 72% 50%, rgba(45,89,134,0.45) 0%, transparent 65%),
    linear-gradient(135deg, rgba(27,58,92,0.92) 0%, rgba(15,30,48,0.97) 100%);
  z-index: 1;
}

.hero .container { position: relative; z-index: 2; padding-top: 9rem; padding-bottom: 6rem; width: 100%; }

.hero-grid { display: grid; grid-template-columns: 56% 44%; align-items: center; gap: 4rem; }

.hero-content h1 { color: var(--white); margin-bottom: 1.75rem; text-shadow: 0 2px 30px rgba(0,0,0,0.2); }

.hero-creds { display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; margin-bottom: 2rem; }
.hero-creds span { font-size: 0.74rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.12em; color: var(--gold-accent); }

.hero-content p { color: rgba(255,255,255,0.78); font-size: 1.1rem; max-width: 540px; margin-bottom: 2.75rem; }

.hero-btns { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; }

.hero-img-container {
  position: absolute; right: 0; bottom: 0; width: 44%; height: 96%; z-index: 2;
  display: flex; align-items: flex-end; justify-content: flex-end;
}

.hero-img-container img {
  height: 100%; width: 100%; object-fit: cover; object-position: top center;
  mask-image: linear-gradient(to right, transparent 0%, black 22%);
  -webkit-mask-image: linear-gradient(to right, transparent 0%, black 22%);
}

/* ── Split Layouts ───────────────────────────────────────── */
.split-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 5.5rem; align-items: center; }
.split-layout.reverse { direction: rtl; }
.split-layout.reverse > * { direction: ltr; }
.text-content h1, .text-content h2 { margin-bottom: 1.5rem; }
.img-content { position: relative; }
.img-fluid { width: 100%; height: auto; border-radius: 2px; }

.img-content::before {
  content: ''; position: absolute; top: 2rem; left: -1.5rem; width: 3px; height: 60%; background: var(--gold-accent);
}
.split-layout.reverse .img-content::before { left: auto; right: -1.5rem; }

/* ── Parallax Background Sections ────────────────────────── */
.bg-parallax { background-attachment: fixed; background-size: cover; background-position: center; position: relative; }
.bg-parallax::before { content: ''; position: absolute; inset: 0; background: rgba(27,58,92,0.82); z-index: 0; }
.bg-parallax > * { position: relative; z-index: 1; }

/* Force readable white text on any heading/paragraph/label
   sitting on a parallax (photo) background — these are
   always navy-toned overlays, so navy text disappears. */
.bg-parallax h1,
.bg-parallax h2,
.bg-parallax h3 { color: var(--white); }

.bg-parallax p { color: rgba(255,255,255,0.82); }

.bg-parallax .label { color: var(--gold-accent); }

/* ── Stats Grid ──────────────────────────────────────────── */
.stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 3.5rem 2rem; margin-top: 4rem; }
.stat-item { text-align: center; }
.stat-number { font-family: var(--font-display); font-size: clamp(2.2rem, 4.5vw, 3.4rem); color: var(--gold-accent); font-weight: 400; line-height: 1; margin-bottom: 0.7rem; }
.stat-label { font-size: 0.74rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.1em; color: rgba(255,255,255,0.55); }

/* ── Cards ───────────────────────────────────────────────── */
.card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 2.25rem; margin-top: 3.5rem; }

.card {
  background: var(--white);
  border-top: 3px solid var(--gold-accent);
  padding: 2.5rem;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 4px 24px rgba(27,58,92,0.08);
}
.card:hover { transform: translateY(-6px); box-shadow: 0 18px 50px rgba(27,58,92,0.15); }

.card .tags { font-size: 0.66rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.14em; color: var(--gold-accent); margin-bottom: 1.1rem; }
.card h3 { font-size: 1.15rem; margin-bottom: 0.9rem; }
.card p { font-size: 0.95rem; }

.card-link {
  display: inline-block; margin-top: 1.6rem; font-size: 0.78rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.1em; color: var(--primary-navy); border-bottom: 1px solid var(--gold-accent); padding-bottom: 2px;
  transition: color 0.2s;
}
.card-link:hover { color: var(--gold-accent); }

/* ── Service Cards ───────────────────────────────────────── */
.service-card { background: var(--white); border-top: 3px solid var(--gold-accent); padding: 2.6rem; box-shadow: 0 4px 24px rgba(27,58,92,0.08); transition: transform 0.3s ease, box-shadow 0.3s ease; }
.service-card:hover { transform: translateY(-6px); box-shadow: 0 18px 50px rgba(27,58,92,0.15); }
.service-card .label { margin-bottom: 0.5rem; }
.service-card h3 { font-size: 1.25rem; margin-bottom: 0.45rem; }
.service-card .subtitle { font-size: 0.9rem; font-style: italic; color: var(--medium-gray); margin-bottom: 1.3rem; line-height: 1.5; }
.service-card ul { list-style: none; margin: 0.85rem 0 1.6rem; padding: 0; }
.service-card ul li { font-size: 0.9rem; color: var(--medium-gray); padding: 0.4rem 0; padding-left: 1.25rem; position: relative; border-bottom: 1px solid var(--muted-gray); }
.service-card ul li:last-child { border-bottom: none; }
.service-card ul li::before { content: '—'; position: absolute; left: 0; color: var(--gold-accent); font-weight: 700; }
.service-meta { border-top: 1px solid var(--muted-gray); padding-top: 1.3rem; margin-top: 1rem; font-size: 0.84rem; color: var(--medium-gray); display: flex; flex-direction: column; gap: 0.55rem; }
.service-meta strong { color: var(--primary-navy); }

/* ── Tags / Filter Pills ─────────────────────────────────── */
.tags-grid { display: flex; flex-wrap: wrap; gap: 0.85rem; justify-content: center; margin-top: 2.75rem; }
.tag-pill { font-size: 0.78rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.1em; color: var(--secondary-navy); border: 1.5px solid var(--secondary-navy); padding: 0.55rem 1.3rem; border-radius: 2px; transition: all 0.2s; }
.tag-pill:hover { background: var(--secondary-navy); color: var(--white); }

.filters { display: flex; flex-wrap: wrap; gap: 0.7rem; margin-bottom: 3.25rem; }
.filter-btn { font-size: 0.74rem; padding: 0.55rem 1.2rem; border-radius: 2px; cursor: pointer; font-family: var(--font-body); border: 1.5px solid var(--primary-navy); background: transparent; color: var(--primary-navy); font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; transition: all 0.2s; }
.filter-btn.active, .filter-btn:hover { background: var(--primary-navy); color: var(--white); }
.filter-btn.active { background: var(--gold-accent); border-color: var(--gold-accent); color: var(--primary-navy); }

/* ── Portfolio Accordion ─────────────────────────────────── */
.accordion-toggle { display: inline-block; margin-top: 1.3rem; font-size: 0.76rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; color: var(--primary-navy); cursor: pointer; border-bottom: 1px solid var(--gold-accent); padding-bottom: 2px; transition: color 0.2s; }
.accordion-toggle:hover { color: var(--gold-accent); }
.accordion-content { display: none; margin-top: 1.6rem; padding-top: 1.6rem; border-top: 1px solid var(--muted-gray); animation: fadeDown 0.3s ease; }
.accordion-content.open { display: block; }
.accordion-content h4 { font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--primary-navy); margin-top: 1rem; margin-bottom: 0.65rem; }
.accordion-content ul { list-style: none; padding: 0; }
.accordion-content ul li { font-size: 0.9rem; color: var(--medium-gray); padding: 0.32rem 0 0.32rem 1.25rem; position: relative; border-bottom: 1px solid var(--muted-gray); }
.accordion-content ul li:last-child { border-bottom: none; }
.accordion-content ul li::before { content: '—'; position: absolute; left: 0; color: var(--gold-accent); font-weight: 700; }

@keyframes fadeDown { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: translateY(0); } }

/* ── Timeline ────────────────────────────────────────────── */
.timeline { position: relative; padding-left: 3.25rem; margin-top: 3.5rem; }
.timeline::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 2px; background: linear-gradient(to bottom, var(--gold-accent), transparent); }
.timeline-item { position: relative; margin-bottom: 3.75rem; padding-left: 1.5rem; }
.timeline-item::before { content: ''; position: absolute; left: -3.6rem; top: 0.4rem; width: 10px; height: 10px; background: var(--gold-accent); border-radius: 50%; border: 2px solid var(--white); box-shadow: 0 0 0 2px var(--gold-accent); }
.timeline-date { font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.14em; color: var(--gold-accent); margin-bottom: 0.4rem; }
.timeline-title { font-family: var(--font-body); font-size: 1.1rem; font-weight: 700; color: var(--primary-navy); margin-bottom: 0.25rem; }
.timeline-role { font-size: 0.87rem; color: var(--medium-gray); margin-bottom: 0.85rem; font-style: italic; }

/* ── Value Cards ─────────────────────────────────────────── */
.value-card { display: flex; gap: 2.25rem; align-items: flex-start; padding: 2.25rem 0; border-bottom: 1px solid var(--muted-gray); }
.value-card:last-child { border-bottom: none; }
.value-number { font-family: var(--font-display); font-size: 2.6rem; color: var(--gold-accent); font-weight: 400; line-height: 1; min-width: 3.2rem; }

/* ── Tables ──────────────────────────────────────────────── */
.table-wrapper { margin-top: 2.75rem; overflow-x: auto; }
.table-alt, .table-dark { width: 100%; border-collapse: collapse; }
.table-alt tr:nth-child(even) { background: var(--light-bg); }
.table-alt td { padding: 1.1rem 1.4rem; font-size: 0.94rem; border-bottom: 1px solid var(--muted-gray); }
.table-alt td strong { color: var(--primary-navy); font-weight: 600; }
.table-dark tr { border-bottom: 1px solid rgba(255,255,255,0.08); }
.table-dark td { padding: 1.3rem 1.4rem; font-size: 0.94rem; }
.table-dark td:first-child { font-weight: 700; color: var(--white); width: 35%; }
.table-dark td:last-child { color: rgba(255,255,255,0.65); }

/* ── Badges ──────────────────────────────────────────────── */
.badge { display: inline-block; font-size: 0.66rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; padding: 0.28rem 0.75rem; border-radius: 2px; }
.badge-gold { background: rgba(201,164,82,0.15); color: var(--gold-accent); border: 1px solid var(--gold-accent); }
.badge-green { background: rgba(39,174,96,0.1); color: #27ae60; border: 1px solid #27ae60; }

/* ── Contact Form ────────────────────────────────────────── */
.contact-form-wrapper { background: var(--white); border-top: 3px solid var(--gold-accent); padding: 2.75rem; box-shadow: 0 4px 32px rgba(27,58,92,0.09); }
.form-group { margin-bottom: 1.5rem; }
.form-group label { display: block; font-size: 0.76rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; color: var(--primary-navy); margin-bottom: 0.55rem; }
.form-control { width: 100%; padding: 0.9rem 1.05rem; border: 1.5px solid var(--muted-gray); border-radius: 2px; font-family: var(--font-body); font-size: 0.97rem; color: var(--dark-text); background: var(--white); transition: border-color 0.2s, box-shadow 0.2s; outline: none; appearance: none; }
.form-control:focus { border-color: var(--secondary-navy); box-shadow: 0 0 0 3px rgba(45,89,134,0.12); }
textarea.form-control { resize: vertical; min-height: 135px; }

#contact-success { display: none; padding: 1.3rem 1.6rem; background: rgba(39,174,96,0.08); border: 1px solid #27ae60; border-radius: 2px; margin-bottom: 1.6rem; }
#contact-details-reveal { display: none; margin-top: 2.75rem; padding-top: 2.2rem; border-top: 1px solid var(--muted-gray); }
.contact-info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.6rem; }
.contact-info-item h4 { margin-bottom: 0.45rem; font-size: 0.7rem; }
.contact-info-item a { color: var(--secondary-navy); font-weight: 600; font-size: 0.97rem; transition: color 0.2s; }
.contact-info-item a:hover { color: var(--gold-accent); }

/* ── Footer ──────────────────────────────────────────────── */
/* ── Floating WhatsApp Button ────────────────────────────── */
.whatsapp-float {
  position: fixed;
  bottom: 1.75rem;
  right: 1.75rem;
  width: 58px;
  height: 58px;
  background: #25D366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  box-shadow: 0 6px 20px rgba(0,0,0,0.25);
  z-index: 900;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s ease;
}

.whatsapp-float:hover {
  transform: scale(1.08);
  box-shadow: 0 10px 28px rgba(0,0,0,0.32);
}

.whatsapp-float:active {
  transform: scale(0.96);
}

/* Gentle pulse ring to draw attention without being obnoxious —
   plays a few times on load, then settles. */
.js-ready .whatsapp-float::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background: #25D366;
  animation: whatsappPulse 2.4s cubic-bezier(0.16, 1, 0.3, 1) 3;
  z-index: -1;
}

@keyframes whatsappPulse {
  0%   { transform: scale(1); opacity: 0.6; }
  100% { transform: scale(1.7); opacity: 0; }
}

footer { background: var(--primary-navy); padding: 4.5rem 0 2.25rem; }
.footer-grid { display: grid; grid-template-columns: 1fr auto; gap: 3rem; padding-bottom: 2.75rem; border-bottom: 1px solid rgba(255,255,255,0.1); align-items: start; }
.footer-name { font-family: var(--font-display); font-weight: 400; color: var(--white); font-size: 1.15rem; margin-bottom: 0.4rem; }
.footer-title { font-size: 0.86rem; color: rgba(255,255,255,0.55); margin-bottom: 0.25rem; }
.footer-location { font-size: 0.8rem; color: rgba(255,255,255,0.4); }
.footer-links { display: flex; flex-direction: column; gap: 0.7rem; align-items: flex-end; }
.footer-links a { font-size: 0.76rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.1em; color: rgba(255,255,255,0.55); transition: color 0.2s; }
.footer-links a:hover { color: var(--gold-accent); }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; padding-top: 1.85rem; font-size: 0.76rem; color: rgba(255,255,255,0.3); }

/* ============================================================
   ANIMATION SYSTEM
   Safe-by-default: every rule below is scoped under .js-ready,
   so if JavaScript ever fails to load, every single element
   falls back to its plain, fully visible state. Animation is
   always a bonus layer, never a requirement to see content.

   Tone: restrained, executive, editorial. Long easing curves,
   no bounce/elastic easing, no spin, nothing playful.
   ============================================================ */

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

.js-ready .fade-in {
  opacity: 0;
  transform: translateY(36px);
  transition: opacity 0.9s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.9s cubic-bezier(0.16, 1, 0.3, 1);
}

.js-ready .fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── Page-load reveal ────────────────────────────────────── 
   A brief curtain wipes away on first load, so the page
   arrives rather than simply appears. Pure CSS, fires once,
   never blocks content if JS is slow — it's just an overlay
   that self-removes after a fixed duration. */
.page-curtain {
  position: fixed;
  inset: 0;
  background: var(--primary-navy);
  z-index: 9999;
  pointer-events: none;
  animation: curtainLift 1.1s cubic-bezier(0.65, 0, 0.35, 1) forwards;
  animation-delay: 0.05s;
}

@keyframes curtainLift {
  0%   { opacity: 1; }
  60%  { opacity: 1; }
  100% { opacity: 0; visibility: hidden; }
}

/* ── Staggered grid reveal ───────────────────────────────── 
   Cards cascade in with a longer, more deliberate stagger
   and a slight scale-in alongside the rise — reads as more
   intentional than a flat translateY. */
.js-ready .card-grid > *,
.js-ready .stats-grid > * {
  opacity: 0;
  transform: translateY(26px) scale(0.985);
  transition: opacity 0.75s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.75s cubic-bezier(0.16, 1, 0.3, 1);
}

.js-ready .card-grid.visible > *,
.js-ready .stats-grid.visible > * {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.js-ready .card-grid.visible > *:nth-child(1),
.js-ready .stats-grid.visible > *:nth-child(1) { transition-delay: 0.04s; }
.js-ready .card-grid.visible > *:nth-child(2),
.js-ready .stats-grid.visible > *:nth-child(2) { transition-delay: 0.13s; }
.js-ready .card-grid.visible > *:nth-child(3),
.js-ready .stats-grid.visible > *:nth-child(3) { transition-delay: 0.22s; }
.js-ready .card-grid.visible > *:nth-child(4),
.js-ready .stats-grid.visible > *:nth-child(4) { transition-delay: 0.31s; }
.js-ready .card-grid.visible > *:nth-child(5),
.js-ready .stats-grid.visible > *:nth-child(5) { transition-delay: 0.4s; }
.js-ready .card-grid.visible > *:nth-child(6),
.js-ready .stats-grid.visible > *:nth-child(6) { transition-delay: 0.49s; }
.js-ready .card-grid.visible > *:nth-child(7),
.js-ready .stats-grid.visible > *:nth-child(7) { transition-delay: 0.58s; }
.js-ready .card-grid.visible > *:nth-child(8),
.js-ready .stats-grid.visible > *:nth-child(8) { transition-delay: 0.67s; }

/* ── Timeline & value-card staggered entrance ────────────── 
   These sit inside a .fade-in parent but deserve their own
   cascade rather than appearing all at once. */
.js-ready .timeline-item,
.js-ready .value-card {
  opacity: 0;
  transform: translateX(-16px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.js-ready .timeline.visible .timeline-item,
.js-ready .fade-in.visible .value-card {
  opacity: 1;
  transform: translateX(0);
}

.js-ready .timeline-item:nth-of-type(1) { transition-delay: 0.05s; }
.js-ready .timeline-item:nth-of-type(2) { transition-delay: 0.16s; }
.js-ready .timeline-item:nth-of-type(3) { transition-delay: 0.27s; }
.js-ready .timeline-item:nth-of-type(4) { transition-delay: 0.38s; }

.js-ready .value-card:nth-of-type(1) { transition-delay: 0.04s; }
.js-ready .value-card:nth-of-type(2) { transition-delay: 0.12s; }
.js-ready .value-card:nth-of-type(3) { transition-delay: 0.2s; }
.js-ready .value-card:nth-of-type(4) { transition-delay: 0.28s; }
.js-ready .value-card:nth-of-type(5) { transition-delay: 0.36s; }

/* ── Hero entrance ───────────────────────────────────────── 
   Each hero element rises in turn on load. The headline gets
   a touch of letter-spacing settle for a more considered,
   editorial arrival rather than a plain slide. */
.js-ready .hero-content > * {
  opacity: 0;
  transform: translateY(20px);
  animation: heroRise 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.js-ready .hero-content > *:nth-child(1) { animation-delay: 0.15s; }
.js-ready .hero-content > *:nth-child(2) { animation-delay: 0.28s; }
.js-ready .hero-content > *:nth-child(3) { animation-delay: 0.41s; }
.js-ready .hero-content > *:nth-child(4) { animation-delay: 0.54s; }
.js-ready .hero-content > *:nth-child(5) { animation-delay: 0.67s; }

@keyframes heroRise {
  to { opacity: 1; transform: translateY(0); }
}

/* Hero photo: gentle reveal-from-mask rather than a hard cut-in */
.js-ready .hero-img-container img {
  animation: heroImageReveal 1.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  animation-delay: 0.2s;
}

@keyframes heroImageReveal {
  from { opacity: 0; transform: scale(1.06); }
  to   { opacity: 1; transform: scale(1); }
}

/* ── Scroll progress indicator ───────────────────────────── 
   A 2px gold line tracking scroll depth, fixed to the very
   top of the viewport — a quiet, premium touch used across
   editorial sites. Width is set by JS via a CSS variable. */
.scroll-progress {
  position: fixed;
  top: 0; left: 0;
  height: 2px;
  width: var(--scroll-progress, 0%);
  background: var(--gold-accent);
  z-index: 1100;
  transition: width 0.1s linear;
}

/* ── Navbar logo entrance ────────────────────────────────── */
.js-ready .logo-text,
.js-ready .logo-creds {
  opacity: 0;
  transform: translateY(-6px);
  animation: navDrop 0.7s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  animation-delay: 0.05s;
}

.js-ready .logo-creds { animation-delay: 0.12s; }

@keyframes navDrop {
  to { opacity: 1; transform: translateY(0); }
}

/* ── Refined hover lifts ─────────────────────────────────── */
.value-card,
.timeline-item {
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.value-card:hover { transform: translateX(6px); }
.timeline-item:hover { transform: translateX(6px); }

.tag-pill {
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.tag-pill:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(45,89,134,0.18);
}

/* ── Magnetic-feel button micro-interaction ──────────────── 
   A soft, deliberate press-down on click rather than just a
   hover state — gives buttons a tactile, premium feel. */
.btn {
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1),
              background 0.3s ease, border-color 0.3s ease,
              box-shadow 0.3s ease;
}

.btn:active {
  transform: scale(0.97);
}

/* ── Animated underline links ─────────────────────────────
   Replaces the instant color-swap with a drawing underline
   that fills from left to right — reads as more deliberate
   and editorial than a flat hover. */
.card-link,
.accordion-toggle {
  position: relative;
  border-bottom: none !important;
  padding-bottom: 4px;
}

.card-link::after,
.accordion-toggle::after {
  content: '';
  position: absolute;
  left: 0; bottom: 0;
  width: 100%;
  height: 1px;
  background: var(--gold-accent);
  transform: scaleX(1);
  transform-origin: left;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.card-link:hover::after,
.accordion-toggle:hover::after {
  transform: scaleX(0.4);
}

.footer-links a,
.nav-links a {
  transition: color 0.25s ease, transform 0.25s ease;
}

/* ── Image reveal on scroll + subtle zoom on hover ───────── 
   Photos wipe in from a soft mask rather than just fading,
   then offer a slow, almost imperceptible zoom on hover —
   signals quality without feeling like a gimmick. */
.js-ready .img-content {
  overflow: hidden;
}

.js-ready .img-content img {
  transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.js-ready .fade-in .img-content img {
  opacity: 0;
  transform: scale(1.08);
  transition: opacity 1s cubic-bezier(0.16, 1, 0.3, 1),
              transform 1s cubic-bezier(0.16, 1, 0.3, 1);
}

.js-ready .fade-in.visible .img-content img {
  opacity: 1;
  transform: scale(1);
}

.img-content:hover img {
  transform: scale(1.025);
}

/* ── Stat numbers: subtle settle after count-up ──────────── 
   The actual counting is handled in JS; this just ensures
   the number doesn't jump or flicker as it locks in. */
.stat-number {
  transition: opacity 0.3s ease;
}

/* ── Section label: animated underline accent on entry ───── */
.js-ready .label {
  position: relative;
  display: inline-block;
}

.js-ready .fade-in .label::after {
  content: '';
  position: absolute;
  left: 0; bottom: -6px;
  width: 24px;
  height: 1.5px;
  background: var(--gold-accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1) 0.2s;
}

.js-ready .fade-in.visible .label::after {
  transform: scaleX(1);
}



/* ── Responsive ──────────────────────────────────────────── 
   Three breakpoints: tablet (960px), mobile (680px), and
   small mobile (400px). Every component on the site is
   addressed here — navbar, hero (both full and short
   variants), forms, tables, cards, timeline, footer, and the
   floating WhatsApp button. */

@media (max-width: 960px) {
  :root { --section-pad: 5.5rem 0; }

  .hero-grid { grid-template-columns: 1fr; }
  .hero { min-height: auto; }

  /* Hero photo: was display:none (the bug) — now it drops out
     of absolute positioning and stacks in normal flow below
     the text content, full width, with a fixed sensible height
     instead of being sized off the (now irrelevant) hero height. */
  .hero-img-container {
    position: relative;
    width: 100%;
    height: 380px;
    margin-top: 2.5rem;
    right: auto; bottom: auto;
  }

  .hero-img-container img {
    /* The left-edge fade mask only makes sense when the photo
       bleeds into a wide hero from the right; on mobile it's a
       normal full-width image so the mask is removed. */
    mask-image: none;
    -webkit-mask-image: none;
    border-radius: 2px;
  }

  .hero-short .hero-img-container { height: 320px; }

  .split-layout, .split-layout.reverse { grid-template-columns: 1fr; direction: ltr; gap: 3rem; }
  .split-layout.reverse .img-content { order: -1; }
  .img-content::before, .split-layout.reverse .img-content::before { display: none; }

  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 2.75rem; }
  .card-grid { grid-template-columns: 1fr; }
  .service-card { padding: 2.2rem; }

  .nav-links { gap: 1.75rem; }
}

@media (max-width: 768px) {
  .nav-links { display: none; }
  .hamburger { display: block; }
}

@media (max-width: 680px) {
  :root { --section-pad: 4rem 0; --container-pad: 0 1.25rem; }

  /* ── Navbar ── */
  .navbar { padding: 1.1rem 0; }
  .navbar.scrolled { padding: 0.85rem 0; }
  .logo-text { font-size: 1.1rem; }
  .logo-creds { font-size: 0.56rem; }

  /* ── Hero ── */
  .hero .container { padding-top: 7.5rem; padding-bottom: 3rem; }
  .hero-short .container { padding-top: 7rem; padding-bottom: 2.5rem; }
  .hero-content p { max-width: 100%; }
  .hero-btns { flex-direction: column; align-items: stretch; gap: 0.85rem; }
  .hero-btns .btn { text-align: center; }
  .hero-creds { gap: 0.4rem 1rem; }
  .hero-img-container { height: 300px; margin-top: 2rem; }
  .hero-short .hero-img-container { height: 260px; }

  /* ── Typography scale-down for very narrow viewports ── */
  h1 { font-size: clamp(2.1rem, 8vw, 2.8rem); }
  h2 { font-size: clamp(1.6rem, 6vw, 2.1rem); }

  /* ── Stats ── */
  .stats-grid { grid-template-columns: 1fr 1fr; gap: 2.25rem; }
  .stat-number { font-size: 1.8rem; }

  /* ── Cards & services ── */
  .card-grid { grid-template-columns: 1fr; gap: 1.5rem; }
  .card { padding: 1.85rem; }
  .service-card { padding: 1.85rem; }
  .service-card h3 { font-size: 1.1rem; }

  /* ── Tags / pills / filters ── */
  .tags-grid { gap: 0.6rem; }
  .tag-pill { font-size: 0.7rem; padding: 0.45rem 1rem; }
  .filters { gap: 0.5rem; }
  .filter-btn { font-size: 0.68rem; padding: 0.45rem 0.9rem; }

  /* ── Timeline ── */
  .timeline { padding-left: 1.75rem; }
  .timeline-item { padding-left: 0.25rem; margin-bottom: 2.75rem; }
  .timeline-item::before { left: -2.05rem; }
  .timeline-title { font-size: 1rem; }

  /* ── Value cards ── */
  .value-card { flex-direction: column; gap: 0.6rem; padding: 1.75rem 0; }
  .value-number { font-size: 2.1rem; }

  /* ── Tables ── */
  .table-alt td { padding: 0.85rem 1rem; font-size: 0.85rem; }
  .table-dark td { padding: 1rem 1rem; font-size: 0.85rem; }
  .table-dark td:first-child { width: auto; display: block; padding-bottom: 0.3rem; }
  .table-dark td:last-child { display: block; padding-top: 0; }
  .table-dark tr { display: block; padding: 0.9rem 0; }

  /* ── Contact form ── */
  .contact-form-wrapper { padding: 1.75rem; }
  .contact-info-grid { grid-template-columns: 1fr; gap: 1.25rem; }
  .form-control { font-size: 0.92rem; padding: 0.8rem 0.9rem; }

  /* ── Footer ── */
  .footer-grid { grid-template-columns: 1fr; gap: 2.25rem; }
  .footer-links { align-items: flex-start; }
  .footer-bottom { flex-direction: column; gap: 1rem; text-align: center; }
  .footer-name { font-size: 1rem; }

  /* ── Mobile menu links: scale down on very short screens ── */
  .mobile-menu a { font-size: 2rem; }

  /* ── Floating WhatsApp button: slightly smaller, closer to edge ── */
  .whatsapp-float {
    width: 52px;
    height: 52px;
    right: 1.1rem;
    bottom: 1.1rem;
  }
}

@media (max-width: 400px) {
  .stat-number { font-size: 1.6rem; }
  .stats-grid { gap: 1.75rem; }
  h1 { font-size: 1.85rem; }
  .hero-img-container { height: 260px; }
  .btn { font-size: 0.72rem; padding: 0.85rem 1.6rem; }
}

