/* ============================================
   TSS HELPDESK - FULL CSS WITH DARK MODE
   ============================================ */

/* ----- CSS VARIABLES (Light Mode Default) ----- */
:root {
    --bg-primary: #f8f8f8;
    --bg-white: #ffffff;
    --bg-card: #ffffff;
    --bg-secondary: #f3f3f3;
    --text-primary: #000000;
    --text-secondary: #666666;
    --text-muted: #6c757d;
    --border-light: #e9ecef;
    --card-shadow: 0 8px 24px rgba(0, 0, 0, 0.05);
    --card-shadow-hover: 0 16px 28px rgba(0, 0, 0, 0.1);
    --faq-bg: #ffffff;
    --faq-border: #eef2ff;
    --hero-bg: #ffffff;
    --cta-gradient-start: #cfe9ff;
    --cta-gradient-end: #dff5e8;
    --footer-overlay: rgba(0, 0, 0, 0.75);
}

/* Dark Mode Variables */
body.dark-mode {
    --bg-primary: #1a1a2e;
    --bg-white: #16213e;
    --bg-card: #1e2a3e;
    --bg-secondary: #2d3748;
    --text-primary: #e2e8f0;
    --text-secondary: #a0aec0;
    --text-muted: #94a3b8;
    --border-light: #2d3748;
    --card-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
    --card-shadow-hover: 0 16px 28px rgba(0, 0, 0, 0.4);
    --faq-bg: #1e2a3e;
    --faq-border: #2d3748;
    --hero-bg: #16213e;
    --cta-gradient-start: #1e3a5f;
    --cta-gradient-end: #2d4a6e;
    --footer-overlay: rgba(0, 0, 0, 0.85);
}

/* Apply variables to elements */
body {
    background: var(--bg-primary);
    color: var(--text-primary);
    transition: background-color 0.3s ease, color 0.3s ease;
}

/* Logo inside mobile collapsible menu with left padding */
.navbar-collapse-img {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 0.5rem;
    text-align: left;  /* Align logo to left instead of center */
    padding-left: 1rem !important;  /* Ensures left spacing */
}

/* Dark mode border adjustment */
body.dark-mode .navbar-collapse-img {
    border-bottom-color: rgba(255, 255, 255, 0.05);
}

/* Ensure image aligns properly */
.navbar-collapse-img img {
    display: inline-block;
    max-width: 120px;
    height: auto;
}

/* On mobile, fine-tune spacing */
@media (max-width: 991.98px) {
    .navbar-collapse-img {
        padding: 0.75rem 0 0.75rem 1rem !important;
    }
    
    .navbar-nav {
        margin-top: 0.5rem !important;
    }
}

.hero-section {
    background: var(--hero-bg);
}

.custom-card,
.faq-item-card,
.modal-content {
    background: var(--bg-card);
    box-shadow: var(--card-shadow);
}

.custom-card:hover {
    box-shadow: var(--card-shadow-hover);
}

.icon-btn {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

.icon-btn:hover {
    background: #e6e6e6;
}

body.dark-mode .icon-btn:hover {
    background: #3a4a6e;
}

.text-secondary,
.hero-section p,
.section-subtitle {
    color: var(--text-secondary) !important;
}

.text-muted {
    color: var(--text-muted) !important;
}

.bg-light {
    background: var(--bg-primary) !important;
}

.faqs-section {
    background: var(--bg-primary);
}

.faq-item-card {
    border-color: var(--faq-border);
}

.faq-tab-btn {
    background: var(--bg-card);
    color: var(--text-primary);
    border-color: var(--border-light);
}

.faq-tab-btn.active,
.faq-tab-btn:hover {
    background: #2563eb;
    color: white;
}

.qa-item-inner {
    background: var(--bg-secondary);
}

.cta-gradient {
    background: linear-gradient(135deg, var(--cta-gradient-start) 0%, var(--cta-gradient-end) 100%);
}

footer::before {
    background: var(--footer-overlay);
}

/* ----- Apply custom font to text elements only (NOT icons) ----- */
body,
button,
input,
select,
textarea,
a,
p,
h1, h2, h3, h4, h5, h6,
span,
div,
li,
.navbar,
.nav-link,
.card,
.modal-content,
.footer,
.faq-item-card,
.hero-section,
.cta-gradient,
.faqs-section,
.main-header .nav-link,
.signin-btn,
.signup-btn,
.btn-outline-custom,
.submit-ticket-btn,
.create-ticket-btn,
.read-more-btn,
.faq-tab-btn,
.faq-question,
.faq-answer-content,
.footer-link {
    font-family: 'Exo 2', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif !important;
}

/* ----- Ensure Font Awesome icons keep their own font family ----- */
i,
.fas,
.far,
.fab,
.fa-solid,
.fa-regular,
.fa-brands,
[class*="fa-"],
.icon-btn i,
.social-icon i {
    font-family: "Font Awesome 6 Free" !important;
    font-weight: 900;
    font-style: normal;
    font-variant: normal;
    text-rendering: auto;
    line-height: 1;
}

.fab,
.fa-brands {
    font-family: "Font Awesome 6 Brands" !important;
    font-weight: 400;
}

/* ----- GLOBAL & TYPOGRAPHY ----- */
body {
    margin: 0;
    padding: 0;
    line-height: 1.5;
    font-weight: 400;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
}

/* ----- HEADER (GLASS + STICKY) ----- */
.main-header {
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.06);
    transition: all 0.3s ease;
    padding: 0.75rem 0;
}

body.dark-mode .main-header {
    background: rgba(0, 0, 0, 0.5);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.main-header.scrolled {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(16px);
}

body.dark-mode .main-header.scrolled {
    background: rgba(0, 0, 0, 0.85);
}

.navbar-nav .nav-link {
    color: var(--text-primary);
    font-weight: 400;
    font-size: 0.8rem;
    transition: 0.3s;
}

.navbar-nav .nav-link:hover,
.navbar-nav .nav-link.active {
    color: #5b7dff;
}

/* Icon buttons */
.icon-btn {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    border: none;
    font-size: 1.1rem;
    cursor: pointer;
    transition: 0.25s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* Auth buttons */
.signin-btn {
    padding: 8px 18px;
    border-radius: 12px;
    background: linear-gradient(90deg, #4f46e5, #06b6d4);
    /* background: linear-gradient(135deg, #e21d74 0%, #6a5cff 100%); */
    color: white;
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    transition: 0.25s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.signin-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 14px rgba(106, 92, 255, 0.25);
    color: white;
}

.signup-btn {
    padding: 8px 22px;
    border-radius: 10px;
    border: 2px solid #6a5cff;
    color: #6a5cff;
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    background: white;
    transition: 0.25s;
}

body.dark-mode .signup-btn {
    background: #1e2a3e;
    color: #8b7eff;
    border-color: #8b7eff;
}

.signup-btn:hover {
    background: #f3f0ff;
    color: #5a4ce0;
}

body.dark-mode .signup-btn:hover {
    background: #2d3a5e;
}

/* ----- HERO SECTION ----- */
.hero-section {
    padding: 2rem 0 3rem;
    margin-top: 60px;
}

.hero-section h1 {
    font-size: 3.2rem;
    font-weight: 800 !important;
    line-height: 1.2;
    color: var(--text-primary);
}

.hero-section p {
    text-align: justify;
}

.btn-outline-custom {
    padding: 0.6rem 2rem;
    border-radius: 12px;
    font-weight: 600;
    color: #5b7dff;
    background: transparent;
    border: 2px solid #5b7dff;
    text-decoration: none;
    transition: 0.25s;
    display: inline-flex;
    align-items: center;
}

.btn-outline-custom:hover {
    background: #eef1ff;
    color: #3a5fe0;
}

body.dark-mode .btn-outline-custom:hover {
    background: #2d3a5e;
}

/* ----- BUTTONS (Ticket / Submit) ----- */
.submit-ticket-btn,
.create-ticket-btn {
    background: linear-gradient(90deg, #4f46e5, #06b6d4);
    /* background: linear-gradient(135deg, #d1105c, #7b5fbf); */
    border: none;
    color: white;
    padding: 12px 24px;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9rem;
    transition: 0.2s;
    box-shadow: 0 8px 18px rgba(123, 95, 191, 0.3);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.submit-ticket-btn:hover,
.create-ticket-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 22px rgba(123, 95, 191, 0.35);
}

/* ----- CARDS ----- */
.custom-card {
    border-radius: 20px;
    padding: 1.25rem;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
    border: 1px solid var(--border-light);
}

.card-category {
    color: #5b7dff;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.card-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0.5rem 0;
    color: var(--text-primary);
}

.card-description {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

.read-more-btn {
    border: 1px solid #5b7dff;
    color: #5b7dff;
    background: transparent;
    padding: 0.4rem 1.2rem;
    border-radius: 30px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.8rem;
    transition: 0.3s;
    margin-top: 1rem;
}

.read-more-btn:hover {
    background: rgba(91, 125, 255, 0.1);
}

/* Horizontal scroll */
.cards-scroll-wrapper {
    width: 100%;
    overflow-x: auto;
}

.cards-scroll-wrapper .d-flex {
    scroll-behavior: smooth;
}

.cards-scroll-wrapper::-webkit-scrollbar {
    height: 6px;
}

.cards-scroll-wrapper::-webkit-scrollbar-track {
    background: var(--border-light);
    border-radius: 10px;
}

.cards-scroll-wrapper::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 10px;
}

body.dark-mode .cards-scroll-wrapper::-webkit-scrollbar-thumb {
    background: #4a5568;
}

/* ----- FAQ SECTION ----- */
.faqs-section {
    padding: 5rem 0;
}

.faq-tab-btn {
    font-size: 0.9rem;        /* readable size */
    padding: 8px 20px;
    border-radius: 40px;
    font-weight: 500;
    background-color: #f0f0f0;
    border: none;
    color: #333;
    transition: 0.2s;
    white-space: nowrap;
}

.faq-tab-btn.active {
    background-color: #0d6efd;
    color: white;
}

/* Tab Container */
.nav-pills {
    display: flex;
    flex-wrap: nowrap !important;
    overflow-x: auto;
    justify-content: flex-start;
    gap: 10px;
    padding: 6px 4px 10px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
}

.footer-icon-bg {
    width: 25px;            /* adjust as needed */
    height: 25px;
    background-color: #e9ecff;   /* choose your desired color */
    border-radius: 50%;          /* makes it a perfect circle */
    display: inline-flex;        /* or flex – keeps icon centered */
    align-items: center;
    justify-content: center;
    text-align: center;
}

/* Base Tab Button */
.faq-tab-btn {
    font-size: 0.9rem;
    padding: 9px 22px;
    border-radius: 999px;
    font-weight: 500;
    background: #f8fafc;
    border: 1px solid #e5e7eb;
    color: #475569;
    white-space: nowrap;
    transition: all 0.25s ease;
    position: relative;
}

/* Hover Effect */
.faq-tab-btn:hover {
    background: #eef2ff;
    border-color: #c7d2fe;
    color: #0d6efd;
    transform: translateY(-1px);
}

/* Active Tab (Main Highlight) */
.faq-tab-btn.active {
    background: linear-gradient(135deg, #0d6efd, #4f46e5);
    color: white;
    border-color: transparent;
    box-shadow: 0 6px 14px rgba(13, 110, 253, 0.25);
}

/* Subtle Click Effect */
.faq-tab-btn:active {
    transform: scale(0.96);
}

/* Scrollbar Styling */
.nav-pills::-webkit-scrollbar {
    height: 5px;
}

.nav-pills::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 10px;
}

.nav-pills::-webkit-scrollbar-thumb {
    background: #cbd5f5;
    border-radius: 10px;
}

.faq-item-card {
    border-radius: 1rem;
    padding: 0.4rem 1rem;
    cursor: pointer;
    transition: 0.2s;
}

.faq-item-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--card-shadow-hover);
}

.faq-question {
    font-weight: 700;
    color: var(--text-primary);
}

.faq-icon {
    font-size: 1.3rem;
    font-weight: 600;
    color: #5b7dff;
}

.faq-answer-content {
    display: none;
    padding-top: 0.75rem;
    border-top: 1px solid var(--faq-border);
    margin-top: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* Q&A inner blocks */
.qa-item-inner {
    background: var(--bg-secondary);
    border-radius: 12px;
    padding: 12px 16px;
    margin-bottom: 12px;
    border-left: 3px solid #2563eb;
}

.question {
    font-weight: 700;
    margin-bottom: 6px;
    display: flex;
    align-items: baseline;
    gap: 8px;
}

.question::before {
    content: "Q";
    background: #2563eb;
    color: white;
    font-size: 0.7rem;
    width: 22px;
    height: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
}

.answer {
    padding-left: 30px;
    position: relative;
}

.answer::before {
    content: "A";
    position: absolute;
    left: 0;
    top: 0;
    background: #10b981;
    color: white;
    font-size: 0.7rem;
    width: 22px;
    height: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
}

/* ----- FOOTER ----- */
footer {
    background-image: url('../images/footer-background.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    padding-top: 5rem;
    padding-bottom: 1rem;
    /* padding: 4rem 0 2rem; */
    position: relative;
    font-size: 0.8rem;
}

footer::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

footer .container {
    position: relative;
    z-index: 2;
}

.footer-link {
    color: #cbd5e1;
    text-decoration: none;
    font-size: 0.85rem;
    transition: 0.2s;
    display: inline-block;
    margin-bottom: 0.5rem;
}

.footer-link:hover {
    color: white;
    transform: translateX(3px);
}

.social-icon {
    width: 36px;
    height: 36px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: white;
    transition: 0.3s;
    text-decoration: none;
}

.social-icon:hover {
    background: #5b7dff;
    transform: translateY(-2px);
}

/* ----- FORMS (modal) ----- */
.modal-content input,
.modal-content select,
.modal-content textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(#e6edf5);
    border-radius: 6px;
    font-size: 0.8rem;
    /* background: var(--bg-secondary); */
    color: var(--text-primary);
    transition: 0.2s;
}

.modal-content input:focus,
.modal-content select:focus,
.modal-content textarea:focus {
    outline: none;
    border-color: #7b5fbf;
    background: var(--bg-card);
    box-shadow: 0 0 0 3px rgba(123, 95, 191, 0.2);
}

.modal-content label {
    color: var(--text-primary);
}

.gradient-text {
    background: linear-gradient(135deg, #d1105c, #7b5fbf);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

/* ----- RESPONSIVE FIXES ----- */
@media (max-width: 992px) {
    .hero-section {
        margin-top: 65px;
        padding-top: 2rem;
    }
    .hero-section h1 {
        font-size: 2.2rem;
    }
    .main-header {
        padding: 0.5rem 0;
    }
    .section-padding {
        padding: 3rem 0;
    }
    .faqs-section {
        padding: 3rem 0;
    }
}

@media (max-width: 768px) {
    .hero-section h1 {
        font-size: 1.8rem;
    }
    .custom-card {
        width: 280px !important;
    }
    .faq-tab-btn {
        padding: 6px 16px;
        font-size: 0.8rem;
    }
    .footer-link {
        font-size: 0.8rem;
    }
}

/* Utility */
.section-padding {
    padding: 5rem 0;
}

.bg-white-10 {
    background-color: rgba(255, 255, 255, 0.1);
}

/* Smooth transitions for dark mode */
* {
    transition: background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}


/* Modal Box */
        .ticket-modal {
            border-radius: 18px;
            box-shadow: 0 18px 45px rgba(0,0,0,0.12);
        }

        /* Header */
        .ticket-header {
            background: #f8fafc;
            padding: 18px 26px;
            border-bottom: 1px solid #e5e7eb;
        }

        /* Title */
        .gradient-text {
            font-size: 22px;
            font-weight: 700;

            background: linear-gradient(90deg,#4f46e5,#06b6d4);
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
        }

        /* Body */
        .ticket-body {
            /* background: #f8fafc; */
            padding: 24px 26px;
        }

        /* Section Titles */
        .section-title {
            font-size: 13px;
            font-weight: 700;
            color: #64748b;

            border-bottom: 1px solid #e2e8f0;
            padding-bottom: 6px;
        }

        /* Labels */
        .form-label {
            font-size: 13px;
            font-weight: 600;
            margin-bottom: 6px;
            color: #475569;
        }

        /* Inputs */
        input,
        select,
        textarea {
            width: 100%;
            padding: 11px 14px;

            border-radius: 12px;
            border: 1px solid #d1d5db;

            font-size: 14px;
            background: #fff;

            transition: 0.2s;
        }

        /* Focus */
        input:focus,
        select:focus,
        textarea:focus {
            border-color: #4f46e5;
            box-shadow: 0 0 0 3px rgba(79,70,229,.12);
            outline: none;
        }

        /* Textarea */
        textarea {
            min-height: 140px;
        }

        /* File Upload */
        .file-upload-box {

            border: 2px dashed #cbd5e1;
            border-radius: 12px;

            padding: 20px;
            text-align: center;

            background: #ffffff;
        }

        .file-upload-box small {
            display: block;
            margin-top: 6px;
            color: #64748b;
        }

        /* Footer */
        .ticket-footer {

            margin-top: 22px;
            padding-top: 16px;

            border-top: 1px solid #e5e7eb;

            display: flex;
            justify-content: flex-end;
            gap: 10px;
        }

        /* Cancel Button */
        .btn-light {

            background: #e2e8f0;
            border-radius: 10px;
        }

        /* Submit Button */
        .submit-ticket-btn {

            background: linear-gradient(90deg,#4f46e5,#06b6d4);

            border: none;
            color: white;

            padding: 11px 26px;
            border-radius: 12px;

            font-weight: 600;

            transition: 0.25s;
        }

        /* Hover */
        .submit-ticket-btn:hover {

            transform: translateY(-1px);

            box-shadow: 0 8px 22px rgba(79,70,229,.35);
        }
