@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700&family=Playfair+Display:wght@600;700;800&display=swap');
@import url('https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css');

:root {
    /* Premium Palette - Red & Blue */
    --primary-color: #d8252b;
    /* Red (Accent) */
    --primary-dark: #b91d22;
    /* Darker Red */
    --primary-light: #d06f71;
    /* Muted Red */

    --secondary-color: #323079;
    /* Main Blue (Base) */
    --secondary-light: #6c6a8e;
    /* Muted Blue */

    /* Backgrounds */
    --bg-surface: #ffffff;
    --bg-background: #f5efeb;
    /* Beige */
    --bg-soft: #e8e2de;
    /* Slightly darker beige for contrast */

    /* Text */
    --text-primary: #2F4156;
    /* Navy for primary text */
    --text-secondary: #6c6a8e;
    /* Muted Blue for secondary text */
    --text-muted: #8898aa;

    /* Spacing */
    --header-height: 80px;

    /* Shadows - Soft & Modern */
    --shadow-sm: 0 2px 8px rgba(47, 65, 86, 0.08);
    /* Navy tinted shadow */
    --shadow-card: 0 10px 25px -5px rgba(47, 65, 86, 0.1), 0 8px 10px -6px rgba(47, 65, 86, 0.05);
    --shadow-hover: 0 20px 25px -5px rgba(47, 65, 86, 0.15), 0 10px 10px -5px rgba(47, 65, 86, 0.1);

    /* Radius */
    --radius-md: 1.25rem;
    --radius-lg: 2rem;

    /* Glass Effect */
    --glass-bg: rgba(255, 255, 255, 0.7);
    --glass-border: rgba(255, 255, 255, 0.4);
    --glass-blur: blur(12px);
}

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

body {
    font-family: 'Plus Jakarta Sans', sans-serif !important;
    background-color: var(--bg-background);
    color: var(--text-primary);
    line-height: 1.7;
    overflow-x: hidden;
    padding-top: var(--header-height);
    background-image: none;
    /* Removed gradient for clean beige look */
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'Playfair Display', serif;
    letter-spacing: -0.02em;
    color: var(--secondary-color);
}

a {
    text-decoration: none !important;
    color: inherit;
    transition: all 0.2s ease;
}

ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

img {
    max-width: 100%;
    height: auto;
}

/* Button Components - Clean & Pill Shaped */
.commonBtn {
    background: var(--primary-color) !important;
    color: white !important;
    padding: 0.6rem 1.5rem !important;
    border-radius: 50px !important;
    font-weight: 600 !important;
    font-size: 0.85rem !important;
    border: none !important;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(50, 48, 121, 0.3) !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    letter-spacing: 0.5px !important;
    text-transform: uppercase !important;
    text-decoration: none !important;
    white-space: nowrap !important;
}

.commonBtn:hover {
    background: var(--primary-dark) !important;
    transform: translateY(-3px) !important;
    box-shadow: 0 8px 25px rgba(50, 48, 121, 0.4) !important;
    text-decoration: none !important;
}

.btn-outline {
    background: transparent;
    color: var(--secondary-color) !important;
    border: 2px solid var(--secondary-color);
    padding: 0.75rem 2rem;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1rem;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
}

.btn-outline:hover {
    background: var(--secondary-color);
    color: white !important;
    transform: translateY(-2px);
}

/* Navbar - Floating Glass Design */
.navbar {
    background-color: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    height: 70px;
    position: fixed !important;
    top: 1rem;
    left: 1rem;
    right: 1rem;
    width: auto;
    border-radius: 16px;
    z-index: 1000;
    padding: 0 1.5rem;
    display: flex;
    align-items: center;
    border: 1px solid var(--glass-border);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.05);
}

.card,
.glass-card {
    background: var(--glass-bg) !important;
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--glass-border) !important;
    border-radius: var(--radius-md) !important;
    box-shadow: var(--shadow-card) !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.card:hover,
.glass-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover) !important;
    background: rgba(255, 255, 255, 0.8) !important;
}

.navbar.scrolled {
    background-color: rgba(255, 255, 255, 0.95);
    box-shadow: 0 10px 30px -10px rgba(47, 65, 86, 0.15);
    border-color: rgba(255, 255, 255, 0.5);
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    /* Full width when scrolled */
    border-radius: 0;
    height: var(--header-height);
    margin: 0;
}

/* Scrolled State Text Colors */
.navbar.scrolled .listItems li a {
    color: var(--secondary-color);
}

.navbar.scrolled .logo {
    filter: none;
}

.navbar .navbarWrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin: 0 auto;
}

.navbar .navLogo {
    display: flex;
    align-items: center;
}

.navbar .logo {
    height: 40px;
    /* Slightly smaller for elegance */
    width: auto;
}

.menuListWrapper {
    flex: 1;
    display: flex;
    justify-content: center;
}

.navbar .listItems {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    /* Reduced gap for pills */
}

.navbar .listItems li a {
    color: var(--secondary-color);
    font-weight: 600;
    font-size: 0.9rem;
    position: relative;
    padding: 0.4rem 0.65rem;
    border-radius: 50px;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.navbar .listItems li a:hover {
    color: var(--primary-color);
    background: rgba(87, 124, 142, 0.08);
}

.navbar .listItems li a::after {
    display: none;
    /* Remove underline */
}

.navbar .listItems li a:hover::after {
    display: none;
}

.loginBtnsWrapper {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Language Toggle Clean Styling */
.navbar .language-btn {
    background: transparent !important;
    color: var(--secondary-color) !important;
    border: none !important;
    padding: 0.5rem 1rem !important;
    box-shadow: none !important;
    font-weight: 600 !important;
    font-size: 0.95rem !important;
    display: flex !important;
    align-items: center !important;
    gap: 5px !important;
}

.navbar .language-btn::after {
    margin-left: 0.25rem;
    vertical-align: 0.255em;
    content: "";
    border-top: 0.3em solid;
    border-right: 0.3em solid transparent;
    border-bottom: 0;
    border-left: 0.3em solid transparent;
}

.navbar.scrolled .language-btn {
    color: var(--secondary-color) !important;
}

/* Hiding Elements Responsively */
.hamburg {
    display: none;
    font-size: 1.5rem;
    color: var(--secondary-color);
    cursor: pointer;
    margin-left: 1rem;
}

/* Hero Section */
.hero-home {
    position: relative;
    padding: 8rem 0 4rem;
    /* Increased top padding for floating nav */
    background: transparent;
    min-height: calc(100vh - 70px);
    display: flex;
    align-items: center;
    overflow: hidden;
}

.hero-content {
    position: relative;
    z-index: 2;
    padding-right: 2rem;
}

.hero-eyebrow {
    display: inline-block;
    color: var(--primary-color);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-size: 0.85rem;
    margin-bottom: 1rem;
    background: rgba(87, 124, 142, 0.1);
    /* Teal tint */
    padding: 0.5rem 1rem;
    border-radius: 50px;
}

.hero-title {
    font-size: 4rem;
    font-weight: 700;
    color: var(--secondary-color);
    line-height: 1.1;
    margin-bottom: 1.5rem;
    letter-spacing: -0.03em;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    font-weight: 500;
    margin-bottom: 2rem;
    max-width: 90%;
}

.hero-description {
    font-size: 1rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
    display: none;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 3rem;
}

/* Metrics - Clean Row */
.hero-metrics {
    display: flex;
    gap: 3rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(47, 65, 86, 0.1);
}

.metric-card {
    display: flex;
    flex-direction: column;
}

.metric-value {
    font-size: 2rem;
    font-weight: 800;
    color: var(--secondary-color);
    /* Navy for numbers */
    line-height: 1;
}

.metric-label {
    font-size: 0.9rem;
    color: var(--primary-color);
    /* Teal for labels */
    font-weight: 600;
    margin-top: 0.25rem;
}

/* Hero Image - Proper Containment */
.hero-image-wrapper {
    position: relative;
    z-index: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero-image-wrapper img {
    max-width: 100%;
    height: auto;
    filter: drop-shadow(0 20px 40px rgba(47, 65, 86, 0.15));
    border-radius: var(--radius-lg);
}

/* Sections Global */
section {
    padding: 5rem 0;
}

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

.section-header h2 {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--secondary-color);
    margin-bottom: 0.75rem;
}

.section-header p {
    font-size: 1.125rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

.section-link {
    display: inline-block;
    margin-top: 1rem;
    color: var(--primary-color);
    font-weight: 700;
    position: relative;
}

.section-link::after {
    content: '';
    display: block;
    width: 0;
    height: 2px;
    background: currentColor;
    transition: width 0.3s;
}

.section-link:hover::after {
    width: 100%;
}

/* Book Series / Cards - Creative Redesign */
.book-scroll {
    display: flex;
    overflow-x: auto;
    gap: 2rem;
    padding: 2rem 1rem 4rem;
    /* More breathing room */
    scroll-snap-type: x mandatory;
}

.book-card {
    min-width: 290px;
    max-width: 290px;
    scroll-snap-align: start;
    background: #ffffff;
    border-radius: 20px;
    /* Creative rounded */
    overflow: hidden;
    position: relative;
    border: 1px solid rgba(0, 0, 0, 0.03);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    /* Soft, deep shadow */
    transition: all 0.5s cubic-bezier(0.25, 0.8, 0.25, 1);
    display: flex;
    flex-direction: column;
}

.book-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    opacity: 0;
    transition: opacity 0.4s ease;
}

.book-card:hover {
    transform: translateY(-15px) scale(1.02);
    box-shadow: 0 20px 40px rgba(47, 65, 86, 0.15);
}

.book-card:hover::before {
    opacity: 1;
}

.book-cover {
    height: 340px;
    overflow: hidden;
    position: relative;
    background: radial-gradient(circle at center, #f8fafc 0%, #edf2f7 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.book-cover img {
    width: auto;
    height: 90%;
    max-width: 90%;
    object-fit: contain;
    filter: drop-shadow(0 15px 25px rgba(0, 0, 0, 0.15));
    transition: transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.book-card:hover .book-cover img {
    transform: scale(1.1) rotate(2deg);
}

.book-body {
    padding: 1.75rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    background: white;
    z-index: 1;
}

.book-body h3 {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--secondary-color);
    margin-bottom: 0.75rem;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.book-body p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 1.25rem;
    line-height: 1.6;
}

.book-meta {
    margin-top: auto;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.meta-pill {
    background: white;
    border: 1px solid rgba(87, 124, 142, 0.2);
    color: var(--primary-dark);
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.4rem 0.8rem;
    border-radius: 50px;
    transition: all 0.3s;
}

.book-card:hover .meta-pill {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.book-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.book-actions .btn-outline {
    padding: 0.6rem;
    font-size: 0.9rem;
    border-width: 2px;
}

/* Feature Grid - Creative Cards */
.feature-highlight {
    background-color: transparent;
    padding: 6rem 0;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2.5rem;
}

.feature-card {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
    /* Frosted */
    padding: 3.5rem 2.5rem;
    border-radius: 24px;
    text-align: center;
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.8);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
}

.feature-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 0;
    background: var(--primary-color);
    opacity: 0.05;
    transition: height 0.4s ease;
    z-index: 0;
    border-radius: 0 0 24px 24px;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px -10px rgba(87, 124, 142, 0.2);
    border-color: var(--primary-light);
}

.feature-card:hover::after {
    height: 100%;
}

.feature-icon {
    width: 90px;
    height: 90px;
    margin: 0 auto 1.5rem;
    background: white;
    color: var(--primary-color);
    border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%;
    /* Organic shape */
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    box-shadow: 0 10px 20px rgba(87, 124, 142, 0.15);
    transition: all 0.4s ease;
    position: relative;
    z-index: 1;
}

.feature-card:hover .feature-icon {
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    transform: scale(1.1) rotate(-10deg);
}

.feature-card h4 {
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: 1rem;
    color: var(--secondary-color);
    position: relative;
    z-index: 1;
}

.feature-card p {
    font-size: 1.05rem;
    color: var(--text-secondary);
    position: relative;
    z-index: 1;
    line-height: 1.6;
}

/* Language Button - Specific Request */
.language-btn {
    background-color: #323079 !important;
    color: white !important;
    border: none !important;
    padding: 0.6rem 2rem !important;
    border-radius: 50px !important;
    font-weight: 700 !important;
    box-shadow: 0 4px 15px rgba(33, 86, 121, 0.3);
    transition: all 0.3s ease;
}

.language-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(50, 48, 121, 0.4) !important;
    background-color: #2a2860 !important;
}

/* Footer - Premium Dark Navy & Larger */
footer {
    background-color: var(--secondary-color);
    color: #e2e8f0;
    padding: 2.5rem 0 1.5rem;
    font-size: 0.95rem;
    border-top: 5px solid var(--primary-color);
    position: relative;
}

footer a {
    color: #cbd5e1;
    text-decoration: none;
    font-weight: 400;
}

footer a:hover {
    color: #cbd5e1;
    padding-left: 0;
}

footer .footer-logo-box {
    background: white;
    padding: 1rem 1.5rem;
    border-radius: 12px;
    display: inline-block;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

footer .footer-logo {
    margin-bottom: 0;
    max-width: 180px;
    /* Adjusted size */
    height: auto;
    display: block;
    filter: none !important;
}

footer h5 {
    color: white;
    font-weight: 800;
    margin-bottom: 2rem;
    font-size: 1.25rem;
    /* Larger headers */
    letter-spacing: 0.5px;
    text-transform: uppercase;
    position: relative;
    padding-bottom: 1rem;
}

footer h5::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 3px;
    background: var(--primary-color);
    border-radius: 2px;
}

footer ul li {
    margin-bottom: 1rem;
}

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

footer .social-icons a {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #e2e8f0;
}

footer .social-icons a:hover {
    color: #e2e8f0;
    transform: none;
    box-shadow: none;
    background: transparent;
    border-color: transparent;
}

footer .copyright {
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    margin-top: 5rem;
    padding-top: 2rem;
    text-align: center;
    color: rgba(255, 255, 255, 0.4);
    font-size: 0.9rem;
}

/* Specific Icon Control */
footer .social-icons i,
footer .social-icons svg,
footer .social-icons img {
    width: 20px !important;
    height: 20px !important;
    font-size: 1.25rem;
    display: block;
    object-fit: contain;
}

/* Responsive Logic */

/* Tablet & Mobile */
@media (max-width: 991px) {
    .navbar .listItems {
        display: none;
        /* Hide Desktop Menu */
    }

    .loginBtnsWrapper {
        display: none;
        /* Hide desktop buttons for now, or move to offcanvas */
    }

    .hamburg {
        display: flex;
        align-items: center;
        justify-content: flex-end;
        width: auto;
        /* Show Burger */
    }

    .navbar {
        padding: 0 1rem;
        left: 0.5rem;
        right: 0.5rem;
    }

    .navbar .navbarWrapper {
        justify-content: space-between;
    }

    .menuListWrapper {
        flex: unset;
        justify-content: flex-end;
    }

    /* Hero Changes */
    .hero-home {
        flex-direction: column;
        text-align: center;
        padding-top: 2rem;
        height: auto;
    }

    .hero-content {
        padding-right: 0;
        margin-bottom: 2rem;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-actions,
    .hero-metrics {
        justify-content: center;
    }

    .section-header h2 {
        font-size: 2rem;
    }

    /* Offcanvas Clean Redesign */
    .offcanvas {
        background-color: #ffffff !important;
        border-left: none !important;
        box-shadow: -15px 0 35px rgba(0, 0, 0, 0.2) !important;
        width: 300px !important;
        height: 100vh !important;
        position: fixed !important;
        top: 0 !important;
        bottom: 0 !important;
        right: 0 !important;
        z-index: 9999 !important;
    }

    .offcanvas-header {
        background-color: #ffffff !important;
        border-bottom: 1px solid rgba(0, 0, 0, 0.05);
        padding: 1.5rem !important;
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
    }

    .offcanvas-body {
        background-color: #ffffff !important;
        padding: 2rem 1.5rem !important;
        display: flex;
        flex-direction: column;
    }

    .offcanvas .listItems {
        display: flex;
        flex-direction: column;
        width: 100%;
        gap: 0;
        margin-bottom: 2rem;
    }

    .offcanvas .listItems li {
        width: 100%;
        border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    }

    .offcanvas .listItems li a,
    .offcanvas .listItems li .dropdown-toggle {
        display: block;
        width: 100%;
        padding: 1.2rem 0;
        font-size: 1.2rem;
        color: var(--secondary-color);
        font-weight: 700;
        text-align: left;
    }

    .offcanvas .listItems li:last-child {
        border-bottom: none;
    }

    .offcanvas .listItems li a:hover,
    .offcanvas .listItems li a.active {
        color: var(--primary-color) !important;
    }

    .offcanvas .dropdown-menu {
        position: static !important;
        transform: none !important;
        float: none !important;
        width: 100% !important;
        border: none !important;
        background: transparent !important;
        padding: 0 !important;
        box-shadow: none !important;
        margin: 0 !important;
        display: none;
    }

    .offcanvas .dropdown-menu.show {
        display: block !important;
    }

    .offcanvas .dropdown-item {
        padding: 1rem 0 1rem 1.5rem !important;
        font-size: 1.1rem !important;
        color: var(--secondary-color) !important;
        font-weight: 600 !important;
        border-bottom: 1px solid rgba(0, 0, 0, 0.05) !important;
        background: transparent !important;
        white-space: normal !important;
    }

    .offcanvas .dropdown-item:last-child {
        border-bottom: none !important;
    }

    .offcanvas .dropdown-item:hover {
        color: var(--primary-color) !important;
        background: transparent !important;
        padding-left: 2rem !important;
    }

    .offcanvas hr {
        display: none !important;
    }

    .offcanvas .dropdown {
        width: 100% !important;
        display: block !important;
    }

    .offcanvas .commonBtn {
        width: 100%;
        margin-bottom: 1rem;
        padding: 1rem !important;
        font-size: 1.1rem !important;
        border-radius: 50px !important;
    }

    .offcanvas .language-btn {
        background: transparent !important;
        color: var(--secondary-color) !important;
        border: none !important;
        box-shadow: none !important;
        padding: 1.2rem 0 !important;
        text-align: left !important;
        font-weight: 700 !important;
        font-size: 1.2rem !important;
        display: block !important;
        width: 100% !important;
    }

    .offcanvas .dropdown-toggle::after {
        margin-left: 0.5rem !important;
    }
}

/* Mobile Adjustments */
@media (max-width: 768px) {
    footer {
        padding: 3rem 0;
        text-align: center;
    }

    footer .social-icons {
        justify-content: center;
        margin-top: 2rem;
    }

    footer .col-lg-3 {
        margin-bottom: 2rem;
    }
}

/* Mobile Specific */
@media (max-width: 576px) {
    .hero-title {
        font-size: 2rem;
    }

    .hero-image-wrapper img {
        width: 80%;
    }

    .hero-metrics {
        flex-direction: column;
        gap: 1.5rem;
    }

    .feature-grid {
        grid-template-columns: 1fr;
    }
}