* {
  box-sizing: border-box;
  font-family: "Montserrat", sans-serif;
}

h1 {
  font-family: "Cinzel", serif;
  font-weight: bold;
}

h2 {
  font-family: "Cinzel", serif;
}

h3 {
  font-family: "Cinzel", serif;
}

/*:root {*/
/*  !* Dark Mode Color Palette *!*/
/*  --bg-primary: #0f1419;*/
/*  --bg-secondary: #1a2332;*/
/*  --bg-tertiary: #252d3d;*/
/*  --bg-card: rgba(42, 50, 68, 0.6);*/
/*  --text-primary: #f0f0f0;*/
/*  --text-secondary: #b0b0b0;*/
/*  --accent-blue: #64b5f6;*/
/*  --accent-green: #81c784;*/
/*  --accent-pink: #f06292;*/
/*  --accent-purple: #ba68c8;*/
/*  --border-color: rgba(255, 255, 255, 0.1);*/
/*  --bg-blur: 3px;*/
/*}*/


:root {
  /* Dark Mode Color Palette */
  --bg-primary: #e6e6e6;
  --bg-secondary: #cccccc;
  --bg-tertiary: #c2c2c2;
  --bg-card: rgba(186, 186, 186, 0.6);
  --text-primary: #0f0f0f;
  --text-secondary: #4f4f4f;
  --accent-blue: #64b5f6;
  --accent-green: #81c784;
  --accent-pink: #f06292;
  --accent-purple: #ba68c8;
  --border-color: rgba(255, 255, 255, 0.1);
  --bg-blur: 3px;

  --dark-azure: #015362;
  --azure: #468b93;
  --cyan: #7bc0c1;
  --pastel-grey-cyan: #bad8da;

  --purple: #5a1f7f;
  --lavender: #a15bc6;
  --light-purple: #ccc1de;
}
html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background: linear-gradient(135deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
}

.glass,
.glass-pill {
  background: var(--bg-primary);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  /* Subtle depth for all glass cards */
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.22),
              0 2px 6px rgba(0, 0, 0, 0.12),
              inset 0 1px 0 rgba(255, 255, 255, 0.06);
  transition: box-shadow 0.3s ease, transform 0.3s ease;
}
.glass { border-radius: 12px; }

/* Navigation */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: var(--bg-primary);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-color);
  z-index: 1000;
  padding: 0.5rem 0;
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 2rem;
}

.nav-menu a {
  color: var(--text-primary);
  text-decoration: none;
  transition: color 0.3s ease;
}

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

.hamburger {
  display: none;
  flex-direction: column;
  cursor: pointer;
  gap: 5px;
}

.hamburger span {
  width: 25px;
  height: 3px;
  background: var(--text-primary);
  border-radius: 3px;
  transition: 0.3s;
}

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

  .nav-menu {
    position: absolute;
    top: 60px;
    left: 0;
    right: 0;
    background: var(--bg-secondary);
    flex-direction: column;
    gap: 1rem;
    padding: 1rem;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
  }

  .nav-menu.active {
    max-height: 300px;
  }

  .hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(10px, 10px);
  }

  .hamburger.active span:nth-child(2) {
    opacity: 0;
  }

  .hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
  }
}

/* Hero Section */
.hero {
  position: relative;
  overflow: hidden;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  /*font-family: "Cinzel", serif;*/
  background-image: linear-gradient(135deg, hsla(0, 0%, 0%, 0.1) 0%, hsla(0, 0%, 100%, 0.1) 100%);
  /*background-image: linear-gradient(135deg, rgba(0, 0, 0, 0.1) 0%, rgba(255, 255, 255, 0.1) 100%);*/
  margin-top: 60px;
  padding: 2rem;
}

.hero-content h1 {
  font-size: clamp(2.5rem, 5vw, 4rem);
  margin-bottom: 1rem;
  background: linear-gradient(180deg, var(--dark-azure), var(--cyan));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-content p {
  margin-bottom: 2rem;
}

.cta-button {
  display: inline-block;
  padding: 1rem 2.5rem;
  background: var(--dark-azure);
  color: var(--bg-primary);
  text-decoration: none;
  border-radius: 50px;
  font-weight: 600;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 8px 30px rgba(100, 181, 246, 0.3);
}

.cta-button:hover {
  background: linear-gradient(155deg, var(--dark-azure), var(--cyan));
  transform: translateY(-3px);
  box-shadow: 0 12px 40px rgba(100, 181, 246, 0.5);
}

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

/* About Section */
.about {
  padding: 5rem 2rem;
  background: var(--bg-primary);
}

.about h2,
.services h2,
.team h2,
.portfolio h2,
.testimonials h2,
.contact h2,
.plans h2 {
  margin-bottom: 3rem;
  text-align: center;
  background: linear-gradient(180deg, var(--dark-azure), var(--cyan));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.what-we-do-content {
  display: grid;
  gap: 3rem;
  margin-bottom: 3rem;
}

.what-we-do-content p {
  line-height: 1.8;
}

.values {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

/* consolidated into unified card rule */
.value-card {
}

.value-card h3 {
  color: var(--accent-blue);
  margin-bottom: 1rem;
  font-size: 1.3rem;
}

.value-card p {
  color: var(--text-secondary);
}

/* Services Section */
.services {
  padding: 5rem 2rem;
  background: var(--bg-secondary);
}

.service-card {
  transition: transform 0.3s ease;
}

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

.service-icon {
  width: 60px;
  height: 60px;
  margin: 0 auto 1.5rem;
  border-radius: 12px;
}

.service-card h3 {
  margin-bottom: 1rem;
}

/* Team Section */
.team {
  padding: 5rem 2rem;
  background: var(--bg-primary);
}

.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(370px, 1fr));
  gap: 2rem;
  justify-content: center; /* center remaining cards on the last row */
}

/* Ensure consistent card widths in the flex layout */
.services .services-grid .service-card {
  flex: 0 1 320px; /* base width similar to previous grid min size */
  width: min(100%, 360px);
}

.team-card {
}

.team-avatar {
  width: 100px;
  height: 100px;
  margin: 0 auto 1.5rem;
  border-radius: 50%;
}

.team-card h3 {
  font-size: 1.3rem;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

.team-card .role {
  color: var(--accent-blue);
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.team-card .skills {
  color: var(--text-secondary);
  font-size: 0.9rem;
}

/* Portfolio Section */
.portfolio {
  padding: 5rem 2rem;
  background: var(--bg-secondary);
}

.portfolio-grid {
  /* Switch to flex to center the last row when it's not full */
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
}

.portfolio-card {
  padding: 2rem;
  overflow: hidden;
}

.portfolio-image {
  width: 100%;
  height: 200px;
  margin-bottom: 1.5rem;
  border-radius: 8px;
}

.portfolio-card h3 {
  font-size: 1.3rem;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

.portfolio-card p {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.view-btn {
  padding: 0.75rem 1.5rem;
  background: var(--accent-blue);
  color: var(--bg-primary);
  border: none;
  border-radius: 25px;
  cursor: pointer;
  font-weight: 600;
  transition: background 0.3s ease;
}

.view-btn:hover {
  background: var(--accent-green);
}

/* Modal */
.modal {
  display: none;
  position: fixed;
  z-index: 2000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(15, 20, 25, 0.8);
  backdrop-filter: blur(5px);
}

.modal-content {
  position: relative;
  background: var(--bg-card);
  margin: 5% auto;
  padding: 2rem;
  width: 90%;
  max-width: 1000px;
  border-radius: 12px;
  border: 1px solid var(--border-color);
  animation: slideIn 0.3s ease;
}

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

.close {
  position: absolute;
  right: 1.5rem;
  top: 1rem;
  font-size: 2rem;
  font-weight: bold;
  color: var(--text-secondary);
  cursor: pointer;
  transition: color 0.3s ease;
}

.close:hover {
  color: var(--accent-blue);
}

.modal h2 {
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.modal p {
  color: var(--text-secondary);
}

/* Testimonials Section */
.testimonials {
  padding: 5rem 2rem;
  background: var(--bg-primary);
}

.testimonials-carousel {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 2rem;
}

.testimonial {
  padding: 2rem;
  position: relative;
}

.testimonial .quote {
  font-style: italic;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  font-size: 1rem;
}

.testimonial .quote:before {
  content: '"';
  font-size: 3rem;
  color: var(--accent-blue);
  opacity: 0.3;
  margin-right: 0.5rem;
}

.testimonial .author {
  color: var(--accent-green);
  font-weight: 600;
}

/* Contact Section */
.contact {
  padding: 5rem 2rem;
  background: var(--bg-secondary);
}

.contact-form {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 2rem;
}

.contact-form input,
.contact-form textarea {
  padding: 1rem;
  background: var(--bg-tertiary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  color: var(--text-primary);
  font-family: inherit;
  transition: border-color 0.3s ease;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: var(--text-secondary);
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--accent-blue);
  background: var(--bg-card);
}

.submit-btn {
  padding: 1rem 2rem;
  background: linear-gradient(135deg, var(--dark-azure), var(--azure));
  color: var(--bg-primary);
  border: none;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.3s ease;
}

.submit-btn:hover {
  transform: translateY(-2px);
}

/* Success state: solid green and permanently disabled */
.submit-btn--success {
  background: linear-gradient(135deg, #16a34a, #22c55e); /* green gradient */
  color: var(--bg-primary);
}
.submit-btn--success:hover { /* no hover lift on success */
  transform: none;
}

/* Generic disabled look */
.submit-btn:disabled {
  cursor: not-allowed;
  opacity: 0.85;
}
/* Keep success button vivid even when disabled */
.submit-btn--success:disabled {
  opacity: 1;
  cursor: default;
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.info-card {
  padding: 2rem;
}

.info-card h3 {
  color: var(--accent-blue);
  margin-bottom: 0.5rem;
}

.info-card p {
  color: var(--text-secondary);
}

/* Footer */
.footer {
  background: var(--bg-primary);
  border-top: 1px solid var(--border-color);
  padding: 2rem;
  text-align: center;
}

.footer .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.footer p {
  color: var(--text-secondary);
}

.footer-links {
  display: flex;
  gap: 2rem;
}

.footer-links a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.3s ease;
}

.footer-links a:hover {
  color: var(--accent-blue);
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

section {
  animation: fadeIn 0.6s ease-out;
}


/* Utilities */
.text-center {
  text-align: center;
}

/* Card consolidation: shared block card layout */
.service-card,
.team-card,
.value-card {
  padding: 2rem;
  text-align: center;
}

/* tsParticles in hero background (legacy when confined to hero) */
.hero #tsparticles {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none; /* allow clicks on CTA and links */
}

/* Global content layer utility: place content above full-screen particles */
.content-layer {
  position: relative;
  z-index: 2;
}

.hero .hero-content {
  position: relative;
  z-index: 1;
}

/* Ensure full-screen particles never block interactions */
#tsparticles canvas { pointer-events: none; }
.tsparticles-canvas-el { pointer-events: none !important; }

/* Glass pill utility */
.glass-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.25rem;
  border-radius: 12px;
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
}

.glass-pill > .pill-icon { width: 1.25rem; height: 1.25rem; border-radius: 50%; }


/* Global blur overlay above particles, below content */
.blur-overlay {
  position: fixed;
  inset: 0;
  z-index: 1; /* tsParticles uses z-index: 0; content-layer uses z-index: 2 */
  pointer-events: none; /* do not block clicks */
  backdrop-filter: blur(var(--bg-blur));
  -webkit-backdrop-filter: blur(var(--bg-blur));
  background: rgba(15, 20, 25, 0.02); /* subtle tint to stabilize blur visuals */
}

/* Fallback when backdrop-filter is unsupported */
@supports not ((-webkit-backdrop-filter: blur(0)) or (backdrop-filter: blur(0))) {
  .blur-overlay {
    background: rgba(15, 20, 25, 0.08);
  }
}


/* Plans Section */
.plans {
  padding: 5rem 2rem;
  background: var(--bg-secondary);
}

.plans-grid {
  /* Switch to flex layout to truly center the last row when it's not full */
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: center; /* center lines (rows) with leftover space */
}

.plan-card {
  padding: 2rem;
  text-align: center;
  transition: transform 0.3s ease;
  /* Layout: stack content and pin CTA to the bottom */
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  /* Flex item sizing to emulate grid min/max and keep consistent card width */
  flex: 0 1 357px; /* base width ~320px, can shrink on smaller screens */
  width: min(100%, 357px);
}

.plan-card:hover {
  transform: translateY(-8px);
}

.plan-card h3 {
  font-size: 1.3rem;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.plan-features {
  list-style: disc;
  padding-left: 1.25rem;
  color: var(--text-secondary);
  text-align: left;
  display: grid;
  gap: 0.5rem;
}


/* Plans: theming + pricing */
/* Per-plan modifiers set theme variables used by shared rules below */
.plan--starter { --plan-color: #64b5f6; --plan-tint: rgba(100, 181, 246, 0.15); --plan-tint-strong: rgba(100, 181, 246, 0.22); }
.plan--pro { --plan-color: #81c784; --plan-tint: rgba(129, 199, 132, 0.15); --plan-tint-strong: rgba(129, 199, 132, 0.22); }
.plan--enterprise { --plan-color: #ba68c8; --plan-tint: rgba(186, 104, 200, 0.15); --plan-tint-strong: rgba(186, 104, 200, 0.22); }
.plan--consulting { --plan-color: #ffb74d; --plan-tint: rgba(255, 183, 77, 0.15); --plan-tint-strong: rgba(255, 183, 77, 0.22); }

/* Overlay tint without breaking glass effect */
.plan-card { position: relative; overflow: hidden; }
.plan-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 0%, var(--plan-tint, transparent) 100%);
  pointer-events: none;
  z-index: 0;
}
.plan-card:hover::before {
  background: linear-gradient(180deg, rgba(255,255,255,0.02) 0%, var(--plan-tint-strong, var(--plan-tint, transparent)) 100%);
}
/* Ensure content stays above the tint overlay */
.plan-card > * { position: relative; z-index: 1; }

/* Colored plan headers per theme */
.plan-card h3 { color: var(--plan-color, var(--text-primary)); }

/* Pricing: big amount, small unit, aligned on baseline */
.plan-price {
  display: inline-flex;
  align-items: baseline;
  gap: 0.35rem;
  justify-content: center;
  margin: 0.25rem 0 1rem;
}
.plan-price .amount {
  font-size: clamp(2rem, 6vw, 3rem);
  line-height: 1;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text-primary);
}
.plan-price .unit {
  font-size: clamp(0.85rem, 1.6vw, 1.1rem);
  color: var(--text-secondary);
}

/* Plan description */
.plan-desc {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin: -0.25rem 0 0.5rem;
}

/* Learn More CTA */
.plan-cta {
  margin-top: auto; /* pin to bottom of the card */
  padding: 0.75rem 1.25rem;
  border-radius: 10px;
  border: 1px solid var(--plan-color, var(--accent-blue));
  background: color-mix(in srgb, var(--plan-color, #64b5f6) 18%, transparent);
  color: var(--text-primary);
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
  width: 100%;
}

.plan-cta:hover {
  transform: translateY(-2px);
  background: color-mix(in srgb, var(--plan-color, #64b5f6) 28%, transparent);
  box-shadow: 0 8px 24px rgba(0,0,0,0.2);
}

.plan-cta:focus {
  outline: 2px solid var(--plan-color, var(--accent-blue));
  outline-offset: 2px;
}


/* Plan Modal: two-column layout with card on the left, details on the right */
.plan-modal {
  display: grid;
  grid-template-columns: 360px minmax(0, 1fr);
  gap: 2rem;
  align-items: start;
}

/* Ensure the card doesn't stretch too wide inside modal */
.plan-modal .plan-card {
  flex: 0 0 360px;
  width: 360px;
}

.plan-modal-details h4 {
  font-size: 1.1rem;
  margin: 0.25rem 0 0.75rem;
  color: var(--text-primary);
}

.plan-modal-details p {
  color: var(--text-secondary);
  margin-bottom: 0.75rem;
}

.plan-modal-details ul {
  padding-left: 1.1rem;
  margin-bottom: 0.75rem;
  display: grid;
  gap: 0.4rem;
}

.plan-modal-details .note {
  font-size: 0.9rem;
  color: var(--text-secondary);
  opacity: 0.9;
}

@media (max-width: 860px) {
  .plan-modal {
    grid-template-columns: 1fr;
  }
  .plan-modal .plan-card {
    flex: 0 1 auto;
    width: 100%;
    max-width: 420px;
  }
}

/*** Team Card — Two‑column internal layout ***/
/* Override shared centering for team cards */
.team-card { text-align: left; padding: 0; overflow: hidden; }

/* Internal grid: fixed media column on the left, fluid details on the right */
.team-card-inner {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr);
  gap: 1.25rem;
  align-items: start;
}

/* Keep the media column fixed-width */
.team-media { width: 120px; }

/* Fixed-width portrait that only takes its own width and sits flush with card edges */
.team-portrait {
  width: 120px;
  aspect-ratio: 3 / 4; /* tall portrait */
  background-size: cover;
  background-position: center;
  border: none; /* let image touch the card border */
  border-radius: 0; /* clipping handled by card's overflow + radius */
  display: block;
}

/* Typography spacing inside the body */
.team-body { padding: 1.25rem; padding-left: 0; }
.team-body .team-name { margin: 0 0 0.25rem; }
.team-body .role { margin: 0 0 0.35rem; }
.team-body .skills { margin: 0; }
.team-body .team-quote { margin-top: 0.5rem; color: var(--text-secondary); font-style: italic; }

/* Responsive tweaks: slightly smaller media column on very small screens */
@media (max-width: 520px) {
  .team-card-inner { grid-template-columns: 90px minmax(0, 1fr); }
  .team-media { width: 90px; }
  .team-portrait { width: 90px; }
}


/* What We Do (About) — horizontally aligned service cards */
.what-we-do .service-card {
  /* Override shared centering */
  text-align: left;
  /* Side-by-side layout: icon left, text right */
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr);
  grid-auto-rows: auto;
  column-gap: 1rem;
  row-gap: 0.35rem;
  align-items: start;
}

/* Keep icon fixed-size on the left and remove global centering margins */
.what-we-do .service-card .service-icon {
  width: 60px;
  height: 60px;
  margin: 0; /* override .service-icon margin: 0 auto 1.5rem; */
  display: grid; /* center the inner svg/img */
  place-items: center;
}

/* Make heading and description occupy the right column */
.what-we-do .service-card h3,
.what-we-do .service-card p {
  grid-column: 2;
  margin: 0; /* tighten spacing for horizontal layout */
}

/* Optional: small tweak for tighter vertical rhythm on mobile without stacking */
@media (max-width: 520px) {
  .what-we-do .service-card {
    grid-template-columns: 56px minmax(0, 1fr);
    column-gap: 0.75rem;
  }
}

/* Restore icon above text with normal spacing */
.what-we-do .service-card .service-icon {
  margin: 0 0 1rem;       /* top aligned, space below icon */
}

/* Clear horizontal grid-specific placement and restore spacing */
.what-we-do .service-card h3,
.what-we-do .service-card p {
  grid-column: auto;      /* no grid column when stacked */
}

.what-we-do .service-card h3 { margin: 0 0 0.5rem; }
.what-we-do .service-card p { margin: 0; }


/* What We Do — rows with alternating diamond and card */
/* Force one card per row under .what-we-do (overrides .values grid) */
.values.what-we-do { grid-template-columns: 1fr; gap: 2rem; }

/* Row layout: two columns (card + diamond) */
.what-we-do .wwd-row {
  display: flex;
  align-items: center; /* center columns; let card define its own height */
  justify-content: space-between;
  gap: 2rem;
}

/* Alternate: invert placement every other row */
.what-we-do .wwd-row:nth-child(even) {
  flex-direction: row-reverse;
}

/* Columns: card grows, diamond has a fixed, responsive width */
.what-we-do .wwd-row > .wwd-card { flex: 1 1 0; }
.what-we-do .wwd-row > .wwd-diamond { flex: 0 0 clamp(96px, 22vw, 250px); }

/* Keep the card styling untouched inside */
/* Ensure the diamond never forces the card to stretch in height */
.what-we-do .wwd-card .service-card { height: auto; }

/* Diamond presentation */
.what-we-do .wwd-diamond {
  display: flex;
  align-items: center; /* diamond should not stretch row height */
  justify-content: center; /* center diamond horizontally */
}

/* Desktop/default: diamond fits within the row/card height and never increases it */
.what-we-do .diamond-svg {
  width: 100%;            /* fill the diamond column */
  height: auto;           /* keep aspect ratio */
  max-height: 100%;       /* do not exceed row/card height */
  max-width: 100%;        /* prevent overflow */
  filter: drop-shadow(0 10px 30px rgba(0,0,0,0.25));
  opacity: 0.9;
}

/* Responsive behavior */
@media (max-width: 900px) {
  /* Slightly reduce diamond size on tall cards; keep height-based sizing */
  .what-we-do .diamond-svg { max-width: 60vw; }
}

@media (max-width: 768px) {
  /* Stack columns vertically; keep alternation by reversing on even rows */
  .what-we-do .wwd-row { flex-direction: column; }
  .what-we-do .wwd-row:nth-child(even) { flex-direction: column-reverse; }
  .what-we-do .wwd-row > .wwd-card,
  .what-we-do .wwd-row > .wwd-diamond { flex: 0 1 auto; }
  /* On mobile, revert to width-based sizing for a balanced look */
  .what-we-do .wwd-diamond { align-items: center; }
  .what-we-do .diamond-svg { height: auto; width: clamp(72px, 40vw, 120px); }
}

/* What We Do — diamond icon overlay */
.what-we-do .wwd-diamond .diamond-wrap {
  position: relative;
  display: block; /* fill the diamond column */
  width: 100%;
  line-height: 0; /* remove inline-gap */
}

/* Ensure SVG participates as the sizing element */
.what-we-do .wwd-diamond .diamond-svg { display: block; }

/* Center the icon within the diamond and allow precise micro‑nudges */
.what-we-do .wwd-diamond .diamond-icon {
  position: absolute;
  left: 50%;
  top: 50%;
  /* Per-icon nudge variables (pixels). Default to perfect center. */
  --dx: 0px;
  --dy: 0px;
  transform: translate(calc(-50% + var(--dx)), calc(-50% + var(--dy)));
  width: min(60%, 140px);
  max-width: 60%;
  height: auto;
  max-height: 60%; /* never exceed diamond interior */
  object-fit: contain;
  pointer-events: none; /* purely decorative */
}

/* Per-icon micro adjustments (tweak as needed) */
.what-we-do .wwd-diamond .icon-window { --dx: 0px; --dy: 0px; }
.what-we-do .wwd-diamond .icon-wench { --dx: -2px; --dy: 0px; }
.what-we-do .wwd-diamond .icon-clipboard { --dx: 0px; --dy: -1px; }

/* Slightly larger icon on small screens to keep visual weight */
@media (max-width: 768px) {
  .what-we-do .wwd-diamond .diamond-icon {
    width: min(70%, 120px);
    max-width: 70%;
    max-height: 70%;
  }
}


/* Card depth interactions */
.glass:hover,
.glass:focus-within {
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.28),
              0 4px 12px rgba(0, 0, 0, 0.18),
              inset 0 1px 0 rgba(255, 255, 255, 0.07);
}


/* What We Do — gradient drop-shadows that follow diamond colors */
/* Defaults to control intensity/tone just for WWD gradient shadows */
.what-we-do {
  --wwd-shadow-opacity: 0.5;             /* base opacity of the gradient glow (was 0.65) */
  --wwd-shadow-opacity-hover: 0.65;      /* hover/focus opacity (was 0.8) */
  --wwd-shadow-mix-start: 30%;           /* color mix for start color (was 40%) */
  --wwd-shadow-mix-end: 30%;             /* color mix for end color (was 40%) */
}
/* Map per-row gradient colors (matching the SVG diamond fills) */
.what-we-do .wwd-row { --shadow-start: var(--lavender); --shadow-end: var(--light-purple); }
.what-we-do .wwd-row:nth-child(2) { --shadow-start: var(--purple); --shadow-end: var(--light-purple); }
.what-we-do .wwd-row:nth-child(3) { --shadow-start: var(--purple); --shadow-end: var(--lavender); }

/* Create a blurred gradient pseudo-shadow behind the card */
.what-we-do .wwd-card .service-card.glass {
  position: relative; /* anchor the pseudo-element */
  z-index: 0; /* establish stacking context so ::after with z-index:-1 sits behind */
}

.what-we-do .wwd-card .service-card.glass::after {
  content: "";
  position: absolute;
  inset: -8px; /* extend slightly beyond the card bounds for a natural glow */
  border-radius: inherit;
  pointer-events: none;
  filter: blur(22px);
  opacity: var(--wwd-shadow-opacity, 0.5);
  transform: translateY(8px);
  z-index: -1; /* sit behind the card so it acts like a shadow */
  transition: opacity 0.25s ease, filter 0.25s ease, transform 0.25s ease;
}

/* Elevation on hover/focus within — slightly stronger, lower shadow */
.what-we-do .wwd-card .service-card.glass:hover::after,
.what-we-do .wwd-card .service-card.glass:focus-within::after {
  opacity: var(--wwd-shadow-opacity-hover, 0.65);
  filter: blur(26px);
  transform: translateY(10px) scale(1.02);
  /* Use a vertical radial gradient that fades outward; mix colors for softness */
  background: radial-gradient(120% 120% at 50% 110%,
  color-mix(in srgb, var(--shadow-start, #64b5f6) var(--wwd-shadow-mix-start, 30%), transparent) 0%,
  color-mix(in srgb, var(--shadow-end, #81c784) var(--wwd-shadow-mix-end, 30%), transparent) 55%,
  transparent 72%
  );
}

/* Fallback: if color-mix unsupported, keep neutral shadow via existing box-shadow */
@supports not (background: color-mix(in srgb, red 50%, transparent)) {
  .what-we-do .wwd-card .service-card.glass::after { display: none; }
}


/* Our Expertise (Services) — gradient drop-shadows that match each icon color */
/* Scoped tuning just for the Services section */
.services {
  --svc-shadow-opacity: 0.48;            /* base opacity for glow */
  --svc-shadow-opacity-hover: 0.62;      /* hover/focus opacity */
  --svc-shadow-mix-start: 28%;           /* color mix for start color */
  --svc-shadow-mix-end: 28%;             /* color mix for end color */
  --svc-shadow-blur: 20px;               /* base blur radius */
  --svc-shadow-blur-hover: 24px;         /* hover blur radius */
}

/* Map per-card gradient colors to follow the icon backgrounds */
/*.services .services-grid .service-card:nth-child(1) { --shadow-start: #64b5f6; --shadow-end: #42a5f5; }*/
/*.services .services-grid .service-card:nth-child(2) { --shadow-start: #f06292; --shadow-end: #ec407a; }*/
/*.services .services-grid .service-card:nth-child(3) { --shadow-start: #81c784; --shadow-end: #66bb6a; }*/
/*.services .services-grid .service-sub-grid .service-card:nth-child(1) { --shadow-start: #81c784; --shadow-end: #66bb6a; }*/
/*.services .services-grid .service-sub-grid .service-card:nth-child(2) { --shadow-start: #64b5f6; --shadow-end: #42a5f5; }*/
/*.services .services-grid .service-card:nth-child(4) { --shadow-start: #ffb6c1; --shadow-end: #ffa7b6; }*/
/*.services .services-grid .service-card:nth-child(5) { --shadow-start: #b4e7d4; --shadow-end: #98dfc3; }*/
/*.services .services-grid .service-card:nth-child(6) { --shadow-start: #e0bbf0; --shadow-end: #d7a6eb; }*/

/*.services .services-grid .service-card { --shadow-start: #a15bc6; --shadow-end: #ccc1de; }*/
.services .services-grid .service-card { --shadow-start: var(--azure); --shadow-end: var(--pastel-grey-cyan); }

/* Create a blurred gradient pseudo-shadow behind each Expertise card */
.services .services-grid .service-card.glass { position: relative; z-index: 0; }
.services .services-grid .service-card.glass::after {
  content: "";
  position: absolute;
  inset: -8px; /* extend slightly for a natural glow */
  border-radius: inherit;
  pointer-events: none;
  background: radial-gradient(120% 120% at 50% 110%,
    color-mix(in srgb, var(--shadow-start, #64b5f6) var(--svc-shadow-mix-start, 28%), transparent) 0%,
    color-mix(in srgb, var(--shadow-end, #42a5f5) var(--svc-shadow-mix-end, 28%), transparent) 55%,
    transparent 72%
  );
  filter: blur(var(--svc-shadow-blur, 20px));
  opacity: var(--svc-shadow-opacity, 0.48);
  transform: translateY(8px);
  z-index: -1;
  transition: opacity 0.25s ease, filter 0.25s ease, transform 0.25s ease;
}

/* Elevation on hover/focus within */
.services .services-grid .service-card.glass:hover::after,
.services .services-grid .service-card.glass:focus-within::after {
  opacity: var(--svc-shadow-opacity-hover, 0.62);
  filter: blur(var(--svc-shadow-blur-hover, 24px));
  transform: translateY(10px) scale(1.02);
}

/* Fallback: if color-mix unsupported, keep neutral shadow only */
@supports not (background: color-mix(in srgb, red 50%, transparent)) {
  .services .services-grid .service-card.glass::after { display: none; }
}
