/* NexisGrow-aligned palette: off-white #f8fafc, charcoal #111, brand red #E30613 */
:root {
  --bg-main: #f8fafc;
  --bg-alt: #f1f0ed;
  --bg-elevated: #ffffff;
  --primary: #e30613;
  --primary-hover: #b8050f;
  --primary-soft: rgba(227, 6, 19, 0.12);
  --text-main: #111111;
  --text-muted: #525252;
  --border-dark: #111111;
  --success: #15803d;

  /* Card / work strip tints — stay warm, low saturation */
  --accent-1: #fecdd3;
  --accent-2: #e7e5e4;
  --accent-3: #fde68a;
  --accent-4: #d6d3d1;

  --br-box: 24px;
  --br-btn: 9999px;
  --br-pill: 9999px;

  --shadow-classic: 4px 4px 0 var(--border-dark);
  --shadow-hover: 6px 6px 0 var(--border-dark);
  --shadow-active: 0 0 0 var(--border-dark);

  --font-body: 'Inter', system-ui, -apple-system, sans-serif;
  --font-display: 'Poppins', 'Inter', system-ui, sans-serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 100px;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-main);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: 800;
  line-height: 1.1;
  color: var(--text-main);
  letter-spacing: -0.03em;
}

.logo,
.btn,
.hero-badge,
.section-title,
.hero-title,
.about-title,
.modal-title {
  font-family: var(--font-display);
}

a {
  text-decoration: none;
  color: inherit;
  transition: all 0.2s ease;
}

ul {
  list-style: none;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Background Grids */
.bg-grid {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: 40px 40px;
  background-image:
    linear-gradient(to right, rgba(17, 17, 17, 0.04) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(17, 17, 17, 0.04) 1px, transparent 1px);
  z-index: 1;
  pointer-events: none;
  border-radius: var(--br-box);
}

/* Buttons (Neubrutalism) */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  border-radius: var(--br-btn);
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.15s ease-out;
  border: 2px solid var(--border-dark);
  box-shadow: var(--shadow-classic);
  color: var(--text-main);
  background-color: var(--bg-elevated);
}

.btn:active {
  box-shadow: var(--shadow-active);
  transform: translate(4px, 4px);
}

.btn-primary {
  background-color: var(--primary);
  color: white;
  border-color: var(--border-dark);
}

.btn-primary:hover {
  background-color: var(--primary-hover);
  box-shadow: var(--shadow-hover);
  transform: translate(-2px, -2px);
}

.btn-primary:active {
  box-shadow: var(--shadow-active);
  transform: translate(4px, 4px);
}

.btn-secondary {
  background-color: var(--bg-elevated);
  color: var(--text-main);
}

.btn-secondary:hover {
  box-shadow: var(--shadow-hover);
  transform: translate(-2px, -2px);
}

/* Navbar */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  padding: 24px 0;
  background-color: var(--bg-main);
  border-bottom: 2px solid transparent;
  transition: all 0.2s ease;
}

.navbar.scrolled {
  padding: 16px 0;
  border-bottom: 2px solid var(--border-dark);
  box-shadow: 0 4px 0 rgba(17, 17, 17, 0.04);
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  position: relative;
  flex-wrap: wrap;
}

.logo {
  font-size: 1.8rem;
  font-weight: 900;
  color: var(--text-main);
  letter-spacing: -1.5px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.logo-mark {
  width: 24px;
  height: 24px;
  color: var(--primary);
  flex-shrink: 0;
}

.nav-links {
  display: flex;
  gap: 32px;
}

.nav-link {
  font-weight: 600;
  color: var(--text-muted);
}

.nav-link:hover {
  color: var(--text-main);
}

.nav-link.active {
  color: var(--text-main);
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 2px solid var(--border-dark);
  border-radius: 12px;
  background: var(--bg-elevated);
  box-shadow: 3px 3px 0 var(--border-dark);
  cursor: pointer;
  flex-shrink: 0;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.hamburger:hover {
  box-shadow: 4px 4px 0 var(--border-dark);
  transform: translate(-1px, -1px);
}

.hamburger:active {
  box-shadow: var(--shadow-active);
  transform: translate(2px, 2px);
}

.hamburger-bar {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--text-main);
  border-radius: 1px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.hamburger[aria-expanded="true"] .hamburger-bar:nth-of-type(1) {
  transform: translateY(7px) rotate(45deg);
}

.hamburger[aria-expanded="true"] .hamburger-bar:nth-of-type(2) {
  opacity: 0;
}

.hamburger[aria-expanded="true"] .hamburger-bar:nth-of-type(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.nav-demo-btn {
  flex-shrink: 0;
}

/* Hero Section */
.hero {
  padding-top: 120px;
  padding-bottom: 60px;
  background-color: var(--bg-main);
}

.hero-box {
  position: relative;
  background-color: var(--primary);
  border-radius: var(--br-box);
  padding: 80px 40px;
  text-align: center;
  border: 4px solid var(--border-dark);
  box-shadow: 8px 8px 0px var(--border-dark);
  overflow: hidden;
}

.hero-content {
  position: relative;
  z-index: 10;
  max-width: 800px;
  margin: 0 auto;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: var(--br-pill);
  background-color: var(--bg-elevated);
  border: 2px solid var(--border-dark);
  color: var(--text-main);
  font-size: 0.9rem;
  font-weight: 700;
  margin-bottom: 24px;
  box-shadow: 2px 2px 0 var(--border-dark);
}

.hero-title {
  font-size: clamp(3rem, 7vw, 5.5rem);
  font-weight: 900;
  color: white;
  margin-bottom: 24px;
  line-height: 1.05;
  text-shadow: 3px 3px 0px var(--border-dark);
}

.hero-subtitle {
  font-size: clamp(1.1rem, 2vw, 1.4rem);
  color: rgba(255, 255, 255, 0.95);
  font-weight: 600;
  max-width: 650px;
  margin: 0 auto 40px auto;
  text-shadow: 1px 1px 0 rgba(17, 17, 17, 0.25);
}

.hero-ctas {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
}

.hero-ctas .btn-secondary {
  background-color: var(--bg-elevated);
}

/* Services Section */
.services {
  padding: 100px 0;
  background-color: var(--bg-alt);
  border-top: 4px solid var(--border-dark);
  border-bottom: 4px solid var(--border-dark);
}

.section-header {
  text-align: center;
  margin-bottom: 60px;
}

.section-title {
  font-size: clamp(2.5rem, 5vw, 4rem);
  margin-bottom: 16px;
}

.section-subtitle {
  color: var(--text-muted);
  font-size: 1.2rem;
  font-weight: 500;
  max-width: 600px;
  margin: 0 auto;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
  gap: 32px;
}

.services-grid--primary {
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
}

.service-title--featured {
  font-size: 1.45rem;
  min-height: 0;
  line-height: 1.22;
}

.service-card {
  background-color: var(--bg-elevated);
  border: 3px solid var(--border-dark);
  border-radius: var(--br-box);
  padding: 32px;
  transition: all 0.2s ease;
  box-shadow: var(--shadow-classic);
  position: relative;
  display: flex;
  flex-direction: column;
}

.service-card:hover {
  transform: translateY(-4px) translateX(-4px);
  box-shadow: var(--shadow-hover);
}

.service-icon-wrapper {
  width: 100%;
  height: 160px;
  border-radius: 16px;
  border: 3px solid var(--border-dark);
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.service-icon-wrapper svg {
  width: 64px;
  height: 64px;
  color: var(--border-dark);
  z-index: 2;
}

.service-card:nth-child(1) .service-icon-wrapper { background-color: var(--accent-1); }
.service-card:nth-child(2) .service-icon-wrapper { background-color: var(--accent-2); }
.service-card:nth-child(3) .service-icon-wrapper { background-color: var(--accent-3); }
.service-card:nth-child(4) .service-icon-wrapper { background-color: var(--accent-4); }

.service-title {
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: 12px;
}

.service-desc {
  color: var(--text-muted);
  font-size: 1rem;
  font-weight: 500;
}

/* Footer */
.footer {
  padding: 80px 0 40px 0;
  background-color: var(--bg-elevated);
  border-top: 1px solid rgba(17, 17, 17, 0.08);
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 40px;
  margin-bottom: 60px;
  align-items: start;
}

.footer-brand .footer-tagline {
  margin-top: 16px;
  font-weight: 700;
  color: var(--text-main);
}

.footer-brand p {
  color: var(--text-muted);
  font-weight: 500;
  margin-top: 16px;
  font-size: 1rem;
  max-width: 300px;
}

.footer-col h4 {
  font-size: 1.2rem;
  margin-bottom: 24px;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-links a {
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.95rem;
}

.footer-links a:hover {
  color: var(--primary);
  text-decoration: underline;
  text-decoration-thickness: 2px;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 32px;
  border-top: 3px solid var(--border-dark);
  font-weight: 600;
  font-size: 0.9rem;
}

/* Modal Overlay */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(11, 14, 20, 0.4);
  backdrop-filter: blur(4px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.modal-overlay.open {
  opacity: 1;
  visibility: visible;
}

.modal-content {
  background-color: var(--bg-elevated);
  border: 4px solid var(--border-dark);
  border-radius: var(--br-box);
  padding: 40px;
  width: 90%;
  max-width: 500px;
  position: relative;
  box-shadow: 8px 8px 0px var(--border-dark);
  transform: translateY(20px);
  transition: all 0.3s ease;
}

.modal-overlay.open .modal-content {
  transform: translateY(0);
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: none;
  border: 2px solid var(--border-dark);
  border-radius: 50%;
  width: 36px;
  height: 36px;
  font-size: 1.5rem;
  font-weight: bold;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  background-color: var(--bg-alt);
  color: var(--text-main);
}

.modal-close:hover {
  background-color: var(--primary-soft);
  color: var(--primary);
  transform: scale(1.05);
}

.demo-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Work Section */
.work-card {
  padding: 0;
  overflow: hidden;
}

.work-img {
  height: 200px;
  border-bottom: 3px solid var(--border-dark);
}

.work-img-1 { background-color: var(--accent-1); }
.work-img-2 { background-color: var(--accent-3); }
.work-img-3 { background-color: var(--accent-4); }
.work-img-4 { background-color: var(--accent-2); }

.work-content {
  padding: 24px;
}

/* Section surfaces (replaces inline backgrounds) */
.section-surface--main {
  background-color: var(--bg-main);
  border-top: none;
}

.section-surface--alt {
  background-color: var(--bg-alt);
}

/* About Section — charcoal marketing block */
.about-box {
  background-color: var(--border-dark);
  padding: 40px;
  text-align: left;
  max-width: 900px;
  margin: 0 auto;
}

.about-title {
  font-size: 2.5rem;
  margin-bottom: 16px;
}

.about-content {
  color: #fff;
  font-size: 1.1rem;
  line-height: 1.8;
}

.about-lead {
  margin-bottom: 24px;
  max-width: 100%;
}

.about-list-intro {
  margin-bottom: 16px;
  max-width: 100%;
}

.about-list {
  margin-bottom: 32px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
  list-style: none;
  padding: 0;
}

.about-list li {
  display: flex;
  align-items: center;
  gap: 8px;
}

.about-subtitle {
  font-size: 1.1rem;
  max-width: 100%;
  margin-bottom: 0;
}

.about-box .about-callout {
  font-size: 1.2rem;
  margin: 0;
  padding: 16px;
  background: rgba(0, 0, 0, 0.1);
  border-radius: 8px;
  color: #fff;
  text-shadow: none;
  max-width: 100%;
}

/* Contact — red marketing band + light panel */
.contact-section {
  background-color: var(--primary);
  border-top: 4px solid var(--border-dark);
  border-bottom: none;
}

.contact-panel {
  background-color: var(--bg-elevated);
  color: var(--text-main);
}

.hero-box.contact-panel .hero-title {
  color: var(--text-main);
  text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.06);
}

.hero-box.contact-panel .hero-subtitle {
  color: var(--text-muted);
  text-shadow: none;
}

.contact-panel__title {
  color: var(--text-main);
  text-shadow: 2px 2px 0 rgba(17, 17, 17, 0.06);
}

.contact-panel__lead {
  color: var(--text-muted);
  text-shadow: none;
}

.contact-pitch {
  color: var(--primary);
  font-weight: 700;
  margin-bottom: 24px;
}

.demo-success {
  color: var(--success);
  font-weight: 700;
  margin-top: 16px;
  text-align: center;
}

.contact-form {
  max-width: 500px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.modal-title {
  font-size: 2rem;
  margin-bottom: 8px;
}

.modal-intro {
  font-size: 1rem;
  margin-bottom: 24px;
}

.contact-input {
  padding: 16px 24px;
  border-radius: var(--br-pill);
  border: 3px solid var(--border-dark);
  font-size: 1rem;
  font-family: var(--font-body);
  width: 100%;
  box-shadow: 4px 4px 0 var(--border-dark);
  outline: none;
  background-color: var(--bg-elevated);
  color: var(--text-main);
}

.contact-input::placeholder {
  color: var(--text-muted);
}

textarea.contact-input {
  min-height: 120px;
  border-radius: 16px;
  resize: vertical;
}

select.contact-input {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23111' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 18px center;
  padding-right: 40px;
}

.section-footer-cta {
  text-align: center;
  margin-top: 40px;
}

.about-more-wrap {
  margin-top: 28px;
}

.about-more-wrap .btn {
  display: inline-flex;
}

.contact-alt-link {
  margin-top: 16px;
  text-align: center;
}

.contact-alt-link__a {
  color: var(--text-muted);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

.contact-alt-link__a:hover {
  color: var(--primary);
}

/* Inner pages — hero */
.page-hero {
  padding-top: 120px;
  padding-bottom: 48px;
  background-color: var(--bg-main);
}

.page-hero .hero-box {
  padding: 48px 32px;
  text-align: center;
}

.page-hero .hero-title {
  font-size: clamp(1.75rem, 4vw, 3rem);
}

.page-hero .hero-subtitle {
  font-size: clamp(1rem, 2vw, 1.2rem);
  margin-bottom: 0;
}

.page-hero--legal {
  padding-top: 100px;
  padding-bottom: 40px;
  background-color: var(--border-dark);
}

.page-hero--legal .page-hero-inner {
  text-align: center;
  max-width: 720px;
  margin: 0 auto;
}

.page-hero--legal .section-title {
  color: #fff;
  margin-bottom: 12px;
}

.page-hero--legal .section-subtitle {
  color: rgba(255, 255, 255, 0.85);
  margin: 0 auto;
}

/* Two-column layouts */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: center;
}

.two-col--about-visual .two-col__visual {
  min-height: 280px;
  border-radius: var(--br-box);
  border: 3px solid var(--border-dark);
  box-shadow: var(--shadow-classic);
  background: linear-gradient(135deg, var(--accent-1), var(--accent-3));
}

/* Service detail blocks */
.service-detail {
  padding: 80px 0;
  border-top: 4px solid var(--border-dark);
}

.service-detail:last-of-type {
  border-bottom: 4px solid var(--border-dark);
}

.service-detail__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: 48px;
  align-items: center;
}

.service-detail--reverse .service-detail__grid {
  direction: rtl;
}

.service-detail--reverse .service-detail__text,
.service-detail--reverse .service-detail__visual {
  direction: ltr;
}

.service-detail__visual-inner {
  min-height: 220px;
  border-radius: var(--br-box);
  border: 3px solid var(--border-dark);
  box-shadow: var(--shadow-classic);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px;
}

.service-detail__visual-inner svg {
  width: 80px;
  height: 80px;
  color: var(--border-dark);
}

.service-detail:nth-of-type(4n+1) .service-detail__visual-inner { background-color: var(--accent-1); }
.service-detail:nth-of-type(4n+2) .service-detail__visual-inner { background-color: var(--accent-2); }
.service-detail:nth-of-type(4n+3) .service-detail__visual-inner { background-color: var(--accent-3); }
.service-detail:nth-of-type(4n+4) .service-detail__visual-inner { background-color: var(--accent-4); }

.service-detail__title {
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  margin-bottom: 16px;
}

.service-detail__lead {
  color: var(--text-muted);
  font-weight: 500;
  margin-bottom: 16px;
  line-height: 1.65;
}

.sub-service-list {
  margin: 20px 0 24px;
  padding-left: 1.25rem;
  list-style: disc;
  color: var(--text-main);
  font-weight: 600;
}

.sub-service-list li {
  margin-bottom: 8px;
  color: var(--text-muted);
  font-weight: 500;
}

.sub-service-list li::marker {
  color: var(--primary);
}

/* Portfolio */
.work-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-bottom: 40px;
}

.work-filter-btn {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.875rem;
  padding: 10px 18px;
  border-radius: var(--br-pill);
  border: 2px solid var(--border-dark);
  background: var(--bg-elevated);
  box-shadow: 3px 3px 0 var(--border-dark);
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.work-filter-btn:hover {
  transform: translate(-1px, -1px);
  box-shadow: 4px 4px 0 var(--border-dark);
}

.work-filter-btn.is-active {
  background: var(--primary);
  color: #fff;
}

.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
  gap: 28px;
}

.project-card.hidden {
  display: none;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.project-tag {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: var(--br-pill);
  border: 2px solid var(--border-dark);
  background: var(--bg-alt);
  color: var(--text-main);
}

/* Stats bar */
.stats-bar {
  padding: 48px 0;
  background-color: var(--border-dark);
  border-top: 4px solid var(--border-dark);
  border-bottom: 4px solid var(--border-dark);
}

.stats-bar__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
  text-align: center;
}

.stats-bar__value {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 900;
  color: #fff;
  margin-bottom: 4px;
}

.stats-bar__label {
  color: rgba(255, 255, 255, 0.8);
  font-weight: 600;
  font-size: 0.95rem;
}

/* Stats inside contact page (replaces map placeholder — bordered card, matches site UI) */
.stats-bar.stats-bar--card {
  padding: 36px 24px;
  margin-top: 48px;
  background-color: var(--bg-elevated);
  border: 3px solid var(--border-dark);
  border-radius: var(--br-box);
  box-shadow: var(--shadow-classic);
  border-top-width: 3px;
  border-bottom-width: 3px;
}

.stats-bar--card .stats-bar__value {
  color: var(--text-main);
}

.stats-bar--card .stats-bar__label {
  color: var(--text-muted);
}

/* Contact page */
.contact-page-section {
  padding: 80px 0;
  background-color: var(--bg-alt);
  border-top: 4px solid var(--border-dark);
}

.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  gap: 40px;
  align-items: start;
}

.contact-info-card {
  background: var(--bg-elevated);
  border: 3px solid var(--border-dark);
  border-radius: var(--br-box);
  padding: 32px;
  box-shadow: var(--shadow-classic);
}

.contact-info-card h3 {
  font-size: 1.35rem;
  margin-bottom: 20px;
}

.contact-info-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.contact-info-list a {
  color: var(--primary);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-thickness: 2px;
}

.contact-info-list p {
  color: var(--text-muted);
  font-weight: 500;
}

.social-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 24px;
}

.social-links a {
  font-weight: 700;
  font-size: 0.875rem;
  padding: 8px 14px;
  border: 2px solid var(--border-dark);
  border-radius: var(--br-pill);
  background: var(--bg-alt);
}

.social-links a:hover {
  background: var(--primary-soft);
  color: var(--primary);
}

.contact-form-card {
  background: var(--bg-elevated);
  border: 3px solid var(--border-dark);
  border-radius: var(--br-box);
  padding: 32px;
  box-shadow: var(--shadow-classic);
}

.contact-form-card h3 {
  font-size: 1.35rem;
  margin-bottom: 8px;
}

.contact-form-card .section-subtitle {
  margin: 0 0 24px;
  text-align: left;
  max-width: none;
}

.map-placeholder {
  margin-top: 48px;
  height: 200px;
  border-radius: var(--br-box);
  border: 3px solid var(--border-dark);
  box-shadow: var(--shadow-classic);
  background: linear-gradient(90deg, var(--accent-2), var(--accent-4));
}

/* Legal page */
.legal-page {
  padding-bottom: 80px;
}

.legal-layout {
  display: grid;
  grid-template-columns: 200px minmax(0, 1fr);
  gap: 48px;
  align-items: start;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

.legal-sidebar {
  position: sticky;
  top: 100px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.legal-sidebar a {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--text-muted);
  padding: 10px 12px;
  border-radius: 12px;
  border: 2px solid transparent;
}

.legal-sidebar a:hover {
  color: var(--text-main);
  background: var(--bg-alt);
}

.legal-sidebar a.is-active {
  color: var(--text-main);
  border-color: var(--border-dark);
  background: var(--bg-elevated);
  box-shadow: 3px 3px 0 var(--border-dark);
}

.legal-content {
  max-width: 720px;
}

.legal-section {
  padding-top: 48px;
  margin-bottom: 48px;
  scroll-margin-top: 100px;
}

.legal-section:first-of-type {
  padding-top: 24px;
}

.legal-section h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 3px solid var(--border-dark);
}

.legal-section h3 {
  font-size: 1.15rem;
  margin: 24px 0 12px;
}

.legal-section p,
.legal-section li {
  color: var(--text-muted);
  font-weight: 500;
  line-height: 1.7;
  margin-bottom: 12px;
}

.legal-section ul {
  list-style: disc;
  padding-left: 1.25rem;
  margin-bottom: 16px;
}

.legal-updated {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 24px;
}

.legal-mobile-nav {
  display: none;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  padding: 16px 24px 0;
  margin-bottom: 8px;
}

.legal-mobile-nav a {
  font-size: 0.8rem;
  font-weight: 700;
  padding: 8px 12px;
  border: 2px solid var(--border-dark);
  border-radius: var(--br-pill);
  background: var(--bg-elevated);
}

/* Believe cards (about) */
.believe-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  gap: 28px;
}

/* Animations */
.reveal {
  opacity: 0;
  transform: translateY(40px) scale(0.95);
  transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.reveal.active {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }
.delay-3 { transition-delay: 0.3s; }

/* Tablet & small laptop (does not apply at desktop ≥1025px) */
@media (max-width: 1024px) {
  html {
    scroll-padding-top: 80px;
  }

  .container {
    padding: 0 18px;
  }

  .navbar {
    padding: 14px 0;
  }

  .navbar.scrolled {
    padding: 12px 0;
  }

  .logo {
    font-size: 1.35rem;
    letter-spacing: -1px;
  }

  .logo-mark {
    width: 22px;
    height: 22px;
  }

  .nav-links {
    gap: 20px;
  }

  .nav-link {
    font-size: 0.875rem;
  }

  .btn {
    padding: 11px 18px;
    font-size: 0.875rem;
  }

  .hero {
    padding-top: 92px;
    padding-bottom: 48px;
  }

  .hero-box {
    padding: clamp(2rem, 6vw, 3.5rem) clamp(1rem, 4vw, 1.5rem);
    border-width: 3px;
    box-shadow: 6px 6px 0 var(--border-dark);
    border-radius: 18px;
  }

  .hero-badge {
    font-size: 0.75rem;
    padding: 6px 12px;
    margin-bottom: 16px;
  }

  .hero-title {
    font-size: clamp(1.65rem, 5vw + 0.5rem, 3.25rem);
    margin-bottom: 16px;
    text-shadow: 2px 2px 0 var(--border-dark);
  }

  .hero-subtitle {
    font-size: clamp(0.9rem, 2vw + 0.5rem, 1.2rem);
    margin-bottom: 28px;
  }

  .hero-ctas {
    gap: 12px;
    flex-wrap: wrap;
    justify-content: center;
  }

  .services {
    padding: 56px 0;
  }

  .section-header {
    margin-bottom: 36px;
  }

  .section-title {
    font-size: clamp(1.35rem, 3.5vw + 0.5rem, 2.5rem);
    margin-bottom: 12px;
    line-height: 1.12;
  }

  .section-subtitle {
    font-size: clamp(0.9rem, 1.5vw + 0.5rem, 1.1rem);
    line-height: 1.5;
    padding: 0 4px;
  }

  .services-grid,
  .services-grid--primary {
    gap: 20px;
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
  }

  .service-card {
    padding: 22px;
    border-radius: 18px;
    border-width: 2px;
    box-shadow: 3px 3px 0 var(--border-dark);
  }

  .service-card:hover {
    transform: translateY(-2px) translateX(-2px);
    box-shadow: 4px 4px 0 var(--border-dark);
  }

  .service-icon-wrapper {
    height: 130px;
    margin-bottom: 16px;
    border-width: 2px;
    border-radius: 12px;
  }

  .service-icon-wrapper svg {
    width: 52px;
    height: 52px;
  }

  .service-title {
    font-size: 1.15rem;
    margin-bottom: 10px;
  }

  .service-title--featured {
    font-size: 1.05rem;
    line-height: 1.25;
  }

  .service-desc {
    font-size: 0.9rem;
    line-height: 1.55;
  }

  .work-img {
    height: 160px;
  }

  .work-content {
    padding: 18px;
  }

  .about-box {
    padding: clamp(1.25rem, 4vw, 2rem);
    border-radius: 18px;
  }

  .about-title {
    font-size: clamp(1.35rem, 3vw + 0.5rem, 2rem);
    margin-bottom: 12px;
  }

  .about-content {
    font-size: 0.95rem;
    line-height: 1.65;
  }

  .about-list {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 160px), 1fr));
    gap: 10px;
  }

  .about-box .about-callout {
    font-size: 1rem;
    padding: 12px 14px;
  }

  #contact .hero-box {
    padding: clamp(1.25rem, 4vw, 2.25rem) clamp(1rem, 3vw, 1.25rem);
    border-radius: 18px;
  }

  #contact .hero-title {
    font-size: clamp(1.15rem, 3vw + 0.5rem, 1.85rem);
  }

  #contact .hero-subtitle {
    font-size: 0.9rem;
    margin-bottom: 12px;
  }

  .contact-pitch {
    font-size: 0.85rem;
    margin-bottom: 16px;
  }

  .contact-form {
    gap: 12px;
  }

  .contact-input {
    padding: 12px 18px;
    font-size: 0.9rem;
    border-width: 2px;
    box-shadow: 3px 3px 0 var(--border-dark);
  }

  .footer {
    padding: 48px 0 32px;
  }

  .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px 24px;
    margin-bottom: 40px;
  }

  .footer-brand {
    grid-column: 1 / -1;
  }

  .footer-col h4 {
    font-size: 1.05rem;
    margin-bottom: 14px;
  }

  .footer-links {
    gap: 10px;
  }

  .footer-links a {
    font-size: 0.875rem;
  }

  .footer-bottom {
    padding-top: 24px;
    font-size: 0.85rem;
  }

  .modal-content {
    padding: 28px 20px 32px;
    width: min(100%, 480px);
    margin: 16px;
    max-height: min(90vh, 640px);
    max-height: min(90dvh, 640px);
    overflow-y: auto;
    border-width: 3px;
    border-radius: 18px;
    box-shadow: 6px 6px 0 var(--border-dark);
  }

  .modal-title {
    font-size: clamp(1.25rem, 3vw, 1.65rem);
    padding-right: 40px;
  }

  .modal-intro {
    font-size: 0.9rem;
    margin-bottom: 18px;
  }

  .modal-close {
    top: 12px;
    right: 12px;
    width: 34px;
    height: 34px;
    font-size: 1.35rem;
  }

  .demo-form {
    gap: 12px;
  }

  .bg-grid {
    background-size: 28px 28px;
  }
}

@media (max-width: 900px) {
  .services-grid,
  .services-grid--primary {
    grid-template-columns: 1fr;
  }

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

  .two-col {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .service-detail__grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .service-detail--reverse .service-detail__grid {
    direction: ltr;
  }

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

  .stats-bar__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .legal-layout {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 0 18px;
  }

  .legal-sidebar {
    display: none;
  }

  .legal-mobile-nav {
    display: flex;
  }

  .project-grid {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  }
}

/* Phone (stacks nav CTA, single-column footer) */
@media (max-width: 768px) {
  html {
    scroll-padding-top: 72px;
  }

  .container {
    padding: 0 16px;
  }

  .hamburger {
    display: inline-flex;
  }

  .nav-links {
    display: none;
    order: 10;
    width: 100%;
    flex-basis: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 16px 0 8px;
    margin: 0;
    border-top: 2px solid var(--border-dark);
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links li {
    width: 100%;
  }

  .nav-links .nav-link {
    display: block;
    padding: 12px 0;
  }

  .nav-container {
    justify-content: flex-start;
    align-items: center;
    gap: 8px;
  }

  /* One row: Logo (left) | Book a Demo | Hamburger — DOM is logo, hamburger, ul, btn */
  .nav-container .logo {
    order: 1;
    margin-right: auto;
    min-width: 0;
  }

  .nav-container .nav-demo-btn {
    order: 2;
    flex-shrink: 0;
  }

  .nav-container .hamburger {
    order: 3;
    flex-shrink: 0;
  }

  .hero {
    padding-top: 80px;
    padding-bottom: 36px;
  }

  .hero-box {
    padding: 1.5rem 1rem;
  }

  .hero-badge {
    font-size: 0.7rem;
    padding: 5px 10px;
    text-align: center;
    max-width: 100%;
  }

  .hero-title {
    font-size: clamp(1.5rem, 6vw + 0.35rem, 2.35rem);
  }

  .hero-subtitle {
    font-size: 0.9rem;
    margin-bottom: 22px;
  }

  .hero-ctas {
    flex-direction: column;
    align-items: center;
    width: 100%;
  }

  .hero-ctas .btn {
    width: 100%;
    max-width: min(320px, 100%);
  }

  .services {
    padding: 40px 0;
  }

  .section-header {
    margin-bottom: 28px;
  }

  .service-card {
    padding: 16px 16px 18px;
  }

  .service-icon-wrapper {
    height: 100px;
    margin-bottom: 12px;
  }

  .service-icon-wrapper svg {
    width: 40px;
    height: 40px;
  }

  .service-title {
    font-size: 1rem;
  }

  .service-title--featured {
    font-size: 0.95rem;
  }

  .service-desc {
    font-size: 0.8125rem;
  }

  .work-img {
    height: 140px;
  }

  .work-content {
    padding: 14px 16px;
  }

  .about-list {
    grid-template-columns: 1fr;
  }

  .page-hero {
    padding-top: 88px;
    padding-bottom: 36px;
  }

  .page-hero .hero-box {
    padding: 28px 20px;
  }

  .service-detail {
    padding: 48px 0;
  }

  .stats-bar__grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  /* Contact page stats card: row1 clients | team, row2 years | projects */
  .stats-bar--card .stats-bar__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px 14px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .footer-brand {
    grid-column: auto;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 10px;
    text-align: center;
  }

  .modal-content {
    padding: 22px 16px 26px;
    margin: 12px;
    width: min(100%, 100vw - 24px);
  }

  .modal-title {
    font-size: 1.1rem;
    padding-right: 36px;
  }

  .modal-intro {
    font-size: 0.8rem;
    margin-bottom: 14px;
  }

  .modal-close {
    width: 32px;
    height: 32px;
    font-size: 1.2rem;
    top: 10px;
    right: 10px;
  }
}

@media (max-width: 480px) {
  .hero-box {
    padding: 1.25rem 0.875rem;
  }

  .section-title {
    font-size: clamp(1.2rem, 5vw + 0.35rem, 1.65rem);
  }

  .bg-grid {
    background-size: 22px 22px;
  }
}

/* Desktop: tighter type & spacing (1025px+ only — tablet/phone use max-width rules above) */
@media (min-width: 1025px) {
  html {
    scroll-padding-top: 88px;
  }

  .container {
    max-width: 1080px;
    padding: 0 20px;
  }

  body {
    font-size: 15px;
    line-height: 1.55;
  }

  h1, h2, h3, h4, h5, h6 {
    letter-spacing: -0.6px;
  }

  .btn {
    padding: 10px 20px;
    font-size: 0.875rem;
  }

  .navbar {
    padding: 14px 0;
  }

  .navbar.scrolled {
    padding: 10px 0;
  }

  .logo {
    font-size: 1.35rem;
    letter-spacing: -1px;
  }

  .logo-mark {
    width: 20px;
    height: 20px;
  }

  .nav-links {
    gap: 22px;
  }

  .nav-link {
    font-size: 0.875rem;
  }

  .hero {
    padding-top: 96px;
    padding-bottom: 48px;
  }

  .hero-box {
    padding: 48px 36px;
    border-radius: 18px;
    border-width: 3px;
    box-shadow: 6px 6px 0 var(--border-dark);
  }

  .hero-content {
    max-width: 640px;
  }

  .hero-badge {
    font-size: 0.75rem;
    padding: 6px 12px;
    margin-bottom: 18px;
  }

  .hero-title {
    font-size: clamp(2rem, 3.8vw, 3rem);
    margin-bottom: 18px;
    text-shadow: 2px 2px 0 var(--border-dark);
  }

  .hero-subtitle {
    font-size: clamp(0.95rem, 1.1vw, 1.1rem);
    margin-bottom: 28px;
    max-width: 520px;
  }

  .hero-ctas {
    gap: 12px;
  }

  .services {
    padding: 64px 0;
  }

  .section-header {
    margin-bottom: 40px;
  }

  .section-title {
    font-size: clamp(1.75rem, 2.8vw, 2.5rem);
    margin-bottom: 12px;
  }

  .section-subtitle {
    font-size: 1rem;
    max-width: 520px;
  }

  #services .services-grid--primary {
    gap: 22px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  #work .services-grid {
    gap: 22px;
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .project-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px;
  }

  .service-card {
    padding: 22px;
    border-radius: 18px;
    border-width: 2px;
  }

  .service-icon-wrapper {
    height: 120px;
    margin-bottom: 16px;
    border-width: 2px;
    border-radius: 12px;
  }

  .service-icon-wrapper svg {
    width: 48px;
    height: 48px;
  }

  .service-title {
    font-size: 1.15rem;
    margin-bottom: 10px;
  }

  .service-title--featured {
    font-size: 1.08rem;
    line-height: 1.25;
  }

  .service-desc {
    font-size: 0.875rem;
    line-height: 1.55;
  }

  .work-img {
    height: 150px;
  }

  .work-content {
    padding: 18px;
  }

  .about-box {
    padding: 32px 36px;
    border-radius: 18px;
  }

  .about-title {
    font-size: 1.75rem;
    margin-bottom: 12px;
  }

  .about-content {
    font-size: 0.95rem;
    line-height: 1.65;
  }

  .about-box .about-callout {
    font-size: 1rem;
    padding: 12px 14px;
  }

  #contact .hero-box {
    padding: 40px 36px;
    border-radius: 18px;
  }

  #contact .hero-title {
    font-size: clamp(1.35rem, 2vw, 1.85rem);
  }

  #contact .hero-subtitle {
    font-size: 0.95rem;
    margin-bottom: 14px;
  }

  .contact-pitch {
    font-size: 0.85rem;
    margin-bottom: 18px;
  }

  .contact-form {
    gap: 12px;
    max-width: 420px;
  }

  .contact-input {
    padding: 12px 18px;
    font-size: 0.875rem;
    border-width: 2px;
  }

  .footer {
    padding: 56px 0 32px;
  }

  .footer-grid {
    gap: 28px;
    margin-bottom: 44px;
  }

  .footer-brand .footer-tagline {
    font-size: 0.9rem;
    margin-top: 12px;
  }

  .footer-brand p {
    font-size: 0.875rem;
    margin-top: 12px;
  }

  .footer-col h4 {
    font-size: 1rem;
    margin-bottom: 16px;
  }

  .footer-links {
    gap: 8px;
  }

  .footer-links a {
    font-size: 0.8125rem;
  }

  .footer-bottom {
    padding-top: 24px;
    font-size: 0.8125rem;
  }

  .modal-content {
    padding: 28px 28px 32px;
    max-width: 420px;
    border-width: 3px;
    border-radius: 18px;
    box-shadow: 6px 6px 0 var(--border-dark);
  }

  .modal-close {
    width: 32px;
    height: 32px;
    font-size: 1.25rem;
    top: 12px;
    right: 12px;
  }

  .modal-title {
    font-size: 1.35rem;
  }

  .modal-intro {
    font-size: 0.875rem;
    margin-bottom: 18px;
  }
}
