/* YBooks Modern UI Styles */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');

:root {
    --y-blue: #004877;
    --y-light-blue: #006eb5;
    --y-accent: #fbc02d;
    --y-dark: #0a192f;
    --y-bg-light: #f4f7f6;
    --y-bg-dark: #0f172a;
    --y-card-bg: rgba(255, 255, 255, 0.95);
    --y-text: #1e293b;
}

body.bgs {
    background: #f8fafc;
    font-family: 'Inter', sans-serif;
    color: var(--y-text);
    margin: 0;
    padding: 0;
}

/* Hide legacy headers and footers */
.cb-header, .header1, .header2, .footer:not(.eb-modern-footer) {
    display: none !important;
}

/* Modern Header Overrides */
.main-header {
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.main-header.scrolled {
    background: #fff;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
}

/* Scrolled state: dark text on white header - HIGHER SPECIFICITY */
body.bgs .main-header.scrolled .lang-switch {
    color: var(--y-blue) !important;
}

body.bgs .main-header.scrolled .lang-switcher span,
body.bgs .main-header.scrolled .lang-separator {
    color: var(--y-blue) !important;
    opacity: 0.3;
}

body.bgs .main-header.scrolled .hamburger span {
    background: var(--y-blue) !important;
}

body.bgs .main-header.scrolled .nav-links li a {
    color: var(--y-blue) !important;
}

body.bgs .main-header.scrolled .nav-links li a:hover {
    color: var(--y-accent) !important;
}

body.bgs .main-header.scrolled .tool-icon {
    color: var(--y-blue) !important;
}

.main-header.scrolled .dropdown-menu {
    background: #fff;
    border: 1px solid rgba(0,0,0,0.06);
}

.main-header.scrolled .dropdown-menu a {
    color: var(--y-text) !important;
}

.main-header.scrolled .dropdown-menu a:hover {
    color: var(--y-blue) !important;
}

/* Header right tools layout */
.header-right-tools {
    display: flex !important;
    align-items: center !important;
    gap: 20px !important;
}

/* Lang separator pipe */
.lang-separator {
    color: white;
    opacity: 0.3;
    font-size: 13px;
}

.main-header.scrolled .lang-separator {
    color: var(--y-blue);
    opacity: 0.3;
}

/* Search / Tool Icon */
.tool-icon {
    color: white !important;
    font-size: 18px;
    text-decoration: none !important;
    transition: all 0.3s ease;
}

.tool-icon:hover {
    opacity: 0.7;
}

/* RTL / Arabic fixes */
body.rtl .header-right-tools {
    flex-direction: row-reverse !important;
    gap: 15px !important;
}

body.rtl .lang-switcher {
    flex-direction: row-reverse !important;
}

body.rtl .lang-separator {
    margin: 0 5px;
}

/* Ensure icons are always visible against blue background initially */
.main-header:not(.scrolled) .tool-icon,
.main-header:not(.scrolled) .lang-switch,
.main-header:not(.scrolled) .lang-separator {
    color: white !important;
}

/* YBook Banner Section */
.inr_banner.cnt_txt {
    background: linear-gradient(135deg, #004877 0%, #006eb5 100%);
    padding: 100px 0 40px;
    margin-top: 0;
    min-height: auto;
    position: relative;
    overflow: hidden;
    color: white;
}

.inr_banner::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -10%;
    width: 120%;
    height: 120%;
    background: radial-gradient(circle, rgba(255,255,255,0.05) 0%, transparent 70%);
    z-index: 1;
}

.bhed_box {
    position: relative;
    z-index: 5;
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
    text-align: center;
}

.black_hed {
    font-size: 5rem;
    font-weight: 900;
    color: #fff;
    text-transform: none;
    letter-spacing: -2px;
    margin-top: 0;
    margin-bottom: 0;
    line-height: 1;
    text-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.hed_sml {
    font-size: 1.5rem;
    color: rgba(255,255,255,0.9);
    font-weight: 400;
    max-width: 700px;
    margin: 10px auto 30px;
    text-transform: none;
    line-height: 1.4;
}

.matter.simg {
    margin: 40px auto;
    transform: perspective(1000px) rotateX(10deg);
    transition: transform 0.5s ease;
}

.matter.simg:hover {
    transform: perspective(1000px) rotateX(0deg) scale(1.02);
}

.matter.simg img {
    max-width: 600px;
    width: 100%;
    filter: drop-shadow(0 30px 50px rgba(0,0,0,0.3));
}

.blue_btn {
    background: var(--y-accent);
    color: #1a1a1a !important;
    padding: 16px 40px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1.1rem;
    display: inline-block;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: none;
    box-shadow: 0 10px 20px rgba(251, 192, 45, 0.3);
}

.blue_btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(251, 192, 45, 0.4);
    background: #fff;
    color: var(--y-blue) !important;
}

/* Features Grid */
.inr_wrapper {
    padding: 100px 0;
    background: #f8fafc;
}

.box_th {
    background: #fff;
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.03);
    transition: all 0.4s ease;
    border: 1px solid rgba(0,0,0,0.02);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    min-height: 250px;
    justify-content: flex-start;
    flex: 0 1 360px;
}

.inr_full {
    width: 100% !important;
}

.inr_wrapper .wrapper {
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 20px;
}

.inr_wrapper .matter.animatedParent {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
    margin-top: 50px;
}



.box_th:hover {
    transform: translateY(-10px);
    box-shadow: 0 30px 60px rgba(0,0,0,0.08);
}

.box_th_icon {
    width: 80px;
    height: 80px;
    background: rgba(0, 72, 119, 0.05);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 25px;
    transition: all 0.3s ease;
}

.box_th_icon img {
    width: 40px;
    height: 40px;
    object-fit: contain;
}

.box_th_hed {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--y-blue);
    margin-bottom: 15px;
    text-transform: none;
}

.box_th_matter {
    font-size: 1rem;
    line-height: 1.7;
    color: #64748b;
}

/* Key Features Section */
.blue_wrapper {
    background: #f1f5f9;
    padding: 80px 0;
    color: #1e293b;
    position: relative;
    overflow: hidden;
}

.white_hed {
    font-size: 3rem;
    font-weight: 900;
    text-align: center;
    color: var(--y-blue);
    margin-bottom: 60px;
    letter-spacing: -1px;
}

.box_ths {
    width: 32%;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.05);
    border-radius: 24px;
    padding: 30px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.03);
}

.blue_wrapper .matter {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.box_ths ul {
    list-style: none;
    padding: 0;
}

.box_ths ul li {
    padding: 12px 0 12px 35px;
    position: relative;
    font-size: 1.05rem;
    color: #475569;
    border-bottom: 1px solid rgba(0,0,0,0.05);
    transition: all 0.3s ease;
}

.box_ths ul li:last-child {
    border-bottom: none;
}

.box_ths ul li::before {
    content: '\f058';
    font-family: 'FontAwesome';
    position: absolute;
    left: 0;
    color: var(--y-light-blue);
}

.box_ths ul li:hover {
    color: var(--y-blue);
    padding-left: 40px;
}

/* Modern Footer Styles */
.eb-modern-footer {
    background: #0a0f1d;
    color: #fff;
    padding: 100px 0 40px;
    font-family: 'Inter', sans-serif;
}

.section-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 60px;
    margin-bottom: 60px;
}

.footer-logo {
    height: 50px;
    margin-bottom: 25px;
    filter: brightness(0) invert(1);
}

.brand-desc {
    color: #94a3b8;
    line-height: 1.7;
    margin-bottom: 30px;
    font-size: 0.95rem;
}

.footer-socials {
    display: flex;
    gap: 15px;
}

.footer-socials a {
    width: 40px;
    height: 40px;
    background: rgba(255,255,255,0.05);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #94a3b8;
    transition: all 0.3s ease;
    text-decoration: none;
}

.footer-socials a:hover {
    background: var(--y-accent);
    color: #000;
    transform: translateY(-3px);
}

.footer-column h4 {
    color: #fff;
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 30px;
}

.footer-links {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 15px;
}

.footer-links a {
    color: #94a3b8;
    text-decoration: none;
    transition: all 0.3s ease;
}

.footer-links a:hover {
    color: var(--y-accent);
    padding-left: 8px;
}

.footer-bottom {
    padding-top: 40px;
    border-top: 1px solid rgba(255,255,255,0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #64748b;
    font-size: 0.9rem;
}

/* Animations */
.animatedParent .box_th {
    opacity: 0;
    transform: translateY(30px);
}

.animatedParent.reveal-active .box_th {
    opacity: 1;
    transform: translateY(0);
}

/* Sidebar Styling (Matching Index) */
.sidebar-menu {
    position: fixed;
    right: -400px;
    top: 0;
    width: 350px;
    height: 100vh;
    background: #fff;
    z-index: 9999;
    box-shadow: -10px 0 50px rgba(0,0,0,0.1);
    transition: 0.4s cubic-bezier(0.7, 0, 0.3, 1);
    padding: 60px 40px;
}

.sidebar-menu.open {
    right: 0;
}

.sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    backdrop-filter: blur(5px);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: 0.4s;
}

.sidebar-overlay.visible {
    opacity: 1;
    visibility: visible;
}

@media (max-width: 991px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
    .inr_wrapper .matter.animatedParent {
        grid-template-columns: repeat(2, 1fr);
    }
    .blue_wrapper .matter {
        justify-content: center;
    }
    .box_ths {
        width: 48%;
        margin: 10px 0;
    }
    .black_hed {
        font-size: 3.5rem;
    }
}

@media (max-width: 768px) {
    .inr_wrapper .matter.animatedParent {
        grid-template-columns: 1fr;
    }
    .box_ths {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .footer-grid {
        grid-template-columns: 1fr;
    }
    .black_hed {
        font-size: 2.5rem;
    }
}
