/* -------------------------------------------------------------------------- */
/*                        HERO TRANSPARENT HEADER SETUP                       */
/* -------------------------------------------------------------------------- */

:root {
    --dr-brand-gold: #C7A047;
    --dr-brand-gold-hover: #B28B3A;
    --dr-brand-black: #000000;
    --dr-brand-smoke: #777777;
}

/* Header Position & Transparency */
body.transparent-header #sp-header,
body.itemid-101 #sp-header {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    background: transparent !important;
    box-shadow: none !important;
    z-index: 9999;
}

/* Force transparency on header children */
body.transparent-header #sp-header .container,
body.transparent-header #sp-header .container-fluid,
body.transparent-header #sp-header .row,
body.transparent-header #sp-header .sp-container,
body.transparent-header #sp-header>div,
body.itemid-101 #sp-header .container,
body.itemid-101 #sp-header .container-fluid,
body.itemid-101 #sp-header .row,
body.itemid-101 #sp-header .sp-container,
body.itemid-101 #sp-header>div {
    background: transparent !important;
    box-shadow: none !important;
}

/* Sticky Header Behavior */
body.transparent-header #sp-header.header-sticky,
body.itemid-101 #sp-header.header-sticky {
    position: fixed;
    background: rgba(255, 255, 255, 0.95) !important;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.1) !important;
    transition: all 0.3s ease;
}

/* Menu Text Colors (Initial White State) */
body.transparent-header:not(.scrolled) #sp-header:not(.header-sticky) .sp-megamenu-parent>li>a,
body.transparent-header:not(.scrolled) #sp-header:not(.header-sticky) .logo a,
body.itemid-101:not(.scrolled) #sp-header:not(.header-sticky) .sp-megamenu-parent>li>a,
body.itemid-101:not(.scrolled) #sp-header:not(.header-sticky) .logo a {
    color: #ffffff !important;
}

/* -------------------------------------------------------------------------- */
/*                        LOGO STRATEGY (Dual Logo)                           */
/* -------------------------------------------------------------------------- */

/* Default / Inner Pages / Sticky: Dark Logo */
.logo-image {
    content: url('/images/logo-drevuelta2.png');
    width: auto;
}

/* Homepage Transparent Header: Light Logo */
body.itemid-101:not(.scrolled) #sp-header:not(.header-sticky) .logo-image,
body.transparent-header:not(.scrolled) #sp-header:not(.header-sticky) .logo-image {
    content: url('/images/logo-drevuelta1.png');
}

/* -------------------------------------------------------------------------- */
/*                        HERO SECTION STYLES                                 */
/* -------------------------------------------------------------------------- */

.hero-section {
    position: relative;
    width: 100%;
    height: 600px;
    /* Mobile */
    background-color: var(--dr-brand-black);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    margin-top: 0;
    overflow: hidden;
}

.hero-bg-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('https://loremflickr.com/1920/1080/university,graduation,students,group?lock=grad-group-bw-2');
    background-size: cover;
    background-position: top center;
    filter: grayscale(100%);
    z-index: 0;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.4));
    z-index: 1;
}

.hero-container {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 1320px;
    padding: 0 15px;
    margin: 0 auto;
}

.hero-content {
    max-width: 800px;
    text-align: center;
    padding-top: 100px;
}

/* Desktop Hero Adjustments */
@media (min-width: 768px) {
    .hero-section {
        height: 30vh;
        min-height: 525px;
        justify-content: flex-start;
        text-align: left;
    }

    .hero-content {
        text-align: left;
        padding-left: 2rem;
    }

    .hero-buttons {
        justify-content: flex-start;
    }
}

.hero-subtitle {
    color: var(--dr-brand-gold);
    font-weight: 700;
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 0.5rem;
    display: block;
}

.hero-title {
    font-weight: 700;
    font-size: 2.5rem;
    /* Mobile */
    line-height: 1.1;
    color: #fff;
    margin-bottom: 1.5rem;
}

@media (min-width: 768px) {
    .hero-title {
        font-size: 4.5rem;
        /* Desktop */
    }
}

.text-gradient-gold {
    background: linear-gradient(to right, var(--dr-brand-gold), #fef08a);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-description {
    font-size: 1rem;
    color: #d1d5db;
    /* Gray-300 */
    margin-bottom: 2.5rem;
    max-width: 42rem;
    line-height: 1.6;
}

@media (min-width: 768px) {
    .hero-description {
        font-size: 1.25rem;
    }
}

/* Buttons */
.hero-buttons {
    display: flex;
    gap: 1rem;
    flex-direction: column;
}

@media (min-width: 768px) {
    .hero-buttons {
        flex-direction: row;
    }
}

.btn-dr {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 32px;
    font-weight: 600;
    font-size: 1.125rem;
    border-radius: 0.375rem;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
}

.btn-dr-primary {
    background-color: var(--dr-brand-gold);
    color: #fff;
    border: 2px solid var(--dr-brand-gold);
}

.btn-dr-primary:hover {
    background-color: var(--dr-brand-gold-hover);
    border-color: var(--dr-brand-gold-hover);
    color: #fff;
    transform: translateY(-2px);
}

.btn-dr-outline {
    background-color: transparent;
    color: #fff;
    border: 2px solid #fff;
}

.btn-dr-outline:hover {
    background-color: #fff;
    color: var(--dr-brand-black);
    transform: translateY(-2px);
}

/* Dark / Solid Button Variant (for white backgrounds) */
.mod-servicios-portada .btn-dr-outline,
.btn-dr-outline-dark {
    background-color: var(--dr-brand-black) !important;
    color: #fff !important;
    border: 2px solid var(--dr-brand-black) !important;
    border-radius: 50px !important;
    /* Pill shape */
}

.mod-servicios-portada .btn-dr-outline:hover,
.btn-dr-outline-dark:hover {
    background-color: var(--dr-brand-gold) !important;
    border-color: var(--dr-brand-gold) !important;
    color: #fff !important;
}

/* -------------------------------------------------------------------------- */
/*                        MENU OVERRIDES                                      */
/* -------------------------------------------------------------------------- */

/* Active Sticky Header */
body.transparent-header #sp-header.header-sticky,
body.itemid-101 #sp-header.header-sticky {
    background: rgba(0, 0, 0, 0.95) !important;
    backdrop-filter: blur(4px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

/* Menu Items (Transparent State) */
body.transparent-header:not(.scrolled) #sp-header:not(.header-sticky) .sp-megamenu-parent>li>a,
body.itemid-101:not(.scrolled) #sp-header:not(.header-sticky) .sp-megamenu-parent>li>a {
    color: #ffffff !important;
    font-weight: 500;
}

/* Menu Hover Effect */
.sp-megamenu-parent>li>a {
    position: relative;
    transition: color 0.3s ease;
}

.sp-megamenu-parent>li>a:hover,
.sp-megamenu-parent>li.active>a {
    color: var(--dr-brand-gold) !important;
}

/* -------------------------------------------------------------------------- */
/*                        ANIMATIONS                                          */
/* -------------------------------------------------------------------------- */

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

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

.animate-fade-up {
    opacity: 0;
    animation: fadeUp 0.8s ease-out forwards;
}

.delay-100 {
    animation-delay: 0.1s;
}

.delay-200 {
    animation-delay: 0.2s;
}

.delay-300 {
    animation-delay: 0.3s;
}

/* -------------------------------------------------------------------------- */
/*                        LAYOUT & SERVICES MODULE                            */
/* -------------------------------------------------------------------------- */

/* Specific max-width for services grid sections */
@media (min-width: 992px) {

    .container:has(.mod-servicios-portada),
    .container-lg:has(.mod-servicios-portada),
    .container-md:has(.mod-servicios-portada),
    .container-sm:has(.mod-servicios-portada),
    .container:has(.mod-articles-grid),
    .container-lg:has(.mod-articles-grid),
    .container-md:has(.mod-articles-grid),
    .container-sm:has(.mod-articles-grid) {
        max-width: 1180px;
    }
}

/* Grid Layout Reset & Setup */
.mod-servicios-portada ul,
.mod-articles-grid {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
}

.mod-servicios-portada ul li,
.mod-articles-grid li {
    list-style-type: none !important;
    flex: 0 0 100%;
    /* Mobile 1 col */
}

@media (min-width: 992px) {

    .mod-servicios-portada ul li,
    .mod-articles-grid li {
        flex: 0 0 calc(33.333% - 20px);
        /* Desktop 3 cols */
    }
}

/* Service Items Styling */
.mod-servicios-portada img,
.mod-articles-grid img {
    border-radius: 8px;
    width: 100%;
    height: auto;
    display: block;
    margin-bottom: 1.5rem;
    object-fit: cover;
    aspect-ratio: 16/9;
}

.mod-servicios-portada h3,
.mod-articles-grid h3 {
    margin-bottom: 0.75rem;
    font-size: 1.5rem;
}

.mod-servicios-portada p,
.mod-articles-grid p {
    color: #6b7280;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.mod-servicios-portada a.readmore,
.mod-servicios-portada a,
.mod-articles-grid a.readmore,
.mod-articles-grid a.btn-link {
    color: #2563eb;
    /* Blue to match PWA screenshot */
    text-decoration: none;
    font-weight: 500;
}

.mod-servicios-portada a:hover,
.mod-articles-grid a:hover {
    color: var(--dr-brand-gold-hover);
    text-decoration: underline;
}

/* -------------------------------------------------------------------------- */
/*                        GRADUATION PROMO SECTION                            */
/* -------------------------------------------------------------------------- */

.grad-promo-section {
    position: relative;
    padding: 80px 0;
    /* Background image will be set via inline style in the module */
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    color: #fff;
    overflow: hidden;
}

/* Fallback background if inline style is missing */
.grad-promo-section {
    background-color: #111;
}

.grad-promo-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    /* Reduced opacity or gradient to ensure image visibility */
    background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.6));
    z-index: 1;
}

.grad-promo-container {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
    text-align: center;
}

@media (min-width: 992px) {
    .grad-promo-container {
        flex-direction: row;
        justify-content: space-between;
        text-align: left;
    }
}

.grad-promo-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .grad-promo-content {
        flex-direction: row;
        align-items: flex-start;
    }
}

.grad-promo-icon {
    width: 48px;
    height: 48px;
    color: var(--dr-brand-gold);
    flex-shrink: 0;
}

.grad-promo-icon svg {
    width: 100%;
    height: 100%;
}

.grad-promo-text h2 {
    color: #fff !important;
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    margin-top: 0;
}

.grad-promo-text p {
    color: #d1d5db;
    max-width: 600px;
    margin: 0;
    font-size: 1.1rem;
    line-height: 1.6;
}

.grad-promo-actions .btn-dr {
    min-width: 220px;
}