/* WebAsha brand alignment — matches webasha.com design tokens */
:root {
    --wa-primary: #e50914;
    --wa-primary-hover: #a60202;
    --wa-primary-light: #fff1f1;
    --wa-secondary: #121212;
    --wa-surface: #f6f7f9;
    --wa-border: #e5e7eb;
    --wa-muted: #6b7280;
    --wa-text-secondary: #5d646d;
    --wa-radius: 8px;
}

body {
    color: var(--wa-secondary);
}

h1, h2, h3, h4, h5, h6 {
    color: var(--wa-secondary);
}

a:hover,
.post-title a:hover,
.nav-main a:hover {
    color: var(--wa-primary-hover);
}

/* Buttons — webasha rounded corners and hover shade */
.btn,
input[type="submit"],
button[type="submit"] {
    border-radius: var(--wa-radius);
}

.btn[style*="background"]:hover,
.btn-custom:hover,
.btn-load-more:hover {
    background-color: var(--wa-primary-hover) !important;
    border-color: var(--wa-primary-hover) !important;
}

/* Category chips — light red pill like webasha.com tags */
.popular-tags a:hover,
.tag-list a:hover {
    background-color: var(--wa-primary-light);
    color: var(--wa-primary);
    border-color: var(--wa-primary);
}

/* Cards and surfaces */
.sidebar-widget,
.card {
    border-radius: var(--wa-radius);
}

/* Footer — exact webasha near-black */
footer,
.footer {
    background-color: var(--wa-secondary) !important;
}

/* Selection highlight in brand red */
::selection {
    background: var(--wa-primary);
    color: #fff;
}

/* Sticky nav — clean white with subtle border like webasha.com */
.nav-main .navbar,
.navbar-sticky {
    border-bottom: 1px solid var(--wa-border);
}

/* Post cards — rounded thumbs with gentle zoom, webasha card feel */
.post-image-container {
    border-radius: var(--wa-radius);
    overflow: hidden;
}

.post-image-container img {
    transition: transform .35s ease;
}

.post-item-horizontal:hover .post-image-container img,
.slider-item:hover .post-image-container img {
    transform: scale(1.04);
}

.post-item-horizontal {
    border-radius: var(--wa-radius);
    transition: background-color .2s ease;
    padding: .5rem;
    margin-left: -.5rem;
    margin-right: -.5rem;
}

.post-item-horizontal:hover {
    background-color: var(--wa-surface);
}

/* Meta text (dates, view counts) in webasha's secondary tone */
.post-meta,
.caption small,
.post-item-horizontal small {
    color: var(--wa-text-secondary);
}

/* Nav items — red underline indicator on hover like webasha.com */
.navbar-nav .nav-item > a {
    position: relative;
}

.navbar-nav .nav-item > a:hover {
    color: var(--wa-primary) !important;
}

/* Slider caption overlay — stronger contrast gradient */
.slider-item .caption {
    background: linear-gradient(180deg, rgba(18,18,18,0) 0%, rgba(18,18,18,.85) 100%);
    border-radius: 0 0 var(--wa-radius) var(--wa-radius);
}

/* Dropdown menus — webasha card style: soft shadow, hairline border, red hover */
body .dropdown-menu,
body .dropdown .dropdown-menu,
body .dropstart .dropdown-menu {
    border-radius: var(--wa-radius);
    border: 1px solid var(--wa-border);
    box-shadow: 0 8px 24px rgba(18, 18, 18, .08);
    padding: .4rem;
}

body .dropdown-menu .dropdown-item {
    border-radius: 6px;
    padding: .5rem .75rem;
}

body .dropdown-menu .dropdown-item:hover,
body .dropdown-menu .dropdown-item:focus {
    background-color: var(--wa-primary-light);
    color: var(--wa-primary);
}

/* Active nav link — red text + underline indicator like webasha.com */
.navbar-nav .nav-link.active {
    color: var(--wa-primary) !important;
    box-shadow: inset 0 -2px 0 var(--wa-primary);
}

/* Pagination & load-more in brand red */
.pagination .page-item.active .page-link {
    background-color: var(--wa-primary);
    border-color: var(--wa-primary);
}

.pagination .page-link {
    color: var(--wa-primary);
    border-radius: 6px;
}

.pagination .page-link:hover {
    background-color: var(--wa-primary-light);
    color: var(--wa-primary-hover);
}

/* Forms — red focus ring like webasha.com inputs */
input:focus,
textarea:focus,
select:focus,
.form-control:focus {
    border-color: var(--wa-primary) !important;
    box-shadow: 0 0 0 3px rgba(229, 9, 20, .12) !important;
    outline: none;
}

/* Post content — readable measure and webasha link style */
.post-text a,
.post-content a {
    color: var(--wa-primary);
    text-decoration-color: rgba(229, 9, 20, .35);
}

.post-text a:hover,
.post-content a:hover {
    color: var(--wa-primary-hover);
}

.post-text blockquote,
.post-content blockquote {
    border-left: 4px solid var(--wa-primary);
    background: var(--wa-surface);
    border-radius: 0 var(--wa-radius) var(--wa-radius) 0;
    padding: 1rem 1.25rem;
}

/* Navbar CTA — same "Enroll Now" button as webasha.com */
.wa-cta {
    align-items: center;
    background-color: var(--wa-primary);
    color: #fff !important;
    font-weight: 600;
    font-size: .9rem;
    padding: .5rem 1.1rem;
    border-radius: var(--wa-radius);
    margin-left: .75rem;
    white-space: nowrap;
    transition: background-color .2s ease;
}

.wa-cta:hover {
    background-color: var(--wa-primary-hover);
    color: #fff !important;
}

/* Footer newsletter — webasha input group: rounded field + solid red button */
.widget-newsletter .newsletter {
    border-radius: var(--wa-radius);
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, .15);
}

.widget-newsletter .newsletter-input {
    background: rgba(255, 255, 255, .06);
    color: #fff;
    border: none;
}

.widget-newsletter .newsletter-input::placeholder {
    color: rgba(255, 255, 255, .55);
}

.widget-newsletter .newsletter-button {
    background-color: var(--wa-primary);
    color: #fff;
    font-weight: 600;
    border: none;
    transition: background-color .2s ease;
}

.widget-newsletter .newsletter-button:hover {
    background-color: var(--wa-primary-hover);
}

/* Footer links — muted gray, red on hover like webasha.com footer */
footer a:hover,
.footer a:hover,
.footer-widget a:hover,
.nav-footer a:hover {
    color: var(--wa-primary) !important;
}

/* Wide layout — main container spans 90% of the viewport on desktop */
@media (min-width: 1200px) {
    body .container-xl {
        max-width: 90%;
    }
}

/* Categories widget — webasha pill chips with count badges + show more */
.sidebar-categories .wa-cat-chip {
    display: inline-flex;
    align-items: center;
    gap: .45rem;
    background: var(--wa-surface);
    border: 1px solid var(--wa-border);
    border-radius: 999px;
    color: var(--wa-secondary);
    font-size: .85rem;
    font-weight: 500;
    padding: .35rem .4rem .35rem .85rem;
    margin: 0 .4rem .5rem 0;
    transition: background-color .2s ease, border-color .2s ease, color .2s ease;
}

.sidebar-categories .wa-cat-chip:hover,
.sidebar-categories a.btn.wa-cat-chip:hover,
.sidebar-categories a.btn.wa-cat-chip:focus {
    background: var(--wa-primary-light) !important;
    border-color: var(--wa-primary) !important;
    color: var(--wa-primary) !important;
}

.sidebar-categories .wa-cat-count {
    background: #fff;
    border: 1px solid var(--wa-border);
    border-radius: 999px;
    color: var(--wa-muted);
    font-size: .72rem;
    font-weight: 600;
    line-height: 1;
    padding: .28rem .5rem;
    min-width: 1.9em;
    text-align: center;
    transition: inherit;
}

.sidebar-categories .wa-cat-chip:hover .wa-cat-count {
    background: var(--wa-primary);
    border-color: var(--wa-primary);
    color: #fff;
}

.sidebar-categories .wa-cat-hidden {
    display: none;
}

.sidebar-categories.wa-cat-expanded .wa-cat-hidden {
    display: inline-flex;
}

.wa-cat-toggle {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    background: none;
    border: none;
    color: var(--wa-primary);
    font-size: .85rem;
    font-weight: 600;
    padding: .25rem 0;
    margin-top: .25rem;
    cursor: pointer;
}

.wa-cat-toggle:hover {
    color: var(--wa-primary-hover);
}

.wa-cat-toggle svg {
    transition: transform .2s ease;
}

.wa-cat-toggle.wa-cat-open svg {
    transform: rotate(180deg);
}

body.dark-mode .sidebar-categories .wa-cat-chip {
    background: #16161a;
    border-color: #26262c;
    color: #e5e7eb;
}

body.dark-mode .sidebar-categories .wa-cat-count {
    background: #0b0b0d;
    border-color: #26262c;
    color: #9ca3af;
}

body.dark-mode .sidebar-categories .wa-cat-chip:hover {
    background: rgba(229, 9, 20, .15);
    border-color: var(--wa-primary);
    color: #ff4d55;
}

/* Hide the top bar (Login/Register + theme toggle) — replaced by nav icon */
.top-bar {
    display: none !important;
}

/* Nav user icon */
.wa-nav-user {
    display: inline-flex;
    align-items: center;
    margin-left: .5rem;
    color: inherit;
}

.wa-nav-user:hover {
    color: var(--wa-primary);
}

/* Top bar (Login/Register + theme switch) hidden on desktop — user icon in menu row instead */
@media (min-width: 992px) {
    .top-bar {
        display: none !important;
    }
}

a.wa-nav-user,
.wa-nav-user {
    margin-left: .25rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: transparent !important;
    color: #000 !important;
}

a.wa-nav-user:hover,
.wa-nav-user:hover {
    color: var(--wa-primary) !important;
    background: var(--wa-primary-light) !important;
}

body.dark-mode .wa-nav-user {
    color: #e5e7eb;
}

/* Sticky enquiry widget — vertical tab + slide-in panel with CRM form */
.wa-enquiry-tab {
    position: fixed;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    z-index: 1050;
    writing-mode: vertical-rl;
    background: var(--wa-primary);
    color: #fff;
    border: none;
    border-radius: var(--wa-radius) 0 0 var(--wa-radius);
    font-weight: 600;
    font-size: .9rem;
    letter-spacing: .03em;
    padding: 1rem .55rem;
    cursor: pointer;
    box-shadow: -2px 2px 10px rgba(18, 18, 18, .25);
    transition: background-color .2s ease, padding .2s ease;
}

.wa-enquiry-tab:hover {
    background: var(--wa-primary-hover);
    padding-right: .8rem;
}

.wa-enquiry-overlay {
    position: fixed;
    inset: 0;
    background: rgba(18, 18, 18, .45);
    z-index: 1051;
    opacity: 0;
    transition: opacity .25s ease;
}

.wa-enquiry-overlay.wa-open {
    opacity: 1;
}

.wa-enquiry-panel {
    position: fixed;
    top: 0;
    right: 0;
    height: 100dvh;
    width: 400px;
    max-width: 92vw;
    background: #fff;
    z-index: 1052;
    display: flex;
    flex-direction: column;
    box-shadow: -8px 0 30px rgba(18, 18, 18, .25);
    transform: translateX(100%);
    transition: transform .3s ease;
}

.wa-enquiry-panel.wa-open {
    transform: translateX(0);
}

.wa-enquiry-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: var(--wa-primary);
    color: #fff;
    padding: .8rem 1rem;
}

.wa-enquiry-header h5 {
    color: #fff;
    font-size: 1.05rem;
    font-weight: 700;
    margin: 0;
}

.wa-enquiry-close {
    background: none;
    border: none;
    color: #fff;
    font-size: 1.6rem;
    line-height: 1;
    cursor: pointer;
    padding: 0 .2rem;
}

.wa-enquiry-note {
    margin: 0;
    padding: .7rem 1rem;
    font-size: .88rem;
    color: var(--wa-text-secondary);
    border-bottom: 1px solid var(--wa-border);
}

.wa-enquiry-body {
    flex: 1;
    overflow: hidden;
}

.wa-enquiry-body iframe {
    width: 100%;
    height: 100%;
    border: none;
}

.wa-enquiry-whatsapp {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .5rem;
    margin: .75rem 1rem 1rem;
    background: #25d366;
    color: #fff !important;
    font-weight: 600;
    padding: .7rem 1rem;
    border-radius: 999px;
    transition: background-color .2s ease;
}

.wa-enquiry-whatsapp:hover {
    background: #1eb857;
}

body.wa-enquiry-lock {
    overflow: hidden;
}

@media (max-width: 575px) {
    .wa-enquiry-tab {
        font-size: .8rem;
        padding: .8rem .45rem;
    }
}

body.dark-mode .wa-enquiry-panel {
    background: #16161a;
}

body.dark-mode .wa-enquiry-note {
    border-color: #26262c;
}

/* Dark mode — align with webasha's near-black palette */
body.dark-mode {
    background-color: #0b0b0d;
    color: #e5e7eb;
}

body.dark-mode h1, body.dark-mode h2, body.dark-mode h3,
body.dark-mode h4, body.dark-mode h5, body.dark-mode h6 {
    color: #f3f4f6;
}

body.dark-mode .dropdown-menu {
    background-color: #16161a;
    border-color: #26262c;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .5);
}

body.dark-mode .dropdown-menu .dropdown-item {
    color: #e5e7eb;
}

body.dark-mode .dropdown-menu .dropdown-item:hover {
    background-color: rgba(229, 9, 20, .15);
    color: #ff4d55;
}

body.dark-mode .post-item-horizontal:hover {
    background-color: #16161a;
}

body.dark-mode .post-text blockquote,
body.dark-mode .post-content blockquote {
    background: #16161a;
}
