/********** Template CSS **********/


.back-to-top {
    position: fixed;
    display: none;
    right: 30px;
    bottom: 30px;
    z-index: 99;
}

.fw-medium {
    font-weight: 500;
}


/*** Spinner ***/
#spinner {
    opacity: 0;
    visibility: hidden;
    transition: opacity .5s ease-out, visibility 0s linear .5s;
    z-index: 99999;
}

#spinner.show {
    transition: opacity .5s ease-out, visibility 0s linear 0s;
    visibility: visible;
    opacity: 1;
}


/*** Button ***/
.btn {
    transition: .5s;
    font-weight: 500;
}

.btn-primary,
.btn-outline-primary:hover {
    color: var(--bs-light);
}

.btn-secondary,
.btn-outline-secondary:hover {
    color: var(--bs-dark);
}

.btn-square {
    width: 38px;
    height: 38px;
}

.btn-sm-square {
    width: 32px;
    height: 32px;
}

.btn-lg-square {
    width: 48px;
    height: 48px;
}

.btn-square,
.btn-sm-square,
.btn-lg-square {
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50px;
    font-weight: normal;
}

.icon-box-primary,
.icon-box-light {
    position: relative;
    padding: 0 0 10px 10px;
    z-index: 1;
}

.icon-box-primary i,
.icon-box-light i {
    font-size: 60px;
    line-height: 0;
}

.icon-box-primary::before,
.icon-box-light::before {
    position: absolute;
    content: "";
    width: 35px;
    height: 35px;
    left: 0;
    bottom: 0;
    border-radius: 35px;
    transition: .5s;
    z-index: -1;
}

.icon-box-primary::before {
    background: var(--bs-primary);
}

.icon-box-light::before {
    background: var(--bs-light);
}


/*** Navbar ***/
.sticky-top {
    top: -100px;
    transition: .5s;
}

.navbar .navbar-nav .nav-link {
    margin-right: 35px;
    padding: 20px 0;
    color: var(--bs-dark);
    font-size: 18px;
    font-weight: 500;
    outline: none;
}

.navbar .navbar-nav .nav-link:hover,
.navbar .navbar-nav .nav-link.active {
    color: var(--bs-primary);
}

.navbar .dropdown-toggle::after {
    border: none;
    content: "\f107";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    vertical-align: middle;
    margin-left: 8px;
}

@media (max-width: 991.98px) {
    .navbar .navbar-nav .nav-link  {
        margin-right: 0;
        padding: 10px 0;
        color: #FFD300 !important;
    }

    .navbar .navbar-nav {
        margin-top: 15px;
        border-top: 1px solid rgba(255, 211, 0, 0.2);
    }
    
    .navbar .navbar-nav .nav-link:hover,
    .navbar .navbar-nav .nav-link.active {
        color: #FFFFFF !important;
    }
}

@media (min-width: 992px) {
    .sticky-top {
        margin-top: -34px;
        background-color: #FFFFFF !important;
    }

    .navbar {
        height: 68px;
        background-color: #FFFFFF !important;
    }

    /* center the navbar items horizontally on desktop */
    .navbar .navbar-collapse {
        justify-content: center;
    }

    .navbar .nav-item .dropdown-menu {
        display: block;
        border: none;
        margin-top: 0;
        top: 150%;
        opacity: 0;
        visibility: hidden;
        transition: .5s;
    }

    .navbar .nav-item:hover .dropdown-menu {
        top: 100%;
        visibility: visible;
        transition: .5s;
        opacity: 1;
    }
    
    /* Nested dropdown for Revue Scientifique */
    .navbar .dropdown-menu .nav-item.dropdown .dropdown-menu {
        display: block;
        border: none;
        margin-top: 0;
        top: 0;
        left: 100%;
        opacity: 0;
        visibility: hidden;
        transition: .5s;
    }
    
    .navbar .dropdown-menu .nav-item.dropdown:hover .dropdown-menu {
        top: 0;
        left: 100%;
        visibility: visible;
        transition: .5s;
        opacity: 1;
    }
}


/*** Header ***/
@media (min-width: 992px) {
    .header-carousel,
    .page-header {
        margin-top: -34px;
    }
}

.carousel-caption {
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    background: rgba(108, 117, 125, .3); /* replaced blue overlay with gray (#6c757d) */
    z-index: 1;
}

.carousel-control-prev,
.carousel-control-next {
    width: 15%;
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 3.5rem;
    background-color: var(--bs-primary);
    border: 15px solid var(--bs-primary);
}

@media (max-width: 767.98px) {
    #header-carousel .carousel-item {
        position: relative;
        min-height: 450px;
    }
    
    #header-carousel .carousel-item img {
        position: absolute;
        width: 100%;
        height: 100%;
        object-fit: cover;
    }
}

.page-header {
    background: linear-gradient(rgba(108, 117, 125, .3), rgba(108, 117, 125, .3)), url(../img/testimonial.jpg) center center no-repeat; /* gray overlay */
    background-size: cover;
}

.page-header .breadcrumb-item+.breadcrumb-item::before {
    color: var(--bs-white);
}

.page-header .breadcrumb-item,
.page-header .breadcrumb-item a {
    font-size: 18px;
    color: var(--bs-white);
}


/*** Features ***/
.feature {
    background: linear-gradient(rgba(108, 117, 125, .3), rgba(108, 117, 125, .3)), url(../img/feature.jpg) left center no-repeat; /* gray overlay */
    background-size: cover;
}

.feature-row {
    box-shadow: 0 0 45px rgba(0, 0, 0, .08);
}

.feature-item {
    border-color: rgba(0, 0, 0, .03) !important;
}

.experience .progress {
    height: 5px;
}

.experience .progress .progress-bar {
    width: 0px;
    transition: 3s;
}

.experience .nav-pills .nav-link {
    color: var(--dark);
}

.experience .nav-pills .nav-link.active {
    color: #FFFFFF;
}

.experience .tab-content hr {
    width: 30px;
}


/*** About ***/
.about-fact {
    width: 220px;
    height: 220px;
    box-shadow: 0 0 30px rgba(0, 0, 0, .1);
}

@media (min-width: 576px) {
    .about-fact.mt-n130 {
        margin-top: -130px;
    }
}

.btn-play {
    position: relative;
    display: block;
    box-sizing: content-box;
    width: 36px;
    height: 46px;
    border-radius: 100%;
    border: none;
    outline: none !important;
    padding: 18px 20px 20px 28px;
    background: var(--bs-primary);
}

.btn-play:before {
    content: "";
    position: absolute;
    z-index: 0;
    left: 50%;
    top: 50%;
    transform: translateX(-50%) translateY(-50%);
    display: block;
    width: 90px;
    height: 90px;
    background: var(--bs-primary);
    border-radius: 100%;
    animation: pulse-border 1500ms ease-out infinite;
}

.btn-play:after {
    content: "";
    position: absolute;
    z-index: 1;
    left: 50%;
    top: 50%;
    transform: translateX(-50%) translateY(-50%);
    display: block;
    width: 90px;
    height: 90px;
    background: var(--bs-primary);
    border-radius: 100%;
    transition: all 200ms;
}

.btn-play span {
    display: block;
    position: relative;
    z-index: 3;
    width: 0;
    height: 0;
    left: 3px;
    border-left: 30px solid #FFFFFF;
    border-top: 18px solid transparent;
    border-bottom: 18px solid transparent;
}

@keyframes pulse-border {
    0% {
        transform: translateX(-50%) translateY(-50%) translateZ(0) scale(1);
        opacity: 1;
    }

    100% {
        transform: translateX(-50%) translateY(-50%) translateZ(0) scale(2);
        opacity: 0;
    }
}

.modal-video .modal-dialog {
    position: relative;
    max-width: 800px;
    margin: 60px auto 0 auto;
}

.modal-video .modal-body {
    position: relative;
    padding: 0px;
}

.modal-video .close {
    position: absolute;
    width: 30px;
    height: 30px;
    right: 0px;
    top: -30px;
    z-index: 999;
    font-size: 30px;
    font-weight: normal;
    color: #FFFFFF;
    background: #000000;
    opacity: 1;
}


/*** Service ***/
.container-service {
    position: relative;
}

.container-service::before {
    position: absolute;
    content: '';
    background: var(--bs-light);
    width: 100%;
    height: 100%;
    left: 0px;
    top: 0px;
    clip-path: polygon(0 0, 100% 0, 100% 30%, 0 70%);
    z-index: -1;
}

.service-item {
    position: relative;
    height: 100%;
    padding: 45px 30px;
    background: var(--bs-white);
    box-shadow: 0 0 45px rgba(0, 0, 0, .05);
}

.service-item::before {
    position: absolute;
    content: "";
    width: 100%;
    height: 0;
    left: 0;
    bottom: 0;
    transition: .5s;
    background: var(--bs-primary);
}

.service-item:hover::before {
    height: 100%;
    top: 0;
}

.service-item * {
    position: relative;
    transition: .5s;
    z-index: 1;
}

.service-item:hover h5,
.service-item:hover p {
    color: var(--bs-white);
}

.service-item:hover .icon-box-primary::before {
    background: var(--bs-dark);
}

.service-item:hover .icon-box-primary i {
    color: var(--bs-white) !important;
}


/*** Team ***/
.container-team {
    position: relative;
}

.container-team::before {
    position: absolute;
    content: '';
    background: var(--bs-light);
    width: 100%;
    height: 100%;
    left: 0px;
    top: 0px;
    clip-path: polygon(0 70%, 100% 30%, 100% 100%, 0% 100%);
    z-index: -1;
}

.team-item {
    background: var(--bs-white);
    box-shadow: 0 0 45px rgba(0, 0, 0, .05);
}

.team-item .team-social {
    position: absolute;
    width: 0;
    height: 100%;
    top: 0;
    right: 0;
    transition: .5s;
    background: var(--bs-primary);
    display: flex;
    align-items: center;
    justify-content: center;
}

.team-item:hover .team-social {
    width: 100%;
    left: 0;
}

.team-item .team-social .btn {
    opacity: 0;
    transition: .5s;
}

.team-item:hover .team-social .btn {
    opacity: 1;
}


/*** Testimonial ***/
.testimonial {
    background: linear-gradient(rgba(108, 117, 125, .3), rgba(108, 117, 125, .3)), url(../img/testimonial.jpg) left center no-repeat; /* gray overlay */
    background-size: cover;
}

.testimonial-item img {
    width: 60px !important;
    height: 60px !important;
    border-radius: 60px;
}

.testimonial-carousel .owl-nav {
    position: absolute;
    top: 0;
    right: 0;
    display: flex;
}

.testimonial-carousel .owl-nav .owl-prev,
.testimonial-carousel .owl-nav .owl-next {
    margin-left: 15px;
    color: var(--bs-primary);
    font-size: 30px;
    line-height: 0;
    transition: .5s;
}

.testimonial-carousel .owl-nav .owl-prev:hover,
.testimonial-carousel .owl-nav .owl-next:hover {
    color: var(--bs-dark);
}


/*** Contact ***/
@media (min-width: 992px) {
    .contact-info::after {
        position: absolute;
        content: "";
        width: 0px;
        height: 100%;
        top: 0;
        left: 50%;
        border-left: 1px dashed rgba(255, 255, 255, .2);
    }
}

@media (max-width: 991.98px) {
    .contact-info::after {
        position: absolute;
        content: "";
        width: 100%;
        height: 0px;
        top: 50%;
        left: 0;
        border-top: 1px dashed rgba(255, 255, 255, .2);
    }
}


/*** Footer ***/
.footer {
    background: linear-gradient(#1111aba0, #1111aba0), url(../img/footer.png) center center no-repeat; /* footer color set to #1111ab */
    background-size: contain;
}

@media (min-width: 992px) {
    .footer::after {
        position: absolute;
        content: "";
        width: 0px;
        height: 100%;
        top: 0;
        left: 50%;
        border-left: 1px dashed rgba(255, 255, 255, .2);
    }
}

.footer .btn.btn-link {
    display: block;
    margin-bottom: 5px;
    padding: 0;
    text-align: left;
    color: rgba(255, 255, 255, .5);
    font-weight: normal;
    text-transform: capitalize;
    transition: .3s;
}

.footer .btn.btn-link::before {
    position: relative;
    content: "\f105";
    font-family: "Font Awesome 5 Free";
    font-weight: 900;
    color: rgba(255, 255, 255, .5);
    margin-right: 10px;
}

.footer .btn.btn-link:hover {
    color: var(--bs-primary);
    letter-spacing: 1px;
    box-shadow: none;
}

.copyright {
    border-top: 1px dashed rgba(255, 255, 255, .2);
}

.copyright a {
    color: var(--bs-white);
}

.copyright a:hover {
    color: var(--bs-primary);
}

/* Split layout for direction pages: left/right panels */
.direction-split {
    display: flex;
    gap: 30px;
    align-items: stretch;
    margin-top: 10px; /* reduced top gap so tables sit higher */
    margin-bottom: 20px;
    min-height: 60vh; /* ensure split fills a large portion of viewport */
}

/* Each panel takes equal space and can scroll its content */
.direction-split .left,
.direction-split .right {
    flex: 1 1 50%;
    min-height: inherit;
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    border-radius: 8px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.06);
    background: var(--bs-white);
    overflow: hidden;
}

/* ensure table containers scroll inside their panel */
.direction-split .left .table-responsive,
.direction-split .right .table-responsive {
    flex: 1 1 auto;
    overflow: auto;
}

/* Make a visual distinction: left light, right slightly tinted */
.direction-split .left {
    background: linear-gradient(180deg, rgba(255,255,255,1), rgba(250,250,250,1));
}

.direction-split .right {
    background: linear-gradient(180deg, rgba(250,250,255,1), rgba(245,245,250,1));
}

/* Optional content helpers inside panels */
.direction-split .left .panel-title,
.direction-split .right .panel-title {
    margin-bottom: 1rem;
    font-weight: 700;
    font-size: 1.5rem;
}

.direction-split .left p,
.direction-split .right p {
    margin-bottom: 1rem;
    color: #333;
}

/* Narrow layout: stack vertically on mobile */
@media (max-width: 991.98px) {
    .direction-split {
        flex-direction: column;
        gap: 20px;
    }
    .direction-split .left,
    .direction-split .right {
        min-height: auto;
        padding: 20px;
    }
}

/* Add a subtle divider for large screens (vertical line) */
@media (min-width: 992px) {
    .direction-split {
        position: relative;
        padding: 10px 0;
    }
    .direction-split::after {
        content: "";
        position: absolute;
        top: 10%;
        bottom: 10%;
        left: 50%;
        width: 1px;
        background: rgba(0,0,0,0.06);
        transform: translateX(-50%);
        z-index: 0;
    }
    .direction-split .left,
    .direction-split .right {
        position: relative;
        z-index: 1;
    }
}

/* Small tweak: ensure images inside panels are responsive */
.direction-split img {
    max-width: 100%;
    height: auto;
    border-radius: 6px;
}

/* Responsive Brand Header */
@media (max-width: 992px) {
    .container-fluid[style*="background-color: #1111ab"] {
        padding-top: 0.5rem !important;
        padding-bottom: 0.5rem !important;
    }
    
    .d-flex[style*="height: 80px"] img {
        height: 60px !important;
    }
    
    .d-flex[style*="height: 80px"] a {
        font-size: 1.1rem !important;
        margin-right: 50px !important;
    }
}

@media (max-width: 768px) {
    .d-flex[style*="height: 80px"] {
        flex-direction: column !important;
        align-items: center !important;
        gap: 0.5rem;
    }
    
    .d-flex[style*="height: 80px"] img {
        height: 50px !important;
        margin-right: 10px !important;
    }
    
    .d-flex[style*="height: 80px"] a {
        font-size: 1rem !important;
        margin-right: 0 !important;
        text-align: center;
    }
}

/* Responsive Navbar */
@media (max-width: 992px) {
    .navbar {
        padding: 0.5rem 0 !important;
    }
    
    .navbar-nav {
        padding: 0.5rem 0;
    }
    
    .nav-link {
        padding: 0.5rem 0.75rem !important;
        font-size: 0.95rem;
    }
}

/* Responsive Page Header */
@media (max-width: 768px) {
    .page-header {
        padding: 2rem 1rem !important;
    }
    
    .page-header h1 {
        font-size: 2rem !important;
    }
    
    .page-header p {
        font-size: 0.9rem;
    }
    
    /* About section circular stats */
    .about-fact {
        width: 140px !important;
        height: 140px !important;
        margin: 0 auto !important;
    }
    
    .about-fact.mt-n130 {
        margin-top: 1rem !important;
    }
    
    .about-fact p {
        font-size: 0.85rem !important;
    }
    
    .about-fact h1 {
        font-size: 2rem !important;
    }
    
    .row.g-4.g-sm-5 {
        gap: 1rem !important;
    }
    
    /* Features section (Tchad-IA) responsive */
    .container-fluid.feature .bg-white {
        padding: 2rem 1.5rem !important;
        margin-top: 0 !important;
    }
    
    .container-fluid.feature .display-6 {
        font-size: 1.5rem !important;
        line-height: 1.3;
    }
    
    .container-fluid.feature p {
        font-size: 0.95rem;
    }
    
    .container-fluid.feature .icon-box-primary {
        padding: 0 0 8px 8px !important;
    }
    
    .container-fluid.feature .icon-box-primary i {
        font-size: 40px !important;
    }
    
    .container-fluid.feature h5 {
        font-size: 1rem;
    }
    
    .container-fluid.feature span {
        font-size: 0.9rem;
    }
    
    .container-fluid.feature .btn-play {
        width: 60px !important;
        height: 60px !important;
    }
    
    .container-fluid.feature .d-flex[style*="min-height"] {
        min-height: 200px !important;
    }
    
    .container-fluid.feature .bg-primary {
        padding: 2rem 1.5rem !important;
    }
    
    .container-fluid.feature .experience span {
        font-size: 0.85rem;
    }
    
    .container-fluid.feature .row.g-5 {
        gap: 1.5rem !important;
    }
}

/* Responsive Container */
@media (max-width: 768px) {
    .container {
        padding: 0 0.75rem;
    }
}

/* Responsive Tables */
@media (max-width: 768px) {
    .table-responsive {
        font-size: 0.85rem;
    }
    
    .table {
        margin-bottom: 0;
    }
    
    .table th,
    .table td {
        padding: 0.5rem !important;
    }
    
    .btn-sm {
        padding: 0.25rem 0.5rem !important;
        font-size: 0.75rem !important;
    }
}

/* Responsive Buttons */
@media (max-width: 768px) {
    .btn {
        padding: 0.4rem 0.8rem;
        font-size: 0.9rem;
    }
    
    .d-flex.justify-content-between {
        flex-direction: column;
        gap: 0.5rem;
    }
}

/* Responsive Footer */
@media (max-width: 768px) {
    .footer {
        padding: 2rem 0 !important;
    }
    
    .footer .row {
        gap: 1.5rem;
    }
    
    .footer h4 {
        font-size: 1rem;
        margin-bottom: 0.5rem !important;
    }
    
    .footer p {
        font-size: 0.9rem;
        margin-bottom: 0.5rem !important;
    }
}

/* Responsive Alerts */
@media (max-width: 768px) {
    .alert {
        padding: 0.75rem !important;
        font-size: 0.9rem;
    }
}

/* Responsive Forms */
@media (max-width: 768px) {
    .form-control,
    .form-select {
        font-size: 1rem;
        padding: 0.5rem !important;
    }
    
    .input-group {
        flex-wrap: wrap;
    }
    
    .input-group .form-control {
        flex: 1 1 100%;
        margin-bottom: 0.5rem;
    }
    
    .input-group .btn {
        flex: 1 1 100%;
    }
}

/* Responsive Typography */
@media (max-width: 768px) {
    h1 {
        font-size: 1.5rem !important;
    }
    
    h2 {
        font-size: 1.25rem !important;
    }
    
    h4 {
        font-size: 1rem !important;
    }
    
    .display-4 {
        font-size: 1.75rem !important;
    }
}

/* Responsive Modal */
@media (max-width: 768px) {
    .modal-dialog {
        margin: 1rem !important;
        width: calc(100% - 2rem);
    }
}

/* Responsive Carousel */
@media (max-width: 768px) {
    .carousel-caption {
        padding: 1rem !important;
    }
    
    .carousel-caption h1 {
        font-size: 1.25rem !important;
    }
}

/* Back to Top Button */
@media (max-width: 768px) {
    .back-to-top {
        width: 2.5rem !important;
        height: 2.5rem !important;
        bottom: 1rem !important;
        right: 1rem !important;
    }
}

/* Responsive Brand */
.brand-bar .brand-content {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
}
.brand-bar .brand-logo {
  height: 80px;
  width: auto;
  flex-shrink: 0;
}
.brand-bar .brand-title {
  flex: 1 1 auto;
  text-align: center;
  color: #FFD300;
}

/* Tables */
.table-responsive { font-size: 0.95rem; }
@media (max-width: 992px) { .table-responsive { font-size: 0.9rem; } }
@media (max-width: 768px) {
  .table-responsive { font-size: 0.85rem; }
  .table th, .table td { padding: 0.5rem !important; }
  .table-sm th, .table-sm td { padding: 0.45rem !important; }
}

/* Buttons & layout */
@media (max-width: 768px) {
  .btn { padding: 0.45rem 0.9rem; font-size: 0.95rem; }
  .btn-sm { padding: 0.35rem 0.7rem; font-size: 0.85rem; }
  .d-flex.justify-content-between { flex-direction: column; gap: 0.75rem; }
}

/* Footer */
@media (max-width: 768px) {
  .footer { padding: 2rem 0 !important; }
  .footer .row { gap: 1.25rem; }
  .footer h4 { font-size: 1rem; margin-bottom: 0.5rem !important; }
  .footer p { font-size: 0.9rem; margin-bottom: 0.4rem !important; }
}

/* Typography */
@media (max-width: 768px) {
  h1, .display-4 { font-size: 1.8rem !important; }
  h2 { font-size: 1.4rem !important; }
  h4 { font-size: 1.05rem !important; }
}

/* Forms & alerts */
@media (max-width: 768px) {
  .form-control, .form-select { font-size: 1rem; padding: 0.55rem !important; }
  .alert { padding: 0.75rem !important; font-size: 0.95rem; }
}

/* Brand size tweaks */
@media (max-width: 992px) {
  .brand-bar .brand-logo { height: 65px; }
}
@media (max-width: 768px) {
  .brand-bar .brand-logo { height: 55px; }
}

/* --- Mobile Polish: cohesive, professional, responsive tweaks --- */
/* Global typography scaling for small screens */
@media (max-width: 576px) {
    html { font-size: 15px; }
    body { line-height: 1.55; }
    h1 { font-size: 1.4rem !important; }
    h2 { font-size: 1.25rem !important; }
    h3 { font-size: 1.1rem !important; }
    h4 { font-size: 1rem !important; }
    .display-1 { font-size: 1.75rem !important; line-height: 1.2; }
    .display-2 { font-size: 1.6rem !important; line-height: 1.25; }
    .display-3 { font-size: 1.45rem !important; line-height: 1.25; }
    .display-6 { font-size: 1.25rem !important; line-height: 1.3; }
    p, .lead { font-size: 0.95rem; }
}

/* Section spacing tightening on mobile */
@media (max-width: 576px) {
    .container-fluid.py-5 { padding-top: 2rem !important; padding-bottom: 2rem !important; }
    .mt-5 { margin-top: 2rem !important; }
    .mb-5 { margin-bottom: 2rem !important; }
    .my-5 { margin-top: 2rem !important; margin-bottom: 2rem !important; }
    .p-5 { padding: 1.5rem !important; }
    .px-5 { padding-left: 1.25rem !important; padding-right: 1.25rem !important; }
    .row.g-5 { --bs-gutter-x: 1rem; --bs-gutter-y: 1rem; }
}

/* Feature grid cards (4-up) */
@media (max-width: 576px) {
    .feature-item { padding: 1.25rem !important; }
    .feature-item h5 { font-size: 1rem; margin-bottom: 0.5rem !important; }
    .feature-item p { font-size: 0.95rem; }
    .icon-box-primary i, .icon-box-light i { font-size: 42px; }
}

/* Services (Mission) cards */
@media (max-width: 576px) {
    .service-item { padding: 1.25rem 1rem !important; }
    .service-item h5 { font-size: 1rem; margin-bottom: 0.5rem !important; }
    .service-item p { font-size: 0.95rem; }
    .service-item .icon-box-primary i { font-size: 44px !important; }
}

/* Header carousel caption & hero text */
@media (max-width: 576px) {
    .carousel-caption { padding: 0.75rem 1rem !important; }
    .header-carousel .display-1, #header-carousel .display-1, .carousel-caption h1 {
        font-size: 1.5rem !important; line-height: 1.25 !important;
    }
}

/* Tchad-IA video play button: shrink pseudo elements too */
@media (max-width: 576px) {
    .btn-play { padding: 14px 16px 16px 22px; }
    .btn-play:before, .btn-play:after { width: 70px; height: 70px; }
    .btn-play span { border-left: 22px solid #FFFFFF; border-top: 14px solid transparent; border-bottom: 14px solid transparent; }
}

/* Team section adjustments */
@media (max-width: 576px) {
    .container-team .row.g-5 { --bs-gutter-x: 1rem; --bs-gutter-y: 1.25rem; }
    .container-team h1 { font-size: 1.35rem !important; }
    .container-team h3 { font-size: 1.1rem !important; }
    .container-team p { font-size: 0.95rem; }
}

/* Footer newsletter & meta */
@media (max-width: 576px) {
    .footer .input-group .form-control { padding: 0.6rem 0.9rem !important; font-size: 0.95rem; }
    .footer .input-group .btn { padding: 0.6rem 0.9rem !important; font-size: 0.95rem; }
    .copyright .row { row-gap: 0.5rem; }
}

/* Back-to-top tappable size & position */
@media (max-width: 576px) {
    .back-to-top { width: 2.75rem !important; height: 2.75rem !important; bottom: 0.9rem !important; right: 0.9rem !important; }
}

/* Ensure containers have breathing room on small screens */
@media (max-width: 576px) {
    .container { padding-left: 0.9rem; padding-right: 0.9rem; }
}