/* ==========================================================================
   HISTORY UNCOVERED - Cinematic Historical Theme Stylesheet
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@400;600;700;800;900&family=Cinzel+Decorative:wght@700;900&family=Cinzel:wght@500;700;800;900&family=Inter:wght@300;400;600;700&display=swap');

:root {
    --bg-obsidian: #08090c;
    --bg-charcoal: #12151e;
    --bg-card: rgba(18, 22, 32, 0.85);
    --bg-card-hover: rgba(26, 32, 46, 0.95);
    
    --gold-primary: #d4af37;
    --gold-light: #f6e07f;
    --gold-dark: #aa7c11;
    --gold-gradient: linear-gradient(135deg, #d4af37 0%, #f6e07f 50%, #aa7c11 100%);
    --gold-glow: 0 0 20px rgba(212, 175, 55, 0.35);
    
    --crimson-accent: #c0392b;
    --crimson-glow: 0 0 15px rgba(192, 57, 43, 0.4);
    
    --text-primary: #ffffff;
    --text-parchment: #e6d5b8;
    --text-muted: #9aa0a6;
    --text-dim: #6c757d;
    
    --border-gold: rgba(212, 175, 55, 0.25);
    --border-gold-bright: rgba(212, 175, 55, 0.6);
    --border-glass: rgba(255, 255, 255, 0.08);
    
    --font-heading: 'Cinzel', 'Cairo', serif;
    --font-heading-deco: 'Cinzel Decorative', 'Cairo', serif;
    --font-body: 'Inter', 'Cairo', sans-serif;
    --font-arabic: 'Cairo', sans-serif;
}

/* Reset & Base Styles */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--bg-obsidian);
    color: var(--text-parchment);
    font-family: var(--font-body);
    font-size: 1rem;
    line-height: 1.6;
    overflow-x: hidden;
    background-image: 
        radial-gradient(circle at 15% 20%, rgba(212, 175, 55, 0.03) 0%, transparent 40%),
        radial-gradient(circle at 85% 80%, rgba(192, 57, 43, 0.03) 0%, transparent 40%);
    background-attachment: fixed;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    color: var(--text-primary);
    font-weight: 700;
    letter-spacing: 0.5px;
}

.font-deco {
    font-family: var(--font-heading-deco);
}

.text-gold {
    color: var(--gold-primary) !important;
}

.text-gold-gradient {
    background: var(--gold-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

.text-crimson {
    color: var(--crimson-accent) !important;
}

.text-parchment {
    color: var(--text-parchment) !important;
}

a {
    color: var(--gold-primary);
    text-decoration: none;
    transition: all 0.3s ease;
}

a:hover {
    color: var(--gold-light);
}

/* Header & Navigation */
.site-navbar {
    background: rgba(8, 9, 12, 0.92);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-gold);
    padding: 12px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: all 0.3s ease;
}

.brand-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.brand-logo-icon {
    width: 45px;
    height: 45px;
    background: linear-gradient(135deg, #1f2430, #08090c);
    border: 2px solid var(--gold-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    box-shadow: var(--gold-glow);
}

.brand-logo-text {
    font-family: var(--font-heading);
    font-size: 1.4rem;
    font-weight: 900;
    letter-spacing: 1.5px;
    color: var(--gold-primary);
    line-height: 1.1;
}

.brand-logo-subtext {
    font-size: 0.65rem;
    letter-spacing: 2px;
    color: var(--text-muted);
    text-transform: uppercase;
    display: block;
}

/* Nav Menu Items */
.navbar-nav .nav-item {
    position: relative;
    margin: 0 4px;
}

.navbar-nav .nav-link {
    color: var(--text-parchment) !important;
    font-family: var(--font-heading);
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 1px;
    padding: 10px 14px !important;
    border-radius: 6px;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    color: var(--gold-primary) !important;
    background: rgba(212, 175, 55, 0.08);
}

/* Dropdown Custom Styling */
.nav-item.dropdown:hover .dropdown-menu {
    display: block;
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu {
    display: block;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    background: rgba(14, 17, 25, 0.98);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-gold);
    border-radius: 12px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.8);
    padding: 10px;
    min-width: 230px;
    margin-top: 5px;
}

.dropdown-item {
    color: var(--text-parchment);
    font-size: 0.88rem;
    padding: 10px 16px;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.25s ease;
    display: flex;
    align-items: center;
    gap: 10px;
}

.dropdown-item:hover {
    background: rgba(212, 175, 55, 0.12);
    color: var(--gold-light);
    transform: translateX(isAr() ? -4px : 4px);
}

.dropdown-item i {
    color: var(--gold-primary);
    width: 18px;
    text-align: center;
}

.dropdown-divider {
    border-top-color: var(--border-gold);
    opacity: 0.3;
}

/* Hero Section */
.hero-section {
    position: relative;
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(180deg, rgba(8,9,12,0.4) 0%, rgba(8,9,12,0.95) 100%),
                url('https://images.unsplash.com/photo-1578632767115-351597cf2477?w=1600') center/cover no-repeat;
    border-bottom: 2px solid var(--border-gold);
    padding: 100px 0 80px;
    overflow: hidden;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, rgba(8,9,12,0.2) 0%, rgba(8,9,12,0.9) 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 18px;
    background: rgba(212, 175, 55, 0.12);
    border: 1px solid var(--gold-primary);
    border-radius: 50px;
    color: var(--gold-light);
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 1px;
    margin-bottom: 20px;
    box-shadow: var(--gold-glow);
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 900;
    line-height: 1.2;
    margin-bottom: 20px;
    text-shadow: 0 4px 20px rgba(0,0,0,0.8);
}

.hero-subtitle {
    font-size: 1.2rem;
    color: var(--text-parchment);
    max-width: 750px;
    margin: 0 auto 35px;
    line-height: 1.7;
    opacity: 0.9;
}

/* Custom Buttons */
.btn-gold {
    background: var(--gold-gradient);
    color: #000 !important;
    font-weight: 800;
    font-family: var(--font-heading);
    letter-spacing: 1px;
    border: none;
    padding: 12px 28px;
    border-radius: 8px;
    transition: all 0.3s ease;
    box-shadow: var(--gold-glow);
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.btn-gold:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 30px rgba(212, 175, 55, 0.6);
    color: #000 !important;
}

.btn-outline-gold {
    background: transparent;
    color: var(--gold-primary) !important;
    border: 1.5px solid var(--gold-primary);
    font-weight: 700;
    font-family: var(--font-heading);
    padding: 11px 26px;
    border-radius: 8px;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.btn-outline-gold:hover {
    background: rgba(212, 175, 55, 0.15);
    color: var(--gold-light) !important;
    border-color: var(--gold-light);
    transform: translateY(-2px);
}

/* Section Controls */
.section-header {
    margin-bottom: 40px;
    position: relative;
}

.section-title {
    font-size: 2.2rem;
    font-weight: 800;
    position: relative;
    display: inline-block;
    padding-bottom: 12px;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background: var(--gold-gradient);
    border-radius: 3px;
}

[dir="rtl"] .section-title::after {
    left: auto;
    right: 0;
}

.section-subtitle {
    color: var(--text-muted);
    font-size: 1rem;
    margin-top: 8px;
}

/* Cards & Grid Styling */
.history-card {
    background: var(--bg-card);
    border: 1px solid var(--border-gold);
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    height: 100%;
    display: flex;
    flex-direction: column;
    position: relative;
}

.history-card:hover {
    transform: translateY(-6px);
    border-color: var(--border-gold-bright);
    box-shadow: 0 12px 35px rgba(0, 0, 0, 0.7), var(--gold-glow);
    background: var(--bg-card-hover);
}

.card-img-wrapper {
    position: relative;
    width: 100%;
    padding-top: 60%;
    overflow: hidden;
    background: #000;
}

.card-img-wrapper img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.history-card:hover .card-img-wrapper img {
    transform: scale(1.08);
}

.card-tag {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(8, 9, 12, 0.85);
    backdrop-filter: blur(8px);
    border: 1px solid var(--gold-primary);
    color: var(--gold-light);
    font-size: 0.75rem;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 50px;
    z-index: 2;
}

[dir="rtl"] .card-tag {
    right: auto;
    left: 15px;
}

.card-body-content {
    padding: 22px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.card-meta {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 10px;
}

.card-meta i {
    color: var(--gold-primary);
}

.card-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 12px;
    line-height: 1.4;
}

.card-title a {
    color: var(--text-primary);
}

.card-title a:hover {
    color: var(--gold-primary);
}

.card-excerpt {
    color: var(--text-parchment);
    font-size: 0.9rem;
    opacity: 0.85;
    margin-bottom: 20px;
    flex-grow: 1;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-footer-info {
    border-top: 1px solid var(--border-glass);
    padding-top: 15px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.85rem;
    color: var(--gold-primary);
    font-weight: 600;
}

/* Video Card Special Styling */
.play-btn-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.4);
    transition: background 0.3s ease;
}

.play-btn-icon {
    width: 55px;
    height: 55px;
    background: var(--gold-gradient);
    color: #000;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    box-shadow: 0 0 25px rgba(212, 175, 55, 0.7);
    transition: transform 0.3s ease;
}

.history-card:hover .play-btn-icon {
    transform: scale(1.15);
}

.video-duration {
    position: absolute;
    bottom: 12px;
    right: 12px;
    background: rgba(0, 0, 0, 0.85);
    color: #fff;
    font-size: 0.75rem;
    padding: 3px 8px;
    border-radius: 4px;
    font-weight: 600;
}

/* Category Pill Badges */
.category-pill {
    display: inline-block;
    padding: 8px 18px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-glass);
    border-radius: 50px;
    color: var(--text-parchment);
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.3s ease;
    margin: 4px;
}

.category-pill:hover,
.category-pill.active {
    background: rgba(212, 175, 55, 0.15);
    border-color: var(--gold-primary);
    color: var(--gold-light);
}

/* Samurai Hub Header */
.samurai-hub-hero {
    background: linear-gradient(180deg, rgba(8,9,12,0.6) 0%, rgba(8,9,12,0.98) 100%),
                url('https://images.unsplash.com/photo-1578632767115-351597cf2477?w=1600') center/cover no-repeat;
    border-bottom: 2px solid var(--gold-primary);
    padding: 90px 0 50px;
}

.samurai-nav-tabs {
    border-bottom: 1px solid var(--border-gold);
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    margin-top: 30px;
}

.samurai-nav-tabs .nav-link {
    color: var(--text-parchment);
    background: rgba(18, 22, 32, 0.8);
    border: 1px solid var(--border-gold);
    border-radius: 8px 8px 0 0;
    padding: 10px 20px;
    font-weight: 700;
    font-family: var(--font-heading);
    transition: all 0.3s ease;
}

.samurai-nav-tabs .nav-link:hover,
.samurai-nav-tabs .nav-link.active {
    background: var(--gold-gradient);
    color: #000 !important;
    border-color: var(--gold-light);
}

/* Footer Styling */
.site-footer {
    background: #050608;
    border-top: 1px solid var(--border-gold);
    color: var(--text-muted);
    padding: 70px 0 30px;
    position: relative;
}

.footer-brand-title {
    font-family: var(--font-heading);
    font-size: 1.6rem;
    font-weight: 900;
    color: var(--gold-primary);
    letter-spacing: 2px;
    margin-bottom: 15px;
}

.footer-column-title {
    font-family: var(--font-heading);
    color: var(--text-primary);
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 22px;
    position: relative;
    padding-bottom: 8px;
}

.footer-column-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 35px;
    height: 2px;
    background: var(--gold-primary);
}

[dir="rtl"] .footer-column-title::after {
    left: auto;
    right: 0;
}

.footer-links {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: var(--text-muted);
    font-size: 0.9rem;
    transition: all 0.25s ease;
}

.footer-links a:hover {
    color: var(--gold-primary);
    padding-left: isAr() ? 0 : 5px;
    padding-right: isAr() ? 5px : 0;
}

.social-links {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

.social-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-glass);
    color: var(--text-parchment);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    transition: all 0.3s ease;
}

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

.footer-bottom {
    border-top: 1px solid var(--border-glass);
    margin-top: 50px;
    padding-top: 25px;
    text-align: center;
    font-size: 0.85rem;
    color: var(--text-dim);
}

/* Modal Search Custom */
.search-modal-content {
    background: rgba(14, 17, 25, 0.98);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-gold);
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.9);
}

.search-input-lg {
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--border-gold);
    color: #fff;
    font-size: 1.2rem;
    padding: 15px 20px;
    border-radius: 10px;
}

.search-input-lg:focus {
    background: rgba(255,255,255,0.08);
    border-color: var(--gold-primary);
    color: #fff;
    box-shadow: var(--gold-glow);
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-obsidian);
}

::-webkit-scrollbar-thumb {
    background: rgba(212, 175, 55, 0.4);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--gold-primary);
}

/* Responsive adjustments */
@media (max-width: 991px) {
    .hero-title {
        font-size: 2.3rem;
    }
    .navbar-collapse {
        background: rgba(12, 15, 22, 0.98);
        border: 1px solid var(--border-gold);
        border-radius: 12px;
        padding: 20px;
        margin-top: 15px;
    }
    .dropdown-menu {
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        background: transparent;
        border: none;
        padding-left: 20px;
    }
}
