* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #08681d;
    --primary-dark: #065218;
    --secondary: #1e4228;
    --accent: #f5d02c;
    --accent-dark: #e0bb1e;
    --light: #f8f9fa;
    --dark: #343a40;
    --gray: #6c757d;
    --light-green: #e9f5ea;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: "Poppins", sans-serif;
    line-height: 1.6;
    color: #222;
    background-color: #f4f4f4;
}

/* Preloader Styles */
#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: #f8fafb;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    transition:
        opacity 0.5s ease,
        visibility 0.5s ease;
}

#preloader.hide {
    opacity: 0;
    visibility: hidden;
}

#preloader .loader {
    text-align: center;
}

#preloader img {
    width: 80px;
    margin-bottom: 1.5rem;
    border-radius: 20%;
    box-shadow: 0 4px 15px rgba(8, 104, 29, 0.15);
}

#preloader .spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #e9f5ea;
    border-top: 4px solid var(--primary);
    border-radius: 50%;
    margin: 0 auto 1.5rem auto;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

#preloader p {
    color: var(--primary);
    font-weight: 500;
    font-size: 1.1rem;
    letter-spacing: 0.5px;
}

/* Pastikan body tidak scroll saat preloader aktif */
body.preload-active {
    overflow: hidden;
}

.arabic {
    font-family: "Noto Sans Arabic", sans-serif;
}

.container {
    width: 100%;
    max-width: 1152px;
    margin: 0 auto;
    padding: 0 15px;
}

/* Header Styles */
header {
    background:
        linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)),
        url("../images/bg-hero.jpg") no-repeat center center/cover;
    color: white;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

nav {
    background-color: rgba(8, 104, 29, 0.95);
    padding: 1rem 0;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

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

.logo {
    display: flex;
    align-items: center;
}
.logo-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    text-decoration: none;
}

.logo-img {
    height: 50px;
    border-radius: 20%;
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 700;
    color: white;
    margin-left: 10px;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 1rem;
    margin: 0 auto;
}

.nav-links li {
    margin-left: 1rem;
}

.nav-links a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
}

.nav-links a::after {
    content: "";
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--accent);
    transition: width 0.3s ease;
}

.nav-links a:hover {
    color: var(--accent);
}

.nav-links a:hover::after {
    width: 100%;
}

/* Navbar Active State */
.nav-links a.active {
    color: var(--accent);
}

.nav-links a.active::after {
    width: 100%;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background-color: white;
    margin: 3px 0;
    transition: all 0.3s ease;
}

/* Login Button Style */
.btn-login {
    display: inline-block;
    background: linear-gradient(135deg, var(--accent), var(--accent-dark));
    color: #fff;
    padding: 0.5rem 2.5rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1.05rem;
    text-decoration: none;
    box-shadow: 0 4px 15px rgba(8, 104, 29, 0.13);
    border: none;
    transition:
        all 0.2s,
        transform 0.2s,
        box-shadow 0.2s;
    margin: 0.5rem 0;
    letter-spacing: 0.5px;
    cursor: pointer;
}

.btn-login:hover,
.btn-login:focus {
    background: linear-gradient(135deg, var(--accent-dark), var(--accent));
    color: #fff;
    transform: translateY(-2px) scale(1.03);
    box-shadow: 0 8px 24px rgba(8, 104, 29, 0.18);
    text-decoration: none;
}

.hero {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 2rem;
    margin-top: 70px;
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
}

.hero p {
    font-size: 1.5rem;
    max-width: 800px;
    margin-bottom: 2rem;
}

.btn {
    display: inline-block;
    background-color: var(--accent);
    border: none;
    color: #eee;
    padding: 1.1rem 3rem;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(245, 208, 44, 0.3);
    cursor: pointer;
}

.btn:hover {
    background-color: var(--accent-dark);
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(245, 208, 44, 0.4);
}

/* Section Styles */
section {
    padding: 5rem 0;
}

section:nth-child(even) {
    background-color: white;
}

.section-title {
    text-align: center;
    margin-bottom: 2rem;
}

.section-title h2 {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 0.5rem;
    position: relative;
    display: inline-block;
}

.section-title h2::after {
    content: "";
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background-color: var(--accent);
}

.section-title p {
    color: var(--gray);
    font-size: 1.1rem;
    margin-top: 1.5rem;
}

/* Profile Section */
.profile-content {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    align-items: center;
}

.profile-text {
    flex: 1;
    min-width: 300px;
}

.profile-image {
    flex: 1;
    min-width: 300px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.profile-image:hover {
    transform: translateY(-5px);
}

.profile-image img {
    width: 100%;
    height: auto;
    display: block;
}

.vision-mission {
    margin-top: 2rem;
}

.vision-mission h3 {
    color: var(--secondary);
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--accent);
    display: inline-block;
}

.vision-mission ul {
    margin-left: 1.5rem;
    margin-bottom: 1.5rem;
}

.vision-mission li {
    margin-bottom: 0.5rem;
    position: relative;
}

.vision-mission li::before {
    content: "•";
    color: var(--accent);
    font-weight: bold;
    display: inline-block;
    width: 1em;
    margin-left: -1em;
}

/* Documentation Section */
.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.gallery-item {
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
    height: 250px;
    position: relative;
}

.gallery-item:hover {
    transform: translateY(-5px);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.7));
    color: white;
    padding: 1rem;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.gallery-item:hover .gallery-overlay {
    transform: translateY(0);
}

.gallery-overlay h3 {
    font-size: 1.2rem;
    margin: 0;
}

/* Gallery Modal Styles */
.gallery-modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.9);
    animation: fadeIn 0.3s ease-out;
}

.modal-content {
    position: relative;
    background-color: #fff;
    margin: 2% auto;
    padding: 0;
    width: 90%;
    max-width: 1200px;
    border-radius: 10px;
    box-shadow: 0 5px 30px rgba(0, 0, 0, 0.3);
    animation: slideIn 0.3s ease-out;
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 25px;
    color: #aaa;
    font-size: 35px;
    font-weight: bold;
    cursor: pointer;
    z-index: 10;
    transition: color 0.3s ease;
}

.close-modal:hover,
.close-modal:focus {
    color: var(--primary);
    text-decoration: none;
}

.modal-header {
    padding: 20px;
    border-bottom: 1px solid #eee;
    background-color: var(--light-green);
    border-radius: 10px 10px 0 0;
}

.modal-header h2 {
    color: var(--primary);
    margin: 0;
    text-align: center;
}

.modal-body {
    padding: 20px;
}

.gallery-detail {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.gallery-main {
    width: 100%;
    text-align: center;
}

.gallery-main img {
    max-width: 100%;
    max-height: 350px;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.gallery-thumbnails {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    padding: 10px 0;
}

.thumbnail {
    width: 100px;
    height: 70px;
    object-fit: cover;
    border-radius: 5px;
    cursor: pointer;
    transition:
        transform 0.3s ease,
        box-shadow 0.3s ease;
    border: 2px solid transparent;
}

.thumbnail:hover {
    transform: scale(1.05);
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.2);
}

.thumbnail.active {
    border-color: var(--primary);
    transform: scale(1.05);
}

/* Animations for modal */
@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive styles for modal */
@media (max-width: 768px) {
    .modal-content {
        width: 95%;
        margin: 5% auto;
    }

    .gallery-main img {
        max-height: 300px;
    }

    .thumbnail {
        width: 80px;
        height: 60px;
    }
}

@media (max-width: 480px) {
    .modal-content {
        width: 98%;
        margin: 2% auto;
    }

    .gallery-main img {
        max-height: 250px;
    }

    .thumbnail {
        width: 60px;
        height: 45px;
    }
}

/* Additional improvements for gallery modal */
.gallery-thumbnails {
    max-height: 200px;
    overflow-y: auto;
    padding: 10px;
}

/* Custom scrollbar untuk thumbnails */
.gallery-thumbnails::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

.gallery-thumbnails::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.gallery-thumbnails::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 10px;
}

.gallery-thumbnails::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Counter untuk jumlah foto */
.gallery-thumbnails::after {
    content: "";
    flex: auto;
}

/* News Section */
.activities {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
}

.weekly,
.yearly {
    flex: 1;
    min-width: 300px;
    background-color: var(--light);
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.weekly h3,
.yearly h3 {
    color: var(--primary);
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--accent);
    display: flex;
    align-items: center;
    gap: 10px;
}

.activity-item {
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #eee;
}

.activity-item:last-child {
    border-bottom: none;
}

.activity-item h3 {
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.activity-item p {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--gray);
}

/* Activities Section Styles */
.activities-tabs {
    display: flex;
    justify-content: center;
    margin-bottom: 3rem;
    border-bottom: 2px solid var(--light);
}

.activity-tab-btn {
    background: none;
    border: none;
    padding: 1rem 2rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--gray);
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.activity-tab-btn:hover {
    color: var(--primary);
}

.activity-tab-btn.active {
    color: var(--primary);
}

.activity-tab-btn.active::after {
    content: "";
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--primary);
    border-radius: 3px 3px 0 0;
}

.activities-container {
    margin-top: 2rem;
}

.activity-tab-content {
    display: none;
    animation: fadeIn 0.5s ease-in-out;
}

.activity-tab-content.active {
    display: block;
}

.activities-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 1.5rem;
    margin-top: 1rem;
}

.activity-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    border-left: 4px solid var(--primary);
}

.activity-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.activity-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.activity-icon i {
    font-size: 1.5rem;
    color: white;
}

.activity-content {
    flex: 1;
}

.activity-content h3 {
    color: var(--primary);
    margin-bottom: 0.5rem;
    font-size: 1.2rem;
}

.activity-schedule {
    color: var(--accent-dark);
    font-weight: 600;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8rem;
}

.activity-schedule i {
    width: 16px;
}

.activity-description {
    color: var(--gray);
    line-height: 1.5;
    font-size: 0.95rem;
}

/* Responsive Styles for Activities */
@media (max-width: 768px) {
    .activities-tabs {
        flex-direction: column;
        align-items: center;
        gap: 0.5rem;
    }

    .activity-tab-btn {
        width: 100%;
        justify-content: center;
        padding: 0.8rem 1rem;
    }

    .activities-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .activity-card {
        padding: 1.2rem;
    }

    .activity-icon {
        width: 40px;
        height: 40px;
    }

    .activity-icon i {
        font-size: 1.2rem;
    }
}

@media (max-width: 480px) {
    .activity-card {
        flex-direction: column;
        text-align: center;
        gap: 0.8rem;
    }

    .activity-schedule {
        justify-content: center;
    }
}

/* Santri Age Group Styles */
.santri-age-group {
    margin-bottom: 3rem;
}

.age-group-title {
    color: var(--primary);
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    padding: 1rem 1.5rem;
    background: linear-gradient(
        135deg,
        rgba(0, 123, 255, 0.1),
        rgba(0, 123, 255, 0.05)
    );
    border-left: 5px solid var(--primary);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.age-group-title i {
    margin-right: 0.5rem;
}

.badge-count {
    background: var(--primary);
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
}

/* Responsive untuk age group */
@media (max-width: 768px) {
    .age-group-title {
        flex-direction: column;
        text-align: center;
        font-size: 1.2rem;
        padding: 1rem;
    }

    .badge-count {
        font-size: 0.85rem;
    }
}

/* Information Section */
.info-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.info-card {
    background-color: white;
    border-radius: 10px;
    padding: 2rem;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    text-align: center;
    transition: transform 0.3s ease;
}

.info-card:hover {
    transform: translateY(-5px);
}

.info-card-icon {
    width: 70px;
    height: 70px;
    background-color: var(--light-green);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
}

.info-card-icon i {
    font-size: 2rem;
    color: var(--primary);
}

.info-card h3 {
    color: var(--primary);
    margin-bottom: 1rem;
}

.financial-summary {
    margin-top: 2rem;
    background-color: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.financial-summary h3 {
    color: var(--primary);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.financial-tabs {
    display: flex;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid #ddd;
}

.tab-btn {
    padding: 0.75rem 1.5rem;
    background: none;
    border: none;
    cursor: pointer;
    font-weight: 500;
    color: var(--gray);
    position: relative;
}

.tab-btn.active {
    color: var(--primary);
    font-weight: 600;
}

.tab-btn.active::after {
    content: "";
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--primary);
}

.tab-content {
    display: none;
}

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

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
}

th,
td {
    padding: 0.75rem;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

th {
    background-color: var(--primary);
    color: white;
}

tr:hover {
    background-color: #f9f9f9;
}

.total-balance {
    margin-top: 2rem;
    background-color: var(--primary);
    color: white;
    padding: 1.5rem;
    border-radius: 8px;
    text-align: center;
}

.total-balance h4 {
    margin: 0;
    font-size: 1.5rem;
}

/* Payment Form */
.payment-form {
    background-color: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    max-width: 800px;
    margin: 0 auto;
}

.payment-options {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.payment-option {
    flex: 1;
    text-align: center;
    padding: 1.5rem 1rem;
    border: 2px solid #ddd;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.payment-option:hover {
    border-color: var(--primary);
    background-color: rgba(8, 104, 29, 0.05);
}

.payment-option.selected {
    border-color: var(--primary);
    background-color: rgba(8, 104, 29, 0.1);
}

.payment-option i {
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--dark);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-family: inherit;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(8, 104, 29, 0.1);
}

/* Improved styles for payment form */
.form-group input[readonly] {
    background-color: #f8f9fa;
    cursor: not-allowed;
}

.payment-option {
    transition: all 0.3s ease;
}

.payment-option.selected {
    transform: scale(1.02);
    box-shadow: 0 5px 15px rgba(8, 104, 29, 0.2);
}

/* Style untuk amount field yang read-only */
#amount:read-only {
    background-color: var(--light-green);
    border-color: var(--primary);
    font-weight: bold;
}

.animal-options {
    display: none;
    margin-top: 1rem;
    padding: 1.5rem;
    background-color: var(--light-green);
    border-radius: 8px;
}

.note {
    background-color: #fff3cd;
    padding: 0.75rem 1rem;
    border-left: 4px solid var(--accent);
    margin-top: 0.5rem;
    font-size: 0.9rem;
    border-radius: 4px;
}

/* Footer */
footer {
    background-color: var(--secondary);
    color: white;
    padding: 3rem 0 1.5rem;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section {
    flex: 1;
    min-width: 250px;
}

.footer-section h3 {
    margin-bottom: 1.5rem;
    position: relative;
    padding-bottom: 0.5rem;
}

.footer-section h3::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 2px;
    background-color: var(--accent);
}

.contact-info {
    list-style: none;
}

.contact-info li {
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
}

.contact-info i {
    margin-right: 0.75rem;
    color: var(--accent);
    width: 20px;
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}

.social-links a {
    display: inline-block;
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    text-align: center;
    line-height: 40px;
    color: white;
    transition: all 0.3s ease;
}

.social-links a:hover {
    background-color: var(--accent);
    transform: translateY(-3px);
}

.footer-bottom {
    text-align: center;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    box-shadow: 0 4px 15px rgba(8, 104, 29, 0.4);
    transition: all 0.3s ease;
    z-index: 999;
}

.back-to-top:hover {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary));
    transform: translateY(-5px);
    box-shadow: 0 6px 20px rgba(8, 104, 29, 0.6);
}

.back-to-top.show {
    display: flex;
    animation: fadeInUp 0.3s ease-out;
}

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

/* Responsive for Back to Top */
@media (max-width: 768px) {
    .back-to-top {
        width: 45px;
        height: 45px;
        bottom: 20px;
        right: 20px;
        font-size: 1rem;
    }
}

/* TPQ Registration Section */

/* Age Warning Style */
.age-warning {
    background-color: #fff3cd;
    border: 1px solid #ffc107;
    color: #856404;
    padding: 0.75rem 1rem;
    border-radius: 5px;
    margin-top: 0.5rem;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    animation: slideDown 0.3s ease-out;
}

.age-warning i {
    color: #ffc107;
}

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

.tpq-registration-form {
    background-color: white;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    max-width: 900px;
    margin: 0 auto;
}

.tpq-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.tpq-info-card {
    background: linear-gradient(135deg, var(--light-green), white);
    padding: 1.5rem;
    border-radius: 10px;
    text-align: center;
    border: 2px solid var(--primary);
    transition:
        transform 0.3s ease,
        box-shadow 0.3s ease;
}

.tpq-info-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(8, 104, 29, 0.15);
}

.tpq-info-card i {
    color: var(--primary);
    margin-bottom: 1rem;
}

.tpq-info-card h3 {
    color: var(--primary);
    margin-bottom: 0.5rem;
    font-size: 1.2rem;
}

.tpq-info-card p {
    color: var(--gray);
    font-size: 0.95rem;
    line-height: 1.6;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.required {
    color: #dc3545;
    font-weight: bold;
}

#tpqRegistrationForm .form-group input[type="date"] {
    cursor: pointer;
}

#tpqRegistrationForm .btn {
    margin-top: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 1.1rem;
}

/* Responsive Styles for TPQ Registration */
@media (max-width: 768px) {
    .tpq-info {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .form-row {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .tpq-registration-form {
        padding: 1.5rem;
    }
}

@media (max-width: 480px) {
    .tpq-info-card {
        padding: 1rem;
    }

    .tpq-info-card i {
        font-size: 2rem;
    }

    .tpq-registration-form {
        padding: 1rem;
    }
}

/* Responsive Styles */
@media (max-width: 992px) {
    .nav-links {
        position: fixed;
        top: 60px;
        left: -100%;
        width: 100%;
        height: 100%;
        overflow-y: auto;
        background-color: var(--primary);
        flex-direction: column;
        align-items: center;
        justify-content: flex-start;
        transition: all 0.3s ease;
        padding: 1rem 0;
    }

    .nav-links.active {
        left: 0;
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    }

    .nav-links li {
        margin: 1rem 0;
        width: 100%;
        text-align: center;
    }

    .nav-links a {
        display: block;
        padding: 0.8rem 1rem;
        font-size: 1.1rem;
    }

    .nav-links a.active {
        background-color: rgba(255, 255, 255, 0.1);
        border-radius: 5px;
    }

    .hamburger {
        display: flex;
        flex-direction: column;
        justify-content: center;
        width: 30px;
        height: 30px;
        cursor: pointer;
        z-index: 1001;
    }

    .hamburger span {
        width: 25px;
        height: 3px;
        background-color: white;
        margin: 2px 0;
        transition: all 0.3s ease;
        transform-origin: center;
    }

    .hamburger.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }

    .hamburger.active span:nth-child(2) {
        opacity: 0;
    }

    .hamburger.active span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -5px);
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .hero p {
        font-size: 1.2rem;
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .hero p {
        font-size: 1.2rem;
    }
}

@media (max-width: 768px) {
    .section-title h2 {
        font-size: 2rem;
    }

    .payment-options {
        flex-direction: column;
    }

    .activities {
        flex-direction: column;
    }

    .footer-content {
        flex-direction: column;
    }

    .nav-links {
        top: 0;
    }
}

/* Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

section {
    animation: fadeIn 0.8s ease-out;
}

/* pindahan */

.financial-summary table tfoot {
    background-color: #f8f9fa;
    font-weight: bold;
    border-top: 2px solid #dee2e6;
}

.financial-summary table tfoot td {
    padding: 12px 8px;
}

/* Notification Toast Styles */
.notification-toast {
    position: fixed;
    top: -100px;
    right: 20px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.2);
    padding: 20px;
    min-width: 350px;
    z-index: 9999;
    transition: all 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    border-left: 5px solid #28a745;
}

.notification-toast.show {
    top: 20px;
}

.notification-toast.error {
    border-left-color: #dc3545;
}

.notification-content {
    display: flex;
    align-items: flex-start;
    gap: 15px;
}

.notification-icon {
    font-size: 24px;
    color: #28a745;
    flex-shrink: 0;
}

.notification-toast.error .notification-icon {
    color: #dc3545;
}

.notification-message {
    flex: 1;
}

.notification-message strong {
    display: block;
    margin-bottom: 5px;
    font-size: 16px;
    color: #333;
}

.notification-message p {
    margin: 0;
    font-size: 14px;
    color: #666;
}

.notification-close {
    position: absolute;
    top: 10px;
    right: 10px;
    background: none;
    border: none;
    color: #999;
    cursor: pointer;
    font-size: 16px;
    padding: 5px;
    transition: color 0.3s;
}

.notification-close:hover {
    color: #333;
}

/* Loading state for button */
.btn.loading {
    position: relative;
    color: transparent;
    pointer-events: none;
}

.btn.loading::after {
    content: "";
    position: absolute;
    width: 16px;
    height: 16px;
    top: 50%;
    left: 50%;
    margin-left: -8px;
    margin-top: -8px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* NOTIF PEMBAYARAN MIDTRANS */
.payment-options {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    justify-content: center;
    flex-wrap: wrap;
}

.payment-option {
    flex: 1;
    min-width: 200px;
    padding: 2rem;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
}

.payment-option:hover {
    border-color: #4caf50;
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.payment-option.active {
    border-color: #4caf50;
    background: #e8f5e9;
}

.payment-option i {
    color: #4caf50;
    margin-bottom: 1rem;
}

.payment-option h3 {
    margin: 0;
    font-size: 1.2rem;
    color: #333;
}

.payment-form {
    max-width: 600px;
    margin: 0 auto;
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: #333;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #4caf50;
}

.btn-primary {
    background: #4caf50;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.3s;
}

.btn-primary:hover {
    background: #45a049;
}

.btn-primary:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* KELOMPOK QURBAN */
.qurban-section {
    background: linear-gradient(180deg, #f8f9fa 0%, #ffffff 100%);
    position: relative;
    overflow: hidden;
}

/* Custom Grid untuk Statistik Cards - Paksa 4 kolom */
.qurban-section .row-stats {
    display: flex !important;
    flex-wrap: wrap !important;
    margin-right: -0.5rem !important;
    margin-left: -0.5rem !important;
}

.qurban-section .col-stat-item {
    flex: 0 0 auto !important;
    width: 50% !important;
    max-width: 50% !important;
    padding-right: 0.5rem !important;
    padding-left: 0.5rem !important;
    margin-bottom: 1rem !important;
}

/* Desktop: 4 kolom - PAKSA! */
@media (min-width: 992px) {
    .qurban-section .row-stats .col-stat-item {
        width: 25% !important;
        max-width: 25% !important;
        flex: 0 0 25% !important;
    }
}

/* Tablet: 2 kolom */
@media (min-width: 576px) and (max-width: 991px) {
    .qurban-section .row-stats .col-stat-item {
        width: 50% !important;
        max-width: 50% !important;
        flex: 0 0 50% !important;
    }
}

/* Mobile: 2 kolom (biar muat) */
@media (max-width: 575px) {
    .qurban-section .row-stats .col-stat-item {
        width: 50% !important;
        max-width: 50% !important;
        flex: 0 0 50% !important;
    }
}

/* Custom Grid untuk Qurban Cards - Paksa 3 kolom */
.qurban-section .row-qurban {
    display: flex !important;
    flex-wrap: wrap !important;
    margin-right: -0.5rem !important;
    margin-left: -0.5rem !important;
}

.qurban-section .col-qurban-item {
    flex: 0 0 auto !important;
    width: 100% !important;
    padding-right: 0.5rem !important;
    padding-left: 0.5rem !important;
    margin-bottom: 1rem !important;
}

/* Desktop: 3 kolom */
@media (min-width: 768px) {
    .qurban-section .row-qurban .col-qurban-item {
        width: 33.333333% !important;
        max-width: 33.333333% !important;
        flex: 0 0 33.333333% !important;
    }
}

/* Tablet: 2 kolom */
@media (min-width: 576px) and (max-width: 767px) {
    .qurban-section .row-qurban .col-qurban-item {
        width: 50% !important;
        max-width: 50% !important;
        flex: 0 0 50% !important;
    }
}

/* Mobile: 1 kolom */
@media (max-width: 575px) {
    .qurban-section .row-qurban .col-qurban-item {
        width: 100% !important;
        max-width: 100% !important;
        flex: 0 0 100% !important;
    }
}

/* Year Badge - Minimalist Style */
.year-badge {
    display: inline-block;
    padding: 8px 24px;
    font-size: 0.875rem;
    font-weight: 600;
    color: #059669;
    background: rgba(5, 150, 105, 0.1);
    border-radius: 50px;
    border: 1px solid rgba(5, 150, 105, 0.2);
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

.year-badge:hover {
    background: rgba(5, 150, 105, 0.15);
    border-color: rgba(5, 150, 105, 0.3);
    transform: translateY(-2px);
}

/* Section Title */
.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: #2d3748;
    margin-bottom: 1rem;
    letter-spacing: -0.5px;
}

/* Section Subtitle */
.section-subtitle {
    font-size: 1.125rem;
    color: #718096;
    max-width: 600px;
    line-height: 1.7;
}

/* Responsive */
@media (max-width: 768px) {
    .section-title {
        font-size: 2rem;
    }

    .section-subtitle {
        font-size: 1rem;
    }

    .year-badge {
        font-size: 0.813rem;
        padding: 6px 20px;
    }
}

/* ============================================
   STATISTIK CARDS
   ============================================ */

.stat-card {
    background: white;
    border-radius: 20px;
    padding: 30px 25px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    display: flex;
    align-items: center;
    gap: 20px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    flex-shrink: 0;
}

.stat-icon i {
    color: white;
}

.bg-gradient-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.bg-gradient-success {
    background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
}

.bg-gradient-danger {
    background: linear-gradient(135deg, #ee0979 0%, #ff6a00 100%);
}

.bg-gradient-info {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

.stat-content {
    flex: 1;
}

.stat-number {
    font-size: 32px;
    font-weight: 700;
    margin: 0;
    color: #2d3748;
    line-height: 1;
}

.stat-label {
    margin: 5px 0 0 0;
    font-size: 14px;
    color: #718096;
    font-weight: 500;
}

/* ============================================
   QURBAN CARDS
   ============================================ */

.qurban-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid #e2e8f0;
    position: relative;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.qurban-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    border-color: #667eea;
}

.qurban-card.card-full {
    opacity: 0.85;
}

/* Card Badge */
.card-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 10;
}

.badge-status {
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 10px;
    font-weight: 700;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
    display: inline-flex;
    align-items: center;
    gap: 2px;
}

.badge-available {
    background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
    color: white;
}

.badge-full {
    background: linear-gradient(135deg, #ee0979 0%, #ff6a00 100%);
    color: white;
}

/* Card Header */
.card-header-custom {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 16px;
    text-align: center;
    position: relative;
}

.animal-icon {
    font-size: 32px;
    margin-bottom: 6px;
}

.card-title {
    font-size: 14px;
    font-weight: 700;
    color: #2d3748;
    margin: 6px 0;
    line-height: 1.3;
}

.animal-type {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 10px;
    font-weight: 600;
    color: white;
}

.animal-type.kambing {
    background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
}

.animal-type.domba {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

.animal-type.sapi {
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
}

.animal-type.kerbau {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.animal-type.unta {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

/* Progress Section */
.progress-section {
    padding: 12px 16px;
    background: white;
}

.progress-label {
    font-size: 11px;
    color: #718096;
    font-weight: 500;
}

.progress-value {
    font-size: 11px;
    color: #2d3748;
    font-weight: 600;
}

.custom-progress {
    height: 6px;
    background: #e2e8f0;
    border-radius: 10px;
    overflow: hidden;
}

.custom-progress-bar {
    height: 100%;
    border-radius: 10px;
    transition: width 1s ease;
}

.custom-progress-bar.available {
    background: linear-gradient(90deg, #11998e 0%, #38ef7d 100%);
}

.custom-progress-bar.almost-full {
    background: linear-gradient(90deg, #fa709a 0%, #fee140 100%);
}

.custom-progress-bar.full {
    background: linear-gradient(90deg, #ee0979 0%, #ff6a00 100%);
}

/* Peserta Section */
.peserta-section {
    padding: 12px 16px;
    background: #f8f9fa;
    flex: 1;
}

.peserta-title {
    font-size: 11px;
    font-weight: 700;
    color: #2d3748;
    margin-bottom: 8px;
}

.peserta-list {
    max-height: 100px;
    overflow-y: auto;
}

.peserta-list::-webkit-scrollbar {
    width: 4px;
}

.peserta-list::-webkit-scrollbar-track {
    background: transparent;
}

.peserta-list::-webkit-scrollbar-thumb {
    background: #cbd5e0;
    border-radius: 10px;
}

.peserta-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 10px;
    background: white;
    border-radius: 6px;
    margin-bottom: 4px;
}

.peserta-number {
    width: 20px;
    height: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: 700;
    margin-right: 8px;
    flex-shrink: 0;
}

.peserta-name {
    flex: 1;
    font-size: 11px;
    color: #2d3748;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.peserta-more {
    text-align: center;
    padding: 6px;
    font-size: 10px;
    color: #667eea;
    font-weight: 600;
}

.peserta-section.empty {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 80px;
}

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

.empty-state i {
    font-size: 28px;
    color: #cbd5e0;
    margin-bottom: 4px;
}

.empty-state p {
    color: #a0aec0;
    margin: 0;
    font-size: 11px;
}

/* Card Footer */
.card-footer-custom {
    padding: 12px 16px;
    background: white;
    margin-top: auto;
}

.btn-custom {
    width: 100%;
    padding: 8px 16px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 12px;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

.btn-primary-gradient {
    background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(17, 153, 142, 0.4);
}

.btn-primary-gradient:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(17, 153, 142, 0.5);
    color: white;
}

.btn-disabled {
    background: #e2e8f0;
    color: #a0aec0;
    cursor: not-allowed;
}

/* Empty State */
.empty-kelompok {
    text-align: center;
    padding: 80px 20px;
    background: white;
    border-radius: 24px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
}

.empty-icon {
    font-size: 80px;
    margin-bottom: 20px;
}

.empty-kelompok h4 {
    font-size: 24px;
    font-weight: 700;
    color: #2d3748;
    margin-bottom: 10px;
}

.empty-kelompok p {
    color: #718096;
    font-size: 16px;
}

/* ============================================
   CTA BANNER
   ============================================ */

.cta-banner {
    background: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
    border-radius: 24px;
    padding: 40px;
    box-shadow: 0 10px 40px rgba(17, 153, 142, 0.3);
}

.cta-content {
    color: white;
}

.cta-title {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 10px;
    color: white;
}

.cta-text {
    font-size: 16px;
    margin: 0;
    opacity: 0.95;
}

.btn-whatsapp {
    background: white;
    color: #25d366;
    padding: 14px 32px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 16px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    transition: all 0.3s;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.btn-whatsapp:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
    color: #25d366;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 991px) {
    .stat-card {
        padding: 20px;
        gap: 15px;
    }

    .stat-icon {
        width: 50px;
        height: 50px;
        font-size: 24px;
    }

    .stat-number {
        font-size: 24px;
    }

    .cta-banner {
        padding: 30px;
    }

    .cta-title {
        font-size: 22px;
    }
}

@media (max-width: 767px) {
    .stat-card {
        flex-direction: column;
        text-align: center;
        padding: 25px 20px;
    }

    .stat-number {
        font-size: 28px;
    }

    .card-title {
        font-size: 18px;
    }

    .animal-icon {
        font-size: 48px;
    }

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

    .btn-whatsapp {
        width: 100%;
        justify-content: center;
    }
}

input[readonly] {
    background-color: #f5f5f5 !important;
    cursor: not-allowed !important;
    color: #666;
}

#amountNote {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem;
    background: #e3f2fd;
    border-radius: 4px;
    font-size: 0.9em;
}
