@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@300;400;500;600;700&family=Sora:wght@100;200;300;400;500;600;700;800&display=swap');

:root {
    --primary: #3b82f6;
    --secondary: #f59e0b;
    --accent: #ec4899;
    --dark: #0f172a;
    --light: #f8fafc;
}

* {
    font-family: 'Sora', sans-serif;
}

/* Remove default tap highlight on mobile */
*,
*::before,
*::after {
    -webkit-tap-highlight-color: transparent;
}

body {
    overflow-x: hidden;
    background: var(--light);
    margin: 0;
    padding: 0;
}

/* Custom Scrollbar */
html {
    scrollbar-color: #3b82f6 #1e293b;
    scrollbar-width: thin;
}

::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #1e293b !important;
}

::-webkit-scrollbar-thumb {
    background: #3b82f6 !important;
    border-radius: 4px;
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    backdrop-filter: none;
    background: transparent;
    border-bottom: 1px solid transparent;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 50;
}

.navbar.blurred {
    backdrop-filter: blur(20px) saturate(180%);
    background: rgba(255, 255, 255, 0.1);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.navbar.scrolled {
    backdrop-filter: blur(20px) saturate(180%);
    background: rgba(255, 255, 255, 0.95);
    border-bottom: 1px solid rgba(148, 163, 184, 0.1);
    box-shadow: 0 5px 20px -5px rgba(0, 0, 0, 0.1);
}

/* Logo Transition */
.navbar img {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.navbar:not(.scrolled) img {
    width: 100px;
    height: 100px;
}

.navbar.scrolled img {
    width: 60px;
    height: 60px;
}

/* Logo Text Transition */
.navbar div>div {
    transition: color 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.navbar:not(.scrolled) .logo-text {
    color: white;
}

.navbar.scrolled .logo-text {
    color: #1e293b;
}

/* Navbar Link Colors */
.navbar:not(.scrolled) .nav-link {
    color: white;
    background: transparent;
    border: none;
}

.navbar:not(.scrolled) .nav-link:hover {
    color: rgba(255, 255, 255, 0.9);
    background: rgba(255, 255, 255, 0.1);
}

.navbar.scrolled .nav-link {
    color: #334155;
    background: transparent;
    border: none;
}

.navbar.scrolled .nav-link:hover {
    color: #004aa5;
    background: rgba(0, 74, 165, 0.05);
}

/* Force remove any default button styling on nav buttons */
.navbar button.nav-link {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

.navbar button.nav-link:hover {
    background: rgba(255, 255, 255, 0.1) !important;
}

.navbar.scrolled button.nav-link:hover {
    background: rgba(0, 74, 165, 0.05) !important;
}

/* Mega menu button specific styling */
.mega-menu-item button {
    background: transparent !important;
    border: none !important;
    outline: none !important;
}

.mega-menu-item button:focus:not(:focus-visible) {
    background: transparent !important;
    border: none !important;
    outline: none !important;
}

/* Mobile Menu Toggle Button */
.navbar:not(.scrolled) #mobile-menu-toggle {
    color: white;
}

.navbar.scrolled #mobile-menu-toggle {
    color: #334155;
}

#mobile-menu-toggle {
    border: none !important;
    outline: none !important;
}

#mobile-menu-toggle:focus-visible {
    outline: 2px solid #3b82f6 !important;
    outline-offset: 2px;
}

/* Mega Menu Dropdown */
.mega-menu-dropdown {
    transform: translateY(10px);
}

.mega-menu-item:hover .mega-menu-dropdown {
    transform: translateY(0);
}

/* Daftar Sekarang Button - Keep white text when scrolled */
.navbar.scrolled a[href="#admisi"] {
    color: white !important;
}

/* Dropdown Menu Styling */
.navbar .dropdown-menu {
    background: white !important;
    backdrop-filter: blur(20px);
    border-color: rgba(148, 163, 184, 0.1);
}

.navbar .dropdown-menu a {
    color: #334155 !important;
}

.navbar .dropdown-menu a:hover {
    background: rgba(0, 74, 165, 0.1) !important;
    color: #004aa5 !important;
}

/* Mobile Menu Background */
.navbar #mobile-menu {
    background: #004aa5;
    margin-left: -1.5rem;
    margin-right: -1.5rem;
    padding-top: 1rem;
    padding-bottom: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.navbar #mobile-menu>div>a,
.navbar #mobile-menu .mobile-dropdown-btn {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.navbar #mobile-menu>div>a:hover,
.navbar #mobile-menu .mobile-dropdown-btn:hover {
    background: rgba(255, 255, 255, 0.1) !important;
}

.navbar #mobile-menu .mobile-dropdown-content a:hover {
    background: rgba(255, 255, 255, 0.15) !important;
}

/* Mobile Dropdown Arrow Animation */
.mobile-dropdown.active .mobile-dropdown-btn i {
    transform: rotate(180deg);
}

.mobile-dropdown-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

.mobile-dropdown.active .mobile-dropdown-content {
    max-height: 500px;
}

/* Mobile Offside Panel */
#mobile-menu-panel {
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

#mobile-menu-panel::-webkit-scrollbar {
    width: 4px;
}

#mobile-menu-panel::-webkit-scrollbar-thumb {
    background: #3b82f6;
    border-radius: 2px;
}

#mobile-menu-close {
    border: none !important;
    outline: none !important;
}

#mobile-menu-close:focus-visible {
    outline: 2px solid #3b82f6 !important;
    outline-offset: 2px;
}

/* Mobile Menu Overlay */
#mobile-menu-overlay {
    backdrop-filter: blur(4px);
}

/* Mobile Accordion */
.mobile-accordion-content {
    display: none;
    overflow: hidden;
}

.mobile-accordion.active .mobile-accordion-content {
    display: block;
}

/* Nested accordions */
.nested-accordion .mobile-accordion-content {
    padding-left: 0.5rem;
}

.mobile-accordion.active .mobile-accordion-toggle i:last-child {
    transform: rotate(180deg);
}

.mobile-accordion-toggle,
.mobile-dropdown-btn {
    border: none !important;
    outline: none !important;
}

.mobile-accordion-toggle:focus-visible,
.mobile-dropdown-btn:focus-visible {
    outline: 2px solid #3b82f6 !important;
    outline-offset: 2px;
}

.mobile-accordion-toggle i {
    transition: transform 0.3s ease;
}

/* Mega Menu Panel Styles */
.mega-menu-dropdown {
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.mega-menu-item:hover .mega-menu-dropdown {
    opacity: 1;
    visibility: visible;
}

/* Mega Menu Link Hover Effects */
.mega-menu-dropdown a {
    transition: all 0.2s ease;
}

.mega-menu-dropdown a:hover {
    transform: translateX(4px);
}

/* Hero Section */
.hero-wrapper {
    position: relative;
    min-height: 100vh;
    background: linear-gradient(135deg, #5B4FE9 0%, #3D8FE0 25%, #2EAAD4 50%, #7EC85C 75%, #C4E054 100%);
    background-size: 200% 200%;
    animation: gradientShift 15s ease infinite;
    overflow: visible;
    /* Allow content to extend beyond */
}

@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

/* Animated Grid Background */
.hero-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(37, 99, 235, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(37, 99, 235, 0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    animation: gridMove 20s linear infinite;
}

@keyframes gridMove {
    0% {
        transform: translate(0, 0);
    }

    100% {
        transform: translate(60px, 60px);
    }
}

/* Floating Orbs */
.hero-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.4;
    animation: float 8s ease-in-out infinite;
}

.orb-1 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, #3b82f6, transparent);
    top: -150px;
    right: -150px;
    animation-delay: 0s;
}

.orb-2 {
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, #f59e0b, transparent);
    bottom: -100px;
    left: -100px;
    animation-delay: 2s;
}

.orb-3 {
    width: 350px;
    height: 350px;
    background: radial-gradient(circle, #ec4899, transparent);
    top: 40%;
    left: 50%;
    animation-delay: 4s;
}

@keyframes float {

    0%,
    100% {
        transform: translate(0, 0) scale(1);
    }

    33% {
        transform: translate(30px, -30px) scale(1.1);
    }

    66% {
        transform: translate(-20px, 20px) scale(0.9);
    }
}

.hero-title {
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(1.5rem, 4vw, 3rem);
    line-height: 1.2;
    font-weight: 700;
    color: white;
}

.stat-item {
    position: relative;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1rem;
    backdrop-filter: blur(10px);
    transition: all 0.4s ease;
}

.stat-item:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(37, 99, 235, 0.3);
    transform: translateY(-5px);
}

/* Feature Cards */
.feature-card {
    position: relative;
    background: white;
    border-radius: 1.5rem;
    padding: 2.5rem;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid #e2e8f0;
}

.feature-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 1.5rem;
    padding: 2px;
    background: #004aa5;
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.5s;
}

.feature-card:hover::before {
    opacity: 1;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
}

.feature-icon {
    width: 70px;
    height: 70px;
    border-radius: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    margin-bottom: 1.5rem;
    position: relative;
    overflow: hidden;
    transition: all 0.5s;
}

.feature-card:hover .feature-icon {
    transform: scale(1.1) rotate(5deg);
}

/* Program Cards - Asymmetric Layout */
.program-card {
    position: relative;
    background: white;
    border-radius: 2rem;
    overflow: hidden;
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.1);
}

.program-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 6px;
    background: #004aa5;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.program-card:hover::after {
    transform: scaleX(1);
}

.program-card:hover {
    transform: translateY(-15px) scale(1.02);
    box-shadow: 0 30px 60px -15px rgba(0, 0, 0, 0.2);
}

.program-header {
    height: 280px;
    position: relative;
    overflow: hidden;
}

.program-bg {
    position: absolute;
    inset: 0;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.program-card:hover .program-bg {
    transform: scale(1.1);
}

.program-icon-wrapper {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 120px;
    height: 120px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.6s;
}

.program-card:hover .program-icon-wrapper {
    transform: translate(-50%, -50%) scale(1.15) rotate(5deg);
}

/* Dosen Carousel Styles - Infinite Continuous Scroll */
.dosen-carousel-container {
    width: 100%;
    overflow: hidden;
    position: relative;
}

.dosen-carousel-track {
    display: flex;
    will-change: transform;
}

/* Card widths will be set by JavaScript for exact calculation */
.dosen-card {
    flex-shrink: 0;
    box-sizing: border-box;
}

/* Dosen Navigation Buttons */
.dosen-prev,
.dosen-next {
    pointer-events: auto;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
    border: none !important;
    outline: none !important;
}

.dosen-prev:focus-visible,
.dosen-next:focus-visible {
    outline: 2px solid #3b82f6 !important;
    outline-offset: 2px;
}

.dosen-prev:active,
.dosen-next:active {
    transform: translateY(-50%) scale(0.95);
}

.dosen-dot {
    cursor: pointer;
    transition: all 0.3s ease;
    border: none !important;
    outline: none !important;
}

.dosen-dot:focus-visible {
    outline: 2px solid #3b82f6 !important;
    outline-offset: 2px;
}

.dosen-dot.active-dosen-dot {
    background: #3b82f6;
    width: 24px;
}

/* Vertical Tab Styles for Keunggulan */
.advantage-tab {
    background: white;
    border: 2px solid #e2e8f0;
    cursor: pointer;
    outline: none !important;
}

.advantage-tab:focus-visible {
    outline: 2px solid #3b82f6 !important;
    outline-offset: 2px;
}

.advantage-tab:hover {
    border-color: #cbd5e1;
    background: #f8fafc;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.advantage-tab.active-advantage-tab {
    background: #ffffff;
    border-color: #3b82f6;
    box-shadow: 0 10px 15px -3px rgba(59, 130, 246, 0.1), 0 4px 6px -2px rgba(59, 130, 246, 0.05);
    transform: translateX(0.5rem);
}

.advantage-content {
    display: none;
    animation: fadeInUp 0.5s ease-out;
}

.advantage-content.active-advantage-content {
    display: block;
}

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

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

/* Testimonial Slider */
.testimonial-container {
    position: relative;
}

.testimonial-prev,
.testimonial-next {
    border: none !important;
    outline: none !important;
}

.testimonial-prev:focus-visible,
.testimonial-next:focus-visible {
    outline: 2px solid #3b82f6 !important;
    outline-offset: 2px;
}

.testimonial-slide {
    display: none;
    opacity: 0;
    transition: opacity 0.6s ease-in-out;
}

.testimonial-slide.active-testimonial {
    display: block;
    opacity: 1;
    animation: fadeInScale 0.6s ease-in-out;
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.95);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.testimonial-dot {
    cursor: pointer;
    border: none !important;
    outline: none !important;
}

.testimonial-dot:focus-visible {
    outline: 2px solid #3b82f6 !important;
    outline-offset: 2px;
}

.testimonial-dot.active-testimonial-dot {
    width: 2rem;
    background: #004aa5;
}

/* Logo Carousel - Infinite Scroll */
.logo-carousel-wrapper {
    position: relative;
}

.logo-carousel {
    animation: scrollLogos 30s linear infinite;
    will-change: transform;
}

.logo-carousel:hover {
    animation-play-state: paused;
}

@keyframes scrollLogos {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

.logo-item {
    min-width: 150px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Scroll to Top Button */
#scroll-to-top {
    cursor: pointer;
    border: none !important;
    outline: none !important;
}

#scroll-to-top:focus-visible {
    outline: 2px solid #3b82f6 !important;
    outline-offset: 2px;
}

#scroll-to-top.visible {
    opacity: 1;
    visibility: visible;
}

/* Accessibility Button */
#accessibility-btn {
    border: none !important;
    outline: none !important;
}

#accessibility-btn:focus-visible {
    outline: 2px solid #3b82f6 !important;
    outline-offset: 2px;
}

/* Accessibility Panel */
#accessibility-panel.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

#close-accessibility,
#reset-accessibility,
.font-size-btn {
    border: none !important;
    outline: none !important;
}

#close-accessibility:focus-visible,
#reset-accessibility:focus-visible,
.font-size-btn:focus-visible {
    outline: 2px solid #3b82f6 !important;
    outline-offset: 2px;
}

/* Toggle Switch */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
    border: none !important;
    outline: none !important;
}

.toggle-switch input:focus-visible+.toggle-bg {
    outline: 2px solid #3b82f6 !important;
    outline-offset: 2px;
}

.toggle-bg {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #cbd5e1;
    border-radius: 24px;
    transition: background-color 0.3s ease;
}

.toggle-dot {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 4px;
    top: 4px;
    background-color: white;
    border-radius: 50%;
    transition: transform 0.3s ease;
}

.toggle-switch input:checked+.toggle-bg {
    background: #004aa5;
}

.toggle-switch input:checked+.toggle-bg .toggle-dot {
    transform: translateX(20px);
}

/* Wrapper for filters - excludes fixed buttons */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
}

/* High Contrast Mode */
body.high-contrast #main-content {
    filter: contrast(1.5);
}

/* Apply high contrast to form controls only, exclude buttons and links */
body.high-contrast input:not([type="button"]):not([type="submit"]):not([type="reset"]),
body.high-contrast select,
body.high-contrast textarea {
    border: 2px solid #000 !important;
    color: #000 !important;
    background: #fff !important;
}

/* For buttons and links, keep their original design in high contrast mode */
body.high-contrast button,
body.high-contrast input[type="button"],
body.high-contrast input[type="submit"],
body.high-contrast input[type="reset"],
body.high-contrast .btn-primary,
body.high-contrast .btn-secondary,
body.high-contrast a {
    border: none !important;
}

body.high-contrast h1,
body.high-contrast h2,
body.high-contrast h3,
body.high-contrast h4,
body.high-contrast h5,
body.high-contrast h6,
body.high-contrast p,
body.high-contrast span,
body.high-contrast div {
    color: #000 !important;
}

/* Preserve theme design elements in high contrast mode */
body.high-contrast .navbar,
body.high-contrast .btn-primary,
body.high-contrast .btn-secondary,
body.high-contrast .scroll-to-top,
body.high-contrast .accessibility-btn,
body.high-contrast .feature-card,
body.high-contrast .program-card,
body.high-contrast .news-card,
body.high-contrast .bento-item,
body.high-contrast .nav-link,
body.high-contrast .mega-menu-dropdown,
body.high-contrast .stat-item {
    border: none !important;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1) !important;
}

/* Ensure proper contrast for links while preserving design */
body.high-contrast .nav-link {
    background: transparent !important;
    border: none !important;
}

/* Font Size Classes */
body.font-small {
    font-size: 14px;
}

body.font-large {
    font-size: 18px;
}

body.font-large h1 {
    font-size: 3.5rem;
}

body.font-large h2 {
    font-size: 2.5rem;
}

body.font-large h3 {
    font-size: 1.75rem;
}

/* Reduce Motion */
body.reduce-motion *,
body.reduce-motion *::before,
body.reduce-motion *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
}

/* =================================================================
   ACCESSIBILITY FILTERS
   Applied directly to #page to avoid affecting fixed elements outside
   ================================================================= */

/* Grayscale Mode */
#page.grayscale {
    filter: grayscale(100%);
}

#page.grayscale.high-contrast {
    filter: grayscale(100%) contrast(1.5);
}

/* Invert Colors */
#page.invert {
    filter: invert(100%);
}

#page.invert.grayscale {
    filter: invert(100%) grayscale(100%);
}

#page.invert.high-contrast {
    filter: invert(100%) contrast(1.5);
}

#page.invert.grayscale.high-contrast {
    filter: invert(100%) grayscale(100%) contrast(1.5);
}

/* Fixed elements outside #page */
#accessibility-btn,
#accessibility-panel,
#scroll-to-top {
    position: fixed !important;
    z-index: 99999 !important;
}

/* Prevent horizontal overflow */
body {
    overflow-x: hidden;
}

/* Keep navbar with proper z-index */
.navbar {
    z-index: 50;
}

/* Ensure that design elements maintain their appearance even when filters are applied */
body.invert .navbar,
body.invert #scroll-to-top,
body.invert #accessibility-btn,
body.invert .btn-primary,
body.invert .btn-secondary,
body.invert .feature-card,
body.invert .program-card,
body.invert .news-card,
body.invert .bento-item,
body.invert .nav-link,
body.invert .mega-menu-dropdown,
body.invert .stat-item {
    filter: none !important;
}

/* News Cards - Magazine Style */
.news-card {
    position: relative;
    background: white;
    border-radius: 1.5rem;
    overflow: hidden;
    transition: all 0.5s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.news-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.2);
}

.news-image-wrapper {
    position: relative;
    overflow: hidden;
    height: 250px;
}

.news-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.news-card:hover .news-image {
    transform: scale(1.15);
}

.news-category {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 0.5rem 1rem;
    border-radius: 2rem;
    font-size: 0.75rem;
    font-weight: 600;
    z-index: 10;
}

/* Bento Grid Layout */
.bento-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 1.5rem;
}

.bento-item {
    background: white;
    border-radius: 2rem;
    padding: 2.5rem;
    border: 1px solid #e2e8f0;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.bento-item:hover {
    border-color: #3b82f6;
    box-shadow: 0 20px 40px -10px rgba(59, 130, 246, 0.2);
    transform: translateY(-5px);
}

.bento-large {
    grid-column: span 8;
}

.bento-small {
    grid-column: span 4;
}

@media (max-width: 768px) {

    .bento-large,
    .bento-small {
        grid-column: span 12;
    }
}

/* CTA Section */
.cta-wrapper {
    position: relative;
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    border-radius: 3rem;
    padding: 4rem;
    overflow: hidden;
}

.cta-wrapper::before {
    content: '';
    position: absolute;
    inset: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="grid" width="40" height="40" patternUnits="userSpaceOnUse"><path d="M 40 0 L 0 0 0 40" fill="none" stroke="rgba(255,255,255,0.03)" stroke-width="1"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.5;
}

/* Scroll Reveal */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* Button Styles */
.btn-primary {
    position: relative;
    overflow: hidden;
    background: #004aa5;
    color: white;
    padding: 1rem 2.5rem;
    border-radius: 3rem;
    font-weight: 600;
    transition: all 0.4s;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    border: none;
}

.btn-primary::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: left 0.5s;
}

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

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 30px -5px rgba(0, 74, 165, 0.5);
    background: #003d8a;
}

.btn-secondary {
    border: 2px solid white;
    color: white;
    padding: 1rem 2.5rem;
    border-radius: 3rem;
    font-weight: 600;
    transition: all 0.4s;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: transparent;
}

.btn-secondary:hover {
    background: white;
    color: #0f172a;
    transform: translateY(-2px);
}

/* Footer */
.footer-link {
    position: relative;
    display: inline-block;
    transition: all 0.3s;
}

.footer-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: #3b82f6;
    transition: width 0.3s;
}

.footer-link:hover::after {
    width: 100%;
}

/* Slideshow */
.slideshow-container {
    position: relative;
    width: 100%;
    height: 100%;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.8s ease-in-out;
    display: flex;
    align-items: center;
}

.slide.active-slide {
    opacity: 1;
    z-index: 10;
}

.slideshow-controls {
    z-index: 20;
}

.slide-prev,
.slide-next {
    border: none !important;
    outline: none !important;
}

.slide-prev:focus-visible,
.slide-next:focus-visible {
    outline: 2px solid #3b82f6 !important;
    outline-offset: 2px;
}

.slide-dot {
    border: none !important;
    cursor: pointer;
    outline: none !important;
    transition: all 0.3s;
}

.slide-dot:focus-visible {
    outline: 2px solid #3b82f6 !important;
    outline-offset: 2px;
}

.slide-dot.active-dot {
    background: white;
    transform: scale(1.2);
}

/* Section Title */
.section-badge {
    display: inline-block;
    padding: 0.5rem 1.5rem;
    background: rgba(0, 74, 165, 0.1);
    border: 1px solid rgba(0, 74, 165, 0.3);
    border-radius: 2rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: #004aa5;
    margin-bottom: 1rem;
}

.section-title {
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(2rem, 4vw, 3.5rem);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

/* Sidebar Widgets Styling */
.sidebar-widgets .widget {
    background: white;
    border-radius: 1rem;
    padding: 1.5rem;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
    border: 1px solid #e2e8f0;
    margin-bottom: 1.5rem;
}

.sidebar-widgets .widget-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid #004aa5;
}

.sidebar-widgets .widget ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-widgets .widget li {
    margin-bottom: 0.5rem;
}

.sidebar-widgets .widget a {
    color: #475569;
    transition: color 0.3s;
}

.sidebar-widgets .widget a:hover {
    color: #004aa5;
}

/* Page Hero Section */
.page-hero {
    min-height: auto;
    padding-bottom: 3rem !important;
    /* Fix bottom padding */
}

.page-hero h1 {
    color: #ffffff !important;
    background: none !important;
    -webkit-background-clip: unset !important;
    background-clip: unset !important;
    -webkit-text-fill-color: #ffffff !important;
    margin-bottom: 1.5rem !important;
}

/* Breadcrumb container - fix alignment and spacing */
.page-hero nav[aria-label="Breadcrumb"] {
    margin-bottom: 1.5rem !important;
    padding: 0 !important;
}

.page-hero nav[aria-label="Breadcrumb"] ol {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    gap: 0.5rem !important;
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

.page-hero nav[aria-label="Breadcrumb"] li {
    display: flex !important;
    align-items: center !important;
    list-style: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

.page-hero nav[aria-label="Breadcrumb"] a {
    color: rgba(255, 255, 255, 0.8) !important;
    text-decoration: none !important;
}

.page-hero nav[aria-label="Breadcrumb"] a:hover {
    color: #ffffff !important;
}

.page-hero nav[aria-label="Breadcrumb"] li span {
    color: #93c5fd !important;
    /* blue-300 */
}

.page-hero nav[aria-label="Breadcrumb"] i {
    color: rgba(255, 255, 255, 0.5) !important;
    margin: 0 0.5rem !important;
}

/* Meta info row - fix gaps */
.page-hero .flex {
    display: flex !important;
}

.page-hero .flex.flex-wrap {
    flex-wrap: wrap !important;
}

.page-hero .gap-x-6 {
    column-gap: 1.5rem !important;
}

.page-hero .gap-y-3 {
    row-gap: 0.75rem !important;
}

.page-hero .gap-2 {
    gap: 0.5rem !important;
}

.page-hero .gap-3 {
    gap: 0.75rem !important;
}

/* Fix text visibility in page hero */
.page-hero .text-slate-300 {
    color: rgba(255, 255, 255, 0.85) !important;
}

.page-hero .text-slate-400 {
    color: rgba(255, 255, 255, 0.75) !important;
}

.page-hero .text-slate-500 {
    color: rgba(255, 255, 255, 0.6) !important;
}

.page-hero .text-blue-300 {
    color: #93c5fd !important;
}

/* Author avatar spacing */
.page-hero .rounded-full {
    margin-right: 0.75rem !important;
}

/* Separator line */
.page-hero .bg-slate-600 {
    background-color: rgba(255, 255, 255, 0.3) !important;
}

/* Remove underline from all links */
a {
    text-decoration: none;
}

a:hover,
a:focus,
a:active {
    text-decoration: none;
}

/* Remove default focus outline for mouse users, keep for keyboard users */
button,
a,
input,
select,
textarea,
[role="button"],
.nav-link,
.btn-primary,
.btn-secondary {
    outline: none;
    border: none;
}

/* Prevent any default browser button styling */
button {
    background: none;
    padding: 0;
    font: inherit;
    cursor: pointer;
}

/* Add visible focus outline for keyboard navigation (accessibility) */
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[role="button"]:focus-visible,
.nav-link:focus-visible,
.btn-primary:focus-visible,
.btn-secondary:focus-visible {
    outline: 2px solid #3b82f6;
    outline-offset: 2px;
}

/* Prevent border on button click */
button:focus:not(:focus-visible),
a:focus:not(:focus-visible),
.nav-link:focus:not(:focus-visible),
.btn-primary:focus:not(:focus-visible),
.btn-secondary:focus:not(:focus-visible) {
    outline: none;
    border: none;
}