/* ==========================================================================
   THC Corporate Theme v2 — Design system, RTL-first, Cairo
   Inspired by premium contracting layouts — unique THC brand identity
   ========================================================================== */

/* --- 1. Design tokens --------------------------------------------------- */
:root {
  /* Brand */
  --brand-black: #000000;
  --brand-red: #ff4d4d;
  --brand-red-hover: #e63e3e;
  --brand-red-soft: rgba(255, 77, 77, 0.14);
  --brand-red-glow: rgba(255, 77, 77, 0.35);
  --brand-white: #ffffff;
  --brand-muted: #b8b8b8;
  --brand-soft: #7a7a7a;

  /* Neutrals */
  --bg: #f0f0f0;
  --bg-muted: #e8e8e8;
  --surface: #ffffff;
  --surface-elevated: #fafafa;
  --text: #121212;
  --text-secondary: #3d3d3d;
  --muted: #5c5c5c;
  --border: #e0e0e0;
  --border-strong: #d0d0d0;

  /* Spacing scale */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;
  --space-16: 4rem;

  /* Typography */
  --font: "Cairo", "Segoe UI", Tahoma, Arial, sans-serif;
  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-lg: 1.125rem;
  --text-xl: 1.25rem;
  --text-2xl: 1.5rem;
  --text-3xl: 1.875rem;
  --text-4xl: 2.25rem;
  --text-5xl: 3rem;
  --leading-tight: 1.25;
  --leading-normal: 1.7;
  --leading-relaxed: 1.85;

  /* Layout — sharp edges (matches angular THC logo) */
  --radius-sm: 0;
  --radius: 0;
  --radius-lg: 0;
  --radius-xl: 0;
  --accent: var(--brand-red);
  --accent-soft: var(--brand-red-soft);
  /* Logo mark geometry (from logo.svg polygons) */
  --thc-logo-clip-a: polygon(18% 22%, 68% 8%, 78% 34%, 48% 48%);
  --thc-logo-clip-b: polygon(42% 48%, 78% 34%, 88% 78%, 52% 92%, 28% 72%);
  --thc-logo-clip-mark: polygon(18% 8%, 78% 8%, 88% 78%, 52% 92%, 18% 72%);
  --thc-track-wide: 0.12em;
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.06);
  --shadow: 0 10px 32px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 20px 48px rgba(0, 0, 0, 0.14);
  --shadow-red: 0 8px 24px rgba(255, 77, 77, 0.2);
  --header-h: 72px;
  --container: 1200px;
  --section-px: clamp(1rem, 4vw, 2rem);
  --section-py: clamp(1.5rem, 3.5vw, 2.25rem);
  --section-py-lg: clamp(2rem, 4vw, 2.75rem);
  --transition: 0.22s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* --- 1b. Logo-inspired sharp brand layer -------------------------------- */

.site-header::after {
  content: "";
  position: absolute;
  bottom: 0;
  inset-inline-start: 0;
  width: 72px;
  height: 3px;
  background: var(--brand-red);
  clip-path: polygon(0 0, 100% 0, 82% 100%, 0 100%);
  pointer-events: none;
}

.hero-panel__inner::before {
  content: "";
  position: absolute;
  top: -1.5rem;
  inset-inline-start: -2.5rem;
  width: 88px;
  height: 72px;
  background: var(--brand-red);
  opacity: 0.14;
  clip-path: var(--thc-logo-clip-mark);
  pointer-events: none;
}

.section-heading__eyebrow::before {
  content: "";
  display: inline-block;
  width: 11px;
  height: 11px;
  margin-inline-end: .55rem;
  background: var(--brand-red);
  clip-path: var(--thc-logo-clip-a);
  vertical-align: -1px;
}

/* Angular red accent on entity cards */
.service-card,
.feature-card,
.why-card--large,
.stats-bar__item,
.article-card,
.testimonial-card,
.testimonial-slide,
.project-card,
.glass-card,
.cta-band,
.contact-section {
  position: relative;
}

.service-card::before,
.feature-card::before,
.why-card--large::before,
.stats-bar__item::before,
.article-card::before,
.testimonial-card::before,
.testimonial-slide::before,
.project-card::before,
.glass-card::before {
  content: "";
  position: absolute;
  top: 0;
  inset-inline-start: 0;
  width: 36px;
  height: 3px;
  background: var(--brand-red);
  clip-path: polygon(0 0, 100% 0, 88% 100%, 0 100%);
  z-index: 2;
  pointer-events: none;
}

.intro-section__media-inner::after {
  content: "";
  position: absolute;
  bottom: 12%;
  inset-inline-start: 8%;
  width: 48px;
  height: 40px;
  background: var(--brand-red);
  opacity: 0.55;
  clip-path: var(--thc-logo-clip-b);
  pointer-events: none;
}

.intro-section__media-inner {
  position: relative;
}

.cta-band::after {
  content: "";
  position: absolute;
  bottom: 12%;
  inset-inline-start: 6%;
  width: 40px;
  height: 34px;
  background: var(--brand-red);
  opacity: 0.2;
  clip-path: var(--thc-logo-clip-b);
  pointer-events: none;
  z-index: 0;
}

.site-branding .site-name,
.site-branding .site-slogan {
  letter-spacing: var(--thc-track-wide);
}

/* --- 2. Base & typography ----------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 1rem); }

body.thc-body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--text-base);
  color: var(--text);
  background: var(--bg);
  line-height: var(--leading-normal);
  direction: rtl;
  text-align: start;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

html[dir="ltr"] body.thc-body,
body.thc-body.dir-ltr {
  direction: ltr;
  line-height: 1.65;
}

img { max-width: 100%; height: auto; display: block; }

a {
  color: var(--brand-red);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover, a:focus-visible { color: var(--brand-red-hover); }

h1, h2, h3, h4, h5, h6 {
  color: var(--brand-black);
  line-height: var(--leading-tight);
  font-weight: 800;
}

h1 { font-size: clamp(var(--text-3xl), 5vw, 3.5rem); letter-spacing: -0.02em; }
h2 { font-size: clamp(var(--text-2xl), 3.5vw, 2.25rem); letter-spacing: -0.015em; }
h3 { font-size: var(--text-xl); }
h4 { font-size: var(--text-lg); }

.prose { max-width: 62ch; }
.prose p { line-height: var(--leading-relaxed); color: var(--text-secondary); }

p.lead {
  font-size: var(--text-lg);
  color: var(--text-secondary);
  line-height: var(--leading-relaxed);
}

.container {
  width: min(100% - (var(--section-px) * 2), var(--container));
  margin-inline: auto;
  padding-inline: 0;
}

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

.visually-hidden.focusable:active,
.visually-hidden.focusable:focus {
  position: fixed !important;
  top: 1rem;
  inset-inline-start: 50%;
  transform: translateX(-50%);
  z-index: 9999;
  width: auto !important;
  height: auto !important;
  clip: auto !important;
  background: var(--brand-black);
  color: var(--brand-white);
  padding: .75rem 1.25rem;
  border-radius: var(--radius-sm);
  white-space: normal !important;
}

/* --- 3. Section bands & rhythm ------------------------------------------ */
.section-band {
  width: 100%;
  padding-block: var(--section-py);
}

.path-frontpage .main-content,
.front-content {
  padding: 0;
  max-width: none;
  width: 100%;
}

.section-band--muted {
  background: var(--surface);
  border-block: 1px solid var(--border);
}

.section-band--dark {
  background: var(--brand-black);
  color: rgba(255, 255, 255, 0.88);
}

.section-band--dark h2,
.section-band--dark h3 { color: #fff; }

.section-band--alt {
  background: linear-gradient(180deg, var(--surface-elevated) 0%, var(--bg) 100%);
}

.section-band--tight {
  padding-block: clamp(1.25rem, 3vw, 2rem);
}

.front-content > .block { margin: 0; }

/* --- 4. Drupal admin clutter -------------------------------------------- */
/* Header region: only branding belongs in .site-branding (display:contents grid) */
.site-branding .block:not(.block-system-branding-block):not(.block-branding),
.region-header .block-search,
.region-header .block-system-breadcrumb-block,
.region-header .block-page-title-block,
.region-header .block-help,
.region-header .block-node-syndicate-block,
.region-header .block-system-menu-blockaccount,
.region-primary-menu .block-search,
.block-local-tasks-block,
.block-local-actions-block,
.path-frontpage .block-page-title-block,
.path-frontpage h1.page-title,
.path-frontpage .breadcrumb,
.path-frontpage nav.breadcrumb,
.path-frontpage ol.breadcrumb,
.path-frontpage .block-system-breadcrumb-block,
.path-frontpage .block-system-menu-blockaccount,
.path-frontpage .site-branding .block-system-menu-blockaccount,
.service-card .node__links,
.service-card ul.links,
.service-card .links,
article.service-card .node__links,
.thc-hidden-footer-menu,
.footer-bottom .block-system-powered-by-block,
.footer-bottom .block[id*="footer_msg"],
.thc-header-clutter,
.thc-front-hidden,
.front-content .node--type-page > h1.visually-hidden {
  display: none !important;
}

/* --- 5. Header & navigation --------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  height: var(--header-h);
  background: rgba(0, 0, 0, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(255, 77, 77, 0.18);
}

.site-header.is-scrolled {
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
}

.header-inner {
  height: var(--header-h);
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  column-gap: var(--space-4);
}

/* Flatten Drupal region wrappers so logo, nav, and lang share one grid row */
.site-branding,
.site-branding > div,
.main-nav > div {
  display: contents;
}

.site-branding .block-branding,
.site-branding .block-system-branding-block {
  grid-column: 1;
  grid-row: 1;
  display: flex;
  align-items: center;
  gap: var(--space-3);
  min-width: 0;
  justify-self: start;
}

.block-branding {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  min-width: 0;
}

.site-branding .block,
.site-branding .block-system-branding-block { margin: 0; }

.site-branding img,
.block-branding .site-logo img {
  height: 44px;
  width: auto;
  max-width: 170px;
  object-fit: contain;
  transition: height var(--transition);
}

.site-branding .site-name,
.block-branding .site-name {
  font-weight: 700;
  font-size: var(--text-sm);
  color: var(--brand-white);
  white-space: nowrap;
}

.main-nav {
  grid-column: 2;
  grid-row: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
  flex-wrap: nowrap;
  min-width: 0;
  justify-self: center;
  width: 100%;
}

.main-nav .block { margin: 0; }
.main-nav h2 { display: none; }

.nav-toggle {
  grid-column: 3;
  grid-row: 1;
  justify-self: end;
}

/* Language switcher — same row as logo and nav */
.thc-language-switcher,
.block-language {
  grid-column: 3;
  grid-row: 1;
  margin: 0;
  flex-shrink: 0;
  justify-self: end;
  align-self: center;
}

.main-nav .thc-language-switcher,
.main-nav .block-language {
  grid-column: auto;
  grid-row: auto;
  justify-self: auto;
  margin-inline-start: var(--space-3);
}

.thc-language-switcher h2,
.block-language h2 { display: none; }

.thc-language-switcher ul,
.thc-language-switcher .thc-lang-toggle,
.block-language ul.links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: inline-flex;
  align-items: center;
}

.thc-language-switcher li,
.block-language ul.links li { margin: 0; }

.thc-language-switcher a,
.thc-language-switcher .language-link,
.block-language ul.links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.25rem;
  padding: .35rem .7rem;
  border-radius: 0;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.05);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: .04em;
  color: rgba(255, 255, 255, 0.85);
  text-transform: uppercase;
  transition: color .15s ease, background .15s ease, border-color .15s ease;
}

.thc-language-switcher a[hreflang="ar"],
.block-language ul.links a[hreflang="ar"] {
  font-size: var(--text-sm);
  letter-spacing: 0;
  text-transform: none;
}

.thc-language-switcher a:hover,
.thc-language-switcher a:focus-visible,
.block-language ul.links a:hover,
.block-language ul.links a:focus-visible {
  color: #fff;
  border-color: var(--brand-red);
  background: var(--brand-red-soft);
}

/* Main menu */
.main-menu {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  gap: .1rem;
  flex-wrap: nowrap;
}

.main-menu > li > a {
  display: block;
  padding: .45rem .8rem;
  border-radius: var(--radius-sm);
  color: rgba(255, 255, 255, 0.86);
  font-weight: 500;
  font-size: var(--text-sm);
  position: relative;
  transition: background var(--transition), color var(--transition);
}

.main-menu > li > a::after {
  content: "";
  position: absolute;
  inset-inline: .8rem;
  bottom: .2rem;
  height: 2px;
  background: var(--brand-red);
  border-radius: 0;
  transform: scaleX(0);
  transition: transform var(--transition);
}

.main-menu > li > a:hover,
.main-menu > li > a:focus-visible,
.main-menu > li > a.is-active {
  color: #fff;
  background: var(--brand-red-soft);
}

.main-menu > li > a.is-active::after,
.main-menu > li.menu-item--active-trail > a::after {
  transform: scaleX(1);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  border: 0;
  background: transparent;
  padding: .5rem;
  cursor: pointer;
  border-radius: var(--radius-sm);
  z-index: 2;
}

.nav-toggle:focus-visible {
  outline: 2px solid var(--brand-red);
  outline-offset: 2px;
}

.nav-toggle__bar {
  width: 22px;
  height: 2px;
  background: #fff;
  border-radius: 2px;
  transition: transform var(--transition), opacity var(--transition);
}

body.nav-open .nav-toggle__bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
body.nav-open .nav-toggle__bar:nth-child(2) { opacity: 0; }
body.nav-open .nav-toggle__bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 900px) {
  .header-inner {
    grid-template-columns: 1fr auto;
  }

  .site-branding .block-branding,
  .site-branding .block-system-branding-block {
    grid-column: 1;
  }

  .nav-toggle { display: flex; }

  .site-header .thc-language-switcher:not(.main-nav .thc-language-switcher),
  .site-header .block-language:not(.main-nav .block-language) {
    grid-column: 2;
    grid-row: 1;
    justify-self: end;
    margin-inline-end: .35rem;
  }

  .main-nav {
    position: fixed;
    top: var(--header-h);
    inset-inline: 0;
    width: 100%;
    max-width: none;
    grid-column: 1 / -1;
    justify-self: stretch;
    background: #080808;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    padding-block: var(--space-4);
    padding-inline: var(--section-px);
    display: none;
    box-shadow: var(--shadow-lg);
    flex-direction: column;
    align-items: stretch;
    max-height: calc(100dvh - var(--header-h));
    overflow-y: auto;
    z-index: 999;
  }

  .main-nav > div {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    width: 100%;
  }

  .main-nav.is-open { display: flex; }
  .main-menu { flex-direction: column; align-items: stretch; width: 100%; }
  .main-menu > li { width: 100%; }
  .main-menu > li > a {
    display: block;
    width: 100%;
    padding: 1rem var(--section-px);
    font-size: var(--text-base);
    min-height: 2.75rem;
  }
  .main-menu > li > a::after { display: none; }
  .main-nav .thc-language-switcher,
  .main-nav .block-language {
    order: -1;
    width: 100%;
    margin: 0 0 var(--space-2);
    margin-inline-start: 0;
  }
  .main-nav .thc-language-switcher ul,
  .main-nav .block-language ul.links {
    width: 100%;
    display: flex;
    justify-content: stretch;
  }
  .main-nav .thc-language-switcher a,
  .main-nav .block-language ul.links a {
    flex: 1;
    justify-content: center;
    min-height: 2.75rem;
    padding: .75rem 1rem;
  }
}

/* --- 6. Buttons --------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .4rem;
  padding: .75rem 1.35rem;
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-weight: 600;
  font-size: var(--text-sm);
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform var(--transition), background var(--transition), border-color var(--transition), box-shadow var(--transition);
}

.btn:focus-visible {
  outline: 2px solid var(--brand-red);
  outline-offset: 2px;
}

.btn-primary {
  background: var(--brand-red);
  color: #fff;
  border-color: var(--brand-red);
  clip-path: polygon(6px 0, 100% 0, calc(100% - 6px) 100%, 0 100%);
}

.btn-primary:hover,
.btn-primary:focus-visible {
  background: var(--brand-red-hover);
  border-color: var(--brand-red-hover);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: var(--shadow-red);
  clip-path: polygon(4px 0, 100% 0, calc(100% - 4px) 100%, 0 100%);
}

.btn-outline {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.45);
}

.btn-outline:hover,
.btn-outline:focus-visible {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.7);
  color: #fff;
}

.btn-dark {
  background: var(--brand-black);
  color: #fff;
  border-color: var(--brand-black);
}

.btn-dark:hover { background: #1a1a1a; color: #fff; }

/* --- 7. Hero (full viewport immersive) -------------------------------- */
.hero-region { margin: 0; }

.front-content .block-system-main-block,
.front-content .node__content { width: 100%; }

.hero-panel {
  position: relative;
  width: 100%;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: clamp(2.5rem, 7vw, 4.5rem) var(--section-px);
  text-align: center;
  color: #fff;
  overflow: hidden;
  background:
    radial-gradient(ellipse 80% 60% at 50% 100%, rgba(255, 77, 77, 0.22), transparent 55%),
    radial-gradient(circle at 15% 25%, rgba(255, 77, 77, 0.14), transparent 35%),
    linear-gradient(165deg, #000000 0%, #0a0a0a 45%, #141414 100%);
}

.hero-panel--has-bg {
  background-image:
    linear-gradient(165deg, rgba(0, 0, 0, 0.82) 0%, rgba(0, 0, 0, 0.55) 45%, rgba(0, 0, 0, 0.75) 100%),
    var(--hero-bg, none);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.hero-panel__overlay {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 50% at 50% 80%, rgba(255, 77, 77, 0.2), transparent 60%),
    repeating-linear-gradient(
      90deg,
      transparent,
      transparent 80px,
      rgba(255, 255, 255, 0.012) 80px,
      rgba(255, 255, 255, 0.012) 81px
    );
  pointer-events: none;
  animation: heroGlow 8s ease-in-out infinite alternate;
}

@keyframes heroGlow {
  from { opacity: 0.85; }
  to { opacity: 1; }
}

.hero-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(
      90deg,
      transparent,
      transparent 80px,
      rgba(255, 255, 255, 0.015) 80px,
      rgba(255, 255, 255, 0.015) 81px
    );
  pointer-events: none;
}

.hero-panel::after {
  content: "";
  position: absolute;
  inset-inline: 0;
  bottom: 0;
  height: 120px;
  background: linear-gradient(to top, var(--bg), transparent);
  pointer-events: none;
}

.hero-panel__inner {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 720px;
  margin-inline: auto;
}

.hero-panel__badge {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .35rem 1rem;
  border-radius: 0;
  background: var(--brand-red-soft);
  border: 1px solid rgba(255, 77, 77, 0.3);
  color: var(--brand-red);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: var(--thc-track-wide);
  text-transform: uppercase;
  margin-bottom: var(--space-4);
  clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 100%, 10px 100%);
  padding-inline: 1.15rem;
}

.hero-panel__title {
  margin: 0 0 var(--space-2);
  font-size: clamp(2.25rem, 6vw, 3.75rem);
  line-height: 1.08;
  font-weight: 800;
  color: #fff;
}

html[dir="ltr"] .hero-panel__title { letter-spacing: -0.025em; }

.hero-panel__subtitle {
  margin: 0 0 var(--space-4);
  color: rgba(255, 255, 255, 0.65);
  font-size: var(--text-lg);
  font-weight: 500;
}

.hero-panel__text {
  max-width: 580px;
  margin: 0 auto var(--space-6);
  color: var(--brand-muted);
  font-size: var(--text-base);
  line-height: var(--leading-relaxed);
}

.hero-panel__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  justify-content: center;
  align-items: center;
}

@media (max-width: 480px) {
  .hero-panel__actions {
    flex-direction: column;
    width: 100%;
  }

  .hero-panel__actions .btn {
    width: min(100%, 280px);
  }
}

/* --- 8. Stats bar ------------------------------------------------------- */
.stats-bar {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-2);
  width: min(100% - (var(--section-px) * 2), var(--container));
  margin: 0 auto;
  position: relative;
  z-index: 3;
}

.stats-bar--enhanced .stats-bar__item {
  padding: var(--space-4) var(--space-3);
}

.stats-bar__icon {
  display: block;
  margin-bottom: var(--space-1);
}

.stats-bar__icon .thc-icon {
  font-size: 1.35rem;
  color: var(--brand-red);
  opacity: 0.9;
}

@media (min-width: 768px) {
  .stats-bar { grid-template-columns: repeat(4, 1fr); }
}

.stats-bar__item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: var(--space-5) var(--space-4);
  text-align: center;
  box-shadow: var(--shadow);
  transition: transform var(--transition), box-shadow var(--transition);
}

.stats-bar__item:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.stats-bar__num {
  display: block;
  color: var(--brand-red);
  font-size: clamp(1.5rem, 3.5vw, 2rem);
  font-weight: 800;
  line-height: 1.15;
  font-variant-numeric: tabular-nums;
}

.stats-bar__label {
  display: block;
  color: var(--muted);
  font-size: var(--text-xs);
  margin-top: var(--space-1);
  font-weight: 500;
}

/* --- 9. Section headings ------------------------------------------------ */
.intro-section,
.services-heading,
.section-heading {
  width: min(100% - (var(--section-px) * 2), var(--container));
  margin-inline: auto;
}

.services-heading,
.section-heading {
  text-align: center;
  margin-bottom: var(--space-6);
}

.section-heading__eyebrow {
  display: inline-block;
  font-size: var(--text-xs);
  font-weight: 700;
  color: var(--brand-red);
  text-transform: uppercase;
  letter-spacing: .12em;
  margin-bottom: var(--space-2);
}

.intro-section__grid {
  display: grid;
  gap: var(--space-8);
  align-items: center;
}

@media (min-width: 860px) {
  .intro-section__grid { grid-template-columns: .9fr 1.1fr; }
  .intro-section__grid--reverse { direction: ltr; }
  html[dir="rtl"] .intro-section__grid--reverse > * { direction: rtl; }
}

.intro-section__media-inner {
  aspect-ratio: 4 / 3;
  border-radius: var(--radius-lg);
  background:
    radial-gradient(circle at 30% 30%, rgba(255, 77, 77, 0.22), transparent 50%),
    linear-gradient(145deg, #000, #1c1c1c);
  color: var(--brand-red);
  display: grid;
  place-items: center;
  font-size: 2.75rem;
  font-weight: 800;
  box-shadow: var(--shadow-lg);
  border: 1px solid rgba(255, 255, 255, 0.08);
  overflow: hidden;
  transition: transform var(--transition-slow);
}

.intro-section__media-inner--photo {
  background-image: var(--media-bg);
  background-size: cover;
  background-position: center;
  color: transparent;
  font-size: 0;
}

.intro-section__media:hover .intro-section__media-inner {
  transform: scale(1.02);
}

.intro-section__body h2,
.services-heading h2,
.section-heading h2 {
  margin: 0 0 var(--space-3);
  color: var(--brand-black);
}

html[dir="ltr"] .intro-section__body h2,
html[dir="ltr"] .services-heading h2,
html[dir="ltr"] .section-heading h2 {
  letter-spacing: -0.02em;
}

.intro-section__body p,
.services-heading p,
.section-heading p {
  color: var(--muted);
  margin: 0 0 var(--space-4);
}

.section-line {
  width: 56px;
  height: 4px;
  border-radius: 0;
  clip-path: polygon(0 0, 100% 0, 92% 100%, 8% 100%);
  background: var(--brand-red);
  margin: 0 auto var(--space-3);
}

.section-line--start { margin-inline: 0; }

/* --- 10. Feature grid (Why Choose Us) ----------------------------------- */
.feature-grid {
  display: grid;
  gap: var(--space-4);
  width: min(100% - (var(--section-px) * 2), var(--container));
  margin-inline: auto;
}

@media (min-width: 640px) {
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 960px) {
  .feature-grid { grid-template-columns: repeat(4, 1fr); }
}

.feature-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: var(--space-5);
  text-align: center;
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: rgba(255, 77, 77, 0.25);
}

.feature-card__icon {
  width: 52px;
  height: 52px;
  margin: 0 auto var(--space-3);
  border-radius: 0;
  background: var(--brand-red-soft);
  border: 1px solid rgba(255, 77, 77, 0.28);
  color: var(--brand-red);
  display: grid;
  place-items: center;
  font-size: 1.5rem;
  line-height: 1;
  box-shadow: 0 4px 14px rgba(255, 77, 77, 0.08);
  position: relative;
}

.feature-card__icon::after {
  content: "";
  position: absolute;
  inset-inline-end: -4px;
  top: -4px;
  width: 14px;
  height: 12px;
  background: var(--brand-red);
  clip-path: var(--thc-logo-clip-a);
  opacity: 0.85;
}

.feature-card h3 {
  margin: 0 0 var(--space-2);
  font-size: var(--text-base);
  font-weight: 700;
}

.feature-card p {
  margin: 0;
  font-size: var(--text-sm);
  color: var(--muted);
  line-height: 1.6;
}

/* --- 11. Services grid & cards ------------------------------------------ */
.block-views-blockservices-block-1,
.view-services,
.view-id-services {
  width: min(100% - (var(--section-px) * 2), var(--container));
  margin: 0 auto var(--section-py);
}

.view-services .view-header,
.view-services > h2,
.view-id-services .view-header { display: none; }

.services-grid,
.articles-grid,
.projects-grid,
.view-services ul,
.view-id-services ul {
  list-style: none !important;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-3);
}

@media (min-width: 640px) {
  .services-grid,
  .articles-grid,
  .view-services ul { grid-template-columns: repeat(2, 1fr); }
  .projects-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 960px) {
  .services-grid,
  .view-services ul { grid-template-columns: repeat(3, 1fr); }
  .articles-grid { grid-template-columns: repeat(3, 1fr); }
}

.services-grid__item,
.articles-grid__item,
.projects-grid__item,
.view-services li {
  list-style: none !important;
  margin: 0;
  padding: 0;
  display: flex;
}

.view-services li::marker { content: ''; }

.service-card {
  height: 100%;
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: var(--space-4);
  min-height: 0;
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
  display: flex;
  flex-direction: column;
}

.service-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: rgba(255, 77, 77, 0.3);
}

.service-card__icon {
  width: 50px;
  height: 50px;
  border-radius: 0;
  background: var(--brand-red-soft);
  border: 1px solid rgba(255, 77, 77, 0.28);
  display: grid;
  place-items: center;
  margin-bottom: var(--space-4);
  flex-shrink: 0;
  position: relative;
}

.service-card__icon::after {
  content: "";
  position: absolute;
  inset-inline-end: -4px;
  top: -4px;
  width: 14px;
  height: 12px;
  background: var(--brand-red);
  clip-path: var(--thc-logo-clip-a);
  opacity: 0.85;
}

.service-card__icon-mark {
  font-size: .6rem;
  font-weight: 800;
  color: var(--brand-red);
  letter-spacing: .05em;
}

.service-card__title {
  margin: 0 0 var(--space-2);
  font-size: var(--text-lg);
  line-height: var(--leading-tight);
}

.service-card__title a { color: var(--brand-black); }
.service-card__title a:hover { color: var(--brand-red); }

.service-card__body {
  color: var(--muted);
  font-size: var(--text-sm);
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.service-card__body p { margin: 0 0 var(--space-2); }
.service-card__body ul,
.service-card__body ol { display: none; }

.service-card__link {
  margin-top: var(--space-4);
  color: var(--brand-red);
  font-weight: 600;
  font-size: var(--text-sm);
  display: inline-flex;
  align-items: center;
  gap: .35rem;
}

html[dir="rtl"] .service-card__arrow { transform: scaleX(-1); }

/* --- 12. Project cards -------------------------------------------------- */
.projects-grid {
  width: min(100% - (var(--section-px) * 2), var(--container));
  margin-inline: auto;
}

.project-card {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--brand-black);
  aspect-ratio: 4 / 3;
  box-shadow: var(--shadow);
}

a.project-card {
  display: block;
  text-decoration: none;
  color: inherit;
}

.project-card__media {
  position: absolute;
  inset: 0;
  display: block;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  transition: transform var(--transition-slow);
}

.project-card:hover .project-card__media { transform: scale(1.06); }

.project-card__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.92) 0%, rgba(0, 0, 0, 0.3) 50%, transparent 100%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: var(--space-5);
  color: #fff;
  opacity: 0.95;
  transition: opacity var(--transition);
}

.project-card__overlay h3 {
  margin: 0 0 var(--space-2);
  color: #fff;
  font-size: var(--text-lg);
}

.project-card__overlay p {
  margin: 0;
  font-size: var(--text-sm);
  color: rgba(255, 255, 255, 0.75);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.project-card__meta {
  margin-top: var(--space-2);
  font-size: var(--text-xs);
  color: var(--brand-red);
  font-weight: 600;
}

.project-card__category {
  display: inline-block;
  padding: .25rem .65rem;
  border-radius: 0;
  background: var(--brand-red);
  border: none;
  color: #fff;
  font-size: var(--text-xs);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35);
  margin-bottom: var(--space-2);
  width: fit-content;
}

.project-card__location {
  font-size: var(--text-xs);
  color: rgba(255, 255, 255, 0.65);
  margin: 0 0 var(--space-2);
}

.project-card__location .thc-icon {
  font-size: 0.9em;
  margin-inline-end: 0.35em;
  color: rgba(255, 255, 255, 0.75);
}

/* Projects page: style intro-section as portfolio items */
.intro-section--project .intro-section__grid {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-5);
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--transition), transform var(--transition);
}

.intro-section--project:hover .intro-section__grid {
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}

/* --- 13. Article / news cards ------------------------------------------- */
.article-card,
.page-card {
  height: 100%;
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition), box-shadow var(--transition);
  display: flex;
  flex-direction: column;
}

.article-card:hover,
.page-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.article-card__media {
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #111 center / cover no-repeat;
  position: relative;
  min-height: 140px;
}

.article-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.article-card:hover .article-card__media img { transform: scale(1.05); }

.article-card__body,
.page-card { padding: var(--space-3) var(--space-4) var(--space-4); }

.article-card__title,
.page-card__title {
  margin: 0 0 var(--space-2);
  font-size: var(--text-base);
  line-height: var(--leading-tight);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.article-card__title a,
.page-card__title a { color: var(--brand-black); }

.article-card__meta {
  font-size: var(--text-xs);
  color: var(--brand-soft);
  margin-bottom: var(--space-2);
  font-weight: 500;
}

.article-card__excerpt,
.page-card__body {
  color: var(--muted);
  font-size: var(--text-sm);
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.article-card__link,
.page-card__link {
  margin-top: var(--space-3);
  font-weight: 600;
  font-size: var(--text-sm);
  display: inline-flex;
  align-items: center;
  gap: .3rem;
}

html[dir="rtl"] .article-card__link span,
html[dir="rtl"] .page-card__link span { transform: scaleX(-1); }

/* --- 14. CTA bands ------------------------------------------------------ */
.cta-band,
.contact-section {
  position: relative;
  background: var(--brand-black);
  color: #fff;
  border-radius: var(--radius-xl);
  padding: clamp(2rem, 5vw, 3rem) var(--section-px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: var(--shadow-lg);
  width: min(100% - (var(--section-px) * 2), var(--container));
  margin: var(--section-py) auto;
  text-align: center;
  overflow: hidden;
}

.cta-band::before,
.contact-section::before {
  content: "";
  position: absolute;
  inset-inline-end: -20%;
  top: -50%;
  width: 50%;
  height: 200%;
  background: radial-gradient(circle, rgba(255, 77, 77, 0.15), transparent 65%);
  pointer-events: none;
}

.cta-band__inner,
.contact-section > div {
  position: relative;
  z-index: 1;
}

.cta-band h2,
.contact-section h2 {
  margin: 0 0 var(--space-3);
  color: #fff;
  font-size: clamp(var(--text-xl), 3vw, var(--text-2xl));
}

.cta-band p,
.contact-section p {
  margin: 0 auto var(--space-5);
  max-width: 520px;
  color: rgba(255, 255, 255, 0.72);
  font-size: var(--text-base);
}

.cta-band--inline {
  border-radius: var(--radius-lg);
  padding: var(--space-8) var(--space-6);
}

/* --- 15. Testimonials & partners ---------------------------------------- */
.testimonials-section,
.partners-section {
  padding-block: var(--section-py);
}

.testimonials-section:empty,
.partners-section:empty,
.testimonials-section--empty,
.partners-section--empty {
  display: none;
}

.testimonials-grid {
  display: grid;
  gap: var(--space-4);
  width: min(100% - (var(--section-px) * 2), var(--container));
  margin-inline: auto;
}

@media (min-width: 768px) {
  .testimonials-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 1024px) {
  .testimonials-grid { grid-template-columns: repeat(3, 1fr); }
}

.testimonial-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: var(--space-5);
  box-shadow: var(--shadow-sm);
}

.testimonial-card__quote {
  font-size: var(--text-base);
  color: var(--text-secondary);
  line-height: var(--leading-relaxed);
  margin: 0 0 var(--space-4);
  font-style: italic;
}

.testimonial-card__quote::before {
  content: "\201C";
  color: var(--brand-red);
  font-size: 1.5em;
  font-weight: 800;
  margin-inline-end: .15em;
}

.testimonial-card__author {
  font-weight: 700;
  font-size: var(--text-sm);
  color: var(--brand-black);
}

.testimonial-card__role {
  font-size: var(--text-xs);
  color: var(--muted);
}

.partners-strip {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: var(--space-6);
  width: min(100% - (var(--section-px) * 2), var(--container));
  margin-inline: auto;
  padding: var(--space-6);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}

.partner-logo {
  opacity: 0.55;
  filter: grayscale(1);
  transition: opacity var(--transition), filter var(--transition);
  font-weight: 700;
  font-size: var(--text-sm);
  color: var(--muted);
  padding: var(--space-3) var(--space-4);
}

.partner-logo:hover {
  opacity: 1;
  filter: grayscale(0);
}

/* --- 16. Contact -------------------------------------------------------- */
.contact-grid {
  display: grid;
  gap: var(--space-6);
}

@media (min-width: 800px) {
  .contact-grid { grid-template-columns: 1fr 1fr; }
}

.contact-item {
  display: flex;
  gap: var(--space-3);
  margin-bottom: var(--space-3);
}

.contact-item a { color: var(--brand-red); font-weight: 600; }

.contact-icon {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  background: var(--brand-red-soft);
  border: 1px solid rgba(255, 77, 77, 0.28);
  border-radius: var(--radius);
  color: var(--brand-red);
}

.contact-icon .thc-icon {
  font-size: 1.1rem;
  color: var(--brand-red);
}

/* --- THC icon library (Font Awesome) ------------------------------------ */
.thc-icon {
  display: inline-block;
  line-height: 1;
}

.thc-icon--inline {
  vertical-align: -0.1em;
}

.contact-form-wrapper {
  background: #fff;
  color: var(--text);
  border-radius: var(--radius);
  padding: var(--space-5);
  text-align: start;
}

.contact-info {
  text-align: start;
}

.contact-form-wrapper h3 {
  margin: 0 0 var(--space-2);
  color: var(--brand-black);
  font-size: var(--text-xl);
  font-weight: 800;
}

.contact-form-wrapper > p {
  margin: 0 0 var(--space-4);
  color: var(--text-secondary);
  font-size: var(--text-sm);
}

.contact-form-wrapper .block-webform-block,
.contact-form-wrapper .thc-contact-webform-block {
  margin: 0;
  padding: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
}

/* --- 16b. Forms & webforms (site-wide) ---------------------------------- */
.thc-webform-form,
.webform-submission-form,
form.thc-form {
  font-family: var(--font);
}

.thc-webform-form .form-item,
.webform-submission-form .form-item,
form.thc-form .form-item {
  margin-block: 0 var(--space-4);
}

.thc-webform-form label,
.webform-submission-form label,
form.thc-form label,
.thc-webform-form .fieldset-legend,
.webform-submission-form .fieldset-legend {
  display: block;
  margin-bottom: var(--space-2);
  font-weight: 700;
  font-size: var(--text-sm);
  color: var(--text);
}

.thc-webform-form .description,
.webform-submission-form .description,
form.thc-form .description {
  margin-top: var(--space-1);
  font-size: var(--text-xs);
  color: var(--muted);
}

.thc-webform-form input[type="text"],
.thc-webform-form input[type="email"],
.thc-webform-form input[type="tel"],
.thc-webform-form input[type="url"],
.thc-webform-form input[type="number"],
.thc-webform-form input[type="password"],
.thc-webform-form input[type="search"],
.thc-webform-form input[type="date"],
.thc-webform-form input[type="time"],
.thc-webform-form select,
.thc-webform-form textarea,
.webform-submission-form input[type="text"],
.webform-submission-form input[type="email"],
.webform-submission-form input[type="tel"],
.webform-submission-form input[type="url"],
.webform-submission-form input[type="number"],
.webform-submission-form input[type="password"],
.webform-submission-form input[type="search"],
.webform-submission-form input[type="date"],
.webform-submission-form input[type="time"],
.webform-submission-form select,
.webform-submission-form textarea,
form.thc-form input[type="text"],
form.thc-form input[type="email"],
form.thc-form input[type="tel"],
form.thc-form input[type="url"],
form.thc-form input[type="number"],
form.thc-form input[type="password"],
form.thc-form input[type="search"],
form.thc-form input[type="date"],
form.thc-form input[type="time"],
form.thc-form select,
form.thc-form textarea {
  display: block;
  width: 100%;
  max-width: 100%;
  padding: .7rem .85rem;
  font-family: var(--font);
  font-size: var(--text-base);
  color: var(--text);
  background: var(--surface);
  border: 2px solid var(--border-strong);
  border-radius: var(--radius-sm);
  transition: border-color var(--transition), box-shadow var(--transition);
}

.thc-webform-form textarea,
.webform-submission-form textarea,
form.thc-form textarea {
  min-height: 8rem;
  resize: vertical;
  line-height: var(--leading-normal);
}

.thc-webform-form input:focus,
.thc-webform-form select:focus,
.thc-webform-form textarea:focus,
.webform-submission-form input:focus,
.webform-submission-form select:focus,
.webform-submission-form textarea:focus,
form.thc-form input:focus,
form.thc-form select:focus,
form.thc-form textarea:focus {
  outline: none;
  border-color: var(--brand-red);
  box-shadow: 0 0 0 3px var(--brand-red-soft);
}

.thc-webform-form input::placeholder,
.webform-submission-form input::placeholder,
.thc-webform-form textarea::placeholder,
.webform-submission-form textarea::placeholder {
  color: var(--muted);
  opacity: 1;
}

.thc-webform-form .form-checkboxes,
.thc-webform-form .form-radios,
.webform-submission-form .form-checkboxes,
.webform-submission-form .form-radios {
  display: grid;
  gap: var(--space-2);
}

.thc-webform-form .form-type-checkbox,
.thc-webform-form .form-type-radio,
.webform-submission-form .form-type-checkbox,
.webform-submission-form .form-type-radio {
  display: flex;
  align-items: flex-start;
  gap: var(--space-2);
  margin-bottom: var(--space-2);
}

.thc-webform-form .form-type-checkbox input,
.thc-webform-form .form-type-radio input,
.webform-submission-form .form-type-checkbox input,
.webform-submission-form .form-type-radio input {
  width: auto;
  margin-top: .2rem;
  accent-color: var(--brand-red);
}

.thc-webform-form .form-actions,
.webform-submission-form .form-actions,
.webform-submission-form .webform-actions,
form.thc-form .form-actions {
  margin-top: var(--space-5);
  margin-bottom: 0;
  padding-top: var(--space-2);
}

.thc-webform-form .form-actions input[type="submit"],
.thc-webform-form .form-actions button[type="submit"],
.thc-webform-form .webform-button--submit,
.webform-submission-form .form-actions input[type="submit"],
.webform-submission-form .form-actions button[type="submit"],
.webform-submission-form .webform-button--submit,
.webform-submission-form .button--primary,
form.thc-form .form-actions input[type="submit"],
form.thc-form .form-actions button[type="submit"] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .4rem;
  padding: .75rem 1.35rem;
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-weight: 600;
  font-size: var(--text-sm);
  border: 2px solid var(--brand-red);
  cursor: pointer;
  background: var(--brand-red);
  color: #fff;
  clip-path: polygon(6px 0, 100% 0, calc(100% - 6px) 100%, 0 100%);
  transition: transform var(--transition), background var(--transition), border-color var(--transition), box-shadow var(--transition);
}

.thc-webform-form .form-actions input[type="submit"]:hover,
.thc-webform-form .form-actions input[type="submit"]:focus-visible,
.webform-submission-form .form-actions input[type="submit"]:hover,
.webform-submission-form .form-actions input[type="submit"]:focus-visible,
.webform-submission-form .webform-button--submit:hover,
.webform-submission-form .webform-button--submit:focus-visible {
  background: var(--brand-red-hover);
  border-color: var(--brand-red-hover);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: var(--shadow-red);
  clip-path: polygon(4px 0, 100% 0, calc(100% - 4px) 100%, 0 100%);
}

.thc-webform-form .form-required,
.webform-submission-form .form-required,
form.thc-form .form-required {
  color: var(--brand-red);
}

.thc-webform-form label.form-required,
.webform-submission-form label.form-required,
form.thc-form label.form-required,
.thc-auth-form label.form-required {
  color: var(--text);
}

.thc-webform-form .webform-element-help,
.webform-submission-form .webform-element-help {
  color: var(--muted);
}

/* Hide webform/block titles when form is embedded in contact layout */
.thc-contact-webform-block > h2,
.block-webform-block > h2,
.thc-webform-form > h2,
.webform-submission-form > h2,
.webform-submission-form .webform-element--processed_text h2 {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.webform-submission-form .messages,
.thc-webform-form .messages,
form.thc-form .messages {
  margin-bottom: var(--space-4);
  padding: var(--space-3) var(--space-4);
  border-inline-start: 4px solid var(--brand-red);
  background: var(--surface-elevated);
  border-radius: var(--radius-sm);
}

/* Contact page: unwrap inner page card, integrate form block */
.thc-contact-page .content-wrap {
  padding-block: var(--section-py);
}

.thc-contact-page .node--type-page.page-full,
.thc-contact-page .page-full {
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 0;
  box-shadow: none;
  max-width: none;
  width: 100%;
}

.thc-contact-page .node__title {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.thc-contact-page .contact-section {
  margin: 0 auto;
  text-align: center;
}

.thc-contact-page .contact-form-wrapper .webform-submission-form,
.thc-contact-page .contact-form-wrapper .thc-webform-form {
  text-align: start;
}

/* --- 16c. Auth pages (login, password, register) ------------------------ */
.thc-auth-page .content-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: calc(100vh - var(--header-h) - 12rem);
  padding-block: var(--space-10);
}

.thc-auth-page #block-thc-theme-content {
  width: 100%;
  max-width: 440px;
  margin-inline: auto;
}

.thc-auth-form {
  background: var(--surface);
  border: 1px solid var(--border);
  padding: clamp(1.5rem, 4vw, 2rem);
  box-shadow: var(--shadow-sm);
}

.thc-auth-form__header {
  margin-bottom: var(--space-5);
  padding-bottom: var(--space-4);
  border-bottom: 3px solid var(--brand-red);
  text-align: center;
}

.thc-auth-form__title {
  margin: 0;
  font-size: var(--text-2xl);
  font-weight: 800;
  color: var(--brand-black);
  line-height: var(--leading-tight);
}

.thc-auth-form__intro {
  margin: var(--space-3) 0 0;
  font-size: var(--text-sm);
  color: var(--text-secondary);
  line-height: var(--leading-normal);
}

.thc-auth-form > p {
  margin: 0 0 var(--space-4);
  font-size: var(--text-sm);
  color: var(--text-secondary);
  line-height: var(--leading-normal);
}

.thc-auth-form__footer {
  margin-top: var(--space-5);
  padding-top: var(--space-4);
  border-top: 1px solid var(--border);
  text-align: center;
  font-size: var(--text-sm);
}

.thc-auth-form__footer a {
  color: var(--brand-red);
  font-weight: 600;
  text-decoration: none;
  transition: color var(--transition);
}

.thc-auth-form__footer a:hover,
.thc-auth-form__footer a:focus-visible {
  color: var(--brand-red-hover);
  text-decoration: underline;
}

.thc-auth-form .form-actions input[type="submit"],
.thc-auth-form .form-actions button[type="submit"] {
  width: 100%;
}

.thc-auth-form .form-item--error-message {
  margin-top: var(--space-2);
  font-size: var(--text-sm);
  color: var(--brand-red);
}

.thc-auth-form .form-item--error input {
  border-color: var(--brand-red);
}

.thc-auth-page .highlighted-region .messages {
  max-width: 440px;
  margin-inline: auto;
}

.thc-auth-page .tabs,
.thc-auth-page .block-local-tasks-block,
.thc-auth-page .local-tasks {
  display: none;
}

.thc-auth-page .page-title,
.thc-auth-page h1.title {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* --- 17. Inner pages ---------------------------------------------------- */
.content-wrap {
  padding-block: var(--section-py) var(--section-py-lg);
  padding-inline: 0;
}

/* Front page: no card wrapper around homepage sections */
.path-frontpage .node--type-page.page-full--front,
.path-frontpage .page-full.page-full--front,
.node--type-page.page-full.page-full--front {
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 0;
  box-shadow: none;
  max-width: none;
  width: 100%;
}

.path-frontpage .page-full--front .page-full__content,
.node--type-page.page-full--front .page-full__content {
  padding: 0;
  max-width: none;
  width: 100%;
}

.node__title,
.page-title {
  color: var(--brand-black);
  margin-top: 0;
  font-weight: 800;
}

.node--type-page,
.node--type-article,
.node--type-service.node--view-mode-full,
.article-full,
.service-full,
.page-full {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: clamp(1.25rem, 3vw, 1.75rem);
  box-shadow: var(--shadow-sm);
}

.article-full__media {
  margin: 0 0 var(--space-5);
  border-radius: var(--radius);
  overflow: hidden;
}

.article-full__media img { width: 100%; }

.article-full__meta,
.service-full__header {
  color: var(--muted);
  font-size: var(--text-sm);
  margin-bottom: var(--space-4);
}

.article-full__tags {
  margin-top: var(--space-5);
  padding-top: var(--space-4);
  border-top: 1px solid var(--border);
  font-size: var(--text-sm);
}

/* --- 18. Footer --------------------------------------------------------- */
.site-footer {
  position: relative;
  background: var(--brand-black);
  color: rgba(255, 255, 255, 0.82);
  margin-top: var(--space-6);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.site-footer::before {
  content: "";
  position: absolute;
  top: 0;
  inset-inline-end: 8%;
  width: 64px;
  height: 52px;
  background: var(--brand-red);
  opacity: 0.12;
  clip-path: var(--thc-logo-clip-mark);
  pointer-events: none;
}

.footer-top {
  display: grid;
  gap: var(--space-8);
  padding: var(--space-10) 0 var(--space-6);
}

@media (min-width: 800px) {
  .footer-top { grid-template-columns: 1.3fr 1fr 1fr 1fr; }
}

.footer-brand strong {
  color: #fff;
  font-size: var(--text-lg);
  display: block;
  margin-bottom: var(--space-2);
}

.footer-brand__sub {
  color: var(--brand-muted);
  font-size: var(--text-sm);
  margin: 0 0 var(--space-3);
}

.footer-desc {
  color: rgba(255, 255, 255, 0.68);
  font-size: var(--text-sm);
  margin: 0;
  line-height: 1.65;
  max-width: 280px;
}

.footer-links h3,
.footer-services h3,
.footer-contact h2,
.footer-contact h3 {
  color: #fff;
  font-size: var(--text-base);
  font-weight: 700;
  margin: 0 0 var(--space-4);
}

.footer-menu {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.footer-menu a,
.footer-contact a {
  color: rgba(255, 255, 255, 0.75);
  font-size: var(--text-sm);
  transition: color var(--transition), padding-inline-start var(--transition);
}

.footer-menu a:hover,
.footer-menu a:focus-visible,
.footer-contact a:hover,
.footer-contact a:focus-visible {
  color: var(--brand-red);
  padding-inline-start: var(--space-1);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: var(--space-4) 0;
  text-align: center;
  font-size: var(--text-sm);
  color: var(--brand-soft);
}

.footer-bottom p { margin: 0; }

/* --- 19. Views & utilities ---------------------------------------------- */
.highlighted-region {
  padding: 0;
  margin: 0;
}

.highlighted-region:not(:has(.messages, [role="alert"])) {
  display: none;
}

.highlighted-region:has(.messages, [role="alert"]) {
  padding-block: var(--space-3);
}
.pager { margin-top: var(--space-6); }

.view-news,
.view-id-news {
  width: min(100% - (var(--section-px) * 2), var(--container));
  margin: 0 auto var(--section-py);
}

.view-empty {
  text-align: center;
  padding: var(--space-8);
  color: var(--muted);
}

/* --- 20. Section band system (homepage) -------------------------------- */
.section-band--hero {
  padding: 0;
  margin: 0;
  background: var(--brand-black);
  width: 100%;
}

.section-band--hero .hero-panel {
  min-height: 100vh;
  min-height: 100dvh;
}

.section-band--hero .hero-panel::after { display: none; }

.section-band--stats {
  background: var(--surface);
  padding-block: var(--space-6) var(--section-py);
  position: relative;
  z-index: 2;
}

.section-band--stats .stats-bar {
  margin-top: calc(-1 * var(--space-10));
}

.section-band--about {
  background: var(--bg-muted);
  position: relative;
}

.section-band--project-detail {
  background: linear-gradient(180deg, #f5f5f5 0%, #ececec 100%);
}

.section-band--project-detail .intro-section__body {
  color: var(--text);
}

.section-band--project-detail .intro-section__body h1 {
  color: var(--brand-black);
  margin-bottom: var(--space-3);
}

.section-band--project-detail .intro-section__body p,
.section-band--project-detail .intro-section__body li {
  color: var(--text-secondary);
  line-height: var(--leading-relaxed);
}

.section-band--project-detail .intro-section__body .project-card__location {
  color: var(--muted);
  font-weight: 600;
}

.section-band--project-detail .intro-section__body .project-card__meta {
  color: var(--brand-red-hover);
  font-weight: 700;
}

.section-band--project-detail .section-heading__eyebrow {
  color: var(--brand-red-hover);
  font-weight: 700;
}

.section-band--project-detail .intro-section__body .btn-outline {
  color: var(--brand-black);
  border-color: var(--brand-black);
  background: #fff;
  box-shadow: var(--shadow-sm);
}

.section-band--project-detail .intro-section__body .btn-outline:hover,
.section-band--project-detail .intro-section__body .btn-outline:focus-visible {
  background: var(--brand-black);
  border-color: var(--brand-black);
  color: #fff;
  box-shadow: var(--shadow-md);
}

.section-band--services {
  background: var(--surface);
}

.section-band--services .view-embed,
.section-band--services .block-views-blockservices-block-1,
.section-band--services .view-services {
  width: min(100% - (var(--section-px) * 2), var(--container));
  margin-inline: auto;
}

.section-band--projects-dark {
  background: linear-gradient(165deg, #050505 0%, #111 50%, #0a0a0a 100%);
  color: rgba(255, 255, 255, 0.9);
  position: relative;
}

.section-band--projects-dark::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 80% 20%, rgba(255, 77, 77, 0.08), transparent 40%),
    repeating-linear-gradient(0deg, transparent, transparent 40px, rgba(255, 255, 255, 0.015) 40px, rgba(255, 255, 255, 0.015) 41px);
  pointer-events: none;
}

.section-band--projects-dark .section-heading h2,
.section-band--projects-dark .services-heading h2 { color: #fff; }

.section-band--projects-dark .section-heading p,
.section-band--projects-dark .services-heading p { color: rgba(255, 255, 255, 0.65); }

.section-band--process {
  background: var(--surface-elevated);
}

.section-band--why {
  background: var(--bg-muted);
}

.section-band--testimonials {
  background: linear-gradient(180deg, var(--surface) 0%, var(--surface-elevated) 100%);
}

.section-band--cta {
  background: var(--brand-black);
  padding: 0;
}

.section-band--cta .cta-band {
  width: 100%;
  max-width: none;
  margin: 0;
  border-radius: 0;
  border-inline: 0;
  box-shadow: none;
}

.section-band--blog {
  background: var(--surface);
}

.section-band--partners {
  background: var(--bg-muted);
  padding-block: var(--section-py);
}

.section-band__actions {
  text-align: center;
  margin-top: var(--space-5);
  width: min(100% - (var(--section-px) * 2), var(--container));
  margin-inline: auto;
}

.section-line--light { background: var(--brand-red); }

/* Section dividers */
.section-divider--angle::before,
.section-divider--wave::before,
.section-divider--gradient::after,
.section-divider--line::before {
  content: "";
  display: block;
  pointer-events: none;
}

.section-divider--angle::before {
  height: 28px;
  margin-bottom: -1px;
  background: linear-gradient(to bottom right, transparent 49.5%, var(--border) 50%, transparent 50.5%);
  opacity: 0.6;
}

.section-divider--wave::before {
  height: 32px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 48' preserveAspectRatio='none'%3E%3Cpath fill='%23ff4d4d' fill-opacity='0.12' d='M0 24 Q300 0 600 24 T1200 24 V48 H0 Z'/%3E%3C/svg%3E") center / 100% 100% no-repeat;
}

.section-divider--gradient::after {
  height: 1px;
  width: min(100% - (var(--section-px) * 2), var(--container));
  margin: 0 auto;
  background: linear-gradient(90deg, transparent, var(--brand-red), transparent);
  opacity: 0.35;
}

.section-divider--line::before {
  height: 1px;
  width: min(100% - (var(--section-px) * 2), var(--container));
  margin: 0 auto var(--space-4);
  background: linear-gradient(90deg, transparent, var(--border-strong), transparent);
}

/* Glass card on dark sections */
.glass-card {
  background: rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-outline--on-dark {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.4);
}

.btn-outline--on-dark:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--brand-red);
  color: #fff;
}

/* Featured projects grid */
.projects-grid--featured {
  width: min(100% - (var(--section-px) * 2), var(--container));
  margin-inline: auto;
  gap: var(--space-3);
}

@media (min-width: 768px) {
  .projects-grid--featured {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: minmax(220px, auto);
  }

  .project-card--featured {
    grid-column: span 2;
    aspect-ratio: 21 / 9;
    min-height: 280px;
  }
}

.project-card {
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition);
}

.project-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35);
}

.project-card:hover .project-card__media { transform: scale(1.08); }

.project-card:hover .project-card__overlay {
  background: linear-gradient(to top, rgba(0, 0, 0, 0.95) 0%, rgba(0, 0, 0, 0.45) 55%, rgba(0, 0, 0, 0.15) 100%);
}

/* Process timeline */
.process-timeline {
  list-style: none;
  margin: 0 auto;
  padding: 0;
  width: min(100% - (var(--section-px) * 2), var(--container));
  display: grid;
  gap: var(--space-4);
  counter-reset: step;
}

@media (min-width: 900px) {
  .process-timeline {
    grid-template-columns: repeat(5, 1fr);
    gap: var(--space-2);
    position: relative;
  }

  .process-timeline::before {
    content: "";
    position: absolute;
    top: 1.35rem;
    inset-inline: 8%;
    height: 2px;
    background: linear-gradient(90deg, var(--brand-red), rgba(255, 77, 77, 0.2));
    z-index: 0;
  }
}

.process-timeline__step {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: var(--space-3);
}

.process-timeline__num {
  display: grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  margin: 0 auto var(--space-3);
  border-radius: 0;
  background: var(--brand-black);
  color: #fff;
  font-weight: 800;
  font-size: var(--text-sm);
  border: 2px solid var(--brand-red);
  box-shadow: var(--shadow-red);
  clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
}

.process-timeline__content h3 {
  margin: 0 0 var(--space-2);
  font-size: var(--text-base);
}

.process-timeline__content p {
  margin: 0;
  font-size: var(--text-sm);
  color: var(--muted);
  line-height: 1.55;
}

@media (max-width: 899px) {
  .process-timeline__step {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: var(--space-3);
    text-align: start;
    border-inline-start: 2px solid rgba(255, 77, 77, 0.25);
    padding-inline-start: var(--space-4);
    margin-inline-start: 1.25rem;
  }

  .process-timeline__num { margin: 0; }
}

/* Why choose us — large cards */
.why-section .why-grid {
  display: grid;
  gap: var(--space-3);
  width: min(100% - (var(--section-px) * 2), var(--container));
  margin-inline: auto;
}

@media (min-width: 640px) {
  .why-section .why-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 1024px) {
  .why-section .why-grid { grid-template-columns: repeat(4, 1fr); }
}

.why-card--large {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-6) var(--space-5);
  text-align: center;
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.why-card--large:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow);
  border-color: rgba(255, 77, 77, 0.3);
}

.why-card__icon {
  width: 64px;
  height: 64px;
  margin: 0 auto var(--space-4);
  border-radius: 0;
  background: var(--brand-red-soft);
  border: 1px solid rgba(255, 77, 77, 0.28);
  color: var(--brand-red);
  display: grid;
  place-items: center;
  line-height: 1;
  box-shadow: 0 6px 18px rgba(255, 77, 77, 0.1);
  position: relative;
}

.why-card__icon .thc-icon {
  font-size: 1.65rem;
  color: var(--brand-red);
}

.why-card__icon::after {
  content: "";
  position: absolute;
  inset-inline-end: -5px;
  top: -5px;
  width: 16px;
  height: 14px;
  background: var(--brand-red);
  clip-path: var(--thc-logo-clip-a);
  opacity: 0.9;
}

.why-card--large h3 {
  margin: 0 0 var(--space-3);
  font-size: var(--text-lg);
}

.why-card--large p {
  margin: 0;
  font-size: var(--text-sm);
  color: var(--muted);
  line-height: 1.65;
}

/* Testimonials slider */
.testimonials-slider {
  width: min(100% - (var(--section-px) * 2), var(--container));
  margin-inline: auto;
  position: relative;
  overflow: hidden;
}

.testimonials-slider__track {
  display: flex;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.testimonial-slide {
  flex: 0 0 100%;
  margin: 0;
  padding: var(--space-6);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  text-align: center;
}

.testimonial-slide__quote {
  font-size: clamp(var(--text-base), 2.5vw, var(--text-lg));
  color: var(--text-secondary);
  line-height: var(--leading-relaxed);
  margin: 0 0 var(--space-5);
  font-style: italic;
  max-width: 680px;
  margin-inline: auto;
}

.testimonial-slide__quote::before {
  content: "\201C";
  color: var(--brand-red);
  font-size: 2em;
  font-weight: 800;
  line-height: 0;
  vertical-align: -.35em;
  margin-inline-end: .1em;
}

.testimonial-slide__author {
  display: block;
  font-weight: 800;
  font-style: normal;
  color: var(--brand-black);
  font-size: var(--text-base);
}

.testimonial-slide__role {
  display: block;
  font-size: var(--text-sm);
  color: var(--muted);
  margin-top: var(--space-1);
}

.testimonials-slider__dots {
  display: flex;
  justify-content: center;
  gap: var(--space-2);
  margin-top: var(--space-4);
}

.testimonials-slider__dot {
  width: 8px;
  height: 8px;
  border-radius: 0;
  border: 0;
  padding: 0;
  background: var(--border-strong);
  cursor: pointer;
  transition: background var(--transition), transform var(--transition);
}

.testimonials-slider__dot.is-active {
  background: var(--brand-red);
  transform: scale(1.25);
}

/* Partners carousel — always LTR marquee (works on AR and EN pages) */
.partners-carousel {
  width: min(100% - (var(--section-px) * 2), var(--container));
  margin-inline: auto;
  overflow: hidden;
  direction: ltr;
  unicode-bidi: isolate;
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}

.partners-carousel__track {
  display: inline-flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: var(--space-8);
  width: max-content;
  min-width: 100%;
  will-change: transform;
  animation: partnersScroll var(--partners-duration, 30s) linear infinite;
}

.partners-carousel:hover .partners-carousel__track {
  animation-play-state: paused;
}

@keyframes partnersScroll {
  from { transform: translate3d(0, 0, 0); }
  to { transform: translate3d(-50%, 0, 0); }
}

.partner-logo {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-5);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-weight: 700;
  font-size: var(--text-sm);
  color: var(--text-secondary);
  opacity: 0.75;
  transition: opacity var(--transition), border-color var(--transition), transform var(--transition);
  white-space: nowrap;
}

.partner-logo:hover {
  opacity: 1;
  border-color: rgba(255, 77, 77, 0.35);
  transform: translateY(-2px);
}

.partner-logo__mark {
  color: var(--brand-red);
  font-size: .65rem;
}

/* Compact article grid */
.articles-grid--compact {
  width: min(100% - (var(--section-px) * 2), var(--container));
  margin-inline: auto;
}

@media (min-width: 640px) {
  .articles-grid--compact { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 960px) {
  .articles-grid--compact { grid-template-columns: repeat(3, 1fr); }
}

/* Link underline micro-interaction */
.intro-section__body a:not(.btn),
.services-heading a:not(.btn),
.article-card__title a {
  background-image: linear-gradient(var(--brand-red), var(--brand-red));
  background-size: 0 1px;
  background-repeat: no-repeat;
  background-position: 0 100%;
  transition: background-size var(--transition), color var(--transition);
}

.intro-section__body a:not(.btn):hover,
.article-card__title a:hover {
  background-size: 100% 1px;
}

/* Inner page full-width bands inside node body */
.node__content > .section-band {
  width: 100vw;
  margin-inline: calc(50% - 50vw);
  padding-inline: max(1rem, calc(50vw - var(--container) / 2));
}

.path-frontpage .node__content > .section-band,
.path-frontpage .node__content .section-band,
.front-content .node__content > .section-band,
.front-content .node__content .section-band {
  width: 100%;
  margin-inline: 0;
  padding-inline: 0;
}

@media print {
  .site-header, .site-footer, .nav-toggle { display: none; }
}
