/* =========================================================
   ENHANCE.CSS - SDN 8 PANARUNG
   Peningkatan tampilan untuk index.php (tema Cream + Gold).
   Pasang SETELAH </style> di dalam <head>:
   <link rel="stylesheet" href="css/enhance.css">
========================================================= */

:root {
    --gold-900: #59470e;
    --gold-700: #8a6810;
    --gold-600: #b98b0d;
    --gold-500: #d4a62a;
    --gold-400: #e5bd38;
    --gold-200: #f4e2a0;
    --gold-100: #fff8dc;
    --navy: #0c2f53;
    --ease: cubic-bezier(.2, .8, .2, 1);
}

html { scroll-behavior: smooth; }

::selection { background: var(--gold-400); color: #3b2f06; }

/* Scrollbar */
::-webkit-scrollbar { width: 11px; }
::-webkit-scrollbar-track { background: #fff9e8; }
::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, var(--gold-600), var(--gold-400));
    border-radius: 20px;
    border: 2px solid #fff9e8;
}

/* =========================================================
   SCROLL PROGRESS + BACK TO TOP
========================================================= */

.scroll-progress {
    position: fixed;
    top: 0; left: 0;
    height: 4px;
    width: 0;
    z-index: 100000;
    background: linear-gradient(90deg, var(--gold-600), var(--gold-400), #fff0a8);
    box-shadow: 0 0 12px rgba(229, 189, 56, .7);
    transition: width .1s linear;
}

.back-to-top {
    position: fixed;
    left: 20px;
    bottom: 20px;
    width: 48px;
    height: 48px;
    border: 0;
    border-radius: 50%;
    z-index: 9998;
    cursor: pointer;
    color: #fff;
    font-size: 20px;
    line-height: 1;
    background: linear-gradient(135deg, var(--gold-600), var(--gold-400));
    box-shadow: 0 10px 25px rgba(130, 100, 20, .35);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: .4s var(--ease);
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
    transform: none;
}

.back-to-top:hover {
    transform: translateY(-5px);
    box-shadow: 0 16px 32px rgba(130, 100, 20, .45);
}

/* =========================================================
   HERO
========================================================= */

.hero {
    position: relative;
    overflow: hidden;
}

.hero-slide.active {
    animation: kenBurns 9s ease-out forwards;
}

@keyframes kenBurns {
    from { transform: scale(1); }
    to   { transform: scale(1.09); }
}

.hero .overlay {
    background:
        radial-gradient(circle at 50% 45%, rgba(0, 0, 0, .05), rgba(0, 0, 0, .55) 80%),
        linear-gradient(180deg, rgba(12, 30, 52, .55) 0%, rgba(30, 24, 6, .45) 55%, rgba(30, 24, 6, .78) 100%);
}

.hero-content {
    /* position sengaja tidak diubah agar posisi tengah dari style.css tetap */
    z-index: 3;
}

.hero-content h1 {
    font-weight: 700;
    letter-spacing: .5px;
    background: linear-gradient(180deg, #ffffff 30%, #ffe9a0 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 6px 22px rgba(0, 0, 0, .45));
}

.hero-content h1::after {
    content: "";
    display: block;
    width: 110px;
    height: 5px;
    margin: 18px auto 0;
    border-radius: 50px;
    background: linear-gradient(90deg, var(--gold-600), #fff0a8, var(--gold-600));
    box-shadow: 0 0 18px rgba(255, 220, 100, .7);
}

.child-title p {
    text-shadow: 0 3px 14px rgba(0, 0, 0, .5);
    letter-spacing: .4px;
}

/* Tombol FAQ */
.faq .btn {
    position: relative;
    overflow: hidden;
    padding: 13px 34px;
    color: #fff !important;
    font-weight: 600;
    letter-spacing: 1.5px;
    border-radius: 50px;
    background: linear-gradient(135deg, var(--gold-600), var(--gold-400));
    border: 1px solid rgba(255, 244, 190, .6);
    box-shadow: 0 10px 28px rgba(185, 139, 13, .45);
    transition: transform .35s var(--ease), box-shadow .35s ease;
    animation: btnGlow 2.8s ease-in-out infinite;
}

.faq .btn::after {
    content: "";
    position: absolute;
    top: 0; left: -120%;
    width: 60%; height: 100%;
    background: linear-gradient(120deg, transparent, rgba(255, 255, 255, .5), transparent);
    transform: skewX(-20deg);
    transition: .7s;
}

.faq .btn:hover {
    transform: translateY(-4px) scale(1.04);
    box-shadow: 0 16px 36px rgba(185, 139, 13, .6);
}

.faq .btn:hover::after { left: 140%; }

@keyframes btnGlow {
    0%, 100% { box-shadow: 0 10px 28px rgba(185, 139, 13, .45), 0 0 0 0 rgba(229, 189, 56, .5); }
    50%      { box-shadow: 0 10px 28px rgba(185, 139, 13, .45), 0 0 0 14px rgba(229, 189, 56, 0); }
}

/* Partikel emas */
.hero-particles {
    position: absolute;
    inset: 0;
    z-index: 2;
    pointer-events: none;
    overflow: hidden;
}

.hero-particles span {
    position: absolute;
    bottom: -20px;
    border-radius: 50%;
    background: radial-gradient(circle, #fff3b8, rgba(229, 189, 56, 0));
    opacity: 0;
    animation: riseUp linear infinite;
}

@keyframes riseUp {
    0%   { transform: translateY(0) translateX(0); opacity: 0; }
    15%  { opacity: .85; }
    100% { transform: translateY(-105vh) translateX(40px); opacity: 0; }
}

/* Indikator scroll */
.scroll-down {
    position: absolute;
    left: 50%;
    bottom: 28px;
    transform: translateX(-50%);
    z-index: 4;
    width: 28px;
    height: 46px;
    border: 2px solid rgba(255, 255, 255, .75);
    border-radius: 20px;
    cursor: pointer;
}

.scroll-down::before {
    content: "";
    position: absolute;
    top: 8px; left: 50%;
    width: 5px; height: 9px;
    margin-left: -2.5px;
    border-radius: 5px;
    background: var(--gold-400);
    animation: wheel 1.7s infinite;
}

@keyframes wheel {
    0%   { opacity: 1; transform: translateY(0); }
    100% { opacity: 0; transform: translateY(18px); }
}

/* =========================================================
   JUDUL SECTION
========================================================= */

.section-premium .title::before,
.news .title::before,
.gallery h2::before,
.info-card .section-header h2::before {
    content: "✦  ✦  ✦";
    display: block;
    margin-bottom: 10px;
    color: var(--gold-500);
    font-size: 13px;
    letter-spacing: 6px;
    opacity: .9;
}

.section-premium .title,
.news .title,
.gallery h2 {
    background: linear-gradient(90deg, var(--gold-900), var(--gold-600), var(--gold-900));
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: titleShine 6s linear infinite;
    text-shadow: none;
}

@keyframes titleShine {
    to { background-position: 200% center; }
}

/* =========================================================
   INFO / SERAGAM
========================================================= */

.info-card {
    position: relative;
    border: 1px solid rgba(232, 214, 158, .7);
    box-shadow: 0 25px 60px rgba(125, 100, 30, .13);
    overflow: hidden;
}

.info-card::before {
    content: "";
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 5px;
    background: linear-gradient(90deg, var(--gold-600), var(--gold-400), #fff0a8, var(--gold-600));
    background-size: 250% 100%;
    animation: programLine 4s linear infinite;
}

.uniformSwiper .swiper-slide,
.mplsSwiper .swiper-slide {
    transition: transform .45s var(--ease), box-shadow .45s ease;
}

.uniformSwiper .swiper-slide:hover {
    transform: translateY(-6px);
    box-shadow: 0 26px 55px rgba(125, 100, 30, .18);
}

.uniformSwiper .swiper-pagination-bullet-active,
.mplsSwiper .swiper-pagination-bullet-active {
    width: 28px;
    border-radius: 20px;
    background: linear-gradient(90deg, var(--gold-600), var(--gold-400));
}

/* =========================================================
   PROGRAM
========================================================= */

.card-link:hover .card-premium {
    transform: translateY(-12px);
    box-shadow: 0 30px 60px rgba(125, 100, 30, .24);
}

.card-link:hover .card-premium img {
    transform: scale(1.1);
    filter: saturate(1.1);
}

.card-premium::after {
    content: "";
    position: absolute;
    top: 0; left: -130%;
    width: 70%; height: 100%;
    background: linear-gradient(120deg, transparent, rgba(255, 255, 255, .3), transparent);
    transform: skewX(-20deg);
    transition: .9s;
    z-index: 6;
    pointer-events: none;
}

.card-link:hover .card-premium::after { left: 140%; }

.card-link:hover .card-body::after {
    color: #fff;
    background: linear-gradient(135deg, var(--gold-600), var(--gold-400));
    border-color: transparent;
    transform: translateX(4px);
}

.card-body::after {
    transition: .35s var(--ease);
}

.card-premium .badge {
    transition: transform .4s var(--ease);
}

.card-link:hover .card-premium .badge {
    transform: translateX(-50%) translateY(-5px);
}

/* =========================================================
   GALERI
========================================================= */

.gallerySwiper .swiper-slide-active {
    box-shadow: 0 35px 80px rgba(125, 100, 30, .28);
    outline: 3px solid rgba(229, 189, 56, .55);
    outline-offset: -3px;
}

.gallerySwiper .swiper-slide-active img {
    transform: scale(1.04);
}

/* =========================================================
   BERITA
========================================================= */

.news-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 28px 55px rgba(125, 100, 30, .22);
}

.news-card:hover img {
    transform: scale(1.08);
}

.news-card img {
    transition: transform .7s var(--ease), filter .5s ease;
}

.news-card:hover .news-read-more span {
    transform: translateX(5px);
}

.news-read-more span {
    transition: transform .35s var(--ease);
}

.news-card:hover .news-content h3 {
    color: var(--gold-600);
}

.news-content h3 {
    transition: color .3s ease;
}

.news-empty {
    grid-column: 1 / -1;
    padding: 50px 20px;
    text-align: center;
    color: var(--gold-700);
    border: 2px dashed var(--gold-200);
    border-radius: 24px;
    background: rgba(255, 255, 255, .7);
}

/* =========================================================
   VISITOR
========================================================= */

.visitor-item {
    transition: transform .45s var(--ease), box-shadow .45s ease;
}

.visitor-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 22px 48px rgba(110, 85, 15, .3);
}

.visitor-left::before {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 58px;
    height: 58px;
    margin-right: 16px;
    font-size: 26px;
    border-radius: 18px;
    background: rgba(255, 255, 255, .18);
    border: 1px solid rgba(255, 255, 255, .3);
    box-shadow: inset 0 0 18px rgba(255, 255, 255, .15);
}

.visitor-left { display: flex; align-items: center; }

.visitor-item:nth-child(1) .visitor-left::before { content: "👥"; }
.visitor-item:nth-child(2) .visitor-left::before { content: "📅"; }
.visitor-item:nth-child(3) .visitor-left::before { content: "🟢"; }

.visitor-item::before {
    content: "";
    position: absolute;
    top: -60px; right: -60px;
    width: 170px; height: 170px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .09);
}

.visitor-number {
    text-shadow: 0 3px 12px rgba(0, 0, 0, .2);
    font-variant-numeric: tabular-nums;
}

/* =========================================================
   SWITCH BAHASA
========================================================= */

.lang-switch {
    border-radius: 18px;
    transition: transform .3s var(--ease);
}

.lang-btn {
    font-weight: 600;
    transition: .3s var(--ease);
}

.lang-btn:hover { transform: translateY(-2px); }

/* =========================================================
   RESPONSIF
========================================================= */

@media (max-width: 768px) {
    .back-to-top { left: 12px; bottom: 12px; width: 42px; height: 42px; }
    .scroll-down { bottom: 18px; }
    .visitor-left::before { width: 48px; height: 48px; font-size: 22px; margin-right: 12px; }
    .hero-content h1::after { width: 80px; height: 4px; }
}

@media (hover: none) {
    .card-link:hover .card-premium,
    .news-card:hover,
    .uniformSwiper .swiper-slide:hover { transform: none; }
    .card-link:hover .card-premium img,
    .news-card:hover img { transform: none; }
}

@media (prefers-reduced-motion: reduce) {
    .hero-slide.active,
    .hero-particles span,
    .faq .btn,
    .scroll-down::before,
    .section-premium .title,
    .news .title,
    .gallery h2 { animation: none !important; }
    html { scroll-behavior: auto; }
}