/* Custom additions that shouldn't affect the original template layout */

/* Cursor line / ripple trail (canvas#trail) — disabled; use normal cursor */
#trail.cursor-trail,
canvas#trail {
  display: none !important;
  pointer-events: none !important;
  visibility: hidden !important;
}

.typewriter-cursor {
  display: inline-block;
  width: 0;
  height: 0.9em;
  transform: translateY(-0.05em);
  margin-left: 2px;
  border-right: 2px solid currentColor;
  animation: typewriter-blink 0.9s steps(1, end) infinite;
}

@keyframes typewriter-blink {
  0%,
  49% {
    opacity: 1;
  }
  50%,
  100% {
    opacity: 0;
  }
}

/* CTA block: favicon image inside crosshair frame */
.logo-custom {
  background: transparent !important;
}

.logo-custom .logo-site-sv img.logo-custom-img {
  display: block;
  width: 34px;
  height: auto;
  max-height: 42px;
  object-fit: contain;
}

/* Site logo: Primary PNG default, Main PNG on hover / keyboard focus */
.logo-site.logo-site--png {
  display: inline-flex;
  align-items: center;
  line-height: 0;
}

.logo-site-png-wrap {
  position: relative;
  display: inline-block;
  height: 56px;
}

.logo-site-png {
  height: 56px;
  width: auto;
  max-width: min(248px, 46vw);
  display: block;
  object-fit: contain;
  object-position: left center;
  transition: opacity 0.35s ease;
}

.logo-site-png--hover {
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  opacity: 0;
  pointer-events: none;
}

.logo-site.logo-site--png:hover .logo-site-png--primary,
.logo-site.logo-site--png:focus-visible .logo-site-png--primary {
  opacity: 0;
}

.logo-site.logo-site--png:hover .logo-site-png--hover,
.logo-site.logo-site--png:focus-visible .logo-site-png--hover {
  opacity: 1;
}

/* Phone / iPad: Main logo only (no Primary). Desktop: unchanged swap above. */
@media (max-width: 1199px) {
  .logo-site.logo-site--png .logo-site-png--primary {
    opacity: 0;
    pointer-events: none;
  }

  .logo-site.logo-site--png .logo-site-png--hover {
    opacity: 1;
    pointer-events: none;
  }

  .logo-site.logo-site--png:hover .logo-site-png--primary,
  .logo-site.logo-site--png:focus-visible .logo-site-png--primary {
    opacity: 0;
  }

  .logo-site.logo-site--png:hover .logo-site-png--hover,
  .logo-site.logo-site--png:focus-visible .logo-site-png--hover {
    opacity: 1;
  }
}

/* Brands section — two rows: 6 logos, then 5 (overrides theme 5-col grid) */
.section-brand .brand-list.brand-list--two-rows {
  display: flex;
  flex-direction: column;
  width: 100%;
}

.section-brand .brand-list.brand-list--two-rows .brand-row {
  display: grid;
  width: 100%;
  gap: 0;
}

.section-brand .brand-list.brand-list--two-rows .img-brand {
  aspect-ratio: auto;
  min-height: clamp(96px, 12vw, 132px);
  padding: clamp(20px, 3vw, 32px);
}

.section-brand .brand-list.brand-list--two-rows .img-brand__img {
  max-height: clamp(64px, 8.5vw, 96px);
  width: auto;
  max-width: 100%;
  height: auto;
  object-fit: contain;
}

@media (min-width: 768px) {
  .section-brand .brand-list.brand-list--two-rows .brand-row--6 {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }

  .section-brand .brand-list.brand-list--two-rows .brand-row--5 {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

@media (min-width: 576px) and (max-width: 767px) {
  .section-brand .brand-list.brand-list--two-rows .brand-row--6,
  .section-brand .brand-list.brand-list--two-rows .brand-row--5 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 575px) {
  .section-brand .brand-list.brand-list--two-rows .brand-row--6,
  .section-brand .brand-list.brand-list--two-rows .brand-row--5 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Grid lines — match theme borders on split rows */
.section-brand .brand-list.brand-list--two-rows .img-brand {
  border-right: 1px solid var(--white-16);
  border-bottom: 1px solid var(--white-16);
}

.section-brand .brand-list.brand-list--two-rows .brand-row--6 .img-brand:nth-child(6n),
.section-brand .brand-list.brand-list--two-rows .brand-row--5 .img-brand:nth-child(5n) {
  border-right: none;
}

.section-brand .brand-list.brand-list--two-rows .brand-row--6 .img-brand {
  border-top: 1px solid var(--white-16);
}

.section-brand .brand-list.brand-list--two-rows.type-line-2 .img-brand {
  border-color: #c4c4c4 !important;
}

/* Default: Brand secondary — hover / focus: Brand main (same filename in Brand main/) */
.section-brand .img-brand--dual .img-brand__pair {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 0;
  line-height: 0;
  transition: transform 0.35s ease;
}

.section-brand .img-brand--dual .img-brand__img--secondary {
  position: relative;
  z-index: 0;
  transition: opacity 0.35s ease;
}

.section-brand .img-brand--dual .img-brand__img--main {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 1;
  transform: translate(-50%, -50%);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}

.section-brand .img-brand--dual:hover .img-brand__img--secondary,
.section-brand .img-brand--dual:focus-visible .img-brand__img--secondary {
  opacity: 0;
}

.section-brand .img-brand--dual:hover .img-brand__img--main,
.section-brand .img-brand--dual:focus-visible .img-brand__img--main {
  opacity: 1;
  transform: translate(-50%, -50%);
}

/* Theme scales img on hover — cancel on secondary; keep main centered */
.section-brand .img-brand--dual:hover .img-brand__img--secondary,
.section-brand .img-brand--dual:focus-visible .img-brand__img--secondary {
  transform: none;
}

.section-brand .img-brand--dual:hover .img-brand__pair,
.section-brand .img-brand--dual:focus-visible .img-brand__pair {
  transform: scale(1.06);
}

/* About page: default Brand main — hover / focus: Brand secondary */
.page-about .section-brand--about .img-brand--dual-about .img-brand__pair {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 0;
  line-height: 0;
  transition: transform 0.35s ease;
}

.page-about .section-brand--about .img-brand--dual-about .img-brand__img--about-main {
  position: relative;
  z-index: 0;
  transition: opacity 0.35s ease;
}

.page-about .section-brand--about .img-brand--dual-about .img-brand__img--about-secondary {
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 1;
  transform: translate(-50%, -50%);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}

.page-about .section-brand--about .img-brand--dual-about:hover .img-brand__img--about-main,
.page-about .section-brand--about .img-brand--dual-about:focus-visible .img-brand__img--about-main {
  opacity: 0;
}

.page-about .section-brand--about .img-brand--dual-about:hover .img-brand__img--about-secondary,
.page-about .section-brand--about .img-brand--dual-about:focus-visible .img-brand__img--about-secondary {
  opacity: 1;
  transform: translate(-50%, -50%);
}

.page-about .section-brand--about .img-brand--dual-about:hover .img-brand__img--about-main,
.page-about .section-brand--about .img-brand--dual-about:focus-visible .img-brand__img--about-main {
  transform: none;
}

.page-about .section-brand--about .img-brand--dual-about:hover .img-brand__pair,
.page-about .section-brand--about .img-brand--dual-about:focus-visible .img-brand__pair {
  transform: scale(1.06);
}

/* About page: founder name under photo */
.page-about .about-founder-name {
  margin-top: 14px;
  font-size: clamp(20px, 2.2vw, 34px);
  line-height: 1.15;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: #fff;
}

/* ------------------------------------------------------------------
   Brand palette UI — Dàvídsècóurt
   Primaries: #2E7FC3 · #0FB0DC · #94C23F · #EB4B3A
   Neutrals: white · dark grey rgb(116,222,204)→#74DECC · #000 · grey #A2ED85
   ------------------------------------------------------------------ */

/* Kill horizontal overflow + bottom “blue line” (often = horizontal scrollbar styled with brand blue) */
html {
  overflow-x: hidden;
  max-width: 100%;
}

body {
  overflow-x: hidden;
  max-width: 100%;
  padding-left: env(safe-area-inset-left, 0);
  padding-right: env(safe-area-inset-right, 0);
  background-color: var(--neutral-black);
  background-image:
    radial-gradient(ellipse 100% 70% at 15% -10%, rgba(46, 127, 195, 0.2), transparent 52%),
    radial-gradient(ellipse 70% 50% at 95% 25%, rgba(235, 75, 58, 0.09), transparent 48%),
    radial-gradient(ellipse 55% 45% at 0% 85%, rgba(148, 198, 63, 0.08), transparent 42%),
    /* Softer + lower so it doesn’t read as a hard line along the viewport bottom */
    radial-gradient(ellipse 85% 55% at 50% 120%, rgba(15, 176, 220, 0.03), transparent 62%);
  background-attachment: fixed;
  color: var(--neutral-white);
}

/* Ensure the very bottom of the page stays pure black */
.tf-footer {
  background-image: none !important;
}

/* Footer brand expression — full-bleed + watermark feel */
.tf-footer .footer-bottom .container {
  max-width: none;
  padding-left: 0;
  padding-right: 0;
}

.tf-footer .footer-bottom .img-agency {
  position: relative;
  left: auto;
  width: 100%;
  transform: none;
  margin: 0;
  padding: 0;
  height: auto;
  overflow: visible;
  display: none; /* default: hidden on all devices */
  justify-content: center;
  align-items: center;
  text-align: center;
}

/* Desktop only (mouse/trackpad): show watermark + force true full-bleed */
@media (hover: hover) and (pointer: fine) and (min-width: 992px) {
  .tf-footer .footer-bottom .img-agency {
    display: flex;
    width: 100dvw;
    max-width: 100dvw;
    margin-left: calc(50% - 50dvw);
    margin-right: calc(50% - 50dvw);
  }
}

/* Keep only a tiny gap below the watermark image */
.tf-footer .footer-bottom .bottom {
  margin-top: 0 !important;
  padding-top: 5px;
}

/* Remove template spacing that creates large empty gap */
.tf-footer .footer-bottom {
  padding-bottom: 5px;
}

.tf-footer .footer-bottom .img-agency {
  margin-bottom: 0 !important;
}

.tf-footer .footer-bottom .img-agency img {
  display: block;
  /* Full-bleed watermark: make the *image* span the viewport */
  width: 100%;
  max-width: 100%;
  margin-inline: auto;
  height: auto;
  object-fit: contain; /* never crop */
  /* Desktop: artwork is right-heavy; bias slightly left so logo/name look centered */
  object-position: 45% 50%;
  opacity: 0.14;
  filter: grayscale(1) contrast(1.06) brightness(0.92);
}

@media (max-width: 991px) {
  /* Hidden on tablets/phones */
  .tf-footer .footer-bottom .img-agency {
    display: none !important;
  }

  /* no img rules needed */
}

@media (max-width: 575px) {
  /* Watermark hidden on phones; no additional rules needed */
}

#wrapper {
  overflow-x: hidden;
  max-width: 100%;
}

/* Footer — solid black */
.tf-footer,
.tf-footer .footer-inner,
.tf-footer .footer-bottom {
  background-color: var(--neutral-black) !important;
}

/* Section / footer rules — brand light grey on dark */
.br-line,
.tf-footer .br-line {
  background-color: rgba(var(--neutral-grey-rgb), 0.2) !important;
}

.tf-footer .footer-heading {
  color: rgba(var(--neutral-grey-rgb), 0.9) !important;
}

/* Header & mobile menu meta — brand grey */
.tf-header .header-contact .text-caption,
.offcanvas-menu .canvas_foot .text-caption {
  color: rgba(var(--neutral-grey-rgb), 0.72) !important;
}

::selection {
  background: rgba(15, 176, 220, 0.45);
  color: #fff;
}

:focus-visible {
  outline: 2px solid var(--brand-cyan);
  outline-offset: 3px;
}

:focus:not(:focus-visible) {
  outline: none;
}

/* Header / nav — solid black */
header.tf-header,
.tf-header .header-inner {
  background-color: var(--neutral-black) !important;
  background-image: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: none;
}

/* Nav links: cyan underline on hover */
.nav-menu-main .menu-item .item-link {
  position: relative;
  transition: color 0.25s ease;
}

.nav-menu-main .menu-item .item-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--brand-cyan), var(--brand-blue));
  transition: width 0.3s ease;
}

.nav-menu-main .menu-item .item-link:hover,
.nav-menu-main .menu-item .item-link:focus-visible {
  color: var(--brand-cyan) !important;
}

.nav-menu-main .menu-item .item-link:hover::after,
.nav-menu-main .menu-item .item-link:focus-visible::after {
  width: 100%;
}

/* Primary CTA buttons — glow + depth */
.tf-btn.style-fill {
  box-shadow:
    0 0 0 1px rgba(46, 127, 195, 0.35),
    0 4px 24px rgba(15, 176, 220, 0.2);
  transition:
    box-shadow 0.35s ease,
    transform 0.25s ease,
    filter 0.25s ease;
}

.tf-btn.style-fill:hover {
  box-shadow:
    0 0 0 1px rgba(15, 176, 220, 0.5),
    0 8px 32px rgba(46, 127, 195, 0.35),
    0 0 48px rgba(235, 75, 58, 0.12);
  transform: translateY(-1px);
  filter: brightness(1.06);
}

.tf-btn.style-fill:active {
  transform: translateY(0);
  filter: brightness(0.98);
}

/* Outline hero CTA — brand ring */
.tf-btn:not(.style-fill):not(.style-fill-white):hover {
  border-color: var(--brand-cyan);
  color: var(--brand-cyan);
  box-shadow: 0 0 20px rgba(15, 176, 220, 0.15);
}

.tf-btn:not(.style-fill):not(.style-fill-white):hover::before {
  background: linear-gradient(135deg, rgba(15, 176, 220, 0.15), rgba(46, 127, 195, 0.12));
  top: 0;
}

/* Hero CTA row: place both buttons side-by-side */
.hero-cta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
}

.hero-cta-row .tf-btn {
  min-width: 200px;
  justify-content: center;
  text-align: center;
}

@media (max-width: 575px) {
  .hero-cta-row {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-cta-row .tf-btn {
    width: 100%;
    min-width: 0;
  }
}

/* Selected works nav: Slick can size slide width from shorter titles, clipping longer ones */
.section-selected-work .slick-nav.slick-vertical .slick-list {
  width: 100%;
}

.section-selected-work .slick-nav.slick-vertical .slick-track {
  width: 100% !important;
}

.section-selected-work .slick-nav.slick-vertical .slick-slide {
  width: 100% !important;
  max-width: 100%;
  box-sizing: border-box;
}

.section-selected-work .slick-nav .slick-slide .text-slide {
  white-space: normal;
  overflow-wrap: break-word;
  word-wrap: break-word;
  max-width: 100%;
  padding-inline-end: 4px;
}

/* Avoid theme-wide backface-visibility on slides clipping 3D-rotated nav titles */
.section-selected-work .slick-nav .slick-slide {
  backface-visibility: visible;
  -webkit-backface-visibility: visible;
}

/* Services page: header uses negative margin for the home hero; cancel it here so the title is not tucked under the nav */
body.page-services .tf-header {
  margin-bottom: 0;
}

/* Extra top breathing room below sticky nav (flat-spacing already applies; this ensures the display title clears) */
body.page-services .section-services-page.flat-spacing {
  padding-top: clamp(100px, 14vw, 160px);
}

body.page-services .section-services-page h1 {
  scroll-margin-top: 96px;
}

/* Blog page: same header overlap fix as services */
body.page-blog .tf-header {
  margin-bottom: 0;
}

body.page-blog .section-blog-page.flat-spacing {
  padding-top: clamp(100px, 14vw, 160px);
}

body.page-blog .section-blog-page h1 {
  scroll-margin-top: 96px;
}

body.page-blog .blog-article h2 {
  scroll-margin-top: 96px;
}

/* Blog alignment fix: keep every article on the same grid column */
body.page-blog .blog-article {
  max-width: none;
  margin-inline: 0;
}

/* Keep text readable without shrinking the whole article container */
body.page-blog .blog-article .text-body-1,
body.page-blog .blog-article .text-caption {
  max-width: 68ch;
}

/* Contact page: same header overlap fix as services / blog */
body.page-contact .tf-header {
  margin-bottom: 0;
}

body.page-contact .section-contact.flat-spacing {
  padding-top: clamp(100px, 14vw, 160px);
}

body.page-contact .section-contact h1 {
  scroll-margin-top: 96px;
}

/* Portfolio hub + brand galleries (portfolio.html, portfolio-*-*.html) */
body.page-portfolio .tf-header {
  margin-bottom: 0;
}

body.page-portfolio .section-portfolio-page.flat-spacing {
  padding-top: clamp(100px, 14vw, 160px);
  padding-bottom: clamp(48px, 8vw, 96px);
}

body.page-portfolio .section-portfolio-page h1 {
  scroll-margin-top: 96px;
}

.portfolio-breadcrumb a {
  text-decoration: none;
}

.portfolio-breadcrumb a:hover {
  color: var(--primary, #c9a962);
}

.portfolio-brand-hub-grid {
  display: grid;
  gap: clamp(20px, 3vw, 32px);
  grid-template-columns: 1fr;
  max-width: 1100px;
  margin-inline: auto;
}

@media (min-width: 768px) {
  .portfolio-brand-hub-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.portfolio-brand-hub-card {
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.02);
  border-radius: clamp(12px, 2vw, 18px);
  overflow: hidden;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.22);
  transition:
    border-color 0.28s ease,
    transform 0.28s ease,
    box-shadow 0.28s ease;
}

.portfolio-brand-hub-card:hover {
  border-color: rgba(255, 255, 255, 0.22);
  transform: translateY(-3px);
  box-shadow: 0 22px 56px rgba(0, 0, 0, 0.36);
}

.portfolio-brand-hub-card__media {
  overflow: hidden;
}

.portfolio-brand-hub-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.portfolio-brand-hub-card__meta {
  padding: clamp(20px, 3vw, 28px);
}

.portfolio-gallery-grid .portfolio-gallery-item img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 2px;
  border: 1px solid rgba(255, 255, 255, 0.06);
}

/* Home: contact teaser block (anchor #contactScroll) */
.section-contact-teaser {
  scroll-margin-top: 96px;
}

/* Home: tighten bottom spacing before footer */
.section-contact-teaser.flat-spacing {
  padding-bottom: clamp(28px, 5vw, 64px);
}

/* Services page: keep primary + secondary CTAs on one baseline */
.services-page-cta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

/* Services detail page — moderate, uniform image frames under each pillar */
body.page-services .services-pillar-visual {
  display: block;
  width: min(100%, 420px);
  margin: clamp(20px, 3.5vw, 36px) auto 0;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border-radius: 3px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(0, 0, 0, 0.2);
}

body.page-services .services-pillar-visual img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

@media (max-width: 575px) {
  body.page-services .services-pillar-visual {
    width: min(100%, 320px);
    aspect-ratio: 4 / 3;
    margin-top: clamp(16px, 4vw, 24px);
  }
}

/* Home services intro: title + subtitle only (no CTA in header row) */
.portfolio-services-header.s-header {
  justify-content: flex-start;
}

/* Works (Portfolio) — header, filters, spotlight cards */
.section-feature-portfolio .portfolio-works-s-header.s-header {
  padding-bottom: 20px;
  align-items: flex-end;
}
.section-feature-portfolio .portfolio-works-heading .portfolio-works-subhead {
  margin-top: 12px;
}
.section-feature-portfolio .portfolio-works-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 10px 14px;
  margin-top: 0;
  margin-bottom: 40px;
}
.section-feature-portfolio .portfolio-filter-sep {
  color: rgba(255, 255, 255, 0.28);
  user-select: none;
}
/* Phones: center Works (Portfolio), Proven Impact., BROWSE ALL, and filter chips */
@media (max-width: 767px) {
  .section-feature-portfolio .portfolio-works-s-header {
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    text-align: center;
  }

  .section-feature-portfolio .portfolio-works-heading {
    width: 100%;
    text-align: center;
  }

  .section-feature-portfolio .portfolio-works-heading .portfolio-works-subhead {
    margin-left: auto;
    margin-right: auto;
    max-width: 22em;
  }

  .section-feature-portfolio .portfolio-works-s-header .tf-btn {
    margin-top: 16px;
    margin-left: auto;
    margin-right: auto;
    align-self: center;
  }

  .section-feature-portfolio .portfolio-works-filters {
    justify-content: center;
    text-align: center;
  }
}

/* Home: Works (Portfolio) — keep all cards same image height */
.section-feature-portfolio .portfolio-work-card .feature-image {
  display: block;
  aspect-ratio: 4 / 3;
  overflow: hidden;
}

.section-feature-portfolio .portfolio-work-card .feature-image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.section-feature-portfolio .portfolio-work-card .feature-content {
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-end;
  padding: 18px 22px 22px;
}
.section-feature-portfolio .portfolio-spotlight-info {
  width: 100%;
  max-width: 100%;
}
.section-feature-portfolio .portfolio-spotlight-info .name {
  margin-top: 4px;
  margin-bottom: 14px;
}
.section-feature-portfolio .portfolio-spotlight-body {
  line-height: 1.5;
  max-width: 42em;
}

/* Scroll to top */
#goTop .border-progress {
  filter: drop-shadow(0 0 6px rgba(15, 176, 220, 0.4));
}

/* Scrollbar — brand tint on vertical only (horizontal bar looked like a full-width blue strip) */
body::-webkit-scrollbar:horizontal {
  display: none;
  height: 0;
}

body::-webkit-scrollbar {
  width: 6px;
}

body::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--brand-cyan), var(--brand-blue));
  border-radius: 4px;
}

body::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, var(--brand-blue), var(--brand-coral));
}

/* Hero — pin content to bottom; keep brand name on the lower edge of the section */
.section-hero-v1 {
  position: relative;
  flex-direction: column;
  justify-content: flex-end;
  align-items: stretch;
}

.section-hero-v1 .overlay,
.section-hero-v1 .bg-video {
  position: absolute;
  inset: 0;
}

.section-hero-v1 .bg-video {
  z-index: 0;
  overflow: hidden;
}

.section-hero-v1 .bg-video video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* Nudge framing upward so the clip's top logo remains visible */
  object-position: 50% -44px;
  display: block;
}

@media (max-width: 575px) {
  .section-hero-v1 .bg-video video {
    object-position: 50% -28px;
  }
}

.section-hero-v1 .overlay {
  z-index: 1;
}

.section-hero-v1 .content-wrap {
  flex-shrink: 0;
  position: relative;
  z-index: 2;
}

/* Home hero: bring the hero down a bit so the clip's top content is visible */
body.page-home .section-hero-v1 {
  min-height: clamp(520px, 78vh, 860px);
}

@media (max-width: 575px) {
  body.page-home .section-hero-v1 {
    min-height: clamp(520px, 72vh, 760px);
  }
}

/* Home hero: keep top of video clear; darken only toward the bottom for text readability */
body.page-home .section-hero-v1 > .overlay {
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0) 0%,
    rgba(0, 0, 0, 0) 68%,
    rgba(0, 0, 0, 0.14) 84%,
    rgba(0, 0, 0, 0.55) 100%
  ) !important;
}

/* Theme uses space-between on columns; stack title + value props at bottom, left-aligned */
.section-hero-v1 .col-left {
  justify-content: flex-end;
  align-items: flex-start;
}

/* Hero brand title — smaller type; row aligns both columns to the bottom edge */
.section-hero-v1 .content-wrap .row {
  align-items: flex-end;
}

.section-hero-v1 .davies-large {
  font-size: clamp(32px, 6.25vw, 112px);
  line-height: clamp(36px, 5.75vw, 102px);
}

/* Hero — core value props: left column, grouped panel, tight rhythm */
.section-hero-v1 .hero-value-props {
  width: 100%;
  max-width: min(36rem, 100%);
  margin-top: clamp(16px, 2.5vw, 22px);
  padding: 14px 16px 16px;
  border-radius: 12px;
  background: linear-gradient(145deg, rgba(15, 28, 27, 0.72) 0%, rgba(0, 0, 0, 0.45) 100%);
  border: 1px solid rgba(255, 255, 255, 0.09);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.section-hero-v1 .hero-value-props__title {
  margin: 0 0 10px;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
  line-height: 1.3;
}

.section-hero-v1 .hero-value-props__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.section-hero-v1 .hero-value-props__list li {
  margin: 0;
  padding-left: 14px;
  position: relative;
  font-size: 0.8125rem;
  line-height: 1.45;
  color: rgba(255, 255, 255, 0.78);
}

.section-hero-v1 .hero-value-props__list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--brand-cyan), var(--brand-blue));
  box-shadow: 0 0 10px rgba(15, 176, 220, 0.35);
}

.section-hero-v1 .hero-value-props__name {
  font-weight: 600;
  color: rgba(255, 255, 255, 0.95);
}

/* Selected Works — mountain sits above slide rail (hides broken/placeholder imgs); nav column stays clear */
.section-selected-work {
  isolation: isolate;
  background-color: var(--neutral-black);
}

.section-selected-work .content-wrap-1 .col-left {
  position: relative;
  z-index: 3;
}

.section-selected-work .col-right {
  position: relative;
  z-index: 0;
}

/* Full-bleed from the 8-col so peaks still span the layout; painted above .slick-for */
.section-selected-work .col-right .selected-work-mountain {
  position: absolute;
  right: 0;
  bottom: 0;
  top: auto;
  left: 50%;
  width: 100vw;
  max-width: none;
  transform: translateX(-50%);
  z-index: 2;
  pointer-events: none;
  display: flex;
  align-items: stretch;
  justify-content: stretch;
  height: clamp(220px, 34vh, 420px);
  background: none;
}

.section-selected-work .col-right .slick-for {
  position: relative;
  z-index: 0;
}

.section-selected-work .col-right .slick-for .image {
  width: 100%;
  max-width: 860px;
  margin-left: auto;
  margin-right: auto;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.06);
}

.section-selected-work .col-right .slick-for .image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.section-selected-work .col-right .slick-for .slick-slide {
  /* Give the mountain some foreground space to overlap the image */
  padding-bottom: clamp(56px, 9vw, 120px);
}

/* (Override) Keep the mountain overlay only on the lower portion */
.section-selected-work .col-right .selected-work-mountain {
  top: auto;
  bottom: 0;
  height: clamp(220px, 34vh, 420px);
}

.section-selected-work .col-right .selected-work-mountain img {
  width: 100%;
  height: 100%;
  min-height: 100%;
  object-fit: cover;
  object-position: center bottom;
  opacity: 1;
  filter: brightness(0.72) contrast(1.05);
  display: block;
}

/* Bottom bar — pills | centered PREV/NEXT | year (above mountain edge) */
.section-selected-work .content-wrap-2 {
  position: relative;
  z-index: 4;
  padding-top: 8px;
  padding-bottom: clamp(20px, 3.5vw, 36px);
}

.section-selected-work .selected-work-slider-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 28px 40px;
  width: 100%;
}

/* Theme sets flex-start on small screens — keep PREV/NEXT centered */
@media (max-width: 767px) {
  .section-selected-work .content-wrap-2 .selected-work-slider-nav {
    justify-content: center;
  }
}

.section-selected-work .selected-work-year {
  line-height: 0.95;
}

/* Vertical project list — center row bright, others muted (matches reference) */
.section-selected-work .slick-nav .slick-slide:not(.slick-center) .text-slide {
  color: rgba(255, 255, 255, 0.34);
  font-weight: 500;
}

.section-selected-work .slick-nav .slick-slide.slick-center .text-slide {
  color: #fff;
  font-weight: 600;
}

/* Hero video — natural color (theme uses primary + mix-blend-mode:hue on .video-overlay → blue cast) */
.section-hero-v1 .bg-video .video-overlay {
  display: none !important;
}

/* Avoid double-dimming bands: use only one hero overlay layer */
.section-hero-v1 .bg-video .video-overlay-2 {
  display: none !important;
}

/* Accent underscore in hero title */
.section-hero-v1 .text-primary {
  text-shadow: 0 0 40px rgba(15, 176, 220, 0.35);
}

/* Preloader bars — multi-stop brand */
.preloader .preloader-gutters .bar .inner-bar {
  background: linear-gradient(180deg, var(--brand-cyan) 0%, var(--brand-blue) 50%, var(--brand-green) 100%);
}

/* Preloader: prevent "typing cursor" flash on non-home pages */
.preloader {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100dvh;
  max-width: 100vw;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  overflow: hidden;
  z-index: 9999;
  --preloader-clip: 0%;
  clip-path: none !important;
  -webkit-clip-path: none !important;
  mask: none !important;
  -webkit-mask: none !important;
}

/* Only enable when JS explicitly activates (home first load) */
.preloader.preloader--active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* Ensure preloader bars always fill entire viewport width */
.preloader .preloader-gutters {
  position: fixed;
  left: 0;
  top: 0;
  width: 100vw;
  height: 100dvh;
  max-width: 100vw;
  max-height: 100dvh;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(8, minmax(0, 1fr));
  z-index: 1;
  clip-path: none !important;
  -webkit-clip-path: none !important;
  mask: none !important;
  -webkit-mask: none !important;
}

.preloader .preloader-gutters .bar {
  width: 100%;
  height: 100%;
  overflow: hidden;
  min-width: 0;
}

.preloader .preloader-gutters .bar .inner-bar {
  width: 0%;
  height: 100%;
}

/* Optional: gradient text utility for headings */
.text-brand-gradient {
  background: var(--brand-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

/* Cards / process hover ring */
.wg-process:hover {
  box-shadow: 0 0 0 1px rgba(46, 127, 195, 0.25), 0 12px 40px rgba(0, 0, 0, 0.35);
}

/* Sticky nav — solid black */
header.tf-header.header-sticky,
header.header-sticky.tf-header {
  background-color: var(--neutral-black) !important;
  background-image: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: none;
}

/* Home (non-sticky): keep the top strip, but let the video show through */
body.page-home header.tf-header:not(.header-sticky) {
  background: var(--neutral-black) !important;
  /* No blur */
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  border-bottom-color: rgba(255, 255, 255, 0.06);
}

/* Ensure the hero video itself is never blurred */
body.page-home .section-hero-v1 .bg-video,
body.page-home .section-hero-v1 .bg-video video {
  filter: none !important;
}

/* Mobile drawer — neutral surfaces */
.offcanvas-menu .offcanvas-content {
  background: linear-gradient(
    165deg,
    var(--neutral-black) 0%,
    #141414 40%,
    rgba(var(--neutral-dark-grey-rgb), 0.35) 100%
  );
}

/* Utility: explicit brand neutrals for light sections or CMS */
.text-neutral-dark-grey {
  color: var(--neutral-dark-grey) !important;
}
.text-neutral-grey {
  color: var(--neutral-grey) !important;
}
.bg-neutral-black {
  background-color: var(--neutral-black) !important;
}
.bg-neutral-dark-grey {
  background-color: var(--neutral-dark-grey) !important;
}
.bg-neutral-grey {
  background-color: var(--neutral-grey) !important;
}
.border-neutral-grey {
  border-color: rgba(var(--neutral-grey-rgb), 0.4) !important;
}

/* Form focus — brand */
.form-cta input:focus,
.form-cta textarea:focus,
.tf-field input:focus,
.tf-field textarea:focus {
  border-color: var(--brand-cyan) !important;
  box-shadow: 0 0 0 3px rgba(15, 176, 220, 0.2);
}

/* Contact form: big “Thank you” state after submit */
.contact-cta-thanks {
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: linear-gradient(145deg, rgba(15, 28, 27, 0.72) 0%, rgba(0, 0, 0, 0.55) 100%);
  box-shadow: 0 16px 52px rgba(0, 0, 0, 0.35);
  border-radius: clamp(14px, 2.6vw, 22px);
  padding: clamp(28px, 5.5vw, 56px);
  text-align: center;
  min-height: clamp(240px, 34vh, 360px);
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.contact-cta-thanks__inner {
  max-width: 46rem;
}

.contact-cta-thanks h2 {
  text-shadow: 0 0 40px rgba(15, 176, 220, 0.22);
}

/* Contact — “Tell us your wildest idea.”: extra top space so the floating label isn’t flush / clipped on the border */
.form-cta .tf-field--textarea {
  overflow: visible;
}

.form-cta .tf-field--textarea textarea.tf-input {
  padding-top: 42px;
  padding-bottom: 16px;
  padding-left: 6px;
  padding-right: 16px;
}

@media (min-width: 576px) {
  .form-cta .tf-field--textarea .tf-lable {
    top: 14px;
    left: 6px;
    right: 18px;
    width: auto;
    max-width: calc(100% - 24px);
    white-space: normal;
    line-height: 1.35;
    z-index: 2;
  }

  .form-cta .tf-field--textarea textarea.tf-input:focus ~ .tf-lable,
  .form-cta .tf-field--textarea textarea.tf-input:not(:placeholder-shown) ~ .tf-lable {
    top: 8px;
    font-size: 11px;
    line-height: 1.3;
  }
}

@media (max-width: 575px) {
  .form-cta .tf-field--textarea textarea.tf-input {
    padding-top: 16px;
  }
}

/* Trusted founders — same image frame height on every card */
.testimonial-v01 .author_image {
  width: 100%;
  aspect-ratio: 3 / 4;
  overflow: hidden;
}

.testimonial-v01 .author_image img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 0;
  object-fit: cover;
  object-position: center top;
}

/* ------------------------------------------------------------------
   Global responsive polish (all pages)
   ------------------------------------------------------------------ */

.tf-header .header-contact .link {
  overflow-wrap: anywhere;
  word-break: break-word;
}

@media (max-width: 575px) {
  .btn-mobile-menu {
    gap: 4px;
    font-size: 10px;
    letter-spacing: 0.02em;
  }

  .footer-bottom .bottom {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
}

/* ------------------------------------------------------------------
   Responsive + modern polish (mobile / tablet / desktop)
   ------------------------------------------------------------------ */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

/* Fluid horizontal rhythm — keeps content off screen edges on phones */
#wrapper .container {
  padding-left: clamp(14px, 4.2vw, 24px);
  padding-right: clamp(14px, 4.2vw, 24px);
}

/* Footer watermark must be true full-bleed (override #wrapper .container padding) */
#wrapper .tf-footer .footer-bottom .container {
  padding-left: 0;
  padding-right: 0;
}

/* Ensure the full-bleed watermark is never clipped on tablets/phones */
#wrapper .tf-footer,
#wrapper .tf-footer .footer-bottom,
#wrapper .tf-footer .footer-bottom .img-agency {
  overflow: visible;
}

/* Prevent any device from “cropping” the watermark image */
#wrapper .tf-footer .footer-bottom .img-agency img {
  max-width: none;
}

/* Media never spills viewport (do not set video height — breaks hero full-bleed) */
#wrapper img,
#wrapper video,
#wrapper iframe,
#wrapper svg {
  max-width: 100%;
}

/* Header: align + comfortable tap target for MENU */
.tf-header .header-inner .row {
  align-items: center;
  min-height: 56px;
}

.btn-mobile-menu {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  min-width: 44px;
  padding: 10px 14px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.03);
  transition:
    background 0.25s ease,
    border-color 0.25s ease,
    color 0.25s ease;
}

.btn-mobile-menu:hover,
.btn-mobile-menu:focus-visible {
  border-color: rgba(15, 176, 220, 0.45);
  background: rgba(15, 176, 220, 0.08);
  color: #fff;
}

@media (max-width: 400px) {
  .logo-site-png-wrap {
    height: 48px;
  }

  .logo-site-png {
    height: 48px;
    max-width: min(200px, 52vw);
  }
}

/* Offcanvas: readable scale + tappable nav */
.offcanvas-menu .mb-menu-link.text-display-1 {
  font-size: clamp(34px, 10vw, 56px);
  line-height: 1.05;
  letter-spacing: -0.02em;
}

.offcanvas-menu .nav-ul-mb .item {
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.offcanvas-menu .nav-ul-mb .mb-menu-link {
  padding-block: clamp(10px, 2.5vw, 16px);
}

.offcanvas-menu .canvas_foot .right {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  gap: 10px 18px;
}

.offcanvas-menu .canvas_foot .tf-link-icon {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

/* Section headings — slightly tighter on narrow phones */
@media (max-width: 575px) {
  .flat-spacing .text-display-2,
  .section-cta .text-display-2 {
    font-size: clamp(26px, 8.5vw, 44px);
    line-height: 1.12;
    letter-spacing: -0.02em;
  }

  .flat-spacing .text-64,
  .flat-spacing .text-80 {
    letter-spacing: -0.02em;
  }
}

/* Section vertical rhythm — a bit more breathing room on large screens */
@media (min-width: 1400px) {
  .flat-spacing {
    padding-top: clamp(100px, 8vw, 140px);
    padding-bottom: clamp(100px, 8vw, 140px);
  }
}

/* Footer: clearer grouping + tap-friendly links */
.tf-footer .footer-inner .row {
  row-gap: clamp(20px, 4vw, 36px);
}

.tf-footer .footer-menu-list li a {
  display: inline-block;
  padding: 6px 0;
  border-radius: 4px;
  transition: color 0.2s ease, transform 0.2s ease;
}

.tf-footer .footer-menu-list li a:hover,
.tf-footer .footer-menu-list li a:focus-visible {
  color: var(--brand-cyan);
}

.footer-bottom .bottom .action-go-top {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

/* Scroll-to-top — clear of home indicator / notch */
#goTop {
  bottom: max(24px, env(safe-area-inset-bottom, 0px) + 12px);
  right: max(16px, env(safe-area-inset-right, 0px) + 8px);
}

/* Works (Portfolio) cards — modern frame + lift on capable devices */
.section-feature-portfolio .portfolio-work-card {
  border-radius: clamp(10px, 1.5vw, 16px);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: rgba(0, 0, 0, 0.2);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.25);
  transition:
    transform 0.4s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.4s ease,
    border-color 0.35s ease;
}

.section-feature-portfolio .portfolio-work-card .feature-image {
  border-radius: 0;
}

@media (hover: hover) and (pointer: fine) {
  .section-feature-portfolio .portfolio-work-card:hover {
    transform: translateY(-6px);
    border-color: rgba(15, 176, 220, 0.28);
    box-shadow:
      0 24px 56px rgba(0, 0, 0, 0.45),
      0 0 0 1px rgba(46, 127, 195, 0.2),
      0 0 48px rgba(15, 176, 220, 0.08);
  }
}

/* Primary buttons — full width only where it reads as a stack */
@media (max-width: 575px) {
  .section-contact-teaser .tf-btn.style-fill,
  .section-cta .tf-btn.style-fill {
    width: 100%;
    max-width: 320px;
    margin-left: auto;
    margin-right: auto;
    justify-content: center;
  }
}

/* Long-form readability */
.page-about .section-about-me .about-us-body {
  max-width: min(100%, 70ch);
}

/* Tables / wide blocks */
.table-responsive,
.wd-table-wrap {
  -webkit-overflow-scrolling: touch;
}

/* Preloader title — never overflow small screens */
.preloader .site-name {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding-inline: 12px;
  font-size: clamp(18px, 5vw, 42px);
  line-height: 1.2;
  z-index: 2;
  background: transparent !important;
}

.preloader .site-name #preloader-typed-text {
  display: inline-block;
  vertical-align: middle;
  max-width: 92vw;
  white-space: nowrap;
}

/* Tablet: two-column footers breathe */
@media (min-width: 576px) and (max-width: 991px) {
  .tf-footer .footer-inner .row > [class*="col-"] {
    margin-bottom: 0;
  }
}

/* Performance: defer off-screen section rendering on homepage */
@supports (content-visibility: auto) {
  body.page-home .section-selected-work,
  body.page-home .section-service-2,
  body.page-home .section-brand,
  body.page-home .section-testimonial,
  body.page-home .section-indicator,
  body.page-home .section-cta {
    content-visibility: auto;
    contain-intrinsic-size: 900px;
  }
}
