* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px;
    color: #333;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

header {
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    color: white;
    padding: 30px;
    text-align: center;
    border-bottom: 4px solid #ffd700;
}

header h1 {
    font-size: 2.5em;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.subtitle {
    font-size: 1.2em;
    opacity: 0.9;
    font-weight: 300;
}

.content-wrapper {
    display: flex;
    min-height: 600px;
}

.sidebar {
    width: 320px;
    background: linear-gradient(180deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 25px;
    border-right: 3px solid #ddd;
    overflow-y: auto;
    max-height: calc(100vh - 200px);
}

.sidebar h2 {
    color: #2a5298;
    margin-bottom: 20px;
    font-size: 1.5em;
    border-bottom: 2px solid #ffd700;
    padding-bottom: 10px;
}

.hadith-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.hadith-button {
    background: white;
    border: 2px solid #2a5298;
    border-radius: 12px;
    padding: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: left;
    font-size: 1em;
    color: #2a5298;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.hadith-button:hover {
    background: linear-gradient(135deg, #2a5298 0%, #1e3c72 100%);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(42, 82, 152, 0.4);
}

.hadith-button.active {
    background: linear-gradient(135deg, #2a5298 0%, #1e3c72 100%);
    color: white;
    border-color: #ffd700;
    box-shadow: 0 4px 16px rgba(42, 82, 152, 0.5);
}

.main-content {
    flex: 1;
    padding: 40px;
    overflow-y: auto;
    max-height: calc(100vh - 200px);
}

.hadith-display {
    background: white;
    border-radius: 15px;
    padding: 35px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    border: 2px solid #e9ecef;
}

.welcome-message {
    text-align: center;
    padding: 60px 20px;
    color: #6c757d;
}

.welcome-message h2 {
    font-size: 2em;
    margin-bottom: 15px;
    color: #2a5298;
}

.hadith-header {
    background: linear-gradient(135deg, #2a5298 0%, #1e3c72 100%);
    color: white;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 25px;
    border-left: 5px solid #ffd700;
}

.hadith-number {
    font-size: 1.3em;
    font-weight: bold;
    margin-bottom: 5px;
}

.hadith-topic {
    font-size: 1.5em;
    font-weight: 600;
}

.hadith-section {
    margin-bottom: 25px;
}

.section-title {
    color: #2a5298;
    font-size: 1.3em;
    font-weight: 700;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 2px solid #ffd700;
    display: flex;
    align-items: center;
    gap: 10px;
}

.section-content {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 10px;
    border-left: 4px solid #2a5298;
    line-height: 1.8;
    font-size: 1.05em;
    color: #495057;
    text-align: justify;
}

.narrator-info {
    background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%);
    padding: 15px;
    border-radius: 8px;
    border-left: 4px solid #2196f3;
    margin-top: 10px;
    font-style: italic;
    color: #1565c0;
}

.reference-info {
    background: linear-gradient(135deg, #fff3e0 0%, #ffe0b2 100%);
    padding: 15px;
    border-radius: 8px;
    margin-top: 20px;
    font-size: 0.95em;
    color: #e65100;
    font-weight: 600;
    border: 2px solid #ffb74d;
}

@media (max-width: 768px) {
    .content-wrapper {
        flex-direction: column;
    }

    .sidebar {
        width: 100%;
        max-height: 300px;
        border-right: none;
        border-bottom: 3px solid #ddd;
    }

    .main-content {
        padding: 20px;
    }

    header h1 {
        font-size: 1.8em;
    }
}

::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: #2a5298;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: #1e3c72;
}