/* INTERNAL TYPEFACES */
/* ---------- Poppins ---------- */
/* Latin-only web fonts (~8 KB each) made from assets/Typeface/Poppins/Poppins-web.zip */
@font-face {
  font-family: "Poppins";
  src: url("../assets/Typeface/Poppins/web/Poppins-Thin.woff2") format("woff2");
  font-weight: 100;
  font-style: normal;
  font-display: swap;
}
 
@font-face {
  font-family: "Poppins";
  src: url("../assets/Typeface/Poppins/web/Poppins-ExtraLight.woff2") format("woff2");
  font-weight: 200;
  font-style: normal;
  font-display: swap;
}
 
@font-face {
  font-family: "Poppins";
  src: url("../assets/Typeface/Poppins/web/Poppins-Light.woff2") format("woff2");
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}
 
@font-face {
  font-family: "Poppins";
  src: url("../assets/Typeface/Poppins/web/Poppins-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
 
@font-face {
  font-family: "Poppins";
  src: url("../assets/Typeface/Poppins/web/Poppins-Medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
 
@font-face {
  font-family: "Poppins";
  src: url("../assets/Typeface/Poppins/web/Poppins-SemiBold.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
 
@font-face {
  font-family: "Poppins";
  src: url("../assets/Typeface/Poppins/web/Poppins-Bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
 
@font-face {
  font-family: "Poppins";
  src: url("../assets/Typeface/Poppins/web/Poppins-ExtraBold.woff2") format("woff2");
  font-weight: 800;
  font-style: normal;
  font-display: swap;
}
 
@font-face {
  font-family: "Poppins";
  src: url("../assets/Typeface/Poppins/web/Poppins-Black.woff2") format("woff2");
  font-weight: 900;
  font-style: normal;
  font-display: swap;
}
 
/* ---------- Montserrat ---------- */
/* One variable file covers every weight (100-900); the loader already preloads it. */
@font-face {
  font-family: "Montserrat";
  src: url("../assets/Typeface/Montserrat/web/Montserrat-latin-var.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
    --white: #ffffff;
    --bg-alt: #f1f5fa;
    --ink: #030316;
    --navy: #010133;
    --prussian: #010930;
    --slate: #70818e;
    --aqua: #a9eae4;
    --ash: #5c6b72;
    --ash-soft: #8a97a0;
    --cyan: #04bfcd;
    --pearl: #72dcdc;
    --slate-grey: #70818e;
    --icy-aqua: #a9eae4;
    --white: #ffffff;
    --surface: #f7f9fa;
    --border: rgba(112, 129, 142, 0.22);
    --shadow-c: 0 20px 60px rgba(3, 3, 22, 0.10);
    --radius-lg: 24px;
    --radius-md: 16px;
    --border: rgba(112, 129, 142, 0.28);
    --shadow: 0 10px 30px -14px rgba(1, 9, 48, 0.14);
    --shadow-lg: 0 24px 60px -20px rgba(1, 9, 48, 0.22);
    --deep-navy: #010133;
    /* used by the contact form ("Continuar" button, steps) */
    --prussian-blue: #010930;

}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    background: var(--white);
    color: var(--ash);
    font-family: "Poppins", sans-serif;
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
    background:
        linear-gradient(100deg,
            rgba(1, 9, 48, 0.92) 0%,
            rgba(1, 9, 48, 0.55) 38%,
            rgba(4, 60, 90, 0.25) 62%,
            rgba(4, 191, 205, 0.28) 100%),
        radial-gradient(120% 130% at 75% 15%, #123a55 0%, #0a2138 42%, #04101f 100%);
}

h1,
h2,
h3 {
    font-family: "Montserrat", serif;
    margin: 0;
    color: var(--ink);
    letter-spacing: -0.01em;
}

p {
    margin: 0;
}

a {
    color: inherit;
    text-decoration: none;
}

section {
    scroll-margin-top: 84px;
}

.bi {
    width: 1em;
    height: 1em;
    display: inline-block;
    vertical-align: -0.125em;
    fill: currentColor;
}

.eyebrow {
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--cyan);
    margin-bottom: 0.7rem;
    display: block;
}

.section {
    position: relative;
    padding: clamp(3.5rem, 7vw, 6rem) 0;
}

.bg-alt-c {
    background: var(--bg-alt);
}

.bg-dark-c {
    background: var(--navy);
}

.bg-dark-c h1,
.bg-dark-c h2,
.bg-dark-c h3 {
    color: var(--white);
}

.bg-dark-c p {
    color: var(--ash-soft);
}

/* ======================================================
      GLOBAL ANIMATIONS | Reveal on Scroll
      ====================================================== */
.reveal {
    opacity: 0;
    transform: translateY(28px);
    transition:
        opacity 0.7s cubic-bezier(0.2, 0.7, 0.2, 1),
        transform 0.7s cubic-bezier(0.2, 0.7, 0.2, 1);
}

.reveal.is-visible {
    opacity: 1;
    transform: none;
}

.reveal-stagger.is-visible .stagger-item {
    opacity: 1;
    transform: none;
}

.stagger-item {
    opacity: 0;
    transform: translateY(20px);
    transition:
        opacity 0.6s ease,
        transform 0.6s ease;
}

.stagger-item:nth-child(1) {
    transition-delay: 0.05s;
}

.stagger-item:nth-child(2) {
    transition-delay: 0.15s;
}

.stagger-item:nth-child(3) {
    transition-delay: 0.25s;
}

.stagger-item:nth-child(4) {
    transition-delay: 0.35s;
}

.stagger-item:nth-child(5) {
    transition-delay: 0.45s;
}



.glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(90px);
    pointer-events: none;
    z-index: 0;
}

.glow-cyan {
    background: radial-gradient(circle, rgba(4, 191, 205, 0.35), transparent 70%);
}

@keyframes floaty {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

@keyframes pulseGlow {

    0%,
    100% {
        opacity: 0.55;
    }

    50% {
        opacity: 1;
    }
}

/* ======================================================
       BUTTONS & LINKS
       ====================================================== */
.btn-cyan {
    background: var(--cyan);
    color: #02181c;
    box-shadow: 0 10px 28px -8px rgba(4, 191, 205, 0.55);
    border: 0;
    font-weight: 700;
}

.btn-cyan:hover {
    transform: translateY(-2px);
    box-shadow: 0 16px 36px -8px rgba(4, 191, 205, 0.7);
    color: #02181c;
}

.btn-outline-c {
    border: 1px solid var(--border);
    color: var(--ink);
    background: var(--white);
    font-weight: 700;
}

.btn-outline-c:hover {
    border-color: var(--cyan);
    color: var(--cyan);
    transform: translateY(-2px);
}

.btn-outline-light-c {
    border: 1px solid rgba(255, 255, 255, 0.55);
    color: var(--white);
    background: rgba(255, 255, 255, 0.06);
    font-weight: 700;
}

.btn-outline-light-c:hover {
    border-color: #fff;
    background: rgba(255, 255, 255, 0.16);
    color: #fff;
    transform: translateY(-2px);
}

.btn-white-c {
    background: var(--white);
    color: var(--ink);
    box-shadow: var(--shadow);
    font-weight: 700;
}

.btn-white-c:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
    color: var(--ink);
}

.btn {
    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease,
        color 0.2s ease,
        border-color 0.2s ease,
        background-color 0.2s ease;
}

.link-arrow {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--cyan);
    font-weight: 700;
    font-size: 0.9rem;
}

.link-arrow .bi {
    transition: transform 0.2s ease;
}

.link-arrow:hover .bi {
    transform: translateX(4px);
}

.card-c {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: 18px;
    box-shadow: var(--shadow);
    transition:
        transform 0.3s ease,
        box-shadow 0.3s ease;
}

.card-c:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.ph {
    background: linear-gradient(160deg, var(--bg-alt), #e4ebf4);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
}

.ph .bi {
    font-size: 2.2rem;
    color: var(--slate);
    opacity: 0.7;
}

/* ======================================================
       GLOBAL KEYFRAMES
       ====================================================== */

@keyframes heroLine {
    to {
        opacity: 1;
        transform: none;
    }
}

@keyframes statIn {
    to {
        opacity: 1;
        transform: none;
    }
}

/* ======================================================
       01. NAVBAR SECTION | Base Component
       ====================================================== */

.navbar-c {
    position: sticky;
    top: 0;
    z-index: 1050;
    background: rgba(255, 255, 255, 0.86);
    backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--border);
    transition:
        box-shadow 0.3s ease,
        padding 0.3s ease;

    &.scrolled {
        box-shadow: 0 8px 24px -16px rgba(1, 9, 48, 0.25);
    }

    .navbar-brand {
        font-family: "Montserrat", serif;
        font-style: italic;
        font-weight: 700;
        color: var(--ink) !important;
        font-size: 1.4rem;
    }

    .nav-link {
        color: var(--ash) !important;
        font-weight: 500;
        font-size: 0.9rem;
        display: flex;
        align-items: center;
        gap: 0.3rem;

        &:hover {
            color: var(--cyan) !important;
        }
    }

    .dropdown-menu {
        border: 1px solid var(--border);
        border-radius: 12px;
        box-shadow: var(--shadow-lg);
        padding: 0.5rem;
    }

    .dropdown-item {
        border-radius: 8px;
        font-size: 0.88rem;
        padding: 0.55rem 0.8rem;

        &:hover {
            background: rgba(4, 191, 205, 0.1);
            color: var(--cyan);
        }
    }
}

/* Hero wrapper */
.hero-wrap {
    padding: clamp(1.4rem, 3vw, 2.2rem) 0 0;
}

/* ======================================================
       02. HERO SECTION | Base Hero Components
       ====================================================== */

.hero {
    position: relative;
    overflow: hidden;
    border-radius: 26px;
    aspect-ratio: 16/8.2;
    min-height: 520px;
    margin: 5rem 2rem 0;
    box-shadow: var(--shadow-lg);

    .hero-inner {
        position: relative;
        z-index: 1;
        height: 100%;
        padding: clamp(1.8rem, 4vw, 3.2rem);
        display: flex;
        flex-direction: column;
        justify-content: space-between;
    }

    .hero-title {
        font-family: "Inter", sans-serif;
        font-weight: 900;
        color: var(--white);
        font-size: clamp(1.8rem, 4.4vw, 3.1rem);
        line-height: 1.06;
        letter-spacing: -0.02em;

        span {
            display: block;
            opacity: 0;
            transform: translateY(22px);
            animation: heroLine 0.7s cubic-bezier(0.2, 0.7, 0.2, 1) forwards;
        }

        span:nth-child(1) {
            animation-delay: 0.05s;
        }

        span:nth-child(2) {
            animation-delay: 0.16s;
        }

        span:nth-child(3) {
            animation-delay: 0.27s;
        }

        span:nth-child(4) {
            animation-delay: 0.38s;
        }
    }

    .hero-sub {
        color: rgba(255, 255, 255, 0.82);
        max-width: 42ch;
        font-size: 0.98rem;
        margin-top: 1.1rem;
    }

    .stat-grid {
        position: absolute;
        right: clamp(1.4rem, 4vw, 3rem);
        top: clamp(1.8rem, 10vw, 7.5rem);
        bottom: clamp(1.8rem, 6vw, 3.2rem);
        width: min(46%, 480px);
        display: grid;
        grid-template-columns: 1.25fr 1fr;
        grid-template-rows: 1fr 1fr auto;
        gap: 0.9rem;
    }

    .stat {
        background: rgba(255, 255, 255, 0.14);
        border: 1px solid rgba(255, 255, 255, 0.28);
        border-radius: 14px;
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        padding: 1rem 1.1rem;
        color: var(--white);
        display: flex;
        flex-direction: column;
        justify-content: center;
        opacity: 0;
        transform: translateY(16px) scale(0.96);
        animation: statIn 0.6s cubic-bezier(0.2, 0.7, 0.2, 1) forwards;

        &:nth-child(1) {
            animation-delay: 0.3s;
        }

        &:nth-child(2) {
            animation-delay: 0.42s;
        }

        &:nth-child(3) {
            animation-delay: 0.54s;
        }

        &:nth-child(4) {
            animation-delay: 0.66s;
        }

        .num {
            font-family: "Inter", sans-serif;
            font-weight: 800;
            font-size: 1.6rem;
            line-height: 1;
        }

        .label {
            font-size: 0.76rem;
            color: rgba(255, 255, 255, 0.85);
            margin-top: 0.3rem;
        }
    }

    .stat-big {
        grid-column: 1;
        grid-row: 1/3;

        .num {
            font-size: 2.1rem;
        }
    }

    .stat-a {
        grid-column: 2;
        grid-row: 1;
    }

    .stat-b {
        grid-column: 2;
        grid-row: 2;
    }

    .stat-wide {
        grid-column: 1/3;
        grid-row: 3;
        flex-direction: row;
        align-items: center;
        gap: 0.7rem;

        .num {
            font-size: 1.7rem;
        }
    }

    .g-side .ph {
        border-radius: 18px;
    }

    .team-body .role {
        color: var(--cyan);
        font-size: 0.85rem;
        font-weight: 700;
        margin: 0.2rem 0 0.8rem;
    }

    .social-ic {
        color: var(--slate);
        transition:
            color 0.2s ease,
            transform 0.2s ease;

        &:hover {
            color: var(--cyan);
            transform: translateY(-2px);
        }
    }
}

/* ======================================================
       SHARED MEDIA / TEAM COMPONENTS
       ====================================================== */

.about-img,
.team-photo,
.event-thumb,
.g-main,
.g-side .ph {
    border-radius: 18px;
}

/* gallery: the two side photos share the height of the square photo beside them (tablet and up);
   stacked on phones there is no height to share (they collapsed to 2px), so each gets its own shape */
.g-side .ph {
    flex: 1;
}

@media (max-width: 767.98px) {
    .g-side .ph {
        flex: none;
        aspect-ratio: 3 / 2;
    }
}

/* gallery: one full-width row of photos, tilted ±2° in turn, drifting left forever
   (moved by js/gallery.js). About 3 photos across on desktop, a bit bigger on TVs,
   3 on tablet, 1 plus the edges of its neighbours on phones. */
.g-section {
    position: relative;
    overflow: hidden;   /* keeps the blobs inside the section */
}

/* soft light blobs behind the photos, right of centre. Soft edges come from the gradient
   itself (no blur filter) and they only move / scale, so they cost nothing to animate */
.g-blob {
    position: absolute;
    z-index: 0;
    pointer-events: none;
    border-radius: 50%;
    background: radial-gradient(closest-side,
            rgba(169, 234, 228, 0.30) 0%,
            rgba(4, 191, 205, 0.16) 45%,
            rgba(4, 191, 205, 0) 100%);
    animation: g-blob 18s ease-in-out infinite alternate;
    will-change: transform;
}

.g-blob-1 {
    width: min(52vw, 760px);
    aspect-ratio: 1.35;
    right: 10%;
    bottom: 3rem;
}

.g-blob-2 {
    width: min(26vw, 380px);
    aspect-ratio: 1;
    right: 4%;
    bottom: 12rem;
    opacity: 0.85;
    animation-duration: 22s;
    animation-direction: alternate-reverse;
}

@keyframes g-blob {
    0%   { transform: translate3d(0, 0, 0) rotate(0deg) scale(1, 1); }
    50%  { transform: translate3d(-3%, 2%, 0) rotate(8deg) scale(1.06, 0.96); }
    100% { transform: translate3d(2%, -2%, 0) rotate(-6deg) scale(0.96, 1.04); }
}

.g-marquee {
    position: relative;
    z-index: 1;
    overflow: hidden;
    /* room for the tilt, the hover zoom and the hover glow: overflow is hidden, so anything
       outside this padding is cut off in a straight line. The extra bottom room is taken back
       with the negative margin so the buttons stay where they were */
    padding-block: 2.5rem 5rem;
    margin-block: -1rem -3.5rem;
}

.g-track {
    display: flex;
    width: max-content;
    margin: 0;
    padding: 0;
    list-style: none;
    will-change: transform;
}

.g-item {
    flex: 0 0 auto;
    width: 33.333vw;
    padding-inline: clamp(0.9rem, 1.8vw, 2rem);
}

/* the card: tilted, rounded, with a soft navy overlay (as on the hero) so bright photos sit calmly */
.g-open {
    position: relative;
    display: block;
    width: 100%;
    padding: 0;
    border: 0;
    background: none;
    overflow: hidden;
    border-radius: 18px;
    cursor: zoom-in;
    transform: rotate(2deg);
    box-shadow: 0 18px 40px -18px rgba(0, 0, 0, 0.55);
    transition: transform 0.3s ease, box-shadow 0.3s ease;

    &::after {
        content: "";
        position: absolute;
        inset: 0;
        pointer-events: none;
        background: linear-gradient(180deg, rgba(1, 9, 48, 0.12) 0%, rgba(1, 9, 48, 0.30) 100%);
        transition: opacity 0.3s ease;
    }

    img {
        display: block;
        width: 100%;
        aspect-ratio: 4 / 3;
        object-fit: cover;
    }

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

.g-item:nth-child(even) .g-open {
    transform: rotate(-2deg);
}

.g-item:hover .g-open {
    transform: rotate(0deg) scale(1.06);
    box-shadow: 0 22px 48px -14px rgba(4, 191, 205, 0.6);   /* accent glow */

    &::after { opacity: 0.35; }
}

/* the two buttons under the row */
.g-controls {
    position: relative;
    z-index: 1;
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    margin-top: 1.5rem;
}

/* .btn.g-btn inside .g-controls: Bootstrap loads after this file, so a plain .g-btn
   would lose to its .btn rule (dark text, no border, small padding) */
.g-controls .btn.g-btn {
    padding: 0.375rem 1.5rem;   /* Bootstrap's medium button height, wider sides */
    border: 1px solid rgba(255, 255, 255, 0.55);
    border-radius: 50rem;
    background: rgba(255, 255, 255, 0.06);
    color: var(--white);
    font-size: 1.1rem;
    line-height: 1.5;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;

    &:hover,
    &:focus-visible {
        background: var(--cyan);
        border-color: var(--cyan);
        color: #02181c;
        box-shadow: 0 10px 24px -10px rgba(4, 191, 205, 0.65);
        transform: translateY(-2px);
    }

    &:active {
        transform: translateY(0);
    }

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

@media (min-width: 1200px) {
    .g-item { width: 35vw; }
}

@media (min-width: 1920px) {
    .g-item { width: 38vw; }   /* TVs and very large screens */
}

@media (max-width: 767.98px) {
    .g-item {
        width: 60vw;          /* one photo in the middle, the next ones peek in at the sides */
        padding-inline: 0.9rem;
    }

    .g-open {
        border-radius: 14px;

        img { aspect-ratio: 1 / 1; }
    }

    .g-blob-1 {
        width: 80vw;
        right: -10%;
        bottom: 5rem;
    }

    .g-blob-2 { display: none; }
}

/* full view: the photo grows out of the row to the middle of the screen */
.g-lb-back {
    position: fixed;
    inset: 0;
    z-index: 2000;
    background: rgba(1, 3, 22, 0.88);
    backdrop-filter: blur(6px);
    cursor: zoom-out;
}

.g-lb {
    position: fixed;
    z-index: 2001;
    overflow: hidden;
    box-shadow: 0 30px 80px -20px rgba(0, 0, 0, 0.7);
    cursor: zoom-out;

    img {
        display: block;
        width: 100%;
        height: 100%;
        object-fit: cover;
    }
}

.g-lb-close {
    position: fixed;
    top: max(16px, env(safe-area-inset-top));
    right: 16px;
    z-index: 2002;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.3);
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    font-size: 1.1rem;
    display: grid;
    place-items: center;
    transition: background 0.2s ease;

    &:hover { background: var(--cyan); }

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

html.g-lb-on {
    overflow: hidden;   /* no page scroll behind the open photo */
}

/* reduced motion: no drift and no blob movement; the buttons still slide the row */
@media (prefers-reduced-motion: reduce) {
    .g-blob { animation: none; }
    .g-open, .g-open::after { transition: none; }
}

/* team photos fill the card's photo area; faces stay at the top if the shape changes */
.team-photo img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center top;
}

/* "Porque nós?" icons: accent tile on the dark section */
.feature .icon-box {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
    background: rgba(4, 191, 205, 0.14);
    border: 1px solid rgba(4, 191, 205, 0.4);
    color: var(--cyan);
    font-size: 1.6rem;
}

.team-body {
    .role {
        color: var(--cyan);
        font-size: 0.85rem;
        font-weight: 700;
        margin: 0.2rem 0 0.8rem;
    }
}

.social-ic {
    color: var(--slate);
    transition:
        color 0.2s ease,
        transform 0.2s ease;

    &:hover {
        color: var(--cyan);
        transform: translateY(-2px);
    }
}

/* ======================================================
       06. SERVIÇOS | Accordion
       Desktop (>= 768px): horizontal, the open service fills the row.
       Phones  (<  768px): normal vertical accordion.
       Behaviour: "SERVICES ACCORDION" script in index.html.
       ====================================================== */

.tabs-h {
    display: flex;
    align-items: stretch;
    min-height: 460px;
    overflow: hidden;
    overflow: clip;
    /* clips the corners like hidden, but isn't a scroll container,
                                               so #servico-... jumps keep their scroll-margin */
    border: 1px solid var(--border);
    border-radius: 18px;
    background: var(--white);
    box-shadow: var(--shadow);
}

.tabs-h .tab-item {
    position: relative;
    display: flex;
    flex: 0 0 68px;
    min-width: 0;
    border-right: 1px solid var(--border);
    background: var(--white);
    transition: flex-grow 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    scroll-margin-top: 110px;
    /* links like #servico-espacos clear the navbar */
}

.tabs-h .tab-item:last-child {
    border-right: 0;
}

.tabs-h .tab-item.active {
    flex: 1 1 auto;
}

/* the header: a vertical strip on desktop, a row on phones */
.tabs-h .tab-strip {
    display: flex;
    flex: 0 0 68px;
    flex-direction: column;
    align-items: center;
    width: 68px;
    padding: 1.6rem 0;
    border: 0;
    background: none;
    color: inherit;
    font: inherit;
    text-align: left;
    cursor: pointer;
    transition: background 0.3s ease;
}

.tabs-h .tab-item.active .tab-strip {
    cursor: default;
}

@media (hover: hover) {

    /* no "stuck" hover colour after a tap on touch screens */
    .tabs-h .tab-item:not(.active) .tab-strip:hover {
        background: rgba(4, 191, 205, 0.06);
    }

    .tabs-h .tab-item:not(.active) .tab-strip:hover .t-label {
        color: var(--cyan);
    }
}

.tabs-h .tab-strip:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: -4px;
    border-radius: 12px;
}

.tabs-h .t-num {
    flex-shrink: 0;
    color: var(--cyan);
    font-family: "Inter", sans-serif;
    font-size: 0.82rem;
    font-weight: 800;
}

.tabs-h .t-label {
    margin-top: 1.4rem;
    color: var(--ash);
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.01em;
    white-space: nowrap;
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    transition: color 0.3s ease;
}

.tabs-h .t-chevron {
    display: none;
    /* phones only */
}

/* the panel */
.tabs-h .tab-full {
    display: none;
    flex: 1 1 auto;
    min-width: 0;
}

.tabs-h .tab-item.active .tab-full {
    display: flex;
}

.tabs-h .tab-body {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    min-width: 0;
    padding: clamp(1.6rem, 3vw, 2.4rem);
}

.tabs-h .tab-body h3 {
    margin-bottom: 0.9rem;
    color: var(--ink);
    font-family: "Inter", sans-serif;
    font-size: 1.4rem;
    font-weight: 700;
}

.tabs-h .tab-body p {
    max-width: 58ch;
    color: var(--ash);
    font-size: 0.95rem;
}

.tabs-h .tab-img {
    flex: 1;
    min-height: 200px;
    margin-top: 1.3rem;
    border-radius: 12px;
    background-position: center;
    background-size: cover;
}

/* ---------- phones: normal accordion ---------- */
@media (max-width: 767.98px) {
    .tabs-h {
        flex-direction: column;
        min-height: 0;
    }

    .tabs-h .tab-item,
    .tabs-h .tab-item.active {
        display: block;
        flex: none;
        border-right: 0;
        border-bottom: 1px solid var(--border);
        transition: none;
    }

    .tabs-h .tab-item:last-child {
        border-bottom: 0;
    }

    .tabs-h .tab-strip,
    .tabs-h .tab-item.active .tab-strip {
        flex-direction: row;
        gap: 0.9rem;
        width: 100%;
        padding: 1.1rem 1.25rem;
        cursor: pointer;
    }

    .tabs-h .t-label {
        flex: 1;
        margin: 0;
        color: var(--ink);
        font-size: 1rem;
        white-space: normal;
        writing-mode: horizontal-tb;
        transform: none;
    }

    .tabs-h .tab-item.active .t-label {
        color: var(--cyan);
    }

    .tabs-h .t-chevron {
        display: block;
        flex: none;
        color: var(--cyan);
        transition: transform 0.35s ease;
    }

    .tabs-h .tab-item.active .t-chevron {
        transform: rotate(180deg);
    }

    /* height animation: the panel's single grid row goes from 0fr to 1fr */
    .tabs-h .tab-full,
    .tabs-h .tab-item.active .tab-full {
        display: grid;
    }

    .tabs-h .tab-full {
        grid-template-rows: 0fr;
        visibility: hidden;
        transition: grid-template-rows 0.35s ease, visibility 0s linear 0.35s;
    }

    .tabs-h .tab-item.active .tab-full {
        grid-template-rows: 1fr;
        visibility: visible;
        transition: grid-template-rows 0.35s ease, visibility 0s linear 0s;
    }

    .tabs-h .tab-body {
        display: block;
        min-height: 0;
        overflow: hidden;
        padding: 0 1.25rem;
        /* no vertical padding: it would stop the panel collapsing to 0 */
    }

    .tabs-h .tab-body h3 {
        display: none;
        /* the header already shows the name */
    }

    .tabs-h .tab-body p {
        margin: 0 0 1rem;
    }

    .tabs-h .tab-img {
        min-height: 0;
        aspect-ratio: 16 / 9;
        margin: 0 0 1.25rem;
    }

    .tabs-h.is-jumping .tab-full,
    .tabs-h.is-jumping .t-chevron {
        transition: none !important;
    }
}

@media (prefers-reduced-motion: reduce) {

    .tabs-h .tab-item,
    .tabs-h .tab-full,
    .tabs-h .t-chevron {
        transition: none !important;
    }
}

/* ======================================================
       07. BENEFÍCIOS / BENTO
       ====================================================== */

.bento {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: minmax(120px, auto);
    gap: 1.4rem;

    .card-c {
        padding: 1.6rem;
        display: flex;
        flex-direction: column;
    }

    .b-a {
        grid-column: 1/3;
        grid-row: 1/3;

        .ph {
            flex: 1;
            margin-top: 1rem;
            border-radius: 12px;
        }
    }

    .b-b {
        grid-column: 3/5;
        grid-row: 1;
        flex-direction: row;
        align-items: center;
        gap: 1.4rem;

        .ph {
            width: 38%;
            aspect-ratio: 1/1;
            border-radius: 12px;
            flex-shrink: 0;
        }
    }

    .b-c {
        grid-column: 3/5;
        grid-row: 2/4;

        .ph {
            flex: 1;
            margin-top: 1rem;
            border-radius: 12px;
        }
    }

    .b-1 {
        grid-column: 1/2;
        grid-row: 3;
    }

    /* pictures in the boxes: <img class="bento-img"> in index.html (change its src to pick a photo) */
    .bento-img {
        display: block;
        width: 100%;
        height: auto;
        /* ignore the photo's own size: the box decides */
        object-fit: cover;
        border-radius: 12px;
    }

    .b-a .bento-img,
    .b-c .bento-img {
        flex: 1 1 auto;
        height: 0;
        /* takes only the space left in the card... */
        min-height: 200px;
        /* ...but never thinner than this */
        margin-top: 1rem;
    }

    .b-b .bento-img {
        width: 38%;
        aspect-ratio: 1 / 1;
        flex-shrink: 0;
    }

    .b-2 {
        grid-column: 2/3;
        grid-row: 3;
    }

    .tag {
        font-size: 0.75rem;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.08em;
        color: var(--cyan);
        margin-bottom: 0.5rem;
    }

    h3 {
        font-family: "Inter", sans-serif;
        font-size: 1.15rem;
        font-weight: 700;
        color: var(--ink);
        margin-bottom: 0.5rem;
    }

    .icon-box {
        width: 38px;
        height: 38px;
        border-radius: 9px;
        background: rgba(4, 191, 205, 0.12);
        display: flex;
        align-items: center;
        justify-content: center;
        margin-bottom: 0.8rem;
        color: var(--cyan);
        font-size: 1.1rem;
    }

}

/* ======================================================
       10. EVENTOS
       ====================================================== */

.badge-c {
    position: absolute;
    top: 0.8rem;
    right: 0.8rem;
    background: rgba(4, 191, 205, 0.14);
    border: 1px solid rgba(4, 191, 205, 0.4);
    color: #037480;
    font-size: 0.7rem;
    font-weight: 700;
    padding: 0.3rem 0.7rem;
    border-radius: 999px;
    backdrop-filter: blur(6px);
}

.event-meta {
    font-size: 0.78rem;
    color: var(--slate);
}

/* ======================================================
       11. TESTEMUNHOS | Bootstrap Carousel Restyle
       ====================================================== */

.testi-carousel {

    .carousel-item {
        padding: 1rem 3rem;
    }

    blockquote {
        font-family: "Montserrat", serif;
        font-size: clamp(1.25rem, 2.4vw, 1.7rem);
        color: var(--ink);
        font-style: italic;
        max-width: 34ch;
        margin: 0 auto 1.6rem;
        line-height: 1.4;
    }

    .avatar-c {
        width: 54px;
        height: 54px;
        border-radius: 50%;
        background: var(--bg-alt);
        border: 1px solid var(--border);
        margin: 0 auto 0.7rem;
        display: flex;
        align-items: center;
        justify-content: center;
        color: var(--slate);
        font-size: 1.4rem;
    }

    .carousel-control-next {
        width: 44px;
        height: 44px;
        top: 50%;
        transform: translateY(-50%);
        border-radius: 50%;
        background: var(--white);
        border: 1px solid var(--border);
        box-shadow: var(--shadow);
        opacity: 1;
    }

    .carousel-control-prev {
        left: -6px;
    }

    .carousel-control-next {
        right: -6px;
    }

    .carousel-control-next-icon {
        filter: invert(1) grayscale(1);
        width: 1rem;
        height: 1rem;
    }

    .carousel-indicators [data-bs-target] {
        background: var(--slate);
        opacity: 0.4;
        width: 7px;
        height: 7px;
        border-radius: 50%;
    }

    .carousel-indicators .active {
        background: var(--cyan);
        opacity: 1;
    }
}

/* ======================================================
       13. FOOTER
       ====================================================== */

footer {
    background: var(--navy);

    /* the wordmark sits on ONE line on every screen and fills the footer's width:
       "Castros Consultoria" in Montserrat Black is 10.25em wide, so the type size is
       the container's width / 10.6 (a little slack). The container is a size
       container for this (cqi = 1% of its width); older browsers use the window width. */
    .container {
        container-type: inline-size;
    }

    .wordmark {
        font-family: "Montserrat", serif;
        font-weight: 900;
        font-size: calc((100vw - 3rem) / 10.6);
        font-size: calc(100cqi / 10.6);
        white-space: nowrap;
        color: var(--white);
        line-height: 1;
        letter-spacing: -0.02em;
        border-top: 1px solid rgba(255, 255, 255, 0.14);
        padding-top: 1.8rem;
        margin-top: 0.5rem;
    }

    a {
        color: var(--ash-soft);
    }


    h5 {
        color: var(--pearl);
        font-size: 0.72rem;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.1em;
        margin-bottom: 0.6rem;
    }

    .foot-p {
        color: var(--ash-soft);
        font-size: 0.9rem;
    }

    a:hover {
        color: var(--pearl);
    }

    .foot-bottom {
        border-top: 1px solid rgba(255, 255, 255, 0.14);
        color: var(--ash-soft);
        font-size: 0.82rem;
    }
}

/* ======================================================
       BACK TO TOP
       ====================================================== */

#backTop {
    position: fixed;
    left: 1.4rem;
    bottom: 1.4rem;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: var(--cyan);
    color: #02181c;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 26px -8px rgba(4, 191, 205, 0.6);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    z-index: 1000;
    border: 0;

    &.show {
        opacity: 1;
        visibility: visible;
        transform: none;
    }
}

#whatsappBtn {
    position: fixed;
    right: 1.4rem;
    bottom: 1.4rem;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: #25D366;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    box-shadow: 0 10px 26px -8px rgba(37, 211, 102, 0.6);
    z-index: 1000;
    transition: transform 0.2s ease;
    line-height: 1;
}

#whatsappBtn:hover {
    transform: translateY(-3px);
    color: #fff;
}

/* ======================================================
       01. NAVBAR | Protected Layout
       ====================================================== */

.main-navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1050;
    padding: 1rem 2rem 5px;
    background: transparent;
    transition:
        transform 0.4s ease,
        opacity 0.4s ease,
        visibility 0.4s ease;

    &.navbar-hidden {
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
    }

    &.navbar-hovered {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }

    .container-fluid {
        display: flex;
        align-items: center;
        width: 100%;
        max-width: 1600px;
        margin: 0 auto;
        padding: 0;
    }

    .navbar-brand {
        display: inline-flex;
        align-items: center;
        margin: 0;
        padding: 0;
        font-size: 1.15rem;
        font-weight: 700;
        text-decoration: none;
        white-space: nowrap;
        color: inherit;
        color: var(--white);
    }

    .desktop-navbar {
        flex: 1;
        display: grid;
        grid-template-columns: 1fr auto 1fr;
        align-items: center;
        margin-left: -8rem;

        .navbar-nav {
            grid-column: 2;
            display: flex;
            flex-direction: row;
            align-items: center;
            justify-content: center;
            gap: 0.25rem;
            margin: 0;
        }

        .nav-link {
            position: relative;
            padding: 0.5rem 0.75rem;
            font-size: 0.95rem;
            font-weight: 500;
            white-space: nowrap;
            color: inherit;
            transition:
                opacity 0.2s ease,
                color 0.2s ease;
            color: var(--ash-soft);
        }

        .nav-link:hover {
            opacity: 0.85;
        }

        .nav-link.active {
            font-weight: 600;
            color: var(--pearl);
        }

        .nav-link:focus {
            color: var(--ash-soft);
        }
    }

    .navbar-cta {
        grid-column: 3;
        justify-self: end;
        white-space: nowrap;
        font-size: 14px;
        padding: 5px 3rem;
        border-radius: 18px;
        border: 0;
        background-image: linear-gradient(109.6deg,
                rgba(34, 211, 238, 1) 11.2%,
                rgba(79, 57, 246, 1) 100.2%);
    }

    .dropdown-menu {
        min-width: 200px;
        margin-top: 0.75rem;
        padding: 0.5rem;
        border: 0;
        border-radius: 12px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    }

    .dropdown-item {
        padding: 0.65rem 0.8rem;
        border-radius: 8px;
        font-size: 0.9rem;
        transition:
            background-color 0.2s ease,
            color 0.2s ease;

        &:hover {
            background-color: #f5f5f5;
        }
    }

    .navbar-toggler {
        margin-left: auto;
        width: 46px;
        height: 46px;
        padding: 0;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border: 1px solid rgba(3, 3, 22, 0.18);
        border-radius: 12px;
        background: rgba(255, 255, 255, 0.92);
        box-shadow: 0 8px 24px rgba(3, 3, 22, 0.14);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);

        &:focus {
            outline: none;
            box-shadow:
                0 0 0 3px rgba(4, 191, 205, 0.22),
                0 8px 24px rgba(3, 3, 22, 0.14);
        }
    }

    .navbar-toggler-icon {
        width: 22px;
        height: 18px;
        position: relative;
        display: block;
        background-image: none !important;
        border-top: 2px solid #030316;
        border-bottom: 2px solid #030316;

        &::after {
            content: "";
            position: absolute;
            left: 0;
            top: 6px;
            width: 100%;
            height: 2px;
            border-radius: 2px;
            background: #030316;
        }
    }
}

/* ======================================================
       02. HERO | Protected Structure + d545a Visual Treatment
       ====================================================== */

main>.hero {

    main>.hero {
        position: relative;
        width: 100%;
        max-width: 100%;
        height: 600px;
        min-height: 600px;
        box-sizing: border-box;
        display: flex;
        align-items: center;
        padding: 4rem 2rem;
        margin-bottom: 4rem;
        overflow: hidden;
        color: #fff;

        #overlayGradient {
            position: relative;
            overflow: hidden;
            isolation: isolate;
        }

        #overlayGradient::before {
            content: "";
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: linear-gradient(126deg,
                    #000d3600 0%,
                    #001a6b00 25%,
                    #00369e45 50%,
                    #123e7199 75%,
                    #1571b2 100%);
            z-index: 0;
            pointer-events: none;
        }

        #overlayGradient>[class*="col-lg-6"] {
            position: relative;
            z-index: 1;
        }
    }

    .hero-copy {
        max-width: 650px;
        position: relative;
        z-index: 1;

        h1 {
            margin: 0 0 1.5rem;
            font-size: clamp(3rem, 5vw, 5.5rem);
            line-height: 0.98;
            font-weight: 700;
            letter-spacing: -0.04em;
            color: #fff;
        }

        p {
            max-width: 600px;
            margin: 0 0 2rem;
            font-size: 14px;
            font-weight: 600;
            line-height: 1.7;
            color: rgba(255, 255, 255, 0.75);
        }
    }

    .hero-actions {
        display: flex;
        flex-wrap: wrap;
        gap: 0.75rem;

        .btn {
            font-size: 12px;
            min-height: 30px;
            padding: 10px 1.25rem;
            border-radius: 0;
            font-weight: 500;
        }

        .btn-light {
            color: #111;
            background-color: #fff;
            border-color: #fff;
        }

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

    .hero-visual {
        position: relative;
        min-height: 550px;
        display: flex;
        flex-direction: column;
        justify-content: center;
    }

    .metrics-grid {
        margin: 15rem 0 0 8rem !important;
    }

    .metric-card {
        min-height: 110px;
        padding: 1.25rem;
        display: flex;
        align-items: center;
        gap: 1rem;
        border: 1px solid rgba(255, 255, 255, 0.25);
        border-radius: 16px;
        background: rgba(245, 245, 245, 0.09);
        backdrop-filter: blur(12px);
        -webkit-backdrop-filter: blur(12px);
        color: #fff;
        transition:
            transform 0.25s ease,
            background-color 0.25s ease,
            border-color 0.25s ease;

        &:hover {
            transform: translateY(-4px);
            background: rgba(0, 0, 0, 0.08);
            border-color: rgba(255, 255, 255, 0.45);
        }
    }

    .metric-value {
        display: block;
        margin-bottom: 0.2rem;
        font-size: 2rem;
        line-height: 1;
        font-weight: 700;
        letter-spacing: -0.03em;
        color: #fff;
    }

    .metric-label {
        display: block;
        font-size: 0.8rem;
        line-height: 1.3;
        color: rgba(255, 255, 255, 0.7);
    }
}

/* ======================================================
       03. ABOUT US SECTION
       ====================================================== */

#sobre {
    position: relative;
    overflow: hidden;
    text-align: justify;

    .container-fluid {
        padding: 0 3rem;

        a.btn.btn-outline-c {
            border: solid 2px var(--cyan) !important;
            color: var(--cyan);
            font-weight: bold;
        }

        a.btn.btn-outline-c {
            &:hover {
                background-color: var(--cyan);
                color: var(--white);
                /* was cyan on cyan: the text disappeared */
            }
        }
    }

    .about-img {
        position: relative;
        overflow: hidden;
        isolation: isolate;
        background:
            radial-gradient(circle at 70% 20%,
                rgba(4, 191, 205, 0.28),
                transparent 34%),
            linear-gradient(145deg, #e4ebf4 0%, #cbd9e8 45%, #8aa9c2 100%);

        &::before {
            content: "";
            position: absolute;
            inset: 0;
            z-index: 2;
            background: linear-gradient(155deg, rgba(42, 67, 188, 0.15) 0%, rgba(4, 191, 205, 0.12) 28%, rgb(0 54 158 / 2%) 58%, rgb(0 15 89 / 39%) 100%), radial-gradient(circle at 18% 15%, rgba(114, 220, 220, 0.28), transparent 32%);
            pointer-events: none;
        }

        &::after {
            content: "";
            position: absolute;
            inset: 6%;
            z-index: 1;
            /* border: 1px solid rgba(255, 255, 255, 0.34); */
            border-radius: 14px;
            box-shadow: inset 0 0 70px rgba(1, 9, 48, 0.12);
            pointer-events: none;
            background-image: url(../assets/team.webp);
            background-size: cover;
            background-position: center;
            filter: contrast(1.2) grayscale(1);
        }

        .bi {
            position: relative;
            z-index: 3;
            color: rgba(255, 255, 255, 0.78);
            filter: drop-shadow(0 8px 24px rgba(1, 9, 48, 0.2));
        }
    }
}

/* ======================================================
       04. EQUIPA / TEAM
       ====================================================== */

/* ======================================================
       05. PARCEIROS / MARCAS
       Partner names remain unchanged
       ====================================================== */

/* ======================================================
       06. SERVIÇOS
       ====================================================== */

/* ======================================================
       07. BENEFÍCIOS
       ====================================================== */

/* ======================================================
       08. PORQUE NÓS
       ====================================================== */

/* ======================================================
       09. CTA FINAL
       ====================================================== */

#cta {
    padding: 9rem;
    background-color: var(--white);

    .container {
        h2.mb-3 {
            color: var(--prussian);
        }

        p {
            color: var(--ash)
        }

        a.btn.btn-cyan {
            background-color: var(--cyan);
            color: whitesmoke;
            font-weight: 600;
        }

        a.btn.btn-outline-light-c {
            border: solid 2px var(--navy);
        }
    }
}

/* phones / tablets: 9rem on every side squeezed the text into a ~100px column */
@media (max-width: 991.98px) {
    #cta {
        padding: 6rem 2rem;
    }
}

@media (max-width: 575.98px) {
    #cta {
        padding: 4.5rem 1rem;
    }
}

/* ======================================================
       10. EVENTOS | Final Refinements
       ====================================================== */

.event-thumb {
    border: none;
}

a.btn-outline-c.px-4.py-2 {
    &:hover {
        color: var(--white) !important;
    }
}

/* ======================================================
       11. TESTEMUNHOS | Final Section
       ====================================================== */

#testimonials {
    height: 60vh;
    margin: 10rem 0 clamp(4rem, 13vw, 13rem);
    /* bottom: room before the contact section */
    overflow-x: clip;

    h6.index {
        font-family: "Manrope";
        text-align: center !important;
        font-size: 0.8rem;
        font-weight: 700;
        letter-spacing: 0.14em;
        text-transform: uppercase;
        color: var(--cyan);
        margin-bottom: 0.7rem;
        display: block;

    }

    #testCarousel {
        height: 100%;

        .carousel-indicators {
            list-style: none;
        }

        .carousel-inner {
            height: 100%;
            /* background-image: url(../assets/workshop2.webp); */
            background-color: var(--white) !important;
            background-position: center;
            background-repeat: no-repeat;
            background-size: cover;
            filter: contrast(1.2) !important;

            .carousel-item {
                height: 100%;
                margin-top: -6rem;

                .carousel-caption {
                    color: black;

                    h3.comment {
                        font-family: "Manrope";
                        margin-bottom: 0;
                        padding-bottom: 0;
                        filter: brightness(1) !important;
                    }

                    /* quote mark above the text, same as the service pages' testimonials */
                    &::before {
                        content: "\201C";
                        display: block;
                        font-family: "Montserrat", serif;
                        font-size: 4.5rem;
                        line-height: 1;
                        height: 2.6rem;
                        color: var(--cyan);
                    }

                    h6.name {
                        font-family: "Montserrat";
                        font-weight: 600;
                        margin-top: 1.5rem;
                    }

                    p.local {
                        font-size: 14px;
                        font-family: "Manrope";
                    }
                }
            }
        }
    }
}

/* ======================================================
       CONTACT SECTION
       ====================================================== */

.contact-section {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(circle at 10% 10%, rgba(169, 234, 228, 0.18), transparent 28%),
        radial-gradient(circle at 90% 80%, rgba(1, 9, 48, 0.07), transparent 30%),
        var(--surface);

    &::before {
        content: "";
        position: absolute;
        width: 420px;
        height: 420px;
        top: -220px;
        right: -160px;
        border-radius: 50%;
        background: rgba(169, 234, 228, 0.12);
        filter: blur(10px);
        pointer-events: none;
    }

    .contact-eyebrow {
        display: inline-block;
        margin-bottom: 12px;
        color: var(--slate-grey);
        font-size: 0.76rem;
        font-weight: 700;
        letter-spacing: 0.14em;
        text-transform: uppercase;
    }

    .contact-title {
        max-width: 850px;
        margin: 0 auto;
        color: var(--ink);
        font-family: "Montserrat", serif;
        font-size: clamp(2.25rem, 5vw, 4.4rem);
        font-weight: 400;
        line-height: 1.05;
    }

    .contact-intro {
        max-width: 650px;
        margin: 22px auto 0;
        color: var(--slate-grey);
        font-size: 1rem;
        line-height: 1.75;
    }

    .contact-info-item {
        display: flex;
        align-items: center;
        gap: 12px;
        /* height: 100%; */
        min-height: 82px;
        padding: 14px;
        color: var(--ink);
        text-decoration: none;
        margin: 0 auto;
        position: relative;
        top: 10px;
    }

    .col-6.col-md-4 {
        background: rgba(255, 255, 255, 0.72);
        border: 1px solid var(--border);
        border-radius: var(--radius-md);
        box-shadow: 0 8px 25px rgba(3, 3, 22, 0.035);
        transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;

        &:hover {
            color: var(--ink);
            transform: translateY(-4px);
            background: var(--white);
            border-color: rgba(169, 234, 228, 0.9);
            box-shadow: 0 14px 32px rgba(3, 3, 22, 0.08);
        }
    }

    .contact-info-icon {
        display: grid;
        flex: 0 0 42px;
        width: 42px;
        height: 42px;
        place-items: center;
        color: var(--deep-navy);
        background: rgba(169, 234, 228, 0.42);
        border-radius: 12px;
        margin: 1rem auto 0;
    }

    .contact-info-content {
        display: flex;
        min-width: 0;
        flex-direction: column;
        margin: 0 auto;
        text-align: center;
        margin-top: -2rem;

        small {
            margin-bottom: 2px;
            color: var(--slate-grey);
            font-size: 0.68rem;
            font-weight: 600;
        }

        strong {
            overflow: hidden;
            color: var(--ink);
            font-size: 0.78rem;
            font-weight: 700;
            text-overflow: ellipsis;
            white-space: nowrap;
        }
    }

    .contact-image-card {
        position: relative;
        min-height: 620px;
        overflow: hidden;
        background:
            linear-gradient(180deg, rgba(1, 9, 48, 0.02), rgba(1, 9, 48, 0.88)),
            url("https://images.unsplash.com/photo-1521737711867-e3b97375f902?auto=format&fit=crop&w=1200&q=85") center / cover no-repeat;
        border-radius: var(--radius-lg);
        box-shadow: var(--shadow);
    }

    .contact-image-overlay {
        position: absolute;
        inset: 0;
        background: linear-gradient(180deg, rgba(1, 9, 48, 0.02) 20%, rgba(1, 9, 48, 0.20) 45%, rgba(1, 9, 48, 0.94) 100%);
    }

    .contact-image-content {
        position: absolute;
        right: 0;
        bottom: 0;
        left: 0;
        z-index: 1;
        padding: clamp(24px, 5vw, 48px);
        color: var(--white);

        h2 {
            max-width: 560px;
            margin: 0;
            font-family: "Montserrat", serif;
            font-size: clamp(2rem, 4vw, 3.4rem);
            font-weight: 400;
            line-height: 1.02;
        }

        p {
            max-width: 470px;
            margin: 18px 0 0;
            color: rgba(255, 255, 255, 0.78);
            font-size: 0.95rem;
            line-height: 1.7;
        }
    }

    .contact-image-label {
        display: inline-block;
        margin-bottom: 14px;
        color: var(--icy-aqua);
        font-size: 0.75rem;
        font-weight: 700;
        letter-spacing: 0.1em;
        text-transform: uppercase;
    }

    .contact-form-card {
        position: relative;
        min-height: 620px;
        padding: clamp(24px, 4vw, 46px);
        background: rgba(255, 255, 255, 0.88);
        border: 1px solid var(--border);
        border-radius: var(--radius-lg);
        box-shadow: var(--shadow);
        backdrop-filter: blur(12px);
    }

    .form-progress {
        display: flex;
        align-items: center;
        width: min(100%, 340px);
        margin: 0 auto;
    }

    .progress-step {
        display: grid;
        flex: 0 0 34px;
        width: 34px;
        height: 34px;
        place-items: center;
        color: var(--slate-grey);
        background: var(--white);
        border: 1px solid rgba(112, 129, 142, 0.35);
        border-radius: 50%;
        font-size: 0.72rem;
        font-weight: 700;
        transition: background 200ms ease, color 200ms ease, border-color 200ms ease, transform 200ms ease;

        &.active {
            color: var(--deep-navy);
            background: var(--icy-aqua);
            border-color: var(--icy-aqua);
            transform: scale(1.08);
        }

        &.completed {
            color: var(--white);
            background: var(--deep-navy);
            border-color: var(--deep-navy);
        }
    }

    .progress-line {
        flex: 1;
        height: 1px;
        margin: 0 8px;
        background: rgba(112, 129, 142, 0.25);

        &.completed {
            background: var(--deep-navy);
        }
    }

    .progress-labels {
        display: flex;
        justify-content: space-between;
        width: min(100%, 400px);
        margin: 10px auto 42px;
        color: var(--slate-grey);
        font-size: 0.68rem;
        font-weight: 600;
    }

    .form-step {
        display: none;

        &.active {
            display: block;
            animation: formStepIn 280ms ease both;
        }
    }

    .form-step-number {
        display: block;
        margin-bottom: 8px;
        color: var(--slate-grey);
        font-size: 0.72rem;
        font-weight: 700;
        letter-spacing: 0.12em;
    }

    .form-step-title {
        margin: 0;
        color: var(--ink);
        font-family: "Montserrat", serif;
        font-size: clamp(1.8rem, 3vw, 2.6rem);
        font-weight: 400;
        line-height: 1.05;
    }

    .form-step-description {
        max-width: 560px;
        margin: 10px 0 0;
        color: var(--slate-grey);
        font-size: 0.9rem;
        line-height: 1.65;
    }

    .form-label {
        margin-bottom: 8px;
        color: var(--ink);
        font-size: 0.78rem;
        font-weight: 700;

        span {
            color: #b3261e;
        }
    }

    .form-select {
        min-height: 52px;
        padding: 0.8rem 0.95rem;
        color: var(--ink);
        background: rgba(255, 255, 255, 0.9);
        border: 1px solid rgba(112, 129, 142, 0.28);
        border-radius: 12px;
        font-size: 0.88rem;
        box-shadow: none;

        &:focus {
            color: var(--ink);
            background: var(--white);
            border-color: var(--deep-navy);
            box-shadow: 0 0 0 3px rgba(169, 234, 228, 0.35);
        }
    }

    .message-field {
        min-height: 160px;
        resize: vertical;
    }

    .btn-contact-secondary {
        min-height: 48px;
        padding: 0.72rem 1.15rem;
        border-radius: 12px;
        font-size: 0.8rem;
        font-weight: 700;
        transition: transform 180ms ease, box-shadow 180ms ease;

        &:focus-visible {
            color: var(--deep-navy);
            background: rgba(169, 234, 228, 0.18);
            border-color: var(--icy-aqua);
        }
    }

    .btn-contact-primary {
        color: var(--white);
        background: var(--deep-navy);
        border: 1px solid var(--deep-navy);

        &:focus-visible {
            color: var(--white);
            background: var(--prussian-blue);
            border-color: var(--prussian-blue);
            box-shadow: 0 10px 24px rgba(1, 9, 48, 0.16);
            transform: translateY(-2px);
        }
    }

    .btn-contact-secondary {
        color: var(--deep-navy);
        background: transparent;
        border: 1px solid rgba(112, 129, 142, 0.3);
    }

    .contact-alert {
        position: fixed;
        z-index: 1080;
        top: 20px;
        right: 20px;
        width: min(440px, calc(100vw - 40px));
        margin: 0;
        padding: 16px 48px 16px 18px;
        color: var(--ink);
        background: var(--white);
        border: 1px solid rgba(169, 234, 228, 0.8);
        border-left: 4px solid var(--deep-navy);
        border-radius: 14px;
        box-shadow: 0 18px 45px rgba(3, 3, 22, 0.16);

        &:not(.show) {
            pointer-events: none;
        }

        strong {
            font-size: 0.86rem;
        }

        span {
            display: block;
            margin-top: 3px;
            color: var(--slate-grey);
            font-size: 0.78rem;
        }
    }

    .contact-alert-icon {
        color: var(--deep-navy);
        font-size: 1.25rem;
    }

    .form-success {
        display: flex;
        min-height: 440px;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 30px;
        text-align: center;
    }

    .form-success-icon {
        display: grid;
        width: 68px;
        height: 68px;
        margin-bottom: 22px;
        place-items: center;
        color: var(--deep-navy);
        background: rgba(169, 234, 228, 0.55);
        border-radius: 50%;
        font-size: 1.6rem;
    }
}

/* ======================================================
       CONTACT FORM ANIMATION
       ====================================================== */

@keyframes formStepIn {
    from {
        opacity: 0;
        transform: translateX(12px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* ======================================================
       12. GALERIA
       ====================================================== */

/* ======================================================
       13. FOOTER
       ====================================================== */



/* ======================================================
       RESPONSIVE REFINEMENTS
       All responsive rules intentionally kept at the end.
       ====================================================== */

@media (max-width: 820px) {
    .hero {
        aspect-ratio: auto;
        min-height: auto;
    }

    .hero-inner {
        padding: 1.6rem;
    }

    .stat-grid {
        position: static;
        width: 100%;
        margin-top: 1.6rem;
        grid-template-columns: 1fr 1fr;
    }

    .stat-big {
        grid-column: 1/3;
        grid-row: auto;
    }

    .stat-a {
        grid-column: 1;
        grid-row: auto;
    }

    .stat-b {
        grid-column: 2;
        grid-row: auto;
    }

    .stat-wide {
        grid-column: 1/3;
        grid-row: auto;
    }
}

@media (max-width: 900px) {
    .bento {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .bento .b-a,
    .bento .b-b,
    .bento .b-c {
        grid-column: 1 / 3;
        grid-row: auto;
    }

    .bento .b-1 {
        grid-column: 1 / 2;
        grid-row: auto;
    }

    .bento .b-2 {
        grid-column: 2 / 3;
        grid-row: auto;
    }
}

@media (max-width: 991.98px) {
    .main-navbar {
        padding: 1rem 1.5rem 5px;
    }

    .main-navbar .desktop-navbar {
        margin-left: 0;
    }

    main {
        margin: 0 1rem;
    }

    main>.hero {
        padding: 7rem 0 3rem;
    }

    .metrics-grid {
        margin: 4rem 0 0;
    }

    .hero-visual {
        min-height: 500px;
    }
}

@media (max-width: 767.98px) {
    .main-navbar {
        padding: 0.9rem 1rem 5px;
    }

    main {
        margin: 0 0.5rem;
    }

    main>.hero {
        height: auto;
        min-height: 600px;
        padding: 6rem 0 2.5rem;
    }

    .hero-copy h1 {
        font-size: clamp(2.6rem, 11vw, 4rem);
        line-height: 1;
    }

    .hero-actions {
        flex-direction: column;
    }

    .hero-actions .btn {
        width: 100%;
    }

    .hero-visual {
        min-height: auto;
    }

    .metrics-grid {
        margin: 1rem 0 0;
    }

    .metric-card {
        min-height: 100px;
        padding: 1rem;
    }

    .metric-value {
        font-size: 1.7rem;
    }

    .metric-label {
        font-size: 0.75rem;
    }
}

@media (max-width: 575.98px) {
    .main-navbar .navbar-brand {
        font-size: 1rem;
    }

    .mobile-offcanvas {
        width: 90vw !important;
    }

    .mobile-offcanvas .offcanvas-header,
    .mobile-offcanvas .offcanvas-body {
        padding-left: 1.25rem;
        padding-right: 1.25rem;
    }
}

@media (max-width: 991.98px) {

    .contact-image-card,
    .contact-form-card {
        min-height: 560px;
    }

    .contact-image-card {
        min-height: 520px;
    }
}

@media (max-width: 767.98px) {
    .contact-title {
        font-size: clamp(2rem, 11vw, 3.1rem);
    }

    .contact-intro {
        font-size: 0.9rem;
    }

    .contact-info-item {
        min-height: 74px;
        padding: 11px;
    }

    .contact-info-icon {
        flex-basis: 36px;
        width: 36px;
        height: 36px;
    }

    .contact-info-content small {
        font-size: 0.62rem;
    }

    .contact-info-content strong {
        font-size: 0.7rem;
    }

    .contact-image-card {
        min-height: 440px;
    }

    .contact-form-card {
        min-height: auto;
        padding: 24px 18px;
    }

    /* Mobile shows only the progress circles. */
    .progress-labels {
        display: none;
    }

    .progress-step {
        flex-basis: 30px;
        width: 30px;
        height: 30px;
    }

    .progress-line {
        margin: 0 6px;
    }

    .form-step-title {
        font-size: 2rem;
    }

    .message-field {
        min-height: 140px;
    }
}

@media (max-width: 575.98px) {
    .contact-image-content {
        padding: 24px;
    }

    .contact-image-content h2 {
        font-size: 2.2rem;
    }

    .contact-form-card,
    .contact-image-card {
        border-radius: 18px;
    }

    .btn-contact-primary,
    .btn-contact-secondary {
        font-size: 0.74rem;
    }
}


/* ======================================================
   MOBILE OFFCANVAS | Fullscreen, centred, responsive
   Replaces the whole old "MOBILE OFFCANVAS | Fullscreen" section
   (from that comment banner down to the end of home.css,
   i.e. through `.mobile-offcanvas .mobile-social a:hover`).

   Works with the markup as it is today, no HTML edits:

     .offcanvas.mobile-offcanvas
       ├─ .offcanvas-header      (close button, + brand on subpages)
       ├─ .offcanvas-body        (.mobile-nav + .mobile-cta-wrapper)
       └─ .mobile-info           (pills + .mobile-social)   <- sibling of the body, not inside it

   The panel itself is the flex column: body gets margin-top:auto,
   .mobile-info gets margin-bottom:auto, so nav + CTA + pills + social
   centre as ONE group in the space under the header. If the group is
   taller than the screen the margins collapse to 0 and the panel scrolls.

   Two-class selectors (.offcanvas.mobile-offcanvas) are deliberate:
   Bootstrap loads AFTER this file, so a single-class rule ties with
   Bootstrap's own and loses.
   ====================================================== */

/* ---------- Shell ---------- */
.offcanvas.mobile-offcanvas {
    --bs-offcanvas-zindex: 1060;
    z-index: 1060;
    /* above the fixed navbar (1050) */
    width: 100% !important;
    /* beats the old "width: 90vw !important" in the 575px media query; delete that rule, then this !important can go */
    max-width: 100%;
    overflow-y: auto;
    /* whole panel scrolls on very short screens */
    padding-bottom: calc(1.5rem + env(safe-area-inset-bottom, 0px));
    border: 0;
    color: var(--white);
    background:
        radial-gradient(120% 90% at 80% 0%, #123a55 0%, #0a2138 45%, #04101f 100%);
}

/* ---------- Header: close button always on the right (brand, when present, on the left) ---------- */
.offcanvas.mobile-offcanvas .offcanvas-header {
    flex: 0 0 auto;
    justify-content: space-between;
    padding: calc(0.9rem + env(safe-area-inset-top, 0px)) 1.5rem 0.9rem;
}

.offcanvas.mobile-offcanvas .offcanvas-title {
    font-family: "Montserrat", serif;
    font-style: italic;
    font-size: 1.35rem;
    color: var(--white);
    text-decoration: none;
}

/* 44px tap target. The invert filter turns the black X white. */
.offcanvas.mobile-offcanvas .btn-close {
    box-sizing: border-box;
    width: 44px;
    height: 44px;
    margin: 0 0 0 auto;
    padding: 0;
    opacity: 1;
    border-radius: 50%;
    background-color: rgba(0, 0, 0, 0.2);
    background-size: 14px;
    filter: invert(1) grayscale(1) brightness(2);
}

/* ---------- Body: nav + CTA, centred horizontally; margin-top:auto centres the group vertically ---------- */
.offcanvas.mobile-offcanvas .offcanvas-body {
    flex: 0 0 auto;
    /* Bootstrap gives it flex-grow:1, which would eat the free space we want to centre with */
    margin-top: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: clamp(1rem, 3.5vh, 1.75rem);
    padding: 0.5rem 1.5rem 0;
    overflow: visible;
    text-align: center;
}

/* Same column width on phones and tablets, so the group stays centred on wide screens */
.offcanvas.mobile-offcanvas .offcanvas-body>* {
    width: 100%;
    max-width: 420px;
}

/* Pages with no .mobile-info (subpages today): the body is the last child, so it takes the bottom auto margin and still centres */
.offcanvas.mobile-offcanvas .offcanvas-body:last-child {
    margin-bottom: auto;
}

/* ---------- Links ---------- */
.offcanvas.mobile-offcanvas .mobile-nav {
    list-style: none;
    margin: 0;
    padding: 0;
}

.offcanvas.mobile-offcanvas .mobile-nav .nav-link {
    display: block;
    padding: clamp(0.3rem, 1.3vh, 0.7rem) 0;
    font-family: "Montserrat", serif;
    font-size: clamp(1.5rem, min(7vw, 4.6vh), 2.3rem);
    /* scales with width AND height, so short screens don't overflow */
    line-height: 1.15;
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    transition: color 0.2s ease;
}

.offcanvas.mobile-offcanvas .mobile-nav .nav-link:hover,
.offcanvas.mobile-offcanvas .mobile-nav .nav-link.active {
    color: var(--pearl);
}

/* Serviços opens in place, centred */
.offcanvas.mobile-offcanvas .mobile-nav .dropdown-menu {
    position: static !important;
    transform: none !important;
    margin: 0 0 0.6rem;
    padding: 0;
    text-align: center;
    background: transparent;
    border: 0;
    box-shadow: none;
}

.offcanvas.mobile-offcanvas .mobile-nav .dropdown-item {
    padding: 0.5rem 0;
    font-size: 1.05rem;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    background: transparent;
}

.offcanvas.mobile-offcanvas .mobile-nav .dropdown-item:hover {
    color: var(--cyan);
}

/* ---------- CTA button ---------- */
.offcanvas.mobile-offcanvas .mobile-cta-wrapper {
    margin: 0;
}

.offcanvas.mobile-offcanvas .mobile-cta-wrapper .btn {
    display: block;
    width: 100%;
    padding: 0.9rem 1rem;
    font-size: 1rem;
    font-weight: 600;
    color: var(--white);
    text-align: center;
    text-decoration: none;
    border: 0;
    border-radius: 18px;
    background-image: linear-gradient(109.6deg,
            rgba(34, 211, 238, 1) 11.2%,
            rgba(79, 57, 246, 1) 100.2%);
}

/* ---------- Info pills + social (sibling of .offcanvas-body) ---------- */
.offcanvas.mobile-offcanvas .mobile-info {
    flex: 0 0 auto;
    align-self: center;
    width: min(420px, calc(100% - 3rem));
    /* same column as the nav and the CTA */
    margin: clamp(1rem, 3.5vh, 1.75rem) 0 auto;
    /* gap above; auto below = vertical centring */
    padding: clamp(1rem, 3vh, 1.5rem) 0 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    position: static;
    /* the old "position: relative; top: -5rem" dragged this block up over the Contato button */
    top: auto;
}

.offcanvas.mobile-offcanvas .mobile-info>span,
.offcanvas.mobile-offcanvas .mobile-info>a {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.45rem 0.9rem;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 999px;
}

.offcanvas.mobile-offcanvas .mobile-info .bi {
    color: var(--cyan);
}

.offcanvas.mobile-offcanvas .mobile-info>a:hover {
    color: var(--pearl);
    border-color: rgba(114, 220, 220, 0.5);
}

.offcanvas.mobile-offcanvas .mobile-social {
    justify-content: center;
    width: 100%;
    margin-top: 0.6rem;
}

.offcanvas.mobile-offcanvas .mobile-social a {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    font-size: 1.1rem;
    color: var(--white);
    text-decoration: none;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 50%;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.offcanvas.mobile-offcanvas .mobile-social a:hover {
    color: var(--ink);
    background: var(--pearl);
    transform: translateY(-2px);
}

/* ---------- Short screens (small phones with browser toolbars, landscape): tighter, scrolls if still too tall ---------- */
@media (max-height: 640px) {
    .offcanvas.mobile-offcanvas .offcanvas-header {
        padding-top: calc(0.5rem + env(safe-area-inset-top, 0px));
        padding-bottom: 0.25rem;
    }

    .offcanvas.mobile-offcanvas .offcanvas-body {
        gap: 0.75rem;
        padding-top: 0;
    }

    .offcanvas.mobile-offcanvas .mobile-nav .nav-link {
        padding: 0.2rem 0;
    }

    .offcanvas.mobile-offcanvas .mobile-cta-wrapper .btn {
        padding: 0.7rem 1rem;
    }

    .offcanvas.mobile-offcanvas .mobile-info {
        margin-top: 0.75rem;
        padding-top: 0.75rem;
    }

    .offcanvas.mobile-offcanvas .mobile-social {
        margin-top: 0.3rem;
    }

    .offcanvas.mobile-offcanvas .mobile-social a {
        width: 40px;
        height: 40px;
    }
}


/* ======================================================
       CONTACT LINKS land on the form card itself
       (clear of the fixed navbar)
   ====================================================== */
.contact-form-card {
    scroll-margin-top: 96px;
}

/* ======================================================
       LANGUAGE SWITCH (PT / EN) | behaviour: js/i18n.js
       Desktop: next to the CTA. Phones/tablets: top bar.
   ====================================================== */
.main-navbar .nav-actions {
    grid-column: 3;
    justify-self: end;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.lang-switch {
    display: inline-flex;
    flex: none;
    align-items: center;
    gap: 2px;
    padding: 3px;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 999px;
    background: rgba(1, 9, 48, 0.45);
    backdrop-filter: blur(8px);
}

.lang-switch__btn {
    min-width: 2.4rem;
    height: 1.9rem;
    padding: 0 0.55rem;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: rgba(255, 255, 255, 0.78);
    font: 700 0.75rem/1 "Manrope", sans-serif;
    letter-spacing: 0.06em;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.lang-switch__btn:hover {
    color: #fff;
}

.lang-switch__btn.is-active {
    background: var(--cyan);
    color: #02181c;
    cursor: default;
}

.lang-switch__btn:focus-visible {
    outline: 2px solid var(--pearl);
    outline-offset: 2px;
}

.lang-switch.is-busy {
    opacity: 0.7;
    pointer-events: none;
    /* no double clicks while the JSON loads */
}

/* phones / tablets: same box as the hamburger button */
.main-navbar .lang-switch--bar {
    height: 46px;
    margin-left: auto;
    padding: 4px;
    border: 1px solid rgba(3, 3, 22, 0.18);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 8px 24px rgba(3, 3, 22, 0.14);
}

.main-navbar .lang-switch--bar .lang-switch__btn {
    height: 36px;
    min-width: 2.5rem;
    border-radius: 8px;
    color: var(--ash);
}

.main-navbar .lang-switch--bar .lang-switch__btn.is-active {
    background: var(--navy);
    color: #fff;
}

.main-navbar .lang-switch--bar+.navbar-toggler {
    margin-left: 0.5rem;
}

.main-navbar .lang-switch--bar,
.main-navbar .navbar-toggler {
    flex: none;
    /* never squeezed by a long logo */
}

/* very small phones (< 375px): logo + name, switch and menu button must share 288px */
@media (max-width: 374.98px) {
    .main-navbar .navbar-brand.brand-lockup {
        font-size: 0.8rem;
    }

    .main-navbar .lang-switch--bar {
        height: 42px;
        padding: 3px;
    }

    .main-navbar .lang-switch--bar .lang-switch__btn {
        height: 34px;
        min-width: 2.1rem;
        padding: 0 0.4rem;
    }

    .main-navbar .navbar-toggler {
        width: 42px;
        height: 42px;
    }

    .main-navbar .lang-switch--bar+.navbar-toggler {
        margin-left: 0.4rem;
    }
}

/* the "message sent" alert opens under the navbar (max ~77px tall),
   so it never covers the language switch or the CTA */
.contact-section .contact-alert {
    top: 88px;
}

/* ======================================================
       SECONDARY NAVBAR (top bar) | from Francisco's branch
       Desktop only (.d-lg-flex in the HTML). Folds away once the
       first section is scrolled past: js/topbar.js adds
       .topbar-collapsed to the navbar.
   ====================================================== */
.main-navbar .topbar {
    max-width: 1600px;
    margin: 0 auto 0.6rem;
    padding-bottom: 0.55rem;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.75);
    border-bottom: 1px solid rgba(255, 255, 255, 0.14);
    max-height: 60px;
    overflow: hidden;
    transition:
        max-height 0.4s ease,
        opacity 0.3s ease,
        margin 0.4s ease,
        padding 0.4s ease,
        border-color 0.4s ease;
}

.main-navbar.topbar-collapsed .topbar {
    max-height: 0;
    opacity: 0;
    margin-bottom: 0;
    padding-bottom: 0;
    border-color: transparent;
    border-bottom-width: 0;
}

.topbar-left,
.topbar-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.topbar-item {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: inherit;
    white-space: nowrap;
    text-decoration: none;
}

.topbar-item .bi {
    color: var(--cyan);
}

.topbar-divider {
    width: 1px;
    height: 14px;
    background: rgba(255, 255, 255, 0.25);
}

.topbar-social {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    font-size: 0.95rem;
}

.topbar-social a {
    color: inherit;
    transition: color 0.2s ease, transform 0.2s ease;
}

.topbar-social a:hover,
a.topbar-item:hover {
    color: var(--pearl);
}

.topbar-social a:hover {
    transform: translateY(-2px);
}

.topbar a:focus-visible {
    outline: 2px solid var(--pearl);
    outline-offset: 3px;
    border-radius: 4px;
}

/* desktop: the hero card starts below the taller navbar (the open top bar adds ~2.75rem),
   with the same ~20px gap as before; its height gives that space back so it still fits the screen.
   "body" only lifts specificity above css/hero-carousel.css, which loads after this file */
@media (min-width: 992px) {
    body main>.hero.hero-carousel {
        --hero-h: clamp(600px, calc(100vh - 11.25rem), 720px);
        margin-top: 7.75rem;
    }
}

/* phone menu: the social icons sit in one row */
.offcanvas.mobile-offcanvas .mobile-social {
    display: flex;
    gap: 0.75rem;
}

@media (prefers-reduced-motion: reduce) {

    .main-navbar .topbar,
    .topbar-social a {
        transition: none;
    }
}

/* ======================================================
       ICONS INSIDE CENTRING BOXES
       Bootstrap Icons nudges every glyph down by 0.125em
       (.bi::before { vertical-align: -.125em }) so it lines up
       with running text. Inside a box that centres its content
       (topbar, mobile-menu pills and round buttons, contact
       squares, event badge) that nudge just makes the icon sit
       low. display: inline-flex turns the glyph into a flex item,
       and vertical-align does not apply to flex items, so the box
       centres the glyph itself. Icons next to text inside a line
       (buttons, lists) keep Bootstrap's default: that nudge is what
       lines them up with the text.
       ====================================================== */
.topbar .bi,
.mobile-info .bi,
.contact-info-icon .bi,
.event-status .bi {
    display: inline-flex;
}

/* the topbar social links are icon-only: make each link a centring box too
   (as plain inline links, the icon sat on the text line, 1px above centre) */
.topbar-social a {
    display: inline-flex;
    align-items: center;
    height: 1.5em;
    /* the line height the inline link had: keeps the topbar exactly as tall as before */
    text-decoration: none;
    /* as a flex box the link's default underline shows under the icon */
}

/* CONTACT FORM ICONS */
.contact-chips {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.75rem;
    margin: 2rem 0 2.5rem;
}

.contact-chip {
    position: relative;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 1px solid var(--border);
    border-radius: 50%;
    background: rgba(169, 234, 228, 0.42);
    color: var(--navy);
    font-size: 1.1rem;
    line-height: 1;
    text-decoration: none;
    transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.contact-chip:hover,
.contact-chip:focus,
.contact-chip:focus-visible {
    transform: translateY(-2px);
    background: var(--navy);
    color: var(--white);
    box-shadow: 0 10px 24px rgba(3, 3, 22, 0.14);
    outline: none;
}

/* ícone centrado: o glifo deixa de ser empurrado 0.125em para baixo */
.contact-chip-icon {
    display: grid;
    place-items: center;
}

.contact-chip-icon .bi {
    display: inline-flex;
}

/* balão com a informação (escondido por defeito) */
.contact-chip-info {
    --tx: -50%;
    position: absolute;
    bottom: calc(100% + 10px);
    left: 50%;
    z-index: 5;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0.45rem 0.8rem;
    border-radius: 10px;
    background: var(--navy);
    box-shadow: 0 12px 28px rgba(3, 3, 22, 0.25);
    white-space: nowrap;
    line-height: 1.25;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translate(var(--tx), 6px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0s linear 0.2s;
}

/* setinha do balão */
.contact-chip-info::after {
    content: "";
    position: absolute;
    top: 100%;
    left: 50%;
    margin-left: -5px;
    border: 5px solid transparent;
    border-top-color: var(--navy);
}

.contact-chip:hover .contact-chip-info,
.contact-chip:focus .contact-chip-info,
.contact-chip:focus-visible .contact-chip-info {
    opacity: 1;
    visibility: visible;
    transform: translate(var(--tx), 0);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0s linear 0s;
}

.contact-chip-info small {
    color: var(--pearl);
    font-size: 0.66rem;
    font-weight: 600;
}

.contact-chip-info strong {
    color: var(--white);
    font-size: 0.76rem;
    font-weight: 700;
}

/* telemóvel: os balões das pontas alinham-se à borda, para não saírem do ecrã */
@media (max-width: 575.98px) {
    .contact-chip:nth-child(-n+3) .contact-chip-info {
        --tx: 0;
        left: 0;
    }

    .contact-chip:nth-child(-n+3) .contact-chip-info::after {
        left: 17px;
        margin-left: 0;
    }

    .contact-chip:nth-last-child(-n+3) .contact-chip-info {
        --tx: 0;
        left: auto;
        right: 0;
    }

    .contact-chip:nth-last-child(-n+3) .contact-chip-info::after {
        left: auto;
        right: 17px;
        margin-left: 0;
    }
}

@media (prefers-reduced-motion: reduce) {

    .contact-chip,
    .contact-chip-info {
        transition: none;
    }
}

#overlayGradient {
    position: relative;
    overflow: hidden;
    isolation: isolate;
}

#overlayGradient::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(126deg,
            #000d3600 0%,
            #001a6b00 25%,
            #00369e45 50%,
            #123e7199 75%,
            #1571b2 100%);
    z-index: 2;
    pointer-events: none;
}

#overlayGradient>[class*="col-lg-6"] {
    position: relative;
    z-index: 1;
}


#equipa {
    .team-photo img {
        filter: brightness(0.9) contrast(1.2) saturate(1.2) !important;
    }
}


.brand-name:hover {
    color: var(--icy-aqua);
}


/* QR code in the event pop-up (computers only).
   Scanning it opens WhatsApp on the visitor's phone with a sign-up message for that
   event (js/events.js draws it). It sits inside the facts card (Data / Horário / Local /
   Formato), at its right end, centred top to bottom. Phones and tablets can't scan their
   own screen, so there it is hidden and the button below does the job. */
.event-facts .event-qr {
    display: none;
}

@media (min-width: 992px) and (pointer: fine) {
    /* a third column for the QR. The facts alone decide the box's height; the QR and its
       label shrink to fit it: top level with Data, label's bottom level with Formato */
    .event-facts.has-qr {
        grid-template-columns: repeat(2, minmax(0, 1fr)) 140px;
        grid-template-rows: auto auto;
    }

    .event-facts .event-qr:not([hidden]) {
        grid-column: 3;
        grid-row: 1 / -1;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 0.2rem;
        contain: size;                     /* adds no height of its own: never grows the box */
    }

    .event-facts .event-qr-code {
        flex: 1 1 0;
        min-height: 0;
        display: flex;
        justify-content: center;
    }

    .event-facts .event-qr-code svg {
        display: block;
        height: 100%;
        width: auto;
        aspect-ratio: 1;
        padding: 0;
        background: #ffffff;
        border-radius: 10px;
        box-shadow: 0 0 0 1px var(--border);
    }

    .event-facts .event-qr-label {
        flex: none;
        font-size: 0.65rem;
        white-space: nowrap;               /* one line, so the code keeps the height */
        font-weight: 700;
        line-height: 1.1;
        text-align: center;
        color: var(--slate);
    }
}

/* ---------- phones and tablets: quick entrance animations ----------
   In one column, blocks cross the screen quickly, so below 992px every
   scroll animation is short and starts at once, whatever the HTML asks
   for (a 3000ms fade, or a 300ms stagger delay, meant a block only became
   visible once it had nearly scrolled away). Desktop keeps the timings set
   in the HTML. The AOS settings for phones (fire earlier, don't replay)
   are in each page's AOS.init. */
@media (max-width: 991.98px) {
    body [data-aos][data-aos][data-aos] {
        transition-duration: 0.5s;
    }

    body [data-aos][data-aos][data-aos][data-aos-delay].aos-animate {
        transition-delay: 0s;
    }
}

/* tablets (768-991px): the hero's video/wave decoration reached 64px past the
   right edge and the whole page could be dragged sideways. "clip" trims it at
   the screen edge without turning <main> into a scroll box (same as the other pages). */
main {
    overflow-x: clip;
}

/* ---------- testimonials: the quote sits in the middle of the white panel ----------
   (same block in css/home.css and css/services.css)
   The quote used Bootstrap's caption placement (pinned to the bottom, pulled up by
   -6rem). Longer text on a phone grew upwards out of the panel: the quote mark was
   cut off at the top, the arrows sat on the words and the bottom half stayed empty.
   Now the quote is centred in the panel, with room left for the arrows and dots. */
#testimonials #testCarousel .carousel-inner .carousel-item {
    margin-top: 0;
}

#testimonials #testCarousel .carousel-inner .carousel-item.active,
#testimonials #testCarousel .carousel-inner .carousel-item-next,
#testimonials #testCarousel .carousel-inner .carousel-item-prev {
    display: flex;
    align-items: center;
    justify-content: center;
}

#testimonials #testCarousel .carousel-inner .carousel-item .carousel-caption {
    position: static;
    width: 100%;
    padding: 2.5rem 15% 3.5rem;   /* sides: the arrows; bottom: the dots */
}

/* phones: the panel grows with the quote instead of cutting it */
@media (max-width: 767.98px) {
    #testimonials {
        height: auto;
        margin: 4rem 0;
    }

    #testimonials #testCarousel,
    #testimonials #testCarousel .carousel-inner {
        height: auto;
    }

    #testimonials #testCarousel .carousel-inner .carousel-item {
        min-height: 60vh;
    }

    #testimonials #testCarousel .carousel-inner .carousel-item .carousel-caption {
        padding: 2.5rem 16% 3.75rem;
    }

    #testimonials #testCarousel .carousel-caption h3 {
        font-size: 1.2rem;
        line-height: 1.4;
    }
}

/* ======================================================
       PARCEIROS E APOIANTES | logo strip under the team
       ====================================================== */
/* each logo sits on a white card of the same height, so logos that come with a
   white background (most of them) look deliberate instead of pasted in */
.partners .partner-logos {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.9rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.partners .partners-title {
    margin: 0 0 1.25rem;
    text-align: center;
    font-family: "Manrope", sans-serif;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--slate);
}

.partners .partner-logos li {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 64px;
    padding: 0.45rem 0.8rem;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 0 0 1px rgba(15, 30, 60, 0.06), 0 6px 18px -12px rgba(15, 30, 60, 0.35);
}

.partners .partner-logos img {
    display: block;
    width: auto;
    height: auto;
    max-height: 100%;
    max-width: 140px;
}

/* the two logos that are full square tiles fill their card edge to edge */
.partners .partner-logos li.tile {
    padding: 0;
    overflow: hidden;
    aspect-ratio: 1;
}

.partners .partner-logos li.tile img {
    height: 100%;
    max-width: none;
}

@media (max-width: 575.98px) {
    .partners .partner-logos {
        gap: 0.6rem;
    }

    .partners .partner-logos li {
        height: 58px;
        padding: 0.4rem 0.6rem;
    }

    .partners .partner-logos img {
        max-width: 112px;
    }
}

/* topbar: both phone numbers, one icon (84 / 87) */
.topbar-phones a {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s ease;
}

.topbar-phones a:hover {
    color: var(--pearl);
}

.topbar-phones .phone-sep {
    opacity: 0.45;
}

/* a partner logo that links to the partner's page: no link colour (Bootstrap's blue), sits inside the card */
.partners .partner-logos li > a {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    max-height: 100%;
    color: inherit;
    text-decoration: none;
    outline: none;
    -webkit-tap-highlight-color: transparent;
}

.partners .partner-logos li > a:focus-visible {
    outline: 2px solid var(--slate);
    outline-offset: 4px;
    border-radius: 8px;
}

/* OS Design logo is a tall mark + name: keep it inside its card like the others */
.partners .partner-logos img.logo-osdesign {
    width: auto;
    height: auto;
    max-height: 100%;
    max-width: 56px;
}

@media (min-width: 992px) {
    .partners .partner-logos img.logo-osdesign,
    main > section.partners .partner-logos img.logo-osdesign {
        max-width: 75px;
    }
}
