/* Afar Culture Website - Main Stylesheet */

:root {
    --primary-blue: #1a3a5c;
    --secondary-blue: #2c5f7c;
    --accent-gold: #ffd700;
    --light-blue: #4a90b8;
    --dark-blue: #0f2640;
    --text-dark: #333333;
    --text-light: #666666;
    --text-muted: #999999;
    --bg-light: #f8f9fa;
    --bg-white: #ffffff;
    --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 5px 20px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 15px 40px rgba(0, 0, 0, 0.12);
    --border-radius: 12px;
    --transition: all 0.3s ease;
}

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

body {
    font-family: 'Poppins', sans-serif;
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 1rem;
}

h1 {
    font-size: 3rem;
}

h2 {
    font-size: 2.5rem;
}

h3 {
    font-size: 1.75rem;
}

p {
    margin-bottom: 1rem;
    color: var(--text-light);
}

a {
    text-decoration: none;
    transition: var(--transition);
}

/* Buttons */
.btn {
    padding: 12px 28px;
    border-radius: 30px;
    font-weight: 500;
    transition: var(--transition);
    border: none;
}

.btn-primary {
    background: var(--primary-blue);
    color: white;
}

.btn-primary:hover {
    background: var(--secondary-blue);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-gold {
    background: var(--accent-gold);
    color: var(--primary-blue);
    font-weight: 600;
}

.btn-gold:hover {
    background: #e6c200;
    transform: translateY(-2px);
}

.btn-outline-light {
    border: 2px solid white;
    color: white;
}

.btn-outline-light:hover {
    background: white;
    color: var(--primary-blue);
}

/* Navigation */
.navbar {
    padding: 1rem 0;
    transition: var(--transition);
}

.navbar.scrolled {
    padding: 0.5rem 0;
    background: rgba(26, 58, 92, 0.98) !important;
    backdrop-filter: blur(10px);
}

.navbar-brand {
    font-weight: 700;
    font-size: 1.5rem;
}

.nav-link {
    font-weight: 500;
    padding: 0.5rem 1rem !important;
}

/* Hero Section */
.hero-section {
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(26, 58, 92, 0.9) 0%, rgba(44, 95, 124, 0.85) 100%);
    z-index: 1;
}

.hero-section .container {
    position: relative;
    z-index: 2;
}

/* Cards */
.card {
    border: none;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    overflow: hidden;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.card-img-top {
    height: 200px;
    object-fit: cover;
}

/* Feature Icons */
.feature-icon {
    width: 70px;
    height: 70px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.feature-icon i {
    font-size: 2rem;
    color: white;
}

/* Section Styles */
.section-padding {
    padding: 80px 0;
}

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

.section-title h2 {
    color: var(--primary-blue);
    margin-bottom: 0.5rem;
}

.section-title .underline {
    width: 80px;
    height: 4px;
    background: var(--accent-gold);
    margin: 0 auto;
}

/* Background Colors */
.bg-primary-blue {
    background: var(--primary-blue);
}

.bg-secondary-blue {
    background: var(--secondary-blue);
}

.bg-light-gray {
    background: var(--bg-light);
}

.bg-gradient {
    background: linear-gradient(135deg, var(--primary-blue) 0%, var(--secondary-blue) 100%);
}

/* Stats Counter */
.stat-box {
    text-align: center;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--border-radius);
    backdrop-filter: blur(10px);
}

.stat-number {
    font-size: 3rem;
    font-weight: 700;
    color: var(--accent-gold);
    margin-bottom: 0.5rem;
}

.stat-label {
    color: white;
    font-size: 1.1rem;
    opacity: 0.9;
}

/* Gallery */
.gallery-item {
    position: relative;
    border-radius: var(--border-radius);
    overflow: hidden;
    cursor: pointer;
}

.gallery-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.gallery-item:hover img {
    transform: scale(1.1);
}

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

.gallery-item:hover .gallery-overlay {
    bottom: 0;
}

/* Testimonials */
.testimonial-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 2rem;
    box-shadow: var(--shadow-md);
    margin: 1rem 0;
}

.testimonial-text {
    font-style: italic;
    margin-bottom: 1.5rem;
    position: relative;
}

.testimonial-text::before {
    content: '"';
    font-size: 4rem;
    color: var(--accent-gold);
    opacity: 0.3;
    position: absolute;
    top: -20px;
    left: -10px;
}

.testimonial-author {
    display: flex;
    align-items: center;
}

.testimonial-author img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    margin-right: 1rem;
}

/* Forms */
.form-control {
    border-radius: 30px;
    padding: 12px 20px;
    border: 1px solid #e0e0e0;
    transition: var(--transition);
}

.form-control:focus {
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 0.2rem rgba(26, 58, 92, 0.1);
}

/* Footer */
.footer {
    background: var(--dark-blue);
    color: white;
}

.footer h5 {
    color: var(--accent-gold);
    margin-bottom: 1.5rem;
}

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

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.8);
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--accent-gold);
    padding-left: 5px;
}

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

.social-links a {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    transition: var(--transition);
}

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

/* Back to Top Button */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--primary-blue);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 99;
    box-shadow: var(--shadow-md);
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background: var(--accent-gold);
    color: var(--primary-blue);
    transform: translateY(-5px);
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fadeInUp {
    animation: fadeInUp 0.6s ease forwards;
}

/* Responsive */
@media (max-width: 992px) {
    h1 {
        font-size: 2.5rem;
    }
    
    h2 {
        font-size: 2rem;
    }
    
    .section-padding {
        padding: 60px 0;
    }
}

@media (max-width: 768px) {
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.75rem;
    }
    
    .hero-section {
        padding: 80px 0;
    }
    
    .navbar-collapse {
        background: var(--primary-blue);
        padding: 1rem;
        border-radius: var(--border-radius);
    }
}

@media (max-width: 576px) {
    .container {
        padding-left: 20px;
        padding-right: 20px;
    }
    
    .btn {
        padding: 10px 20px;
    }
}

/* Print Styles */
@media print {
    .navbar,
    .footer,
    .back-to-top,
    .newsletter-section,
    .social-links {
        display: none !important;
    }
    
    body {
        color: black;
    }
    
    a {
        color: black;
        text-decoration: none;
    }
    
    .hero-section {
        background: none;
        color: black;
        padding: 20px 0;
    }
}

/* RTL Support for Arabic/Afar */
[dir="rtl"] {
    text-align: right;
}

[dir="rtl"] .social-links {
    flex-direction: row-reverse;
}

[dir="rtl"] .footer-links a:hover {
    padding-left: 0;
    padding-right: 5px;
}

/* Loading Spinner */
.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid var(--bg-light);
    border-top: 4px solid var(--primary-blue);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Toast Notifications */
.toast {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: white;
    padding: 12px 24px;
    border-radius: 30px;
    box-shadow: var(--shadow-lg);
    z-index: 9999;
    animation: slideUp 0.3s ease;
}

.toast.success {
    background: #d4edda;
    color: #155724;
    border-left: 4px solid #28a745;
}

.toast.error {
    background: #f8d7da;
    color: #721c24;
    border-left: 4px solid #dc3545;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translate(-50%, 20px);
    }
    to {
        opacity: 1;
        transform: translate(-50%, 0);
    }
}

/* =========================
   HERO ANIMATIONS
========================= */

.hero-animate {
  opacity: 0;
  transform: translateY(30px);
  animation: fadeUp 0.8s ease forwards;
}

.hero-animate.delay-1 { animation-delay: 0.2s; }
.hero-animate.delay-2 { animation-delay: 0.4s; }
.hero-animate.delay-3 { animation-delay: 0.6s; }
.hero-animate.delay-4 { animation-delay: 0.8s; }

@keyframes fadeUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* =========================
   HERO TEXT STYLE
========================= */

.hero-title {
  font-size: clamp(2.8rem, 6vw, 5rem);
  font-weight: 800;
  margin-bottom: 20px;
}

.hero-sub {
  font-size: clamp(1.1rem, 2vw, 1.4rem);
  max-width: 750px;
  margin: 0 auto 30px;
  color: rgba(255,255,255,0.9);
  line-height: 1.7;
}

/* =========================
   HERO BUTTONS
========================= */

.hero-buttons {
  display: flex;
  justify-content: center;
  gap: 15px;
  flex-wrap: wrap;
}

.hero-btn {
  padding: 14px 28px;
  border-radius: 999px;
  font-weight: 700;
  text-decoration: none;
  transition: 0.3s ease;
  display: inline-block;
}

/* PRIMARY */
.hero-btn.primary {
  background: linear-gradient(135deg, #1a3a5c, #2c5f7c);
  color: #fff;
}

.hero-btn.primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 25px rgba(0,0,0,0.25);
}

/* SECONDARY */
.hero-btn.secondary {
  background: #ffd700;
  color: #1a3a5c;
}

.hero-btn.secondary:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 25px rgba(0,0,0,0.25);
}

/* GHOST */
.hero-btn.ghost {
  border: 2px solid #fff;
  color: #fff;
}

.hero-btn.ghost:hover {
  background: #fff;
  color: #1a3a5c;
}

@media (max-width: 768px) {
  .hero-buttons {
    flex-direction: column;
    gap: 12px;
  }

  .hero-btn {
    width: 100%;
    text-align: center;
  }
}


/* =========================================================
   FINAL RESPONSIVE + SEO/PERFORMANCE POLISH OVERRIDES
   Safe to keep at the end of style.css
========================================================= */
html, body {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden !important;
}
img, video, iframe {
  max-width: 100%;
}
.navbar, .page-header, .hero-section, .footer, section {
  max-width: 100%;
  overflow-x: clip;
}

/* Home hero: gallery-style background using local cultural image */
.hero-section {
  position: relative !important;
  min-height: 580px !important;
  padding: 90px 0 !important;
  background:
    linear-gradient(rgba(10,35,58,.62), rgba(10,35,58,.72)),
    url("/assets/images/home/cultural-home.jpg") center/cover no-repeat !important;
  background-attachment: scroll !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  text-align: center !important;
  color: #fff !important;
}
.hero-section::before {
  content: "" !important;
  position: absolute !important;
  inset: 0 !important;
  background: radial-gradient(circle at center, rgba(255,255,255,.055), transparent 62%) !important;
  z-index: 1 !important;
  pointer-events: none !important;
}
.hero-section .container {
  position: relative !important;
  z-index: 2 !important;
}
.hero-section h1,
.hero-title {
  font-size: clamp(2.4rem, 5.2vw, 4.7rem) !important;
  line-height: 1.08 !important;
  font-weight: 800 !important;
  color: #fff !important;
  margin-bottom: 18px !important;
  text-shadow: 0 6px 24px rgba(0,0,0,.55) !important;
}
.hero-section p,
.hero-sub {
  max-width: 820px !important;
  margin-left: auto !important;
  margin-right: auto !important;
  font-size: clamp(1.02rem, 1.7vw, 1.32rem) !important;
  line-height: 1.7 !important;
  color: rgba(255,255,255,.94) !important;
  text-shadow: 0 4px 15px rgba(0,0,0,.45) !important;
}
.hero-section .eyebrow,
.eyebrow.hero-animate {
  color: #ffd700 !important;
  font-weight: 800 !important;
  letter-spacing: .22em !important;
  text-transform: uppercase !important;
  text-shadow: 0 3px 10px rgba(0,0,0,.55) !important;
}

/* Modern hero buttons */
.hero-buttons {
  display: flex !important;
  justify-content: center !important;
  gap: 15px !important;
  flex-wrap: wrap !important;
  margin-top: 30px !important;
}
.hero-btn {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 14px 28px !important;
  min-height: 54px !important;
  border-radius: 999px !important;
  font-weight: 800 !important;
  text-decoration: none !important;
  transition: transform .25s ease, box-shadow .25s ease, background .25s ease, color .25s ease !important;
}
.hero-btn.primary { background: linear-gradient(135deg,#1a3a5c,#2c5f7c) !important; color: #fff !important; }
.hero-btn.secondary { background: #ffd700 !important; color: #1a3a5c !important; }
.hero-btn.ghost { border: 2px solid #fff !important; color: #fff !important; background: transparent !important; }
.hero-btn:hover { transform: translateY(-3px) !important; box-shadow: 0 12px 28px rgba(0,0,0,.25) !important; }
.hero-btn.ghost:hover { background: #fff !important; color: #1a3a5c !important; }
.hero-animate { opacity: 0; transform: translateY(28px); animation: acFadeUp .8s ease forwards; }
.hero-animate.delay-1 { animation-delay: .15s; }
.hero-animate.delay-2 { animation-delay: .32s; }
.hero-animate.delay-3 { animation-delay: .48s; }
.hero-animate.delay-4 { animation-delay: .64s; }
@keyframes acFadeUp { to { opacity: 1; transform: translateY(0); } }

/* Inner page headers: reduce height on mobile and prevent overflow */
.page-header {
  position: relative !important;
  padding: 70px 16px !important;
  min-height: auto !important;
  overflow: hidden !important;
}
.page-header h1, .page-header h2 {
  overflow-wrap: anywhere !important;
}

/* Footer less tall on mobile */
.footer {
  overflow-x: hidden !important;
}

@media (max-width: 991.98px) {
  .navbar {
    padding: 10px 0 !important;
  }
  .navbar .container {
    max-width: 100% !important;
  }
  .navbar-brand img {
    max-width: 150px !important;
    height: auto !important;
  }
  .navbar-collapse {
    margin-top: 12px !important;
    max-height: calc(100vh - 90px) !important;
    overflow-y: auto !important;
  }
  .language-selector {
    margin-left: 0 !important;
    margin-top: 10px !important;
    flex-wrap: wrap !important;
  }
}

@media (max-width: 768px) {
  .hero-section {
    min-height: 430px !important;
    padding: 60px 16px 70px !important;
    background-position: center center !important;
  }
  .hero-section h1, .hero-title {
    font-size: clamp(2rem, 9vw, 3.1rem) !important;
  }
  .hero-section p, .hero-sub {
    font-size: 1rem !important;
    line-height: 1.65 !important;
  }
  .hero-buttons {
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 12px !important;
  }
  .hero-btn, .btn-hero {
    width: 100% !important;
    text-align: center !important;
  }
  .page-header {
    padding: 42px 14px !important;
  }
  .page-header h1, .page-header h2 {
    font-size: 2rem !important;
    line-height: 1.2 !important;
  }
  .footer {
    padding: 34px 0 16px !important;
  }
  .footer-bottom {
    margin-top: 22px !important;
    padding-top: 15px !important;
  }
  .container {
    max-width: 100% !important;
    padding-left: 16px !important;
    padding-right: 16px !important;
  }
}

@media (max-width: 420px) {
  .hero-section {
    min-height: 390px !important;
    padding-top: 48px !important;
  }
  .navbar-brand img { max-width: 132px !important; }
}

/* =====================
   Cover QAFAR COVER
===================== */
:root{
  --navy:#082d49;
  --navy2:#061f34;
  --gold:#f6c24f;
  --cream:#fff8ec;
  --paper:#fff8e9;
  --text:#21384c;
}
*{box-sizing:border-box}
body{margin:0;background:#efe7dc;font-family:"Segoe UI",Arial,sans-serif;color:var(--text)}

/* =====================
   EDITABLE QAFAR COVER
===================== */
.cover-wrapper{width:100%;margin:34px auto;padding:0 16px}
.cover-large{max-width:1500px}.cover-medium{max-width:1100px}.cover-small{max-width:780px}.cover-compact{max-width:540px}
.qafar-cover{width:100%;background:var(--cream);border-radius:28px;overflow:hidden;box-shadow:0 25px 70px rgba(0,0,0,.18)}
.qafar-hero{position:relative;overflow:hidden;background:var(--navy)}
.cover-large .qafar-hero{aspect-ratio:16/7;max-height:620px}.cover-medium .qafar-hero{aspect-ratio:16/8;max-height:460px}.cover-small .qafar-hero{aspect-ratio:16/6;max-height:260px}.cover-compact .qafar-hero{aspect-ratio:4/3;max-height:300px}
.qafar-hero img{width:100%;height:100%;object-fit:cover;object-position:center;display:block}
.qafar-overlay{position:absolute;inset:0;background:linear-gradient(90deg,rgba(5,35,60,.96) 0%,rgba(5,35,60,.82) 24%,rgba(5,35,60,.36) 48%,rgba(5,35,60,.05) 100%)}
.qafar-text{position:absolute;top:9%;left:5%;width:360px;color:white;z-index:3}
.qafar-title{margin:0;font-size:clamp(42px,5vw,76px);line-height:.9;font-weight:900;color:var(--gold)}
.qafar-title span{display:block;color:white}.qafar-subtitle{margin:18px 0 0;font-size:clamp(20px,2vw,30px);font-weight:800}.gold-line{width:78px;height:5px;background:var(--gold);border-radius:30px;margin:18px 0}.qafar-description{font-size:clamp(15px,1.4vw,20px);line-height:1.55;margin:0 0 26px;color:#fff;max-width:350px;text-align:left;word-spacing:normal;letter-spacing:normal}.explore-btn{border:0;background:var(--gold);color:var(--navy);padding:15px 26px;border-radius:12px;font-size:16px;font-weight:800;cursor:pointer;box-shadow:0 12px 28px rgba(0,0,0,.25);transition:.25s ease}.explore-btn:hover{background:#ffd76f;transform:translateY(-2px)}
.justice-circle{position:absolute;right:5%;bottom:-45px;width:150px;height:150px;background:var(--navy);border:9px solid var(--gold);border-radius:50%;z-index:5;display:flex;align-items:center;justify-content:center;color:var(--gold);font-size:70px}
.qafar-features{position:relative;z-index:4;display:grid;grid-template-columns:repeat(5,1fr);gap:0;padding:70px 35px 42px;background:var(--cream)}
.feature-box{text-align:center;padding:0 22px;border-right:1px solid rgba(8,45,73,.18)}.feature-box:last-child{border-right:0}.feature-icon{width:70px;height:70px;margin:0 auto 16px;background:var(--navy);color:var(--gold);border-radius:50%;display:flex;align-items:center;justify-content:center;font-size:30px}.feature-box h3{margin:0 0 10px;color:var(--navy);font-size:19px;font-weight:900}.feature-box p{margin:0;color:var(--text);font-size:15px;line-height:1.45;text-align:center;word-spacing:normal;letter-spacing:normal}

/* compact cover-small */
.cover-small .qafar-text{top:6%;width:260px}.cover-small .qafar-title{font-size:32px;line-height:1}.cover-small .qafar-subtitle{font-size:16px;margin-top:8px}.cover-small .gold-line{margin:10px 0;height:3px}.cover-small .qafar-description{font-size:13px;line-height:1.4;margin-bottom:14px}.cover-small .explore-btn{padding:10px 16px;font-size:13px}.cover-small .justice-circle{width:80px;height:80px;font-size:34px;bottom:-20px;border-width:6px}.cover-small .qafar-features{grid-template-columns:repeat(2,1fr);padding:45px 20px 25px;gap:18px}.cover-small .feature-box{border-right:0}.cover-small .feature-icon{width:50px;height:50px;font-size:22px}.cover-small .feature-box h3{font-size:15px}.cover-small .feature-box p{font-size:13px}
.cover-compact .qafar-text{width:300px}.cover-compact .qafar-title{font-size:42px}.cover-compact .qafar-subtitle{font-size:20px}.cover-compact .qafar-description{font-size:14px}.cover-compact .justice-circle{width:86px;height:86px;font-size:38px;bottom:-28px}.cover-compact .qafar-features{grid-template-columns:1fr;gap:24px}.cover-compact .feature-box{border-right:0}

/* =====================
   MODAL DIGITAL BOOK
===================== */
.madaa-modal{position:fixed;inset:0;background:rgba(3,15,28,.86);backdrop-filter:blur(8px);display:flex;align-items:center;justify-content:center;z-index:9999;padding:20px;overflow-y:auto;opacity:0;visibility:hidden;pointer-events:none;transform:scale(.96);transition:opacity .35s ease,transform .35s ease,visibility .35s ease}
.madaa-modal.show{opacity:1;visibility:visible;pointer-events:auto;transform:scale(1)}
.madaa-modal-box{position:relative;width:min(1100px,96vw);max-height:92vh;background:#f7efe0;border-radius:28px;overflow:hidden;box-shadow:0 30px 90px rgba(0,0,0,.45);transform:translateY(28px) scale(.96);opacity:0;transition:transform .45s ease,opacity .45s ease}.madaa-modal.show .madaa-modal-box{transform:translateY(0) scale(1);opacity:1}
.madaa-close{position:absolute;top:15px;right:18px;z-index:10;width:42px;height:42px;border:0;border-radius:50%;background:var(--navy);color:#fff;font-size:30px;line-height:1;cursor:pointer}.book-reader{display:grid;grid-template-columns:1fr 1fr;min-height:620px}.book-cover-page{position:relative;overflow:hidden}.book-cover-page img{width:100%;height:100%;object-fit:cover}.cover-overlay{position:absolute;inset:auto 0 0;padding:45px;background:linear-gradient(transparent,rgba(9,36,60,.95));color:white}.cover-overlay h1{font-size:48px;color:var(--gold);margin:0}.cover-overlay p{font-size:22px;font-weight:700}.book-pages{padding:45px;background:linear-gradient(90deg,rgba(0,0,0,.08),transparent 8%),var(--paper);display:flex;flex-direction:column}.book-toolbar{display:grid;grid-template-columns:1fr auto 1fr;align-items:center;gap:10px;margin-bottom:30px}.book-toolbar button{display:flex;align-items:center;justify-content:center;gap:6px;border:0;background:var(--navy);color:white;padding:11px 18px;border-radius:12px;font-weight:800;cursor:pointer;transition:.2s;white-space:nowrap}.book-toolbar button:hover{background:#123d5f;transform:translateY(-2px)}.book-toolbar span{font-weight:900;color:var(--navy);text-align:center;white-space:nowrap}.book-content-area{flex:1;overflow-y:auto}.book-page{display:none;animation:pageSlide .35s ease}.book-page.active{display:block}.book-page h2{font-size:36px;color:var(--navy);margin:0 0 20px}.book-page p{font-size:20px;line-height:1.9;color:#26384a;text-align:left;display:block;word-spacing:normal;letter-spacing:normal;max-width:620px}@keyframes pageSlide{from{opacity:0;transform:translateX(18px)}to{opacity:1;transform:translateX(0)}}body.modal-open{overflow:hidden}

@media(max-width:992px){.qafar-features{grid-template-columns:repeat(2,1fr);gap:30px}.feature-box{border-right:0}}
@media(max-width:768px){.madaa-modal{align-items:flex-start;justify-content:flex-start;padding:12px;overflow-y:auto;-webkit-overflow-scrolling:touch}.madaa-modal-box{width:100%;max-width:100%;height:auto;max-height:none;min-height:auto;border-radius:22px;overflow:visible;margin:10px auto 30px}.book-reader{display:block;height:auto;min-height:auto}.book-cover-page{height:170px;min-height:170px;border-radius:22px 22px 0 0;overflow:hidden}.cover-overlay{padding:18px}.cover-overlay h1{font-size:26px}.cover-overlay p{font-size:16px}.book-pages{height:auto;min-height:auto;padding:0}.book-toolbar{position:sticky;top:0;z-index:5;margin:0;padding:12px;background:#f0e6d2}.book-toolbar button{min-width:96px;height:48px;padding:0 12px;font-size:14px;border-radius:14px}.book-toolbar span{font-size:20px}.book-content-area{height:auto;max-height:none;overflow:visible;padding:22px 20px 35px}.book-page h2{font-size:28px;line-height:1.15}.book-page p{font-size:16px;line-height:1.7}.madaa-close{position:fixed;top:18px;right:18px;z-index:10000;width:42px;height:42px}}
@media(max-width:600px){.cover-wrapper{margin:22px auto;padding:0 12px}.qafar-cover{border-radius:22px}.cover-wrapper .qafar-hero{aspect-ratio:4/5;max-height:440px}.cover-small .qafar-hero{aspect-ratio:16/7;max-height:220px}.qafar-overlay{background:linear-gradient(180deg,rgba(5,35,60,.9) 0%,rgba(5,35,60,.65) 45%,rgba(5,35,60,.18) 100%)}.qafar-text{top:28px;left:22px;right:22px;width:auto}.cover-small .qafar-text{top:18px;left:18px;right:18px;width:auto}.qafar-title{font-size:44px}.cover-small .qafar-title{font-size:30px}.qafar-subtitle{font-size:21px}.cover-small .qafar-subtitle{font-size:15px}.qafar-description{font-size:15px;max-width:100%}.cover-small .qafar-description{display:none}.explore-btn{width:100%;padding:14px}.cover-small .explore-btn{width:auto;padding:9px 12px}.justice-circle{width:95px;height:95px;right:22px;bottom:-32px;font-size:42px;border-width:7px}.cover-small .justice-circle{width:64px;height:64px;font-size:28px;bottom:-18px}.qafar-features{grid-template-columns:1fr;padding:65px 24px 35px;gap:28px}.cover-small .qafar-features{display:none}}
@media(max-width:430px){.book-cover-page{height:145px;min-height:145px}.book-toolbar{gap:6px;padding:12px 8px}.book-toolbar button{min-width:82px;height:44px;font-size:12px;padding:0 8px}.book-toolbar span{font-size:18px}.book-page h2{font-size:24px}}

.feature-icon.flat-icon {
  background: none;
  box-shadow: none;
  width: auto;
  height: auto;
  border-radius: 0;
  color: #ffd21f;
  font-size: 48px;
  line-height: 1;
  margin-bottom: 18px;
}

.feature-icon.flat-icon i {
  color: #ffd21f;
}
.hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}


/* /afar/homepage */

:root {
      --deep: #102b45;
      --blue: #1a3a5c;
      --teal: #2c5f7c;
      --gold: #ffd700;
      --cream: #fbf7ee;
      --sand: #c2b280;
      --ink: #1d2939;
    }

    * { box-sizing: border-box; }

    html { scroll-behavior: smooth; }

    body {
      margin: 0;
      font-family: 'Poppins', sans-serif;
      color: var(--ink);
      background: var(--cream);
      overflow-x: hidden;
    }

    a { text-decoration: none; }

    .site-shell {
      min-height: 100vh;
      background:
        radial-gradient(circle at 10% 10%, rgba(255, 215, 0, 0.18), transparent 26%),
        radial-gradient(circle at 90% 20%, rgba(44, 95, 124, 0.35), transparent 28%),
        linear-gradient(135deg, #0f2640 0%, #1a3a5c 48%, #2c5f7c 100%);
      position: relative;
      isolation: isolate;
    }

    .site-shell::before {
      content: '';
      position: absolute;
      inset: 0;
      background-image:
        linear-gradient(135deg, rgba(255,255,255,0.045) 0 2px, transparent 2px 120px),
        linear-gradient(45deg, rgba(255,255,255,0.035) 0 2px, transparent 2px 140px);
      opacity: 0.75;
      z-index: -2;
    }

    .site-shell::after {
      content: '';
      position: absolute;
      inset: 0;
      background: linear-gradient(rgba(12, 28, 45, 0.62), rgba(12, 28, 45, 0.78)), url('/assets/images/culture/cultural-home.jpg.jpg') center/cover no-repeat;
      opacity: 0.35;
      z-index: -3;
    }

    .landing-nav {
      position: absolute;
      top: 0;
      left: 0;
      right: 0;
      z-index: 10;
      padding: 24px clamp(18px, 5vw, 70px);
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 20px;
    }

    .brand-mark {
      display: flex;
      align-items: center;
      gap: 14px;
      color: #fff;
      font-weight: 900;
      letter-spacing: -0.03em;
    }

    .brand-logo {
      width: 54px;
      height: 54px;
      border-radius: 18px;
      display: grid;
      place-items: center;
      background: var(--gold);
      color: var(--blue);
      box-shadow: 0 16px 35px rgba(0,0,0,0.22);
      font-size: 1.35rem;
    }

    .brand-mark span small {
      display: block;
      font-weight: 600;
      letter-spacing: 0.06em;
      text-transform: uppercase;
      font-size: 0.7rem;
      color: rgba(255,255,255,0.72);
      margin-top: 2px;
    }

    .nav-actions {
      display: flex;
      align-items: center;
      gap: 10px;
      flex-wrap: wrap;
      justify-content: flex-end;
    }

    .nav-pill {
      color: #fff;
      border: 1px solid rgba(255,255,255,0.25);
      background: rgba(255,255,255,0.1);
      backdrop-filter: blur(8px);
      padding: 10px 16px;
      border-radius: 999px;
      font-weight: 700;
      font-size: 0.9rem;
      transition: 0.25s ease;
    }

    .nav-pill:hover, .nav-pill.gold {
      background: var(--gold);
      color: var(--blue);
      border-color: var(--gold);
    }

    .hero-platform {
      min-height: 100vh;
      display: flex;
      align-items: center;
      padding: 130px clamp(18px, 5vw, 70px) 70px;
    }

    .hero-grid {
      width: min(1180px, 100%);
      margin: 0 auto;
      display: grid;
      grid-template-columns: 1.08fr 0.92fr;
      gap: clamp(28px, 5vw, 70px);
      align-items: center;
    }

    .hero-kicker {
      display: inline-flex;
      align-items: center;
      gap: 10px;
      color: var(--gold);
      background: rgba(255, 215, 0, 0.12);
      border: 1px solid rgba(255, 215, 0, 0.28);
      border-radius: 999px;
      padding: 10px 16px;
      font-weight: 800;
      letter-spacing: 0.08em;
      text-transform: uppercase;
      font-size: 0.78rem;
      margin-bottom: 22px;
    }

    .hero-title {
      color: #fff;
      font-size: clamp(3rem, 7vw, 6.8rem);
      line-height: 0.92;
      letter-spacing: -0.075em;
      font-weight: 900;
      margin: 0 0 24px;
      text-shadow: 0 20px 55px rgba(0,0,0,0.32);
    }

    .hero-title span {
      color: var(--gold);
      display: block;
      font-size: 0.45em;
      letter-spacing: 0.08em;
      text-transform: uppercase;
      margin-top: 16px;
    }

    .hero-subtitle {
      color: rgba(255,255,255,0.82);
      font-size: clamp(1rem, 2vw, 1.24rem);
      line-height: 1.85;
      max-width: 740px;
      margin-bottom: 30px;
    }

    .hero-buttons {
      display: flex;
      gap: 14px;
      flex-wrap: wrap;
      margin-bottom: 34px;
    }

    .btn-main, .btn-outline-main {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      gap: 10px;
      border-radius: 999px;
      padding: 14px 22px;
      font-weight: 900;
      transition: 0.25s ease;
    }

    .btn-main {
      background: var(--gold);
      color: var(--blue);
      box-shadow: 0 18px 42px rgba(255, 215, 0, 0.22);
    }

    .btn-main:hover { color: var(--blue); transform: translateY(-3px); }

    .btn-outline-main {
      color: #fff;
      border: 1px solid rgba(255,255,255,0.35);
      background: rgba(255,255,255,0.08);
    }

    .btn-outline-main:hover { background: #fff; color: var(--blue); transform: translateY(-3px); }

    .stat-row {
      display: grid;
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 12px;
      max-width: 680px;
    }

    .stat-card {
      padding: 16px 14px;
      border-radius: 22px;
      background: rgba(255,255,255,0.09);
      border: 1px solid rgba(255,255,255,0.13);
      color: #fff;
      backdrop-filter: blur(10px);
    }

    .stat-card strong { display: block; color: var(--gold); font-size: 1.5rem; line-height: 1; }
    .stat-card span { font-size: 0.84rem; color: rgba(255,255,255,0.72); }

    .language-panel {
      background: rgba(255,255,255,0.94);
      border-radius: 34px;
      padding: clamp(22px, 4vw, 38px);
      box-shadow: 0 35px 90px rgba(0,0,0,0.34);
      border: 1px solid rgba(255,255,255,0.34);
      position: relative;
      overflow: hidden;
    }

    .language-panel::before {
      content: '';
      position: absolute;
      width: 230px;
      height: 230px;
      border-radius: 50%;
      background: rgba(255,215,0,0.18);
      right: -70px;
      top: -80px;
    }

    .panel-top {
      position: relative;
      z-index: 1;
      text-align: center;
      margin-bottom: 24px;
    }

    .mini-logo {
      width: 124px;
      height: 76px;
      border-radius: 18px;
      margin: 0 auto 18px;
      display: grid;
      place-items: center;
      background: linear-gradient(135deg, var(--blue), var(--teal));
      color: var(--gold);
      font-weight: 900;
      box-shadow: 0 16px 35px rgba(26,58,92,0.2);
    }

    .mini-logo small { display: block; color: #fff; font-size: 0.72rem; font-weight: 600; text-align: center; }

    .panel-top h2 {
      color: var(--blue);
      font-weight: 900;
      letter-spacing: -0.045em;
      font-size: clamp(1.7rem, 4vw, 2.45rem);
      margin-bottom: 8px;
    }

    .panel-top p { color: #667085; margin: 0; line-height: 1.65; }

    .language-options {
      display: grid;
      gap: 14px;
      position: relative;
      z-index: 1;
    }

    .language-card {
      position: relative;
      display: flex;
      align-items: center;
      gap: 16px;
      padding: 18px;
      border-radius: 22px;
      color: #fff;
      background: linear-gradient(135deg, #1a3a5c, #2c5f7c);
      transition: 0.28s ease;
      overflow: hidden;
      box-shadow: 0 15px 35px rgba(26,58,92,0.14);
    }

    .language-card::after {
      content: '→';
      position: absolute;
      right: 20px;
      font-size: 1.3rem;
      color: var(--gold);
      transition: 0.25s ease;
    }

    .language-card:hover {
      color: #fff;
      transform: translateY(-4px);
      box-shadow: 0 22px 50px rgba(26,58,92,0.26);
    }

    .language-card:hover::after { transform: translateX(4px); }

    .language-card i {
      width: 52px;
      height: 52px;
      border-radius: 18px;
      display: grid;
      place-items: center;
      background: rgba(255,215,0,0.16);
      color: var(--gold);
      font-size: 1.45rem;
      flex: 0 0 auto;
    }

    .language-card h3 {
      margin: 0;
      font-weight: 900;
      font-size: 1.25rem;
    }

    .language-card p { margin: 2px 0 0; color: rgba(255,255,255,0.72); font-size: 0.9rem; }
    .language-card.amharic { background: linear-gradient(135deg, #236083, #3589a8); }
    .language-card.english { background: linear-gradient(135deg, #0f7b74, #2c9f93); }

    .ticker-wrapper {
      position: relative;
      z-index: 1;
      margin-top: 22px;
      padding: 13px 16px;
      border-radius: 999px;
      background: #eef2f5;
      border-left: 4px solid var(--gold);
      overflow: hidden;
      color: var(--blue);
      font-weight: 700;
      font-size: 0.9rem;
    }

    .ticker-text { white-space: nowrap; overflow: hidden; }
    .ticker-text span { display: inline-block; animation: ticker 24s linear infinite; padding-left: 100%; }
    @keyframes ticker { 100% { transform: translateX(-100%); } }

    .main-content { background: var(--cream); }

    .section-wrap {
      padding: clamp(54px, 8vw, 90px) clamp(18px, 5vw, 70px);
    }

    .section-head {
      max-width: 820px;
      margin: 0 auto 42px;
      text-align: center;
    }

    .section-kicker {
      color: var(--teal);
      font-weight: 900;
      letter-spacing: 0.12em;
      text-transform: uppercase;
      font-size: 0.78rem;
      display: inline-flex;
      gap: 8px;
      align-items: center;
      margin-bottom: 12px;
    }

    .section-head h2 {
      color: var(--blue);
      font-weight: 900;
      font-size: clamp(2rem, 4vw, 3.2rem);
      letter-spacing: -0.055em;
      margin-bottom: 14px;
    }

    .section-head p { color: #667085; line-height: 1.8; font-size: 1.04rem; }

    .collection-grid {
      width: min(1120px, 100%);
      margin: 0 auto;
      display: grid;
      grid-template-columns: repeat(3, 1fr);
      gap: 22px;
    }

    .collection-card {
      min-height: 270px;
      padding: 28px;
      border-radius: 30px;
      color: #fff;
      position: relative;
      overflow: hidden;
      box-shadow: 0 20px 55px rgba(16,43,69,0.12);
      transition: 0.28s ease;
      display: flex;
      flex-direction: column;
      justify-content: flex-end;
      isolation: isolate;
    }

    .collection-card::before {
      content: '';
      position: absolute;
      inset: 0;
      background: linear-gradient(to top, rgba(15,38,64,0.92), rgba(15,38,64,0.28));
      z-index: -1;
    }

    .collection-card::after {
      content: '';
      position: absolute;
      inset: 0;
      background: var(--bg) center/cover no-repeat;
      z-index: -2;
      transition: 0.4s ease;
    }

    .collection-card:hover { transform: translateY(-7px); color: #fff; }
    .collection-card:hover::after { transform: scale(1.08); }

    .collection-icon {
      width: 58px;
      height: 58px;
      border-radius: 20px;
      display: grid;
      place-items: center;
      background: rgba(255,215,0,0.16);
      color: var(--gold);
      font-size: 1.5rem;
      margin-bottom: 18px;
      border: 1px solid rgba(255,215,0,0.2);
    }

    .collection-card h3 { font-size: 1.45rem; font-weight: 900; margin-bottom: 8px; }
    .collection-card p { color: rgba(255,255,255,0.76); line-height: 1.6; margin-bottom: 16px; }
    .collection-card span { color: var(--gold); font-weight: 900; }

    .books-showcase {
      background:
        radial-gradient(circle at 20% 20%, rgba(255,215,0,0.16), transparent 28%),
        linear-gradient(135deg, #102b45, #1a3a5c);
      color: #fff;
    }

    .books-showcase .section-head h2 { color: #fff; }
    .books-showcase .section-head p { color: rgba(255,255,255,0.74); }
    .books-showcase .section-kicker { color: var(--gold); }

    .book-grid {
      width: min(960px, 100%);
      margin: 0 auto;
      display: grid;
      grid-template-columns: repeat(2, 1fr);
      gap: 22px;
    }

    .digital-book {
      min-height: 260px;
      border-radius: 30px;
      background: rgba(255,255,255,0.09);
      border: 1px solid rgba(255,255,255,0.13);
      padding: 28px;
      color: #fff;
      position: relative;
      overflow: hidden;
      transition: 0.28s ease;
    }

    .digital-book::before {
      content: '';
      position: absolute;
      left: 0;
      top: 0;
      width: 14px;
      height: 100%;
      background: linear-gradient(var(--gold), #b88400);
    }

    .digital-book:hover { color: #fff; transform: translateY(-7px); background: rgba(255,255,255,0.13); }
    .digital-book i { color: var(--gold); font-size: 2rem; margin-bottom: 20px; }
    .digital-book h3 { font-weight: 900; font-size: 1.55rem; margin-bottom: 12px; }
    .digital-book p { color: rgba(255,255,255,0.74); line-height: 1.7; }
    .digital-book span { color: var(--gold); font-weight: 900; }

    .mission-card {
      width: min(1050px, 100%);
      margin: 0 auto;
      display: grid;
      grid-template-columns: 0.88fr 1.12fr;
      gap: 30px;
      align-items: center;
      background: #fff;
      border-radius: 34px;
      padding: clamp(20px, 4vw, 42px);
      box-shadow: 0 24px 70px rgba(16,43,69,0.12);
      border: 1px solid rgba(26,58,92,0.06);
    }

    .mission-image {
      min-height: 360px;
      border-radius: 28px;
      background: linear-gradient(to top, rgba(15,38,64,0.45), transparent), url('/assets/images/culture/mablo.png') center/cover no-repeat;
    }

    .mission-text h2 { color: var(--blue); font-weight: 900; letter-spacing: -0.05em; font-size: clamp(1.9rem, 4vw, 3rem); }
    .mission-text p { color: #667085; line-height: 1.85; }

    .footer-lite {
      background: #0f2640;
      color: rgba(255,255,255,0.75);
      padding: 28px 20px;
      text-align: center;
      font-size: 0.92rem;
    }

    .footer-lite strong { color: var(--gold); }

    .admin-link {
      position: fixed;
      bottom: 20px;
      right: 20px;
      z-index: 30;
      display: inline-flex;
      align-items: center;
      gap: 8px;
      padding: 10px 16px;
      border-radius: 999px;
      color: #fff;
      background: rgba(15,38,64,0.68);
      border: 1px solid rgba(255,255,255,0.16);
      backdrop-filter: blur(8px);
      font-weight: 700;
      font-size: 0.84rem;
    }

    .admin-link:hover { color: var(--gold); }

    @media (max-width: 980px) {
      .hero-grid, .mission-card { grid-template-columns: 1fr; }
      .hero-platform { padding-top: 120px; }
      .language-panel { max-width: 680px; }
      .collection-grid { grid-template-columns: 1fr; }
    }

    @media (max-width: 700px) {
      .landing-nav { position: relative; background: rgba(15,38,64,0.35); padding: 16px; align-items: flex-start; }
      .nav-actions { display: none; }
      .hero-platform { padding: 34px 16px 50px; min-height: auto; }
      .hero-title { font-size: clamp(2.7rem, 15vw, 4rem); }
      .stat-row, .book-grid { grid-template-columns: 1fr; }
      .collection-card, .digital-book { min-height: 230px; border-radius: 24px; }
      .language-panel { border-radius: 26px; padding: 22px; }
      .language-card { padding: 15px; border-radius: 18px; }
      .language-card i { width: 46px; height: 46px; border-radius: 15px; }
      .section-wrap { padding: 52px 16px; }
      .mission-image { min-height: 260px; }
      .admin-link { display: none; }
    }

    
    /* Navbrand Name*/
html[lang="am"] .navbar .nav-link{
  font-size:1rem !important;
  font-weight:800 !important;
}

html[lang="am"] .language-selector .lang-btn{
  font-size:.92rem !important;
}

html[lang="am"] .brand-text strong{
  font-size:1.25rem !important;
}

html[lang="am"] .brand-text span{
  font-size:.62rem !important;
}

html[lang="am"] .navbar .nav-link{
  font-size:1rem !important;
  font-weight:800 !important;
}

html[lang="am"] .language-selector .lang-btn{
  font-size:.92rem !important;
}

html[lang="am"] .brand-text strong{
  font-size:1.25rem !important;
}

html[lang="am"] .brand-text span{
  font-size:.62rem !important;
}

  /* ========================================= */
/* MODERN NAVBAR BRAND COMPONENT - COMPLETE CSS */
/* For: Afar Culture Digital Library */
/* Logo + Brand Name + Subtitle - Fully Responsive */
/* Does NOT change any existing page content */
/* ========================================= */

/* Modern Brand Container - replaces existing navbar-brand */
.navbar-brand.brand-modern {
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
    text-decoration: none !important;
    transition: all 0.25s ease !important;
    padding: 0 !important;
    margin: 0 !important;
    background: transparent !important;
    border-radius: 0 !important;
}

/* Hover effect */
.navbar-brand.brand-modern:hover {
    transform: translateX(3px);
}

/* Logo Wrapper with Gradient Background */
.navbar-brand.brand-modern .brand-logo-wrapper {
    width: 52px;
    height: 52px;
    background: linear-gradient(145deg, #F7E0AC, #EDCD8A);
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.12), inset 0 1px 0 rgba(255, 255, 240, 0.7);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.navbar-brand.brand-modern:hover .brand-logo-wrapper {
    transform: scale(1.02);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.2);
}

/* Logo Image */
.navbar-brand.brand-modern .brand-logo-img {
    width: 44px;
    height: 44px;
    object-fit: contain;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.2));
    transition: transform 0.2s ease;
}

.navbar-brand.brand-modern:hover .brand-logo-img {
    transform: scale(1.02);
}

/* Text Group */
.navbar-brand.brand-modern .brand-text-group {
    display: flex !important;
    flex-direction: column !important;
    line-height: 1.1 !important;
}

/* Brand Name - Gold/Yellow */
.navbar-brand.brand-modern .brand-name {
    font-size: 1.28rem !important;
    font-weight: 900 !important;
    color: #ffd700 !important;
    letter-spacing: -0.02em !important;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1) !important;
    transition: color 0.2s ease !important;
    background: none !important;
    -webkit-background-clip: unset !important;
}

.navbar-brand.brand-modern:hover .brand-name {
    color: #ffe066 !important;
}

/* Subtitle - DIGITAL LIBRARY - ALWAYS VISIBLE */
.navbar-brand.brand-modern .brand-sub {
    font-size: 0.6rem !important;
    font-weight: 800 !important;
    letter-spacing: 0.12em !important;
    color: #FFD966 !important;
    text-transform: uppercase !important;
    margin-top: 4px !important;
    display: block !important;
    transition: color 0.2s ease !important;
}

.navbar-brand.brand-modern:hover .brand-sub {
    color: #ffe680 !important;
}

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

/* Tablet */
@media (max-width: 768px) {
    .navbar-brand.brand-modern {
        gap: 8px !important;
    }
    .navbar-brand.brand-modern .brand-logo-wrapper {
        width: 42px;
        height: 42px;
    }
    .navbar-brand.brand-modern .brand-logo-img {
        width: 36px;
        height: 36px;
    }
    .navbar-brand.brand-modern .brand-name {
        font-size: 1rem !important;
    }
    .navbar-brand.brand-modern .brand-sub {
        font-size: 0.5rem !important;
        letter-spacing: 0.1em !important;
        margin-top: 3px !important;
    }
}

/* Mobile Large */
@media (max-width: 480px) {
    .navbar-brand.brand-modern {
        gap: 6px !important;
    }
    .navbar-brand.brand-modern .brand-logo-wrapper {
        width: 38px;
        height: 38px;
    }
    .navbar-brand.brand-modern .brand-logo-img {
        width: 32px;
        height: 32px;
    }
    .navbar-brand.brand-modern .brand-name {
        font-size: 0.9rem !important;
    }
    .navbar-brand.brand-modern .brand-sub {
        font-size: 0.48rem !important;
        letter-spacing: 0.08em !important;
        margin-top: 2px !important;
    }
}

/* Mobile Small - Keep subtitle visible (no hiding) */
@media (max-width: 420px) {
    .navbar-brand.brand-modern .brand-sub {
        display: block !important;
        font-size: 0.45rem !important;
        letter-spacing: 0.06em !important;
    }
}

/* ========== EXISTING NAVBAR STYLES PRESERVATION ========== */
/* These styles maintain your current navbar appearance */
/* The brand-modern class overrides only the brand area */

.navbar {
    background: linear-gradient(135deg, #1a3a5c, #2c5f7c) !important;
    padding: 12px 0 !important;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.12);
    z-index: 1000;
}

.navbar .container {
    max-width: 1320px !important;
    width: 100%;
    display: flex;
    align-items: center !important;
    gap: 14px;
}

/* Preserve existing navbar-collapse */
.navbar-collapse {
    flex-grow: 1;
}

/* Preserve existing nav links */
.navbar-nav {
    display: flex;
    align-items: center !important;
    gap: 6px !important;
    flex-wrap: nowrap !important;
}

.navbar .nav-item {
    flex: 0 0 auto !important;
}

.navbar .nav-link {
    color: #fff !important;
    font-weight: 800 !important;
    font-size: 0.88rem !important;
    margin: 0 !important;
    padding: 8px 10px !important;
    border-radius: 999px !important;
    line-height: 1 !important;
    white-space: nowrap !important;
    text-align: center !important;
    transition: 0.22s ease;
}

.navbar .nav-link:hover,
.navbar .nav-link.active {
    color: #ffd700 !important;
    background: rgba(255, 255, 255, 0.08) !important;
}

/* Preserve language selector */
.language-selector {
    display: flex !important;
    align-items: center !important;
    gap: 7px !important;
    margin-left: 18px !important;
    flex-wrap: nowrap !important;
    flex: 0 0 auto !important;
}

.language-selector .lang-btn {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: rgba(255, 255, 255, 0.18) !important;
    color: #fff !important;
    border: 1px solid rgba(255, 255, 255, 0.30) !important;
    padding: 8px 12px !important;
    min-height: 34px !important;
    border-radius: 999px !important;
    font-size: 0.82rem !important;
    line-height: 1 !important;
    font-weight: 900 !important;
    text-decoration: none !important;
    white-space: nowrap !important;
}

.language-selector .lang-btn:hover,
.language-selector .lang-btn.active {
    background: #ffd700 !important;
    color: #1a3a5c !important;
    border-color: #ffd700 !important;
}

/* Preserve navbar toggler */
.navbar-toggler {
    border-color: rgba(255, 255, 255, 0.28) !important;
    margin-left: auto;
}

.navbar-toggler-icon {
    filter: invert(1);
}

/* Medium desktop/tablet */
@media (max-width: 1200px) {
    .navbar .nav-link {
        font-size: 0.78rem !important;
        padding: 8px 7px !important;
    }
    .language-selector {
        margin-left: 10px !important;
        gap: 5px !important;
    }
    .language-selector .lang-btn {
        font-size: 0.76rem !important;
        padding: 7px 9px !important;
    }
}

/* Bootstrap mobile collapse */
@media (max-width: 991px) {
    .navbar .container {
        align-items: center !important;
        flex-wrap: wrap;
    }
    .navbar-collapse {
        width: 100% !important;
        flex-basis: 100% !important;
        padding-top: 14px;
    }
    .navbar-nav {
        align-items: stretch !important;
        flex-wrap: wrap !important;
        gap: 7px !important;
    }
    .navbar .nav-item {
        width: 100% !important;
    }
    .navbar .nav-link {
        text-align: left !important;
        padding: 11px 14px !important;
        background: rgba(255, 255, 255, 0.06) !important;
        font-size: 0.92rem !important;
        line-height: 1.2 !important;
    }
    .language-selector {
        margin-left: 0 !important;
        margin-top: 12px !important;
        flex-wrap: wrap !important;
        gap: 8px !important;
    }
    .language-selector .lang-btn {
        font-size: 0.85rem !important;
        padding: 9px 13px !important;
    }
}
/* =========================================
   QUSBA OYTA NAVBAR BALANCE FIX
   CSS-only patch: keeps the new Updates button visible
   without stretching or breaking the main navigation.
   ========================================= */
.navbar .navbar-nav .afc-news-nav-item {
  flex: 0 0 auto !important;
}

body .navbar .navbar-nav .afc-news-nav-item .afc-news-nav-link {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 7px !important;
  border-radius: 999px !important;
  background: linear-gradient(135deg, #ffd700, #ffe978) !important;
  color: #102b45 !important;
  font-weight: 950 !important;
  text-decoration: none !important;
  line-height: 1 !important;
  white-space: nowrap !important;
  border: 0 !important;
  box-shadow: 0 10px 22px rgba(255, 215, 0, .18) !important;
}

body .navbar .navbar-nav .afc-news-nav-item .afc-news-nav-link:hover,
body .navbar .navbar-nav .afc-news-nav-item .afc-news-nav-link.active {
  color: #102b45 !important;
  background: linear-gradient(135deg, #ffe978, #ffd700) !important;
  transform: translateY(-1px) !important;
}

@media (min-width: 1200px) {
  .navbar,
  .custom-navbar,
  .afc-navbar-final {
    min-height: 86px !important;
    padding-top: 9px !important;
    padding-bottom: 9px !important;
  }

  .navbar > .container,
  .navbar .afc-nav-container {
    max-width: 1500px !important;
    width: min(100% - 40px, 1500px) !important;
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
    flex-wrap: nowrap !important;
  }

  .navbar .navbar-brand,
  .navbar .brand-modern {
    flex: 0 0 auto !important;
    max-width: 250px !important;
    min-width: 0 !important;
    gap: 10px !important;
  }

  .navbar .brand-logo-img,
  .navbar .brand-main-logo,
  .navbar-brand img,
  .brand-modern img {
    width: 58px !important;
    height: 58px !important;
    max-width: 58px !important;
    max-height: 58px !important;
    object-fit: contain !important;
    flex: 0 0 58px !important;
  }

  .navbar .brand-text strong,
  .navbar .brand-name,
  .navbar-brand span:first-of-type {
    font-size: clamp(1.12rem, 1.55vw, 1.55rem) !important;
    line-height: 1.05 !important;
    white-space: nowrap !important;
  }

  .navbar .brand-sub,
  .navbar .brand-text span {
    font-size: .68rem !important;
    letter-spacing: .12em !important;
    white-space: nowrap !important;
  }

  .navbar .navbar-collapse {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 10px !important;
    min-width: 0 !important;
  }

  .navbar .navbar-nav {
    flex: 1 1 auto !important;
    min-width: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 5px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    flex-wrap: nowrap !important;
  }

  .navbar .navbar-nav .nav-item {
    flex: 0 0 auto !important;
  }

  .navbar .navbar-nav .nav-link {
    min-height: 42px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 12px !important;
    font-size: clamp(.82rem, .84vw, .94rem) !important;
    line-height: 1 !important;
    white-space: nowrap !important;
  }

  .navbar .navbar-nav .afc-news-nav-item {
    margin-left: 5px !important;
  }

  body .navbar .navbar-nav .afc-news-nav-item .afc-news-nav-link {
    min-height: 42px !important;
    padding: 0 15px !important;
    font-size: clamp(.82rem, .86vw, .94rem) !important;
  }

  body .navbar .navbar-nav .afc-news-nav-item .afc-news-nav-link i {
    font-size: .9em !important;
  }

  .navbar .language-selector,
  .navbar .lang-switcher,
  .navbar .language-switcher,
  .navbar .afc-lang-switcher {
    flex: 0 0 auto !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: flex-end !important;
    gap: 8px !important;
    margin-left: 6px !important;
    flex-wrap: nowrap !important;
    white-space: nowrap !important;
  }

  .navbar .lang-btn,
  .navbar .language-selector a {
    min-height: 42px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 14px !important;
    font-size: .84rem !important;
    line-height: 1 !important;
    white-space: nowrap !important;
  }

  .navbar .qafaraf-nav-logo-desktop {
    flex: 0 0 190px !important;
    width: 190px !important;
    max-width: 190px !important;
    margin-left: 8px !important;
  }

  .navbar .qafaraf-nav-logo-desktop img {
    width: 190px !important;
    height: 76px !important;
    max-width: 190px !important;
    max-height: 76px !important;
    object-fit: contain !important;
  }
}

@media (min-width: 1200px) and (max-width: 1360px) {
  .navbar > .container,
  .navbar .afc-nav-container {
    width: min(100% - 28px, 1320px) !important;
    gap: 8px !important;
  }

  .navbar .navbar-brand,
  .navbar .brand-modern {
    max-width: 218px !important;
  }

  .navbar .brand-logo-img,
  .navbar .brand-main-logo,
  .navbar-brand img,
  .brand-modern img {
    width: 52px !important;
    height: 52px !important;
    max-width: 52px !important;
    max-height: 52px !important;
    flex-basis: 52px !important;
  }

  .navbar .brand-text strong,
  .navbar .brand-name,
  .navbar-brand span:first-of-type {
    font-size: 1.12rem !important;
  }

  .navbar .brand-sub,
  .navbar .brand-text span {
    font-size: .58rem !important;
  }

  .navbar .navbar-nav {
    gap: 2px !important;
  }

  .navbar .navbar-nav .nav-link {
    min-height: 39px !important;
    padding: 0 7px !important;
    font-size: .78rem !important;
  }

  body .navbar .navbar-nav .afc-news-nav-item .afc-news-nav-link {
    min-height: 39px !important;
    padding: 0 11px !important;
    font-size: .78rem !important;
  }

  .navbar .lang-btn,
  .navbar .language-selector a {
    min-height: 39px !important;
    padding: 0 10px !important;
    font-size: .78rem !important;
  }

  .navbar .qafaraf-nav-logo-desktop {
    flex-basis: 150px !important;
    width: 150px !important;
    max-width: 150px !important;
  }

  .navbar .qafaraf-nav-logo-desktop img {
    width: 150px !important;
    height: 62px !important;
    max-width: 150px !important;
    max-height: 62px !important;
  }
}

/* Tablet widths: keep the hamburger layout instead of squeezing all links into one broken row. */
@media (min-width: 992px) and (max-width: 1199.98px) {
  .navbar.navbar-expand-lg,
  .custom-navbar.navbar-expand-lg,
  .afc-navbar-final.navbar-expand-lg {
    min-height: auto !important;
  }

  .navbar.navbar-expand-lg > .container,
  .custom-navbar.navbar-expand-lg > .container,
  .afc-navbar-final.navbar-expand-lg > .container {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    flex-wrap: wrap !important;
    row-gap: 10px !important;
  }

  .navbar.navbar-expand-lg .navbar-toggler {
    display: inline-flex !important;
  }

  .navbar.navbar-expand-lg .navbar-collapse {
    flex: 0 0 100% !important;
    width: 100% !important;
  }

  .navbar.navbar-expand-lg .navbar-collapse.collapse:not(.show) {
    display: none !important;
  }

  .navbar.navbar-expand-lg .navbar-collapse.collapse.show,
  .navbar.navbar-expand-lg .navbar-collapse.collapsing {
    display: block !important;
    background: rgba(16,43,69,.98) !important;
    border: 1px solid rgba(255,255,255,.12) !important;
    border-radius: 20px !important;
    padding: 14px !important;
    margin-top: 10px !important;
    box-shadow: 0 18px 40px rgba(0,0,0,.20) !important;
  }

  .navbar.navbar-expand-lg .navbar-nav {
    width: 100% !important;
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 8px !important;
    margin: 0 !important;
  }

  .navbar.navbar-expand-lg .navbar-nav .nav-link,
  body .navbar.navbar-expand-lg .navbar-nav .afc-news-nav-item .afc-news-nav-link {
    width: 100% !important;
    min-height: 44px !important;
    justify-content: center !important;
    padding: 0 12px !important;
    font-size: .92rem !important;
  }

  .navbar.navbar-expand-lg .language-selector,
  .navbar.navbar-expand-lg .afc-lang-switcher {
    margin-top: 12px !important;
    justify-content: center !important;
  }

  .navbar.navbar-expand-lg .qafaraf-nav-logo-desktop {
    display: none !important;
  }
}

@media (max-width: 991.98px) {
  .navbar .navbar-nav .afc-news-nav-item {
    margin-top: 4px !important;
  }

  body .navbar .navbar-nav .afc-news-nav-item .afc-news-nav-link {
    width: 100% !important;
    min-height: 46px !important;
    padding: 0 14px !important;
    font-size: .94rem !important;
  }
}



/* =========================================
   Qusba Oyta updates archive: no demo content.
   Shows a simple coming-soon state until real admin posts exist.
   ========================================= */
.afc-updates-coming-soon {
  width: min(100%, 980px);
  margin: 42px auto 70px;
  padding: clamp(28px, 5vw, 56px);
  border-radius: 34px;
  background: linear-gradient(145deg, rgba(255,255,255,.96), rgba(248,251,255,.92));
  border: 1px solid rgba(16,43,69,.10);
  box-shadow: 0 24px 70px rgba(16,43,69,.12);
  text-align: center;
}
.afc-updates-coming-soon .afc-news-kicker {
  margin-inline: auto;
}
.afc-updates-coming-soon h2 {
  margin: 18px 0 10px;
  color: #102b45;
  font-size: clamp(2.1rem, 7vw, 4rem);
  font-weight: 950;
  letter-spacing: -.06em;
  line-height: 1;
}
.afc-updates-coming-soon p {
  max-width: 720px;
  margin: 0 auto;
  color: #5c6d86;
  font-size: clamp(1rem, 2vw, 1.18rem);
  line-height: 1.75;
  font-weight: 650;
}
@media (max-width: 575px) {
  .afc-updates-coming-soon {
    margin: 28px auto 48px;
    border-radius: 24px;
  }
}

