:root {
    --primary-color: #874d63;
    --primary-dark: #6b3d4f;
    --primary-light: #f9f2f5;
    --secondary-color: #0284c7;
    --dark-color: #0f172a;
    --gray-bg: #f8fafc;
    --card-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.05), 0 8px 10px -6px rgba(0, 0, 0, 0.01);
    --border-radius: 12px;
}

body {
    font-family: 'Visby Round CF', 'Visby Round', 'Outfit', 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: #334155;
    background-color: #ffffff;
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6 {
    font-family: 'Visby Round CF', 'Visby Round', 'Outfit', sans-serif;
}

/* Top Header Bar */
.top-header-bar {
    background-color: #ffffff;
    border-bottom: 1px solid #e2e8f0;
}

.fw-extrabold {
    font-weight: 800;
}

.letter-spacing-tight {
    letter-spacing: -0.5px;
}

.fs-7 {
    font-size: 0.825rem;
}

.fs-8 {
    font-size: 0.75rem;
}

.info-icon-circle {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    background-color: var(--primary-light);
}

.btn-maestro-cta {
    background-color: var(--primary-color);
    color: #ffffff;
    font-weight: 700;
    font-size: 0.95rem;
    padding: 6px 6px 6px 24px;
    border-radius: 50px;
    display: inline-flex;
    align-items: center;
    gap: 14px;
    text-decoration: none;
    box-shadow: 0 4px 14px rgba(135, 77, 99, 0.25);
    transition: all 0.3s ease;
}

.btn-maestro-cta:hover {
    background-color: var(--primary-dark);
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 8px 22px rgba(135, 77, 99, 0.4);
}

.cta-icon-badge {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(4px);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
}

/* Slanted Floating Navigation Bar */
.slanted-nav-wrapper {
    background-color: var(--primary-color);
    position: relative;
    z-index: 999;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Sticky Float State */
.slanted-nav-wrapper.is-sticky {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1050;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
    animation: maestroSlideDown 0.35s ease-out forwards;
    background-color: var(--primary-color) !important;
}

@keyframes maestroSlideDown {
    from {
        transform: translateY(-100%);
    }

    to {
        transform: translateY(0);
    }
}

.border-white-10 {
    border-color: rgba(255, 255, 255, 0.15) !important;
}

/* Social Media Icons Group */
.social-nav-group {
    position: relative;
    z-index: 2;
}

@media (min-width: 992px) {
    .social-nav-group {
        min-height: 56px;
        padding-left: 16px !important;
        padding-right: 16px !important;
    }
}

.social-pill-btn {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    font-size: 0.95rem;
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.social-pill-btn:hover {
    transform: translateY(-3px) scale(1.1);
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.25);
    border-color: transparent;
    color: #ffffff;
}

/* Brand Specific Hover Colors */
.social-share:hover {
    background-color: #f59e0b;
}

.social-ig:hover {
    background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
}

.social-web:hover {
    background-color: #0284c7;
}

.social-wa:hover {
    background-color: #25D366;
}

.social-yt:hover {
    background-color: #FF0000;
}

.nav-link-item {
    color: #ffffff;
    font-weight: 600;
    font-size: 1rem;
    padding: 16px 20px;
    text-decoration: none;
    display: block;
    position: relative;
    transition: color 0.2s ease;
}

.nav-link-item:hover {
    color: #e2e8f0;
}

.nav-link-item.active::after,
.nav-link-item:hover::after {
    content: '';
    position: absolute;
    bottom: 8px;
    left: 20px;
    right: 20px;
    height: 3px;
    background-color: #ffffff;
    border-radius: 2px;
}

.search-trigger-box {
    border-left: 1px solid rgba(255, 255, 255, 0.2);
}

.search-btn {
    transition: transform 0.2s ease;
    display: inline-block;
}

.search-btn:hover {
    transform: scale(1.15);
}

@media (max-width: 991.98px) {
    .social-slanted-bar {
        display: none !important;
    }

    .slanted-nav-wrapper .navbar-collapse {
        background-color: var(--primary-color);
        border-top: 1px solid rgba(255, 255, 255, 0.15);
        padding-top: 8px;
        padding-bottom: 16px;
    }

    .nav-link-item {
        padding: 12px 16px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

    .nav-link-item.active::after {
        display: none;
    }

    .social-nav-group {
        min-height: auto;
        padding-left: 0 !important;
        padding-right: 0 !important;
        justify-content: center;
    }
}

/* ==========================================================================
   HOMEPAGE SECTIONS & CARDS
   ========================================================================== */

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 100%);
    color: #ffffff;
    padding: 90px 0 100px;
    position: relative;
    overflow: hidden;
}

/* Hero Custom Background Slider & Overlay */
.hero-bg-container {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1;
}

.hero-bg-slide {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-size: cover;
    background-position: center center;
    opacity: 0;
    transition: opacity 1.5s ease-in-out, transform 8s ease;
    transform: scale(1);
}

.hero-bg-slide.active {
    opacity: 1;
    transform: scale(1.06);
}

.hero-bg-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(15, 23, 42, 0.90) 0%, rgba(15, 23, 42, 0.80) 50%, var(--primary-dark) 85%);
    z-index: 2;
}

.hero-section .container {
    position: relative;
    z-index: 3;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: radial-gradient(circle at 80% 20%, rgba(2, 132, 199, 0.25) 0%, transparent 50%);
    pointer-events: none;
    z-index: 2;
}

.hero-badge {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #ffffff;
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 0.875rem;
    font-weight: 600;
    display: inline-block;
    margin-bottom: 20px;
}

.hero-title {
    font-family: 'Visby Round CF', 'Visby Round', 'Outfit', sans-serif;
    font-size: 2.8rem;
    font-weight: 800;
    line-height: 1.25;
    margin-bottom: 20px;
    letter-spacing: -0.5px;
}

.hero-subtitle {
    font-size: 1.15rem;
    color: #e2e8f0;
    margin-bottom: 35px;
    max-width: 620px;
}

/* Custom Buttons */
.btn-primary-custom {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: #ffffff;
    font-weight: 600;
    padding: 12px 28px;
    border-radius: 8px;
    transition: all 0.25s ease;
}

.btn-primary-custom:hover {
    background-color: var(--primary-dark);
    border-color: var(--primary-dark);
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px -5px rgba(135, 77, 99, 0.4);
}

.btn-outline-custom {
    background-color: transparent;
    border: 2px solid rgba(255, 255, 255, 0.8);
    color: #ffffff;
    font-weight: 600;
    padding: 11px 26px;
    border-radius: 8px;
    transition: all 0.25s ease;
}

.btn-outline-custom:hover {
    background-color: #ffffff;
    color: var(--primary-dark);
    transform: translateY(-2px);
}

/* Section Header Titles */
.section-tag {
    color: var(--primary-color);
    font-weight: 700;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 8px;
    display: block;
}

.section-title {
    font-weight: 800;
    font-size: 2.2rem;
    color: var(--dark-color);
    letter-spacing: -0.5px;
}

/* Cards & Micro Animations */
.featured-card {
    background: #ffffff;
    border-radius: var(--border-radius);
    padding: 35px 28px;
    box-shadow: var(--card-shadow);
    border: 1px solid #f1f5f9;
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    height: 100%;
}

.featured-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 35px -10px rgba(0, 0, 0, 0.08);
    border-color: var(--primary-light);
}

.icon-box {
    width: 60px;
    height: 60px;
    border-radius: 14px;
    background-color: var(--primary-light);
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    margin-bottom: 22px;
}

/* News Cards */
.news-card {
    background: #ffffff;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--card-shadow);
    border: 1px solid #f1f5f9;
    transition: all 0.3s ease;
    height: 100%;
}

.news-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 18px 30px -8px rgba(0, 0, 0, 0.08);
}

.news-img-wrapper {
    height: 200px;
    overflow: hidden;
    position: relative;
    background-color: #f1f5f9;
}

.news-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

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

.news-cat-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    background-color: var(--primary-color);
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 20px;
}

/* PPDB Steps */
.step-card {
    background: #ffffff;
    border-radius: var(--border-radius);
    padding: 30px 24px;
    box-shadow: var(--card-shadow);
    border: 1px solid #e2e8f0;
    position: relative;
    height: 100%;
    transition: all 0.3s ease;
}

.step-card:hover {
    border-color: var(--primary-color);
}

.step-number {
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--primary-color);
    opacity: 0.85;
    margin-bottom: 12px;
}

/* Footer High-Contrast & Custom Icon Links */
footer {
    background-color: #0f172a;
    color: #e2e8f0;
    padding-top: 70px;
    padding-bottom: 30px;
    border-top: 1px solid #1e293b;
}

footer h5 {
    color: #ffffff;
    font-weight: 700;
    margin-bottom: 22px;
    letter-spacing: -0.3px;
}

footer p,
footer span,
footer li {
    color: #cbd5e1;
    font-size: 0.925rem;
}

.footer-logo-img {
    height: 150px;
    max-height: 150px;
    width: auto;
    object-fit: contain;
}

footer a {
    color: #e2e8f0;
    text-decoration: none;
    transition: all 0.2s ease;
}

footer a:hover {
    color: #d69ab0;
}

.footer-simple-link {
    color: #cbd5e1;
    text-decoration: none;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
}

.footer-simple-link i {
    color: var(--primary-color);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

a.footer-simple-link:hover {
    color: #ffffff;
    transform: translateX(3px);
}

.footer-link-item {
    color: #e2e8f0;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    transition: all 0.25s ease;
    font-weight: 500;
    width: 100%;
}

.footer-link-item:hover {
    color: #ffffff;
    background: var(--primary-color);
    border-color: var(--primary-color);
    transform: translateX(4px);
    box-shadow: 0 4px 12px rgba(5, 150, 105, 0.25);
}

.footer-link-icon {
    color: #34d399;
    font-size: 1.05rem;
    transition: color 0.2s ease;
}

.footer-link-item:hover .footer-link-icon {
    color: #ffffff;
}

.social-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.15);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    margin-right: 10px;
    transition: all 0.25s ease;
}

.social-icon:hover {
    background: var(--primary-color);
    color: #ffffff;
    border-color: var(--primary-color);
    transform: translateY(-3px);
}

/* Modern Geometric Background Section */
.geometric-bg-section {
    position: relative;
    background-color: #f8fafc;
    background-image:
        radial-gradient(at 0% 0%, rgba(135, 77, 99, 0.06) 0px, transparent 50%),
        radial-gradient(at 100% 100%, rgba(2, 132, 199, 0.06) 0px, transparent 50%),
        url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23874d63' fill-opacity='0.04'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    border-top: 1px solid #e2e8f0;
    border-bottom: 1px solid #e2e8f0;
}

.hover-translate-x {
    transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.hover-translate-x:hover {
    transform: translateX(6px);
    border-color: var(--primary-color) !important;
    box-shadow: 0 4px 12px rgba(5, 150, 105, 0.08);
}

/* ==========================================================================
   ARTICLE & PAGE TABLE STYLING
   ========================================================================== */
.article-content figure.table,
.page-content figure.table,
.ck-content figure.table {
    width: 100%;
    overflow-x: auto;
    margin: 1.5rem 0;
}

.article-content table,
.page-content table,
.ck-content table {
    width: 100%;
    margin-bottom: 1.5rem;
    color: #1e293b;
    border-collapse: collapse;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid #e2e8f0;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
}

.article-content th,
.page-content th,
.ck-content th,
.article-content td,
.page-content td,
.ck-content td {
    padding: 12px 18px;
    border: 1px solid #e2e8f0;
    font-size: 0.95rem;
    line-height: 1.6;
}

.article-content th,
.page-content th,
.ck-content th {
    background-color: var(--primary-light, #f9f2f5);
    color: var(--primary-dark, #6b3d4f);
    font-weight: 700;
    text-align: left;
    border-bottom: 2px solid var(--primary-color, #874d63);
}

.article-content tbody tr:nth-child(even),
.page-content tbody tr:nth-child(even),
.ck-content tbody tr:nth-child(even) {
    background-color: #f8fafc;
}

.article-content tbody tr:hover,
.page-content tbody tr:hover,
.ck-content tbody tr:hover {
    background-color: #f1f5f9;
    transition: background-color 0.2s ease;
}

/* Safinah Custom Pagination */
.pagination-safinah {
    display: flex;
    gap: 8px;
    align-items: center;
    list-style: none;
    padding-left: 0;
}

.pagination-safinah .page-item .page-link {
    color: #475569;
    background-color: #ffffff;
    border: 1.5px solid #e2e8f0;
    min-width: 42px;
    height: 42px;
    padding: 0 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    font-weight: 700;
    font-size: 0.95rem;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
    text-decoration: none;
}

.pagination-safinah .page-item .page-link:hover {
    background-color: var(--primary-light, #f9f2f5);
    color: var(--primary-color, #874d63);
    border-color: var(--primary-color, #874d63);
    transform: translateY(-2px);
    box-shadow: 0 6px 14px rgba(135, 77, 99, 0.15);
}

.pagination-safinah .page-item.active .page-link {
    background: linear-gradient(135deg, var(--primary-color, #874d63), var(--primary-dark, #6b3d4f));
    color: #ffffff;
    border-color: transparent;
    box-shadow: 0 6px 18px rgba(135, 77, 99, 0.35);
    transform: scale(1.04);
}

.pagination-safinah .page-item.disabled .page-link {
    color: #cbd5e1;
    background-color: #f8fafc;
    border-color: #f1f5f9;
    box-shadow: none;
    cursor: not-allowed;
    pointer-events: none;
}

/* ==========================================================================
   Collapsible Card Component (Visi, Misi & Profil)
   ========================================================================== */
.collapsible-card-wrapper {
    position: relative;
    width: 100%;
}

.collapsible-card-wrapper.is-collapsible.is-collapsed .collapsible-card-content {
    max-height: 350px;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.collapsible-card-wrapper.is-collapsible.is-expanded .collapsible-card-content {
    max-height: 4000px;
    overflow: visible;
    transition: max-height 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.collapsible-card-fade {
    display: none;
    position: absolute;
    bottom: 50px;
    left: 0;
    right: 0;
    height: 120px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.85) 60%, #ffffff 100%);
    pointer-events: none;
    z-index: 2;
    transition: opacity 0.3s ease;
}

.collapsible-card-wrapper.is-collapsible.is-collapsed .collapsible-card-fade {
    display: block;
}

.collapsible-card-action {
    position: relative;
    z-index: 3;
}

.btn-collapse-toggle {
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    font-size: 0.875rem;
}

.btn-collapse-toggle:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1) !important;
}

.btn-collapse-toggle .btn-collapse-icon {
    transition: transform 0.3s ease;
}