/* ─── Smooth scroll ─────────────────────────────────────────────────────── */
html { scroll-behavior: smooth; }
section { scroll-margin-top: 96px; }

/* Light theme overrides */
html.light body { background: #f8fafc !important; color: #0f172a !important; }
html.light #main-navbar {
    background: rgba(255,255,255,0.94) !important;
    border-color: rgba(148,163,184,0.35) !important;
    box-shadow: 0 10px 30px rgba(15,23,42,0.08) !important;
    backdrop-filter: blur(14px);
}
html.light #main-navbar .navbar-text,
html.light #main-navbar .text-white { color: #0f172a !important; }
html.light #main-navbar .text-gray-300,
html.light #main-navbar .text-gray-400 { color: #475569 !important; }
html.light #mobile-drawer {
    background: #ffffff !important;
    border-color: rgba(148,163,184,0.35) !important;
}
html.light #mobile-drawer .text-white { color: #0f172a !important; }
html.light #mobile-drawer .text-gray-300,
html.light #mobile-drawer .text-gray-400 { color: #475569 !important; }
html.light section:not(#home),
html.light .contact-section { background: #f8fafc !important; }
html.light section:not(#home) .text-white,
html.light section:not(#home) h2,
html.light section:not(#home) h3 { color: #0f172a !important; }
html.light section:not(#home) .text-gray-400,
html.light section:not(#home) .text-gray-300 { color: #475569 !important; }
html.light section:not(#home) .bg-\[\#060b18\],
html.light section:not(#home) .bg-\[\#080d1c\],
html.light section:not(#home) .bg-\[\#0d1526\],
html.light section:not(#home) .bg-blue-950\/20,
html.light section:not(#home) .bg-blue-950\/30 {
    background: #ffffff !important;
}
html.light section:not(#home) .border-blue-900\/40,
html.light section:not(#home) .border-blue-900\/50,
html.light section:not(#home) .border-blue-800\/50 {
    border-color: rgba(148,163,184,0.35) !important;
}
html.light .form-input {
    background: #ffffff;
    border-color: #cbd5e1;
    color: #0f172a;
}
html.light .form-input::placeholder { color: #94a3b8; }
html.light .form-label { color: #334155; }
html.light #floating-btns #scroll-top-btn {
    background: rgba(255,255,255,0.94) !important;
    border-color: rgba(148,163,184,0.45) !important;
    color: #475569 !important;
}

/* ─── Scrollbar ─────────────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: #0a0f1e; }
::-webkit-scrollbar-thumb { background: #1e3a5f; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #22d3ee; }

/* ─── Swiper custom ─────────────────────────────────────────────────────── */
.swiper-button-next,
.swiper-button-prev {
    color: #22d3ee !important;
    background: rgba(10,15,30,0.7) !important;
    width: 40px !important;
    height: 40px !important;
    border-radius: 8px !important;
    border: 1px solid rgba(34,211,238,0.2) !important;
    backdrop-filter: blur(8px);
}
.swiper-button-next::after,
.swiper-button-prev::after { font-size: 14px !important; font-weight: 700; }
.swiper-button-next:hover,
.swiper-button-prev:hover {
    background: rgba(34,211,238,0.15) !important;
    border-color: rgba(34,211,238,0.5) !important;
}
.swiper-pagination-bullet { background: rgba(34,211,238,0.4) !important; opacity: 1 !important; }
.swiper-pagination-bullet-active { background: #22d3ee !important; width: 24px !important; border-radius: 4px !important; }

/* ─── Partner scroll animation ──────────────────────────────────────────── */
.partner-scroll-track { animation: partnerScrollAnim 35s linear infinite; }
.partner-scroll-track:hover { animation-play-state: paused !important; }
.partner-strip {
    background: #0d1526;
}
.partner-fade-left {
    background: linear-gradient(to right, #0d1526, rgba(13,21,38,0));
}
.partner-fade-right {
    background: linear-gradient(to left, #0d1526, rgba(13,21,38,0));
}
.partner-logo-card {
    height: 74px;
    min-width: 188px;
    padding: 0 20px;
}
.partner-logo-card img,
.partner-logo-card .partner-logo-text {
    border-radius: 0.75rem;
}
.partner-logo {
    padding: 0.6rem 1rem;
    background: rgba(255,255,255,0.92);
    border: 1px solid rgba(148,163,184,0.22);
    box-shadow: 0 12px 26px rgba(2,8,23,0.18);
    opacity: 0.82;
}
.partner-logo-card:hover .partner-logo {
    opacity: 1;
    transform: translateY(-2px);
    background: #ffffff;
    border-color: rgba(34,211,238,0.42);
}
.partner-logo-text {
    color: #cbd5e1;
    padding: 0.6rem 1rem;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(148,163,184,0.2);
}
.partner-logo-card:hover .partner-logo-text {
    color: #22d3ee;
}
@keyframes partnerScrollAnim {
    0%   { transform: translateX(0); }
    100% { transform: translateX(-33.333%); }
}

/* ─── Line clamp ────────────────────────────────────────────────────────── */
.line-clamp-1 { overflow:hidden; display:-webkit-box; -webkit-line-clamp:1; -webkit-box-orient:vertical; }
.line-clamp-2 { overflow:hidden; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; }
.line-clamp-3 { overflow:hidden; display:-webkit-box; -webkit-line-clamp:3; -webkit-box-orient:vertical; }

/* ─── CountUp animation ─────────────────────────────────────────────────── */
@keyframes countUp {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}
.count-up { animation: countUp 0.5s ease forwards; }

/* ─── Gallery thumbs active ─────────────────────────────────────────────── */
.gallery-thumbs .swiper-slide-thumb-active div { border-color: #22d3ee !important; }

/* ─── Prose dark mode ───────────────────────────────────────────────────── */
.prose-dark { color: #d1d5db; }
.prose-dark h1,.prose-dark h2,.prose-dark h3,.prose-dark h4 { color: #fff; }
.prose-dark a { color: #22d3ee; }
.prose-dark strong { color: #fff; }
.prose-dark blockquote { border-left-color: #22d3ee; color: #9ca3af; }
.prose-dark li { color: #d1d5db; }
.prose-dark code { color: #22d3ee; background: rgba(34,211,238,0.1); padding: 2px 6px; border-radius: 4px; }
.prose-dark pre { background: #0a0f1e; border: 1px solid rgba(34,211,238,0.2); }

/* ─── CMS Sidebar ───────────────────────────────────────────────────────── */
.cms-body { overflow-x: hidden; }
.cms-sidebar {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 50;
    height: 100vh;
    width: 16rem;
    transform: translateX(0);
    transition: transform 0.3s ease;
}
.cms-sidebar nav { min-height: 0; }
.cms-main { min-width: 0; }
.cms-sidebar-overlay { display: none; }
@media (max-width: 1023px) {
    .cms-sidebar { transform: translateX(-100%); }
    .cms-sidebar.open { transform: translateX(0); }
    .cms-sidebar-overlay { position: fixed; inset: 0; background: rgba(0,0,0,0.55); backdrop-filter: blur(4px); z-index: 40; }
}

/* ─── CMS Table ─────────────────────────────────────────────────────────── */
.cms-table th { background: #1e293b; color: #94a3b8; font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.05em; padding: 0.75rem 1rem; }
.cms-table td { padding: 0.75rem 1rem; border-bottom: 1px solid #1e293b; vertical-align: middle; }
.cms-table tr:hover td { background: rgba(30,41,59,0.5); }

/* ─── Form inputs ───────────────────────────────────────────────────────── */
.form-input {
    width: 100%; border-radius: 0.5rem; border: 1px solid #334155;
    background: #0f172a; color: #f1f5f9; padding: 0.625rem 0.875rem;
    font-size: 0.875rem; transition: border-color 0.2s;
    outline: none;
}
.form-input:focus { border-color: #22d3ee; box-shadow: 0 0 0 3px rgba(34,211,238,0.1); }
.form-input::placeholder { color: #475569; }
.form-label { display: block; font-size: 0.875rem; font-weight: 500; color: #94a3b8; margin-bottom: 0.375rem; }
.form-error { font-size: 0.75rem; color: #f87171; margin-top: 0.25rem; }

/* Contact section */
.contact-grid { align-items: stretch; }
.contact-map,
.contact-form-card,
.contact-info-card {
    box-shadow: 0 20px 50px rgba(2,8,23,0.18);
}
.contact-info-card {
    display: flex;
    align-items: flex-start;
    gap: 0.875rem;
    min-height: 104px;
    padding: 1rem;
    border: 1px solid rgba(30,58,138,0.4);
    border-radius: 1rem;
    background: rgba(23,37,84,0.22);
    color: #e2e8f0;
    transition: transform 0.2s, border-color 0.2s, background-color 0.2s;
}
.contact-info-card:hover {
    transform: translateY(-2px);
    border-color: rgba(34,211,238,0.5);
    background: rgba(14,116,144,0.14);
}
.contact-info-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    flex: 0 0 2.5rem;
    border-radius: 0.75rem;
    background: rgba(34,211,238,0.12);
    color: #22d3ee;
}
.contact-info-label {
    display: block;
    margin-bottom: 0.25rem;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #22d3ee;
}
.contact-info-value {
    display: block;
    color: #f8fafc;
    font-size: 0.94rem;
    line-height: 1.45;
    overflow-wrap: anywhere;
}
html.light .contact-info-card,
html.light .contact-form-card,
html.light .contact-map {
    background: #ffffff !important;
    border-color: rgba(148,163,184,0.35) !important;
    box-shadow: 0 20px 50px rgba(15,23,42,0.08);
}
html.light .contact-info-card { color: #0f172a; }
html.light .contact-info-card:hover { background: #f8fafc !important; }
html.light .contact-info-value { color: #0f172a; }

@media (max-width: 640px) {
    .contact-map,
    .contact-map iframe {
        min-height: 340px !important;
    }
}

/* ─── Btn primary ───────────────────────────────────────────────────────── */
.btn-primary {
    display: inline-flex; align-items: center; gap: 0.5rem;
    padding: 0.625rem 1.25rem; border-radius: 0.5rem;
    background: linear-gradient(to right, #2563eb, #06b6d4);
    color: #fff; font-size: 0.875rem; font-weight: 600;
    transition: all 0.2s; cursor: pointer; border: none;
}
.btn-primary:hover { background: linear-gradient(to right, #1d4ed8, #0891b2); transform: translateY(-1px); }
.btn-primary:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

.btn-secondary {
    display: inline-flex; align-items: center; gap: 0.5rem;
    padding: 0.625rem 1.25rem; border-radius: 0.5rem;
    border: 1px solid #334155; color: #94a3b8;
    font-size: 0.875rem; font-weight: 500;
    transition: all 0.2s; cursor: pointer; background: transparent;
}
.btn-secondary:hover { border-color: #22d3ee; color: #22d3ee; }

.btn-danger {
    display: inline-flex; align-items: center; gap: 0.5rem;
    padding: 0.5rem 1rem; border-radius: 0.5rem;
    background: rgba(239,68,68,0.1); border: 1px solid rgba(239,68,68,0.3);
    color: #f87171; font-size: 0.875rem; font-weight: 500;
    transition: all 0.2s; cursor: pointer;
}
.btn-danger:hover { background: rgba(239,68,68,0.2); border-color: #f87171; }

/* ─── Badge ─────────────────────────────────────────────────────────────── */
.badge-active { display:inline-flex; align-items:center; gap:4px; padding:2px 10px; border-radius:9999px; font-size:0.75rem; font-weight:500; background:rgba(34,197,94,0.1); color:#4ade80; border:1px solid rgba(34,197,94,0.2); }
.badge-inactive { display:inline-flex; align-items:center; gap:4px; padding:2px 10px; border-radius:9999px; font-size:0.75rem; font-weight:500; background:rgba(100,116,139,0.1); color:#94a3b8; border:1px solid rgba(100,116,139,0.2); }
.badge-pending { display:inline-flex; align-items:center; gap:4px; padding:2px 10px; border-radius:9999px; font-size:0.75rem; font-weight:500; background:rgba(234,179,8,0.1); color:#facc15; border:1px solid rgba(234,179,8,0.2); }

/* ─── Alert ─────────────────────────────────────────────────────────────── */
.alert-success { padding:0.875rem 1rem; border-radius:0.5rem; background:rgba(34,197,94,0.1); border:1px solid rgba(34,197,94,0.3); color:#4ade80; font-size:0.875rem; margin-bottom:1rem; }
.alert-error   { padding:0.875rem 1rem; border-radius:0.5rem; background:rgba(239,68,68,0.1); border:1px solid rgba(239,68,68,0.3); color:#f87171; font-size:0.875rem; margin-bottom:1rem; }

/* ─── Transition helpers ────────────────────────────────────────────────── */
.transition-colors { transition: color 0.2s, background-color 0.2s, border-color 0.2s; }

/* News pages */
.news-hero,
.news-related {
    background: #060b18;
}
.news-page,
.news-detail-page {
    background: #0a0f1e;
}
.news-card,
.news-comment-card,
.news-reply-card,
.news-comment-form {
    background: rgba(23,37,84,0.28);
    border-color: rgba(30,58,138,0.42);
}
.news-search-input {
    background: rgba(23,37,84,0.5);
    border-color: rgba(30,64,175,0.5);
}
.news-category-badge,
.news-tag {
    background: rgba(30,58,138,0.8);
}
.news-card-title,
.news-section-title,
.news-comment-name {
    color: #f8fafc;
}
.news-card-excerpt,
.news-excerpt,
.news-comment-text {
    color: #cbd5e1;
}
.news-muted,
.news-meta {
    color: #94a3b8;
}
.news-share,
.news-meta {
    border-color: rgba(30,58,138,0.42);
}
.news-share-link,
.news-filter,
.news-pagination-link {
    border-color: rgba(30,64,175,0.5);
}
.news-empty-comments {
    border-color: rgba(30,58,138,0.42);
    color: #64748b;
}

html.light .partner-strip {
    background: #f8fafc !important;
    border-color: rgba(148,163,184,0.35) !important;
}
html.light .partner-fade-left {
    background: linear-gradient(to right, #f8fafc, rgba(248,250,252,0));
}
html.light .partner-fade-right {
    background: linear-gradient(to left, #f8fafc, rgba(248,250,252,0));
}
html.light .partner-logo {
    background: #ffffff;
    border-color: rgba(148,163,184,0.32);
    box-shadow: 0 12px 26px rgba(15,23,42,0.08);
    opacity: 0.9;
}
html.light .partner-logo-card:hover .partner-logo {
    border-color: rgba(8,145,178,0.45);
}
html.light .partner-logo-text {
    color: #334155;
    background: #ffffff;
    border-color: rgba(148,163,184,0.32);
}
html.light .news-hero,
html.light .news-related,
html.light .news-page,
html.light .news-detail-page {
    background: #f8fafc !important;
}
html.light .news-hero h1,
html.light .news-section-title,
html.light .news-card-title,
html.light .news-comment-name {
    color: #0f172a !important;
}
html.light .news-hero p,
html.light .news-card-excerpt,
html.light .news-excerpt,
html.light .news-comment-text {
    color: #475569 !important;
}
html.light .news-card,
html.light .news-comment-card,
html.light .news-reply-card,
html.light .news-comment-form,
html.light .news-empty-comments {
    background: #ffffff !important;
    border-color: rgba(148,163,184,0.35) !important;
    box-shadow: 0 18px 44px rgba(15,23,42,0.08);
}
html.light .news-search-input {
    background: #ffffff !important;
    border-color: #cbd5e1 !important;
    color: #0f172a !important;
}
html.light .news-search-input::placeholder {
    color: #94a3b8 !important;
}
html.light .news-filter:not(.is-active),
html.light .news-pagination-link:not(.is-active),
html.light .news-share-link {
    color: #475569 !important;
    border-color: rgba(148,163,184,0.45) !important;
    background: #ffffff;
}
html.light .news-filter:not(.is-active):hover,
html.light .news-pagination-link:not(.is-active):hover,
html.light .news-share-link:hover {
    color: #0891b2 !important;
    border-color: rgba(8,145,178,0.5) !important;
}
html.light .news-meta,
html.light .news-share {
    color: #64748b !important;
    border-color: rgba(148,163,184,0.35) !important;
}
html.light .news-back-link,
html.light .news-muted {
    color: #475569 !important;
}
html.light .news-category-badge,
html.light .news-tag {
    background: rgba(236,254,255,0.95) !important;
    color: #0891b2 !important;
    border-color: rgba(8,145,178,0.28) !important;
}
html.light .news-prose,
html.light .news-prose p,
html.light .news-prose li {
    color: #334155 !important;
}
html.light .news-prose h1,
html.light .news-prose h2,
html.light .news-prose h3,
html.light .news-prose h4,
html.light .news-prose strong {
    color: #0f172a !important;
}
html.light .news-prose blockquote {
    color: #475569 !important;
    border-left-color: #0891b2 !important;
}
html.light .news-prose a {
    color: #0891b2 !important;
}
