/* ==========================================================================
   Design System & Variables (Light Theme Overhaul)
   ========================================================================== */
:root {
    --bg-primary: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-tertiary: #f1f5f9;
    
    --accent: #f2c12e; /* Golden Yellow from the Flyer */
    --accent-rgb: 242, 193, 46;
    --accent-hover: #dca618;
    --accent-glow: rgba(242, 193, 46, 0.25);
    
    --police-blue: #0b2b61; /* Royal/Navy Police Blue from the Flyer */
    --police-glow: rgba(11, 43, 97, 0.15);
    
    --text-main: #1e293b; /* Dark Slate for high readability */
    --text-muted: #5e718d; /* Medium Slate for secondary text */
    --text-dark: #0b2b61;
    
    --border-color: rgba(11, 43, 97, 0.08);
    --border-accent: rgba(242, 193, 46, 0.45);
    
    --font-title: 'Montserrat', system-ui, -apple-system, sans-serif;
    --font-body: 'Inter', system-ui, -apple-system, sans-serif;
    
    --transition-smooth: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-quick: all 0.25s ease;
    
    --shadow-main: 0 10px 30px rgba(11, 43, 97, 0.05);
    --shadow-card: 0 15px 35px rgba(11, 43, 97, 0.04);
    --shadow-glow: 0 0 25px rgba(242, 193, 46, 0.2);
    --shadow-modal: 0 30px 60px -15px rgba(11, 43, 97, 0.25);

    --header-offset: calc(4.75rem + env(safe-area-inset-top, 0px));
    --section-gap: clamp(0.5rem, 1.8vh, 1.25rem);
    --section-padding-y: clamp(2.25rem, 4.5vw, 5rem);
}

/* ==========================================================================
   Global Reset & Base
   ========================================================================== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    background-color: var(--bg-primary);
    color: var(--text-main);
    overflow-x: hidden;
    scroll-padding-top: var(--header-offset);
}

body {
    font-family: var(--font-body);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    background-color: var(--bg-primary);
    max-width: 100%;
    min-width: 0;
    overflow-x: hidden;
}

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

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition-quick);
}

button, input, select, textarea {
    font-family: inherit;
    color: inherit;
    background: none;
    border: none;
    outline: none;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 clamp(1rem, 3vw, 1.5rem);
    min-width: 0;
}

main {
    min-width: 0;
    max-width: 100%;
    overflow-x: clip;
}

.grid {
    display: grid;
    gap: 2rem;
}

.grid-2col {
    display: grid;
    grid-template-columns: 1fr;
    gap: clamp(1.25rem, 3vw, 2rem);
}

@media (min-width: 768px) {
    .grid-2col {
        grid-template-columns: 1fr 1fr;
        gap: clamp(1.5rem, 3vw, 2.25rem);
    }
}

.items-center {
    align-items: center;
}

.text-center {
    text-align: center;
}

.text-gradient {
    background: linear-gradient(135deg, var(--police-blue) 40%, #1d4ed8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.divider {
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--border-color), transparent);
    margin: 1.5rem 0;
}

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--bg-secondary);
}

::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border: 2px solid var(--bg-secondary);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--police-blue);
}

/* Dotted grid pattern overlay */
.grid-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: radial-gradient(rgba(11, 43, 97, 0.04) 1.5px, transparent 0);
    background-size: 24px 24px;
    pointer-events: none;
    z-index: 1;
}

/* ==========================================================================
   Scroll Reveal & Motion System
   ========================================================================== */
.reveal-on-scroll {
    opacity: 0;
    transform: translateY(24px);
    transition:
        opacity 0.75s cubic-bezier(0.16, 1, 0.3, 1),
        transform 0.75s cubic-bezier(0.16, 1, 0.3, 1);
    transition-delay: var(--reveal-delay, 0s);
    will-change: opacity, transform;
}

.reveal-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

.reveal-from-left {
    transform: translateX(-32px);
}

.reveal-from-left.visible {
    transform: translateX(0);
}

.reveal-from-right {
    transform: translateX(32px);
}

.reveal-from-right.visible {
    transform: translateX(0);
}

.reveal-scale {
    transform: scale(0.94);
}

.reveal-scale.visible {
    transform: scale(1);
}

@keyframes headerEnter {
    from {
        opacity: 0;
        transform: translateY(-100%);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes floatSoft {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.animate-float {
    animation: floatSoft 4.5s ease-in-out infinite;
}

@keyframes statPop {
    from {
        opacity: 0;
        transform: translateY(16px) scale(0.92);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.stats-container.reveal-stagger > .stat-card.visible {
    animation: statPop 0.6s cubic-bezier(0.16, 1, 0.3, 1) both;
    animation-delay: var(--reveal-delay, 0s);
}

@keyframes moduleSlideIn {
    from {
        opacity: 0;
        transform: translateX(-16px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.modal-overlay.active .syllabus-module-item {
    animation: moduleSlideIn 0.5s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.modal-overlay.active .syllabus-module-item:nth-child(1) { animation-delay: 0.05s; }
.modal-overlay.active .syllabus-module-item:nth-child(2) { animation-delay: 0.12s; }
.modal-overlay.active .syllabus-module-item:nth-child(3) { animation-delay: 0.19s; }

.modal-overlay.active .modal-course-title {
    animation: moduleSlideIn 0.5s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.modal-overlay.active .modal-meta-row .modal-badge-duration,
.modal-overlay.active .modal-meta-row .modal-badge-price,
.modal-overlay.active .modal-meta-row .modal-badge-mode {
    animation: statPop 0.45s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.modal-overlay.active .modal-meta-row .modal-badge-duration { animation-delay: 0.08s; }
.modal-overlay.active .modal-meta-row .modal-badge-price { animation-delay: 0.14s; }
.modal-overlay.active .modal-meta-row .modal-badge-mode { animation-delay: 0.2s; }

.stat-card,
.acc-tile,
.contact-info-card,
.feat-box,
.step-item,
.footer-brand,
.footer-links,
.footer-legal {
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.35s ease, border-color 0.25s ease;
}

@media (prefers-reduced-motion: reduce) {
    .reveal-on-scroll,
    .reveal-from-left,
    .reveal-from-right,
    .reveal-scale {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .main-header,
    .animate-float,
    .wa-float-pulse,
    .modal-overlay.active .syllabus-module-item,
    .modal-overlay.active .modal-course-title,
    .stats-container.reveal-stagger > .stat-card.visible {
        animation: none;
    }
}

/* ==========================================================================
   Buttons & Badges
   ========================================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    padding: 0.85rem 1.6rem;
    font-size: 0.95rem;
    font-weight: 700;
    border-radius: 4px;
    cursor: pointer;
    transition: var(--transition-smooth);
    letter-spacing: 0.5px;
    position: relative;
    overflow: hidden;
    min-height: 48px; /* Mobile Friendly Touch Target */
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: all 0.6s ease;
}

.btn:hover::before {
    left: 100%;
}

.btn-primary {
    background: linear-gradient(135deg, var(--police-blue) 0%, #061c42 100%);
    color: #ffffff;
    box-shadow: 0 4px 15px rgba(11, 43, 97, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #103b82 0%, var(--police-blue) 100%);
    transform: translateY(-2.5px);
    box-shadow: 0 8px 25px rgba(11, 43, 97, 0.3);
}

.btn-accent {
    background: linear-gradient(135deg, var(--accent) 0%, #dca618 100%);
    color: var(--police-blue);
    box-shadow: 0 4px 15px rgba(242, 193, 46, 0.2);
    border: 1px solid rgba(242, 193, 46, 0.2);
}

.btn-accent:hover {
    background: linear-gradient(135deg, #ffe285 0%, var(--accent) 100%);
    transform: translateY(-2.5px);
    box-shadow: 0 8px 25px rgba(242, 193, 46, 0.35);
}

.btn-outline {
    border: 1.5px solid var(--police-blue);
    color: var(--police-blue);
    background: rgba(11, 43, 97, 0.01);
}

.btn-outline:hover {
    background: var(--police-blue);
    color: #ffffff;
    transform: translateY(-2.5px);
    box-shadow: 0 8px 25px rgba(11, 43, 97, 0.15);
}

.btn-block {
    display: flex;
    width: 100%;
}

.btn-lg {
    padding: 1rem 2.2rem;
    font-size: 1.05rem;
    min-height: 52px;
}

.btn-sm {
    padding: 0.55rem 1.2rem;
    font-size: 0.85rem;
    min-height: 38px;
}

.badge-accent {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(242, 193, 46, 0.12);
    border: 1px solid var(--border-accent);
    color: #a87e00;
    padding: 0.45rem 1.1rem;
    border-radius: 50px;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    margin-bottom: 1.5rem;
    position: relative;
    overflow: hidden;
}

@media (max-width: 991px) {
    .hero-content .badge-accent {
        margin-left: auto;
        margin-right: auto;
    }
}

/* Shine effect on Badge */
.badge-accent::after {
    content: '';
    position: absolute;
    top: 0;
    left: -50%;
    width: 30%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transform: skewX(-25deg);
    animation: shine 4s infinite;
}

@keyframes shine {
    0% { left: -50%; }
    15% { left: 125%; }
    100% { left: 125%; }
}

.pulse-dot {
    width: 8px;
    height: 8px;
    background-color: #16a34a;
    border-radius: 50%;
    box-shadow: 0 0 0 0 rgba(22, 163, 74, 0.7);
    animation: pulse 1.6s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(22, 163, 74, 0.7);
    }
    70% {
        transform: scale(1);
        box-shadow: 0 0 0 6px rgba(22, 163, 74, 0);
    }
    100% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(22, 163, 74, 0);
    }
}

.btn-pulse {
    animation: buttonPulse 3s infinite;
}

@keyframes buttonPulse {
    0% {
        box-shadow: 0 0 0 0 rgba(242, 193, 46, 0.5);
    }
    70% {
        box-shadow: 0 0 0 8px rgba(242, 193, 46, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(242, 193, 46, 0);
    }
}

/* ==========================================================================
   Header & Navigation
   ========================================================================== */
.main-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: calc(0.85rem + env(safe-area-inset-top, 0px)) 0 0.85rem;
    transition: var(--transition-smooth);
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    animation: headerEnter 0.65s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.main-header.scrolled {
    padding-top: calc(0.55rem + env(safe-area-inset-top, 0px));
    padding-bottom: 0.55rem;
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 4px 25px rgba(11, 43, 97, 0.04);
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo-area {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.logo-img {
    height: 48px;
    width: auto;
    filter: drop-shadow(0 2px 5px rgba(11, 43, 97, 0.1));
    transition: var(--transition-smooth);
}

.logo-area:hover .logo-img {
    transform: rotate(4deg) scale(1.04);
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.brand-name {
    font-family: var(--font-title);
    font-size: 1.15rem;
    font-weight: 800;
    letter-spacing: -0.2px;
    color: var(--police-blue);
    line-height: 1.1;
}

.brand-sub {
    font-size: 0.58rem;
    font-weight: 700;
    letter-spacing: 1px;
    color: var(--text-muted);
    margin-top: 1px;
}

@media (min-width: 400px) {
    .logo-img {
        height: 52px;
    }
    .brand-name {
        font-size: 1.25rem;
    }
    .brand-sub {
        font-size: 0.62rem;
        letter-spacing: 1.5px;
    }
}

.nav-menu {
    display: none;
    align-items: center;
    gap: 2rem;
}

.nav-link {
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 0.3px;
    color: var(--text-muted);
    position: relative;
    padding: 0.5rem 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2.5px;
    background-color: var(--police-blue);
    transition: width 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-link:hover, .nav-link.active {
    color: var(--police-blue);
}

.nav-link:hover::after, .nav-link.active::after {
    width: 100%;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 0.55rem;
}

@media (max-width: 479px) {
    .header-actions .btn-accent span {
        display: none;
    }

    .header-actions .btn-accent {
        padding: 0.7rem;
        min-width: 44px;
        min-height: 44px;
    }
}

@media (min-width: 480px) {
    .header-actions {
        gap: 0.8rem;
    }
}

.mobile-menu-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 4px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    cursor: pointer;
    font-size: 1.5rem;
    color: var(--police-blue);
}

@media (min-width: 992px) {
    .nav-menu {
        display: flex;
    }
    .mobile-menu-toggle {
        display: none;
    }
}

/* Mobile Menu Slide In */
@media (max-width: 991px) {
    .nav-menu.mobile-active {
        display: flex;
        flex-direction: column;
        position: fixed;
        top: var(--header-offset);
        left: 0;
        width: 100%;
        background: #ffffff;
        padding: 2rem 1.5rem;
        border-bottom: 2.5px solid var(--police-blue);
        box-shadow: 0 15px 30px rgba(11, 43, 97, 0.08);
        gap: 1.25rem;
        z-index: 999;
        animation: slideDown 0.3s ease-out;
    }
    
    .nav-menu.mobile-active .nav-link {
        font-size: 1.1rem;
        width: 100%;
        text-align: center;
        color: var(--police-blue);
        padding: 0.75rem 0;
    }
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero-section {
    position: relative;
    padding-top: calc(var(--header-offset) + 2.25rem);
    padding-bottom: clamp(3rem, 8vw, 4.5rem);
    min-height: auto;
    display: flex;
    align-items: center;
    background-color: #f0f4fa;
    overflow-x: clip;
    overflow-y: visible;
    isolation: isolate;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background-image: url('/preview/virgen-del-carme/images/hero_criminologia.png');
    background-size: cover;
    background-position: center 22%;
    background-repeat: no-repeat;
    filter: blur(10px);
    transform: scale(1.04);
    z-index: 0;
    pointer-events: none;
}

@media (min-width: 992px) {
    .hero-bg {
        inset: -24px;
        transform: scale(1.06);
    }
}

.hero-bg-overlay {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(
            105deg,
            rgba(255, 255, 255, 0.88) 0%,
            rgba(255, 255, 255, 0.82) 42%,
            rgba(248, 250, 252, 0.78) 100%
        );
    z-index: 0;
    pointer-events: none;
}

.hero-section .grid-overlay {
    z-index: 1;
    background-image: radial-gradient(rgba(11, 43, 97, 0.025) 1.5px, transparent 0);
}

@media (min-width: 768px) {
    .hero-section {
        padding-top: calc(var(--header-offset) + 3rem);
        padding-bottom: clamp(4rem, 7vw, 5.5rem);
    }

    .hero-bg {
        filter: blur(12px);
    }

    .hero-bg-overlay {
        background:
            linear-gradient(
                105deg,
                rgba(255, 255, 255, 0.84) 0%,
                rgba(255, 255, 255, 0.76) 45%,
                rgba(248, 250, 252, 0.72) 100%
            );
    }
}

@media (min-width: 992px) {
    .hero-section {
        padding-top: calc(var(--header-offset) + 3.5rem);
        padding-bottom: 5.5rem;
        min-height: clamp(720px, 88vh, 960px);
    }

    .hero-bg {
        filter: blur(14px);
        background-position: center 18%;
    }
}

.hero-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: clamp(2rem, 5vw, 3.5rem);
    align-items: center;
    position: relative;
    z-index: 2;
    width: 100%;
}

@media (min-width: 992px) {
    .hero-container {
        grid-template-columns: 1.15fr 0.85fr;
        gap: clamp(2.5rem, 4vw, 4rem);
        align-items: stretch;
    }
}

.hero-content {
    max-width: 680px;
    margin: 0 auto;
    text-align: center;
    width: 100%;
    min-width: 0;
}

@media (min-width: 992px) {
    .hero-content {
        margin: 0;
        text-align: left;
    }
}

.hero-title {
    font-family: var(--font-title);
    font-size: 2.15rem;
    font-weight: 900;
    line-height: 1.2;
    letter-spacing: -0.5px;
    margin-bottom: 1.2rem;
    color: var(--police-blue);
    text-wrap: balance;
}

@media (min-width: 576px) {
    .hero-title {
        font-size: 3rem;
    }
}

@media (min-width: 992px) {
    .hero-title {
        font-size: 4.15rem;
        line-height: 1.1;
        margin-bottom: 1.5rem;
    }
}

.hero-description {
    font-size: 1.05rem;
    color: #334155;
    margin-bottom: 2rem;
    font-weight: 500;
    line-height: 1.65;
    text-wrap: pretty;
}

@media (min-width: 992px) {
    .hero-description {
        font-size: 1.2rem;
        margin-bottom: 2.75rem;
        max-width: 36rem;
    }
}

.hero-buttons {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    margin-bottom: 2rem;
    align-items: stretch;
    width: 100%;
}

.hero-buttons .btn {
    width: 100%;
    min-width: 0;
    max-width: 100%;
}

@media (min-width: 480px) {
    .hero-buttons {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
    }

    .hero-buttons .btn {
        flex: 1 1 calc(50% - 0.5rem);
        width: auto;
    }
}

@media (min-width: 992px) {
    .hero-buttons {
        justify-content: flex-start;
        gap: 1rem;
        margin-bottom: 2.75rem;
    }

    .hero-buttons .btn {
        flex: 0 1 auto;
        min-width: 0;
    }
}

.hero-features {
    display: flex;
    gap: clamp(0.85rem, 2.5vw, 1.5rem);
    flex-wrap: wrap;
    justify-content: center;
}

@media (min-width: 992px) {
    .hero-features {
        justify-content: flex-start;
    }
}

.feat-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--police-blue);
}

.feat-item i {
    width: 18px;
    height: 18px;
}

.text-accent {
    color: #c2930c;
}

/* Glassmorphic Hero Card (Light version) */
.hero-card {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 15px 35px rgba(11, 43, 97, 0.08);
    border: 1px solid rgba(11, 43, 97, 0.12);
    width: 100%;
    max-width: 440px;
    margin: 0 auto;
}

@media (min-width: 992px) {
    .hero-card {
        max-width: none;
        margin: 0;
        align-self: center;
    }
}

.card-glow {
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(242, 193, 46, 0.1) 0%, transparent 60%);
    pointer-events: none;
    z-index: 1;
}

.card-inner {
    position: relative;
    z-index: 2;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    padding: 1.75rem;
    color: var(--text-main);
}

@media (min-width: 576px) {
    .card-inner {
        padding: 2.5rem;
    }
}

.card-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.2rem;
}

.icon-box {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    background: rgba(11, 43, 97, 0.08);
    border: 1px solid rgba(11, 43, 97, 0.15);
    color: var(--police-blue);
    border-radius: 6px;
    flex-shrink: 0;
}

.card-header h3 {
    font-family: var(--font-title);
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--police-blue);
}

.hero-card p {
    font-size: 0.92rem;
    color: var(--text-muted);
}

.benefit-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    margin-bottom: 2rem;
}

.benefit-list li {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--text-main);
}

.benefit-list li i {
    width: 16px;
    height: 16px;
    margin-top: 3px;
    color: #16a34a;
    flex-shrink: 0;
}

.wave-divider {
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    overflow: hidden;
    line-height: 0;
    transform: rotate(180deg);
}

.wave-divider svg {
    position: relative;
    display: block;
    width: 100%;
    height: 35px;
}

@media (min-width: 768px) {
    .wave-divider svg {
        height: 60px;
    }
}

.wave-divider .shape-fill {
    fill: var(--bg-primary);
}

/* ==========================================================================
   About Section & Images Grid
   ========================================================================== */
.about-section {
    padding: clamp(2rem, 4vw, 4rem) 0;
    background-color: var(--bg-primary);
    position: relative;
}

.about-section .grid-2col {
    align-items: stretch;
}

@media (min-width: 992px) {
    .about-section .grid-2col {
        grid-template-columns: 1.08fr 0.92fr;
        gap: clamp(1.25rem, 2.5vw, 2rem);
    }
}

.about-images-grid {
    position: relative;
    display: flex;
    align-items: stretch;
    justify-content: center;
    width: 100%;
    max-width: none;
    margin: 0;
    min-height: 0;
}

.main-classroom-img-wrapper {
    position: relative;
    width: 100%;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 18px 40px rgba(11, 43, 97, 0.12);
    border: 4px solid #ffffff;
    flex: 1;
    min-height: 260px;
}

.classroom-img {
    width: 100%;
    height: 100%;
    min-height: 260px;
    object-fit: cover;
    object-position: center;
    border-radius: 8px;
    transition: var(--transition-smooth);
}

@media (min-width: 480px) {
    .main-classroom-img-wrapper,
    .classroom-img {
        min-height: 300px;
    }
}

@media (min-width: 768px) {
    .main-classroom-img-wrapper,
    .classroom-img {
        min-height: 360px;
    }
}

@media (min-width: 992px) {
    .main-classroom-img-wrapper,
    .classroom-img {
        min-height: 100%;
        height: 100%;
    }

    .about-images-grid {
        min-height: 420px;
    }
}

.main-classroom-img-wrapper:hover .classroom-img {
    transform: scale(1.05);
}

.image-glow-circle {
    position: absolute;
    top: -10%;
    left: -10%;
    width: 120%;
    height: 120%;
    background: radial-gradient(circle, rgba(242, 193, 46, 0.12) 0%, transparent 70%);
    pointer-events: none;
    z-index: 1;
}

.virgen-medallion-wrapper {
    position: absolute;
    bottom: -12px;
    right: 12px;
    width: 88px;
    height: 88px;
    border-radius: 50%;
    border: 4px solid #ffffff;
    box-shadow: 0 8px 20px rgba(11, 43, 97, 0.12);
    overflow: hidden;
    z-index: 3;
    background-color: var(--police-blue);
}

@media (min-width: 480px) {
    .virgen-medallion-wrapper {
        width: 110px;
        height: 110px;
        bottom: -14px;
        right: 16px;
        border: 5px solid #ffffff;
    }
}

@media (min-width: 992px) {
    .virgen-medallion-wrapper {
        width: 120px;
        height: 120px;
        bottom: -16px;
        right: 20px;
    }
}

.virgen-medallion {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.about-text-content {
    max-width: none;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.section-title {
    font-family: var(--font-title);
    font-size: 1.85rem;
    font-weight: 800;
    margin-bottom: 0.85rem;
    line-height: 1.25;
    color: var(--police-blue);
}

@media (min-width: 768px) {
    .section-title {
        font-size: 2.2rem;
    }
}

.section-tag {
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 2px;
    color: #b38600;
    text-transform: uppercase;
    margin-bottom: 0.4rem;
    display: inline-block;
}

.section-desc {
    color: var(--text-muted);
    font-size: 0.95rem;
    margin-bottom: 0.85rem;
    line-height: 1.6;
}

.section-desc:last-of-type {
    margin-bottom: 0;
}

.features-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.65rem;
    margin-top: 1rem;
}

@media (min-width: 576px) {
    .features-grid {
        grid-template-columns: 1fr 1fr;
        gap: 0.75rem;
        margin-top: 1.15rem;
    }
}

.feat-box {
    display: flex;
    align-items: flex-start;
    gap: 0.65rem;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    padding: 0.7rem 0.8rem;
    border-radius: 8px;
    transition: var(--transition-quick);
}

.feat-box:hover {
    border-color: var(--border-accent);
    transform: translateY(-2px);
    box-shadow: var(--shadow-main);
}

.feat-icon {
    width: 34px;
    height: 34px;
    background: rgba(11, 43, 97, 0.06);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--police-blue);
    flex-shrink: 0;
}

.feat-icon i {
    width: 17px;
    height: 17px;
}

.feat-box-body {
    min-width: 0;
}

.feat-box h4 {
    font-size: 0.84rem;
    font-weight: 800;
    color: var(--police-blue);
    margin-bottom: 0.2rem;
    line-height: 1.25;
}

.feat-box p {
    font-size: 0.76rem;
    color: var(--text-muted);
    line-height: 1.45;
    margin: 0;
}

/* ==========================================================================
   Stats Counter Section (Kept Dark Blue for structural contrast)
   ========================================================================== */
.stats-section {
    background: linear-gradient(135deg, var(--police-blue) 0%, #051430 100%);
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    padding: clamp(2rem, 4vw, 3.25rem) 0;
    color: #ffffff;
}

.stats-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.75rem 1.25rem;
    align-items: start;
}

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

.stat-card {
    text-align: center;
    padding: 0 0.35rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    min-height: 5.5rem;
}

.stat-number {
    font-family: var(--font-title);
    font-size: 2.15rem;
    font-weight: 900;
    color: var(--accent);
    margin-bottom: 0.3rem;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

@media (min-width: 768px) {
    .stat-number {
        font-size: 2.6rem;
    }
}

.stat-label {
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.75);
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 0.8px;
    line-height: 1.35;
    max-width: 9.5rem;
}

@media (min-width: 768px) {
    .stat-label {
        font-size: 0.78rem;
        letter-spacing: 1px;
        max-width: none;
    }
}

/* ==========================================================================
   Career Opportunities Section
   ========================================================================== */
.career-section {
    padding: var(--section-padding-y) 0;
    background-color: var(--bg-secondary);
}

@media (min-width: 992px) {
    .career-section {
        padding: var(--section-padding-y) 0;
    }
}

.career-text-content {
    max-width: 585px;
}

.career-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    margin-top: 1.5rem;
}

.career-list li {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.career-icon-box {
    width: 40px;
    height: 40px;
    background-color: var(--police-blue);
    border-radius: 50%;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 4px 8px rgba(11, 43, 97, 0.15);
}

.career-icon-box i {
    width: 16px;
    height: 16px;
}

.career-text {
    font-size: 0.9rem;
    line-height: 1.55;
    color: var(--text-main);
}

.career-text strong {
    color: var(--police-blue);
    display: block;
    font-size: 1rem;
    margin-bottom: 0.15rem;
    font-weight: 800;
}

.career-image-wrapper {
    position: relative;
    display: flex;
    justify-content: center;
    margin-top: 2rem;
}

@media (min-width: 992px) {
    .career-image-wrapper {
        margin-top: 0;
    }
}

.career-img {
    width: 100%;
    max-width: 380px;
    height: 300px;
    object-fit: cover;
    border-radius: 12px;
    box-shadow: 0 15px 30px rgba(11, 43, 97, 0.1);
    border: 4px solid #ffffff;
    z-index: 2;
    transition: var(--transition-smooth);
}

@media (min-width: 480px) {
    .career-img {
        height: 380px;
    }
}

@media (min-width: 992px) {
    .career-img {
        height: 460px;
        border: 5px solid #ffffff;
        box-shadow: 0 20px 40px rgba(11, 43, 97, 0.15);
    }
}

.career-image-wrapper:hover .career-img {
    transform: scale(1.02);
}

.career-image-wrapper .image-glow {
    position: absolute;
    bottom: -8%;
    right: 5%;
    width: 250px;
    height: 250px;
    background: radial-gradient(circle, rgba(242, 193, 46, 0.12) 0%, transparent 70%);
    pointer-events: none;
    z-index: 1;
}

/* ==========================================================================
   Courses Section (Grid & Cards)
   ========================================================================== */
.courses-section {
    padding: var(--section-padding-y) 0;
    background-color: var(--bg-primary);
}

@media (min-width: 992px) {
    .courses-section {
        padding: var(--section-padding-y) 0;
    }
}

.section-header {
    max-width: 720px;
    margin: 0 auto clamp(1.25rem, 3vw, 2.5rem) auto;
    padding: 0 0.25rem;
}

.section-subtitle {
    font-size: 0.95rem;
    color: var(--text-muted);
    margin-top: 0.6rem;
    font-weight: 500;
}

@media (min-width: 768px) {
    .section-subtitle {
        font-size: 1.05rem;
    }
}

.filter-wrapper {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 0.55rem;
    margin-top: clamp(1.5rem, 4vw, 2.5rem);
    max-width: 760px;
    margin-left: auto;
    margin-right: auto;
}

@media (min-width: 768px) {
    .filter-wrapper {
        gap: 0.75rem;
    }
}

.filter-btn {
    padding: 0.55rem 1rem;
    font-size: 0.78rem;
    font-weight: 800;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 50px;
    cursor: pointer;
    color: var(--text-muted);
    transition: transform 0.25s ease, background 0.25s ease, color 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
    min-height: 38px;
    text-align: center;
    line-height: 1.2;
}

.filter-btn:active {
    transform: scale(0.96);
}

@media (min-width: 576px) {
    .filter-btn {
        padding: 0.55rem 1.1rem;
        font-size: 0.8rem;
    }
}

.filter-btn:hover {
    border-color: var(--police-blue);
    color: var(--police-blue);
}

.filter-btn.active {
    background: var(--police-blue);
    color: #ffffff;
    border-color: var(--police-blue);
    box-shadow: 0 4px 12px rgba(11, 43, 97, 0.15);
}

.courses-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: clamp(1.25rem, 3vw, 2rem);
    align-items: stretch;
}

@media (min-width: 640px) {
    .courses-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: clamp(1.5rem, 2.5vw, 2rem);
    }
}

@media (min-width: 1400px) {
    .courses-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 1.5rem;
    }
}

.course-card {
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--shadow-card);
    display: flex;
    flex-direction: column;
    height: 100%;
    transition:
        transform 0.45s cubic-bezier(0.16, 1, 0.3, 1),
        box-shadow 0.45s ease,
        border-color 0.3s ease,
        opacity 0.35s ease;
}

.course-image-area {
    height: 190px;
    position: relative;
    overflow: hidden;
    background: var(--bg-tertiary);
    flex-shrink: 0;
}

@media (min-width: 480px) {
    .course-image-area {
        height: 200px;
    }
}

.course-image-area--flyer {
    height: 210px;
    background: linear-gradient(180deg, #081a36 0%, #102a4f 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

@media (min-width: 480px) {
    .course-image-area--flyer {
        height: 220px;
    }
}

.course-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.course-image-area--flyer .course-img {
    object-fit: contain;
    object-position: center;
    padding: 0.65rem;
    transform: none;
}

.course-card:hover .course-img {
    transform: scale(1.06);
}

.course-card:hover .course-image-area--flyer .course-img {
    transform: scale(1.02);
}

.course-card:hover {
    transform: translateY(-5px);
    border-color: var(--border-accent);
    box-shadow: 0 15px 30px rgba(11, 43, 97, 0.06);
}

.course-duration-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background-color: rgba(255, 255, 255, 0.94);
    border: 1px solid rgba(11, 43, 97, 0.15);
    backdrop-filter: blur(4px);
    color: var(--police-blue);
    padding: 0.3rem 0.7rem;
    border-radius: 4px;
    font-size: 0.7rem;
    font-weight: 800;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.course-body {
    padding: 1.35rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
    gap: 0;
}

@media (min-width: 576px) {
    .course-body {
        padding: 1.5rem;
    }
}

@media (min-width: 1200px) {
    .course-body {
        padding: 1.35rem;
    }
}

.course-tag {
    font-size: 0.68rem;
    font-weight: 800;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    color: #b38600;
    margin-bottom: 0.35rem;
}

.course-title {
    font-family: var(--font-title);
    font-size: 1rem;
    font-weight: 800;
    color: var(--police-blue);
    margin-bottom: 0.65rem;
    line-height: 1.35;
    min-height: 2.7em;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

@media (min-width: 640px) {
    .course-title {
        font-size: 1.05rem;
    }
}

.course-description {
    font-size: 0.82rem;
    color: var(--text-muted);
    margin-bottom: 0;
    line-height: 1.55;
    flex-grow: 1;
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.course-price-row {
    min-height: 2rem;
    display: flex;
    align-items: center;
    margin-top: 0.85rem;
    flex-shrink: 0;
}

.course-price-row:empty,
.course-price-row[aria-hidden="true"]:empty {
    visibility: hidden;
}

.course-inscription-price {
    display: inline-flex;
    align-items: center;
    background-color: var(--accent);
    color: #1a1a1a;
    font-size: 0.76rem;
    font-weight: 800;
    letter-spacing: 0.2px;
    padding: 0.35rem 0.7rem;
    border-radius: 4px;
    line-height: 1.2;
}

.course-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.75rem;
    width: 100%;
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: auto;
    margin-bottom: 1rem;
    padding-top: 0.85rem;
    border-top: 1px solid var(--border-color);
    flex-shrink: 0;
}

.course-actions {
    margin-top: 0;
    flex-shrink: 0;
}

.course-actions .btn {
    min-height: 44px;
    font-size: 0.82rem;
    padding-left: 1rem;
    padding-right: 1rem;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    white-space: nowrap;
}

.meta-item i {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
}

/* Stylized placeholder gradients */
.card-placeholder-bg {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.card-placeholder-bg::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background-image: radial-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 0);
    background-size: 16px 16px;
    top: 0;
    left: 0;
}

.policing-gradient {
    background: linear-gradient(135deg, #0f2b5c 0%, #2563eb 100%);
}
.crime-gradient {
    background: linear-gradient(135deg, #311042 0%, #6d28d9 100%);
}
.law-gradient {
    background: linear-gradient(135deg, #451a03 0%, #9a3412 100%);
}
.victim-gradient {
    background: linear-gradient(135deg, #064e3b 0%, #059669 100%);
}

.placeholder-icon {
    width: 44px;
    height: 44px;
    color: rgba(255, 255, 255, 0.65);
    position: relative;
    z-index: 2;
}

/* ==========================================================================
   Acreditaciones y Avales — Compact Strip
   ========================================================================== */
.accreditations-section {
    position: relative;
    padding: clamp(2rem, 4vw, 3rem) 0;
    background: linear-gradient(180deg, #f1f5fb 0%, #f8fafc 100%);
}

.acc-header-compact {
    margin-bottom: clamp(1.25rem, 3vw, 1.75rem);
}

.acc-header-compact .section-subtitle {
    max-width: 36rem;
    margin-inline: auto;
}

.acc-strip {
    display: grid;
    gap: 0.75rem;
}

@media (min-width: 768px) {
    .acc-strip {
        grid-template-columns: repeat(3, 1fr);
        gap: 0.85rem;
        align-items: stretch;
    }
}

.acc-tile {
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
    padding: 0.95rem 1rem;
    background: #ffffff;
    border: 1px solid rgba(11, 43, 97, 0.08);
    border-radius: 10px;
    box-shadow: 0 4px 16px rgba(11, 43, 97, 0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.25s ease;
}

@media (min-width: 576px) {
    .acc-tile {
        padding: 1rem 1.1rem;
    }
}

.acc-tile:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 24px rgba(11, 43, 97, 0.08);
    border-color: rgba(242, 193, 46, 0.35);
}

.acc-tile-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.acc-tile-icon i {
    width: 20px;
    height: 20px;
}

.acc-tile-icon--blue {
    background: linear-gradient(135deg, var(--police-blue) 0%, #1a4088 100%);
    color: #ffffff;
}

.acc-tile-icon--gold {
    background: linear-gradient(135deg, var(--accent) 0%, #e8a800 100%);
    color: var(--police-blue);
}

.acc-tile-body {
    min-width: 0;
    flex: 1;
}

.acc-tile-label {
    display: inline-block;
    font-size: 0.62rem;
    font-weight: 800;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: var(--police-blue);
    background: rgba(11, 43, 97, 0.07);
    border: 1px solid rgba(11, 43, 97, 0.1);
    border-radius: 50px;
    padding: 0.15rem 0.55rem;
    margin-bottom: 0.35rem;
}

.acc-tile-label--gold {
    color: #8a6500;
    background: rgba(242, 193, 46, 0.14);
    border-color: rgba(242, 193, 46, 0.3);
}

.acc-tile-title {
    font-family: var(--font-title);
    font-size: 0.88rem;
    font-weight: 800;
    color: var(--police-blue);
    line-height: 1.3;
    margin-bottom: 0.25rem;
}

@media (min-width: 992px) {
    .acc-tile-title {
        font-size: 0.92rem;
    }
}

.acc-tile-text {
    font-size: 0.78rem;
    color: var(--text-muted);
    line-height: 1.45;
    margin: 0;
}

/* Certificado — tarjeta azul compacta */
.acc-tile--cert {
    background: linear-gradient(135deg, #0b2b61 0%, #061a3d 100%);
    border-color: rgba(242, 193, 46, 0.22);
}

.acc-tile--cert:hover {
    border-color: rgba(242, 193, 46, 0.45);
}

.acc-tile-icon--cert {
    background: rgba(242, 193, 46, 0.15);
    border: 1px solid rgba(242, 193, 46, 0.4);
    color: var(--accent);
}

.acc-tile-label--cert {
    color: var(--police-blue);
    background: linear-gradient(135deg, var(--accent) 0%, #f5d060 100%);
    border-color: transparent;
}

.acc-tile--cert .acc-tile-title {
    color: #ffffff;
}

.acc-tile-tags {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    margin: 0;
    padding: 0;
}

.acc-tile-tags li {
    font-size: 0.68rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.88);
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 50px;
    padding: 0.2rem 0.55rem;
    line-height: 1.3;
}

.gap-lg {
    gap: clamp(1.5rem, 3vw, 2.5rem);
}

@media (min-width: 992px) {
    .gap-lg {
        gap: clamp(2rem, 3.5vw, 3rem);
    }
}

/* ==========================================================================
   Enrollment / Form Section
   ========================================================================== */
.enrollment-section {
    padding: var(--section-padding-y) 0;
    background-image: linear-gradient(135deg, var(--police-blue) 0%, #051430 100%);
    border-top: 1px solid var(--border-color);
    color: #ffffff;
}

@media (min-width: 992px) {
    .enrollment-section {
        padding: var(--section-padding-y) 0;
    }

    .enrollment-section .grid-2col {
        align-items: center;
        gap: clamp(2.5rem, 5vw, 4rem);
    }
}

.enrollment-section .badge-accent {
    background: rgba(242, 193, 46, 0.18);
    border-color: rgba(242, 193, 46, 0.55);
    color: #ffe9a8;
}

.enrollment-info {
    max-width: 520px;
    margin: 0 auto;
    text-align: center;
}

@media (min-width: 992px) {
    .enrollment-info {
        margin: 0;
        text-align: left;
    }
}

.enrollment-info h2 {
    font-family: var(--font-title);
    font-size: 1.85rem;
    font-weight: 800;
    margin-top: 0.8rem;
    margin-bottom: 1.2rem;
    color: #ffffff;
    line-height: 1.25;
}

.enrollment-lead {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.98rem;
    line-height: 1.65;
    font-weight: 500;
}

@media (min-width: 768px) {
    .enrollment-info h2 {
        font-size: 2.2rem;
    }

    .enrollment-lead {
        font-size: 1.05rem;
    }
}

.steps-flow {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    margin-top: 2rem;
    align-items: stretch;
}

@media (min-width: 992px) {
    .steps-flow {
        margin-top: 2.5rem;
        gap: 1.5rem;
        align-items: flex-start;
    }
}

.step-item {
    display: flex;
    gap: 1rem;
    text-align: left;
    align-items: flex-start;
}

.step-num {
    width: 32px;
    height: 32px;
    background: var(--accent);
    color: var(--police-blue);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.step-desc h5 {
    font-size: 0.95rem;
    font-weight: 800;
    margin-bottom: 0.2rem;
    color: #ffffff;
}

.step-desc p {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.82);
    line-height: 1.5;
}

/* Form Card */
.form-card {
    background: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    padding: 1.5rem;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.2);
    color: var(--text-main);
    margin-top: 2rem;
    width: 100%;
}

@media (min-width: 576px) {
    .form-card {
        padding: 2rem 2.25rem;
        margin-top: 0;
    }
}

.form-title {
    font-family: var(--font-title);
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--police-blue);
    margin-bottom: 0.3rem;
}

.form-subtitle {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.interactive-form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    margin-top: 1rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.form-group label {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--police-blue);
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.form-group label i {
    width: 14px;
    height: 14px;
}

.form-group input, .form-group select, .form-group textarea {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    padding: 0.75rem 0.9rem;
    border-radius: 4px;
    color: var(--text-main);
    font-size: 0.9rem;
    width: 100%;
    transition: var(--transition-quick);
    min-height: 46px;
    resize: vertical;
}

.form-group textarea {
    min-height: 96px;
    line-height: 1.5;
}

.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
    border-color: var(--police-blue);
    background: #ffffff;
    box-shadow: 0 0 8px rgba(11, 43, 97, 0.08);
}

.form-group select option {
    background: #ffffff;
    color: var(--text-main);
}

.form-info-box {
    display: flex;
    gap: 0.6rem;
    background: rgba(242, 193, 46, 0.08);
    border: 1px solid rgba(242, 193, 46, 0.2);
    padding: 0.85rem;
    border-radius: 4px;
}

.form-info-box i {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    margin-top: 2px;
    color: #b38600;
}

.form-info-box p {
    font-size: 0.78rem;
    color: #785d0b;
    line-height: 1.5;
}

/* ==========================================================================
   Contact Section
   ========================================================================== */
.contact-section {
    padding: clamp(2rem, 4vw, 3rem) 0;
    background-color: var(--bg-primary);
}

.contact-header-compact {
    margin-bottom: clamp(1rem, 2.5vw, 1.5rem);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.75rem;
    margin-top: 0;
    align-items: start;
}

@media (min-width: 768px) {
    .contact-grid {
        grid-template-columns: 1.15fr 1fr 1fr;
        gap: 0.85rem;
    }
}

.contact-info-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 1rem 1rem;
    box-shadow: var(--shadow-card);
    transition: var(--transition-quick);
}

.contact-info-card:hover {
    border-color: var(--police-blue);
    transform: translateY(-3px);
    box-shadow: var(--shadow-main);
}

.icon-box-round {
    width: 50px;
    height: 50px;
    background: rgba(11, 43, 97, 0.05);
    border: 1px solid rgba(11, 43, 97, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--police-blue);
    flex-shrink: 0;
}

.icon-box-round--sm {
    width: 40px;
    height: 40px;
}

.icon-box-round--sm i {
    width: 18px;
    height: 18px;
}

.contact-info-card h3 {
    font-family: var(--font-title);
    font-size: 0.95rem;
    font-weight: 800;
    color: var(--police-blue);
    margin-bottom: 0.15rem;
    line-height: 1.25;
}

.contact-info-card p {
    font-size: 0.78rem;
    color: var(--text-muted);
    margin: 0;
    line-height: 1.45;
}

/* WhatsApp card */
.contact-info-card--whatsapp {
    text-align: left;
}

.contact-card-head {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.contact-card-head p {
    font-size: 0.76rem;
}

.contact-info-card--whatsapp {
    border-color: rgba(11, 43, 97, 0.14);
}

.contact-wa-form {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    margin-bottom: 0.5rem;
}

.contact-wa-form .form-group {
    margin-bottom: 0;
}

.contact-wa-form .form-group label {
    font-size: 0.72rem;
    margin-bottom: 0.25rem;
}

.contact-wa-form .form-group input,
.contact-wa-form .form-group textarea {
    padding: 0.55rem 0.7rem;
    font-size: 0.85rem;
}

.contact-wa-form .form-group textarea {
    min-height: 0;
    resize: vertical;
}

.btn-sm-contact {
    padding: 0.65rem 1rem;
    min-height: 42px;
    font-size: 0.85rem;
}

.contact-phone-link {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--police-blue);
    text-align: center;
    display: block;
    margin-top: 0.15rem;
}

.contact-phone-link:hover {
    color: var(--accent-hover);
}

/* Mail / sede — fila compacta */
.contact-info-card--compact {
    padding: 0.85rem 1rem;
}

.contact-compact-row {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    text-align: left;
}

.contact-compact-body {
    min-width: 0;
    flex: 1;
}

.contact-compact-body p {
    margin: 0.2rem 0 0.45rem;
}

.contact-link {
    font-size: 0.88rem;
    font-weight: 800;
    color: var(--police-blue);
    margin: 0;
    display: block;
    word-break: break-word;
    line-height: 1.35;
}

.contact-wa-form .form-group label i {
    display: none;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.main-footer {
    background-color: #030a17;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    padding-top: clamp(2.5rem, 5vw, 3.5rem);
    padding-bottom: calc(5rem + env(safe-area-inset-bottom, 0px));
    color: #ffffff;
}

@media (min-width: 768px) {
    .main-footer {
        padding-bottom: 0;
    }
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2.5rem 1.5rem;
    padding-bottom: 3rem;
}

@media (min-width: 768px) {
    .footer-grid {
        grid-template-columns: 1.2fr 0.8fr 1fr;
        padding-bottom: 4rem;
    }
}

.footer-brand {
    max-width: 320px;
}

.footer-logo {
    height: 50px;
    margin-bottom: 0.8rem;
    filter: drop-shadow(0 2px 8px rgba(255, 255, 255, 0.1));
}

.footer-brand h4 {
    font-family: var(--font-title);
    font-size: 1.15rem;
    color: var(--accent);
    margin-bottom: 0.5rem;
    font-weight: 800;
}

.footer-brand p {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.6);
}

.footer-links h4, .footer-legal h4 {
    font-family: var(--font-title);
    font-size: 0.95rem;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 1rem;
    position: relative;
    padding-bottom: 0.4rem;
}

.footer-links h4::after, .footer-legal h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 30px;
    height: 2px;
    background-color: var(--accent);
}

.footer-links ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
}

.footer-links ul a {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.6);
}

.footer-links ul a:hover {
    color: var(--accent);
    padding-left: 5px;
}

.footer-legal p {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 1.25rem;
}

.footer-logos-row {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    font-size: 0.72rem;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: 1px;
}

.footer-logos-row .divider {
    color: var(--accent);
}

.footer-bottom {
    background-color: #01040a;
    padding: 0.85rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.footer-bottom-flex {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    align-items: center;
    text-align: center;
}

@media (min-width: 768px) {
    .footer-bottom-flex {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        text-align: left;
        gap: 1rem;
    }
}

.footer-bottom-meta {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    align-items: center;
}

@media (min-width: 768px) {
    .footer-bottom-meta {
        align-items: flex-start;
    }
}

.footer-bottom p {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.5);
    margin: 0;
}

.footer-credit {
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.38);
}

.footer-credit a {
    color: rgba(255, 255, 255, 0.62);
    text-decoration: underline;
    text-underline-offset: 2px;
    transition: color 0.2s ease;
}

.footer-credit a:hover {
    color: var(--accent);
}

.footer-social {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
}

.footer-social-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 50%;
    color: rgba(255, 255, 255, 0.85);
    transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.footer-social-btn i {
    width: 17px;
    height: 17px;
}

.footer-social-svg {
    width: 18px;
    height: 18px;
}

.footer-social-btn:hover {
    color: var(--accent);
    border-color: rgba(242, 193, 46, 0.45);
    background: rgba(242, 193, 46, 0.08);
    transform: translateY(-2px);
}

.footer-social-btn--wa {
    background: #25d366;
    border-color: #25d366;
    color: #ffffff;
}

.footer-social-btn--wa:hover {
    background: #1ebe57;
    border-color: #1ebe57;
    color: #ffffff;
}

@media (max-width: 767px) {
    .footer-social-btn--wa {
        display: none;
    }

    .footer-bottom {
        padding-bottom: calc(0.85rem + env(safe-area-inset-bottom, 0px));
    }
}

/* ==========================================================================
   Floating WhatsApp Button
   ========================================================================== */
.floating-whatsapp {
    position: fixed;
    right: max(14px, env(safe-area-inset-right, 0px));
    bottom: max(18px, calc(16px + env(safe-area-inset-bottom, 0px)));
    z-index: 1500;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #ffffff;
    transform: translateZ(0);
    -webkit-transform: translateZ(0);
}

.wa-float-pulse {
    position: absolute;
    inset: 0;
    border-radius: 999px;
    background: rgba(37, 211, 102, 0.35);
    animation: waFloatRing 2.4s ease-out infinite;
    pointer-events: none;
}

.wa-float-btn {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    min-width: 56px;
    height: 56px;
    padding: 0;
    border-radius: 999px;
    background: linear-gradient(145deg, #2ee06a 0%, #25d366 45%, #1aab52 100%);
    border: 2px solid rgba(255, 255, 255, 0.92);
    box-shadow:
        0 10px 28px rgba(37, 211, 102, 0.42),
        0 2px 8px rgba(11, 43, 97, 0.12),
        inset 0 1px 0 rgba(255, 255, 255, 0.35);
    transition: transform 0.28s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.28s ease, padding 0.28s ease, gap 0.28s ease;
}

.wa-float-icon {
    width: 28px;
    height: 28px;
    flex-shrink: 0;
    filter: drop-shadow(0 1px 1px rgba(0, 0, 0, 0.12));
}

.wa-float-text {
    display: none;
    font-family: var(--font-title);
    font-size: 0.88rem;
    font-weight: 800;
    letter-spacing: 0.02em;
    white-space: nowrap;
    padding-right: 0.15rem;
}

@media (min-width: 576px) {
    .floating-whatsapp {
        right: max(20px, env(safe-area-inset-right, 0px));
        bottom: max(22px, calc(20px + env(safe-area-inset-bottom, 0px)));
    }

    .wa-float-btn {
        min-width: auto;
        height: 54px;
        padding: 0 1.15rem 0 0.95rem;
        gap: 0.55rem;
    }

    .wa-float-icon {
        width: 26px;
        height: 26px;
    }

    .wa-float-text {
        display: inline;
    }
}

.floating-whatsapp:hover .wa-float-btn,
.floating-whatsapp:focus-visible .wa-float-btn {
    transform: translateY(-3px) scale(1.03);
    box-shadow:
        0 14px 36px rgba(37, 211, 102, 0.5),
        0 4px 12px rgba(11, 43, 97, 0.14),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
    color: #ffffff;
}

.floating-whatsapp:active .wa-float-btn {
    transform: translateY(-1px) scale(0.98);
}

.floating-whatsapp:focus-visible {
    outline: none;
}

.floating-whatsapp:focus-visible .wa-float-btn {
    outline: 2px solid #ffffff;
    outline-offset: 3px;
}

@keyframes waFloatRing {
    0% {
        transform: scale(1);
        opacity: 0.55;
    }
    70% {
        transform: scale(1.45);
        opacity: 0;
    }
    100% {
        transform: scale(1.45);
        opacity: 0;
    }
}

/* ==========================================================================
   Syllabus Modal Style
   ========================================================================== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(11, 43, 97, 0.45);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease, visibility 0.4s ease;
    padding: 1rem;
}

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

.modal-card {
    background-color: #ffffff;
    width: 100%;
    max-width: 620px;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    box-shadow: var(--shadow-modal);
    transform: translateY(30px) scale(0.95);
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    max-height: 90vh;
    display: flex;
    flex-direction: column;
}

.modal-overlay.active .modal-card {
    transform: translateY(0) scale(1);
}

.modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.95);
    border: 1px solid var(--border-color);
    color: var(--police-blue);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    transition: var(--transition-quick);
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.modal-close:hover {
    background-color: var(--police-blue);
    color: #ffffff;
    transform: rotate(90deg);
}

.modal-header-accent {
    height: 6px;
    background: linear-gradient(90deg, var(--police-blue) 0%, var(--accent) 50%, var(--police-blue) 100%);
    flex-shrink: 0;
}

.modal-content-area {
    padding: 1.5rem;
    overflow-y: auto;
    flex-grow: 1;
    -webkit-overflow-scrolling: touch; /* Smooth iOS modal scroll */
}

@media (min-width: 576px) {
    .modal-content-area {
        padding: 2.5rem;
    }
}

.modal-meta-row {
    display: flex;
    gap: 0.6rem;
    margin-bottom: 1rem;
    margin-top: 0.25rem;
    flex-wrap: wrap;
    align-items: center;
}

.modal-badge-duration {
    background-color: rgba(11, 43, 97, 0.08);
    border: 1px solid rgba(11, 43, 97, 0.15);
    color: var(--police-blue);
    padding: 0.35rem 0.85rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 800;
    line-height: 1.2;
}

.modal-badge-price {
    background-color: var(--accent);
    border: 1px solid rgba(168, 126, 0, 0.35);
    color: #1a1a1a;
    padding: 0.35rem 0.85rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 800;
    display: none;
    align-items: center;
    line-height: 1.2;
}

.modal-badge-mode {
    background-color: rgba(242, 193, 46, 0.12);
    border: 1px solid var(--border-accent);
    color: #a87e00;
    padding: 0.3rem 0.8rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.modal-badge-mode i {
    width: 14px;
    height: 14px;
}

.modal-course-title {
    font-family: var(--font-title);
    font-size: 1.35rem;
    font-weight: 900;
    color: var(--police-blue);
    line-height: 1.3;
    margin-bottom: 1.5rem;
}

@media (min-width: 576px) {
    .modal-course-title {
        font-size: 1.6rem;
        margin-bottom: 1.8rem;
    }
}

.modal-tab-container {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.tab-title {
    font-family: var(--font-title);
    font-size: 0.9rem;
    font-weight: 800;
    color: var(--police-blue);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1.5px solid var(--border-color);
    padding-bottom: 0.5rem;
}

.tab-title i {
    width: 16px;
    height: 16px;
}

.syllabus-modules {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
}

.syllabus-module-item {
    background-color: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-left: 4px solid var(--police-blue);
    padding: 1rem;
    border-radius: 4px;
    transition: var(--transition-quick);
}

.syllabus-module-item:hover {
    border-color: var(--border-accent);
    transform: translateX(3px);
    background-color: #ffffff;
    box-shadow: 0 4px 12px rgba(11, 43, 97, 0.04);
}

.syllabus-module-item h5 {
    font-family: var(--font-title);
    font-size: 0.88rem;
    font-weight: 800;
    color: var(--police-blue);
    margin-bottom: 0.3rem;
}

.syllabus-module-item p {
    font-size: 0.8rem;
    color: var(--text-muted);
    line-height: 1.5;
}

.modal-actions {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    margin-top: 1rem;
    flex-shrink: 0;
}

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

@media (max-width: 768px) and (max-height: 740px) {
    :root {
        --section-gap: clamp(0.4rem, 1.4vh, 0.85rem);
    }

    .hero-title {
        font-size: 1.95rem;
    }

    .hero-description {
        font-size: 0.95rem;
        margin-bottom: 1.5rem;
    }

    .course-image-area,
    .course-image-area--flyer {
        height: 170px;
    }

    .course-title {
        min-height: auto;
        -webkit-line-clamp: 3;
    }
}

@media (max-width: 380px) {
    .filter-btn {
        flex: 1 1 calc(50% - 0.35rem);
        padding-inline: 0.65rem;
        font-size: 0.72rem;
    }

    .hero-features {
        flex-direction: column;
        align-items: center;
        gap: 0.65rem;
    }

    .course-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.45rem;
    }
}

/* ==========================================================================
   FAQ Section (regla SEO / rich snippets)
   ========================================================================== */
.faq-section {
    background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
    padding: var(--section-padding-y) 0;
}

.faq-list {
    max-width: 42rem;
    margin: clamp(1.5rem, 4vw, 2.5rem) auto 0;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.faq-item {
    background: #ffffff;
    border: 1px solid var(--border-accent);
    border-radius: var(--radius-md, 12px);
    box-shadow: 0 4px 18px rgba(11, 43, 97, 0.05);
    overflow: hidden;
}

.faq-item summary {
    padding: 1rem 1.25rem;
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--police-blue);
    cursor: pointer;
    list-style: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

.faq-item summary::-webkit-details-marker {
    display: none;
}

.faq-item summary::after {
    content: '+';
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--accent);
    flex-shrink: 0;
    transition: transform 0.2s ease;
}

.faq-item[open] summary::after {
    transform: rotate(45deg);
}

.faq-item p {
    padding: 0 1.25rem 1.15rem;
    margin: 0;
    font-size: 0.92rem;
    line-height: 1.65;
    color: var(--text-muted);
}

.faq-item p a {
    color: var(--police-blue);
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.faq-item p a:hover {
    color: var(--accent);
}

/* ==========================================================================
   Mobile overflow fixes (Regla 08 — MOB-001, MOB-003, MOB-008)
   ========================================================================== */
@media (max-width: 991px) {
    .hero-section {
        align-items: flex-start;
    }

    .hero-container,
    .hero-card {
        width: 100%;
        max-width: 100%;
        min-width: 0;
    }

    .hero-card {
        max-width: 100%;
        margin-inline: auto;
    }

    .hero-features {
        justify-content: center;
        width: 100%;
    }

    .reveal-from-left,
    .reveal-from-right {
        transform: translateY(20px);
    }

    .reveal-from-left.visible,
    .reveal-from-right.visible {
        transform: translateY(0);
    }
}

@media (max-width: 380px) {
    .hero-buttons {
        flex-direction: column;
    }

    .hero-buttons .btn {
        flex: 1 1 100%;
        width: 100%;
    }

    .hero-title {
        font-size: 1.85rem;
    }
}
