/* MyZakat - Professional & Educational UI 
   Fokus: Kerapihan Literasi & Tipografi Premium
*/

/* 1. DASAR & RESET */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', -apple-system, sans-serif;
    scroll-behavior: smooth;
}

body {
    background-color: #ffffff;
    color: #1a1a1a;
    line-height: 1.6;
}

/* 2. SISTEM BINTANG HITAM */
.stars-container {
    position: fixed;
    inset: 0;
    z-index: -1;
    background-color: #ffffff;
}

.star {
    position: absolute;
    background: linear-gradient(90deg, #000, transparent);
    height: 1px;
    opacity: 0.08;
    animation: shooting 4s linear infinite;
}

@keyframes shooting {
    0% { transform: rotate(-35deg) translateX(0); opacity: 0; }
    10% { opacity: 1; }
    100% { transform: rotate(-35deg) translateX(-800px); opacity: 0; }
}

/* 3. NAVBAR MODERN */
.navbar {
    position: sticky;
    top: 0;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(15px);
    border-bottom: 1px solid #f0f0f0;
    z-index: 1000;
}

.nav-wrap {
    max-width: 1100px;
    margin: 0 auto;
    padding: 15px 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 24px;
    font-weight: 900;
    letter-spacing: -1.5px;
}

.menu {
    list-style: none;
    display: flex;
    gap: 30px;
}

.menu a {
    text-decoration: none;
    color: #555;
    font-size: 14px;
    font-weight: 600;
    transition: 0.3s;
}

.menu a:hover { color: #000; }

/* 4. HERO SECTION */
.hero {
    text-align: center;
    padding: 120px 25px 80px;
    max-width: 900px;
    margin: 0 auto;
}

.hero h1 {
    font-family: 'Playfair Display', serif;
    font-size: clamp(40px, 8vw, 68px);
    font-weight: 900;
    line-height: 1.1;
    margin-bottom: 25px;
    letter-spacing: -1px;
}

.hero p {
    color: #666;
    font-size: 19px;
    margin-bottom: 40px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

#startBtn {
    background: #000;
    color: #fff;
    border: none;
    padding: 18px 45px;
    font-size: 16px;
    font-weight: 700;
    border-radius: 50px; /* Pill shape */
    cursor: pointer;
    transition: 0.4s;
}

#startBtn:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.15);
}

/* 5. LITERASI & DALIL */
.main-info {
    max-width: 1000px;
    margin: 60px auto;
    padding: 0 25px;
}

.box {
    background: #fff;
    border: 1px solid #f0f0f0;
    padding: 50px;
    border-radius: 32px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.03);
}

.tag {
    display: inline-block;
    background: #f0f0f0;
    padding: 6px 14px;
    border-radius: 100px;
    font-size: 12px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 20px;
}

.section-title {
    font-size: 32px;
    font-weight: 800;
    margin-bottom: 20px;
}

.intro-text {
    font-size: 17px;
    color: #444;
    margin-bottom: 25px;
}

blockquote {
    border-left: 4px solid #000;
    padding: 20px 30px;
    margin: 30px 0;
    background: #fafafa;
    font-family: 'Playfair Display', serif;
    font-size: 20px;
    font-style: italic;
    color: #222;
}

blockquote span {
    display: block;
    margin-top: 10px;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    font-style: normal;
    color: #888;
}

/* 6. MAZHAB GRID */
.sub-title {
    text-align: center;
    font-size: 32px;
    font-weight: 800;
    margin-bottom: 10px;
}

.mazhab-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 25px;
    margin-top: 40px;
}

.mazhab-card {
    background: #fff;
    border: 1px solid #eee;
    padding: 30px;
    border-radius: 24px;
    transition: 0.3s ease;
}

.mazhab-card:hover {
    border-color: #000;
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.05);
}

.m-header {
    margin-bottom: 20px;
    border-bottom: 1px solid #f0f0f0;
    padding-bottom: 15px;
}

.m-header h3 {
    font-size: 20px;
    font-weight: 800;
    margin-bottom: 5px;
}

.focus {
    font-size: 11px;
    font-weight: 700;
    color: #007bff;
    text-transform: uppercase;
}

.mazhab-card p {
    font-size: 14px;
    color: #555;
    margin-bottom: 20px;
}

.dalil-note {
    font-size: 12px;
    color: #999;
    font-style: italic;
    display: block;
}

/* 7. KALKULATOR AREA */
.main {
    max-width: 550px;
    margin: 80px auto;
    padding: 0 25px;
}

.calc-box {
    background: #fff;
    border: 2px solid #000; /* Lebih tegas untuk kalkulator */
    padding: 40px;
    border-radius: 32px;
}

.input-group { margin-bottom: 25px; }

.label-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.auto-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    font-weight: 600;
}

.input-group input[type="text"] {
    width: 100%;
    padding: 16px;
    background: #f9f9f9;
    border: 1px solid #e0e0e0;
    border-radius: 14px;
    font-size: 16px;
    transition: 0.2s;
}

.input-group input:focus {
    background: #fff;
    border-color: #000;
    outline: none;
    box-shadow: 0 0 0 4px rgba(0,0,0,0.05);
}

#hitungZakat {
    width: 100%;
    padding: 20px;
    background: #000;
    color: #fff;
    border: none;
    border-radius: 14px;
    font-weight: 700;
    font-size: 16px;
    cursor: pointer;
    transition: 0.3s;
}

/* 8. LEMBAGA LINKS */
.lembaga-links {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 25px;
}

.lembaga-links a {
    text-decoration: none;
    color: #000;
    border: 1px solid #000;
    padding: 12px 24px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 700;
    transition: 0.3s;
}

.lembaga-links a:hover {
    background: #000;
    color: #fff;
}

/* 9. MODAL */
.modal {
    position: fixed;
    inset: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}

.modal.show { display: flex; }

.modal-box {
    background: #fff;
    padding: 50px;
    border-radius: 32px;
    border: 1px solid #eee;
    max-width: 500px;
    width: 100%;
    box-shadow: 0 40px 80px rgba(0,0,0,0.1);
}

/* FIX: STYLE TOMBOL DI DALAM MODAL */
.modal-btn {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

.modal-btn button {
    flex: 1;
    padding: 14px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: 0.3s;
}

#closeModal {
    background: #f5f5f5;
    color: #666;
    border: 1px solid #eee;
}

#closeModal:hover {
    background: #eeeeee;
}

#confirmBtn.primary {
    background: #000;
    color: #fff;
    border: none;
}

#confirmBtn.primary:hover {
    background: #333;
    transform: translateY(-2px);
}

/* 10. UTILITIES */
.hidden { display: none; }
.fade-in { animation: fadeIn 0.8s ease-out forwards; }

/* FIX: STYLE UNTUK LIST TOMBOL MAZHAB */
.list {
    display: grid;
    gap: 12px;
    margin-top: 25px;
}

.list button {
    width: 100%;
    padding: 18px 25px;
    text-align: left;
    background: #fcfcfc;
    border: 1px solid #eeeeee;
    border-radius: 16px;
    font-size: 15px;
    font-weight: 600;
    color: #1a1a1a;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.list button:hover {
    background: #ffffff;
    border-color: #000;
    transform: translateX(5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

/* Tambahan hiasan panah di tombol */
.list button::after {
    content: '→';
    font-size: 18px;
    opacity: 0.3;
}

.list button:hover::after {
    opacity: 1;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 768px) {
    .nav-wrap { justify-content: center; }
    .menu { display: none; }
    .hero h1 { font-size: 42px; }
    .box { padding: 30px; }
}

/* FIX INPUT JUMLAH ORANG BIAR CAKEP */
#jumlahJiwa {
    width: 100%;
    padding: 16px;
    background: #f9f9f9;
    border: 1px solid #e0e0e0;
    border-radius: 14px;
    font-size: 16px;
    outline: none;
    transition: 0.2s;
    margin-bottom: 20px;
}

#jumlahJiwa:focus {
    background: #fff;
    border-color: #000;
    box-shadow: 0 0 0 4px rgba(0,0,0,0.05);
}

/* Hilangin tanda panah di input number biar clean */
input#jumlahJiwa::-webkit-outer-spin-button,
input#jumlahJiwa::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Styling Tombol Hitung */
.btn-hitung, #hitungZakat, #hitungFitrah {
    width: 100%;
    padding: 20px;
    background: #000;
    color: #fff;
    border: none;
    border-radius: 14px;
    font-weight: 700;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
}

.btn-hitung:hover, #hitungZakat:hover, #hitungFitrah:hover {
    background: #333;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.btn-hitung:active, #hitungZakat:active, #hitungFitrah:active {
    transform: translateY(0);
}