/* ==========================================
   AZIEL V2.5 SUPPORT PAGE
   Shared Theme Compatible
========================================== */

.support-page {
    width: min(1400px, calc(100% - 40px));
    margin: 120px auto 60px;

    display: grid;
    grid-template-columns: minmax(0, 1.15fr) 420px;
    gap: 30px;
    align-items: start;
}

.support-left,
.support-right {
    display: flex;
    flex-direction: column;
    gap: 28px;
}

/* ==========================================
   CARD
========================================== */

.support-card {
    position: relative;

    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 26px;

    padding: 28px;
    overflow: hidden;

    backdrop-filter: blur(18px);
    box-shadow: var(--shadow-sm);

    transition:
        transform var(--motion-duration-normal, .28s) var(--motion-ease-standard, ease),
        box-shadow var(--motion-duration-normal, .28s) var(--motion-ease-standard, ease),
        border-color var(--motion-duration-normal, .28s) var(--motion-ease-standard, ease);
}

.support-card:hover {
    transform: translateY(-3px);
    border-color: rgba(139, 92, 246, .35);
    box-shadow: var(--shadow-md);
}

/* ==========================================
   SECTION HEADING
========================================== */

.section-heading {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;

    margin-bottom: 24px;
}

.section-heading h2 {
    color: var(--text);
    font-size: 26px;
    font-weight: 800;
    letter-spacing: -.4px;
}

.support-subtitle {
    margin-top: 8px;

    color: var(--text-muted);
    line-height: 1.7;
    font-size: 15px;
}

/* ==========================================
   HERO
========================================== */

.support-hero {
    position: relative;
    overflow: hidden;

    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 40px;

    padding: 38px;
    border-radius: 30px;

    background:
        radial-gradient(circle at top right,
            rgba(139, 92, 246, .22),
            transparent 58%),
        var(--card);

    border: 1px solid var(--border);
    backdrop-filter: blur(18px);
    box-shadow: var(--shadow-sm);
}

.support-hero::before {
    content: "";
    position: absolute;
    inset: 0;

    background:
        linear-gradient(135deg,
            rgba(255, 255, 255, .05),
            transparent);

    pointer-events: none;
}

.support-hero-content {
    flex: 1;
    position: relative;
    z-index: 2;
}

.support-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;

    padding: 10px 18px;
    border-radius: 999px;

    background: rgba(139, 92, 246, .12);
    color: var(--primary);

    font-size: 13px;
    font-weight: 700;

    margin-bottom: 18px;
}

.support-hero h1 {
    margin-bottom: 18px;

    color: var(--text);
    font-size: 54px;
    line-height: 1.05;
    letter-spacing: -2px;
    font-weight: 900;
}

.hero-icon {
    width: 140px;
    height: 140px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 50%;

    background: linear-gradient(135deg, var(--primary), var(--primary-hover));
    color: #fff;

    font-size: 58px;
    flex-shrink: 0;

    box-shadow: 0 25px 70px rgba(124, 58, 237, .35);
}

/* ==========================================
   SUPPORT CATEGORIES
========================================== */

.support-categories {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 16px;
}

.category-card {
    border: 1px solid var(--border);
    background: var(--card);
    border-radius: 24px;

    padding: 22px 18px;
    text-align: left;

    cursor: pointer;
    transition: .25s ease;

    backdrop-filter: blur(16px);
    color: var(--text);
}

.category-card span {
    width: 46px;
    height: 46px;

    display: flex;
    align-items: center;
    justify-content: center;

    margin-bottom: 16px;

    border-radius: 16px;
    background: rgba(139, 92, 246, .13);
    color: var(--primary);

    font-size: 20px;
}

.category-card strong {
    display: block;

    margin-bottom: 6px;

    color: var(--text);
    font-size: 15px;
    font-weight: 800;
}

.category-card small {
    display: block;

    color: var(--text-muted);
    font-size: 12.5px;
    line-height: 1.5;
}

.category-card:hover {
    transform: translateY(-5px);
    border-color: rgba(139, 92, 246, .42);
    box-shadow: var(--shadow-md);
}

.category-card.active {
    border-color: rgba(139, 92, 246, .75);
    background:
        linear-gradient(135deg,
            rgba(139, 92, 246, .18),
            rgba(124, 58, 237, .06)),
        var(--card);
}

.category-card.active span {
    background: linear-gradient(135deg, var(--primary), var(--primary-hover));
    color: #fff;
    box-shadow: 0 12px 30px rgba(124, 58, 237, .32);
}

/* ==========================================
   FAQ
========================================== */

.faq-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.faq-item {
    overflow: hidden;

    border: 1px solid var(--border);
    border-radius: 18px;

    background: var(--card);
}

.faq-question {
    width: 100%;

    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;

    padding: 20px;

    background: transparent;
    border: none;

    color: var(--text);
    cursor: pointer;

    font-size: 15px;
    font-weight: 800;
    text-align: left;
}

.faq-question i {
    color: var(--text-muted);
    transition: .25s ease;
}

.faq-answer {
    max-height: 0;
    overflow: hidden;

    padding: 0 20px;

    color: var(--text-muted);
    line-height: 1.8;

    transition: .3s ease;
}

.faq-item.active .faq-answer {
    max-height: 180px;
    padding: 0 20px 20px;
}

.faq-item.active .fa-chevron-down {
    transform: rotate(180deg);
    color: var(--primary);
}

/* ==========================================
   SUPPORT FORM
========================================== */

.support-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 9px;
}

.support-form label {
    color: var(--text);
    font-size: 13px;
    font-weight: 800;
}

.support-form input,
.support-form select,
.support-form textarea {
    width: 100%;

    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text);

    border-radius: 18px;
    padding: 15px 16px;

    outline: none;
    font-size: 14px;

    transition: .22s ease;
}

.support-form textarea {
    resize: vertical;
    min-height: 140px;
    line-height: 1.7;
}

.support-form input::placeholder,
.support-form textarea::placeholder {
    color: var(--text-muted);
}

.support-form input:focus,
.support-form select:focus,
.support-form textarea:focus {
    border-color: rgba(139, 92, 246, .75);
    box-shadow: 0 0 0 4px rgba(139, 92, 246, .13);
}

.support-form input[type="file"] {
    cursor: pointer;
    padding: 13px 16px;
}

.support-submit-btn {
    width: 100%;
    height: 54px;

    margin-top: 6px;

    border: none;
    border-radius: 18px;

    background: linear-gradient(135deg, var(--primary), var(--primary-hover));
    color: #fff;

    font-weight: 900;
    font-size: 15px;

    cursor: pointer;

    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;

    transition: .24s ease;
    box-shadow: 0 18px 42px rgba(124, 58, 237, .32);
}

.support-submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 24px 56px rgba(124, 58, 237, .42);
}

.support-submit-btn:disabled {
    opacity: .65;
    cursor: not-allowed;
    transform: none;
}

.support-msg {
    min-height: 22px;

    color: var(--text-muted);
    font-size: 13px;
    font-weight: 700;
}

.support-msg.success {
    color: var(--success);
}

.support-msg.error {
    color: var(--danger);
}

/* ==========================================
   CONTACT CHANNELS
========================================== */

.contact-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
}

.contact-item {
    min-height: 116px;

    padding: 20px;

    border-radius: 22px;
    border: 1px solid var(--border);

    background: rgba(139, 92, 246, .06);
    text-decoration: none;
    color: var(--text);

    transition: .24s ease;
}

.contact-item span {
    width: 44px;
    height: 44px;

    display: flex;
    align-items: center;
    justify-content: center;

    margin-bottom: 14px;

    border-radius: 15px;
    background: rgba(139, 92, 246, .14);
    color: var(--primary);

    font-size: 19px;
}

.contact-item strong {
    display: block;

    margin-bottom: 6px;

    color: var(--text);
    font-size: 14px;
    font-weight: 850;
}

.contact-item small {
    color: var(--text-muted);
    font-size: 12.5px;
}

.contact-item:hover {
    transform: translateY(-4px);
    border-color: rgba(139, 92, 246, .45);
    box-shadow: var(--shadow-md);
}

/* ==========================================
   STATUS CARD
========================================== */

.status-card h2 {
    margin-bottom: 20px;

    color: var(--text);
    font-size: 24px;
    font-weight: 900;
}

.status-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.status-item {
    display: flex;
    align-items: center;
    gap: 14px;

    padding: 16px;

    border-radius: 20px;
    background: rgba(139, 92, 246, .06);
    border: 1px solid var(--border);
}

.status-item>span {
    width: 42px;
    height: 42px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 14px;
    background: rgba(139, 92, 246, .14);
    color: var(--primary);

    flex-shrink: 0;
}

.status-item strong {
    display: block;

    margin-bottom: 4px;

    color: var(--text);
    font-size: 14px;
    font-weight: 850;
}

.status-item small {
    color: var(--text-muted);
    font-size: 12.5px;
    line-height: 1.5;
}

.status-dot.online {
    background: var(--success);
    box-shadow: 0 0 0 6px rgba(34, 197, 94, .12);
}

/* ==========================================
   TICKET TABS
========================================== */

.ticket-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;

    margin-bottom: 20px;
}

.ticket-tab {
    border: 1px solid var(--border);
    background: rgba(139, 92, 246, .06);
    color: var(--text-muted);

    border-radius: 999px;
    padding: 9px 15px;

    font-size: 12.5px;
    font-weight: 850;

    cursor: pointer;
    transition: .22s ease;
}

.ticket-tab:hover {
    color: var(--text);
    border-color: rgba(139, 92, 246, .45);
}

.ticket-tab.active {
    background: linear-gradient(135deg, var(--primary), var(--primary-hover));
    color: #fff;

    border-color: transparent;
    box-shadow: 0 12px 28px rgba(124, 58, 237, .28);
}

/* ==========================================
   MY TICKETS
========================================== */

.my-tickets {
    min-height: 120px;

    display: flex;
    flex-direction: column;
    gap: 14px;

    color: var(--text-muted);
    font-size: 14px;
}

.ticket-item {
    padding: 18px;

    border-radius: 22px;
    border: 1px solid var(--border);

    background: rgba(139, 92, 246, .055);
    transition: .24s ease;
}

.ticket-item:hover {
    transform: translateY(-3px);
    border-color: rgba(139, 92, 246, .42);
    box-shadow: var(--shadow-md);
}

.ticket-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;

    margin-bottom: 12px;
}

.ticket-title {
    color: var(--text);
    font-size: 14px;
    font-weight: 900;
    line-height: 1.4;
}

.ticket-title i {
    margin-right: 6px;
    color: var(--primary);
}

.ticket-meta {
    margin-top: 5px;

    color: var(--text-muted);
    font-size: 12px;
    line-height: 1.5;
}

.ticket-message {
    margin-top: 10px;

    color: var(--text-muted);
    font-size: 13px;
    line-height: 1.65;
}

.ticket-reply {
    margin-top: 14px;
    padding: 14px;

    border-radius: 18px;

    background: rgba(34, 197, 94, .08);
    border: 1px solid rgba(34, 197, 94, .18);

    color: var(--text);
    font-size: 13px;
    line-height: 1.6;
}

.ticket-reply strong {
    display: block;
    margin-bottom: 6px;
    color: var(--success);
}

.ticket-status {
    flex-shrink: 0;

    border-radius: 999px;
    padding: 7px 11px;

    font-size: 11px;
    font-weight: 900;
    text-transform: capitalize;
}

.ticket-status.open {
    background: rgba(59, 130, 246, .12);
    color: #3b82f6;
}

.ticket-status.replied {
    background: rgba(34, 197, 94, .12);
    color: var(--success);
}

.ticket-status.solved {
    background: rgba(139, 92, 246, .13);
    color: var(--primary);
}

.ticket-status.closed {
    background: rgba(148, 163, 184, .13);
    color: var(--text-muted);
}

.empty-tickets {
    padding: 22px;

    text-align: center;
    border-radius: 22px;

    border: 1px dashed var(--border);
    color: var(--text-muted);

    line-height: 1.6;
}

/* ==========================================
   FOOTER
========================================== */

.support-footer {
    width: min(1400px, calc(100% - 40px));

    margin: 0 auto 40px;
    padding: 34px 0 24px;

    border-top: 1px solid var(--border);

    color: var(--text-muted);
    font-size: 13px;
}

.support-footer-grid {
    display: grid;
    grid-template-columns: 1.4fr repeat(4, minmax(0, 1fr));
    gap: 28px;
    text-align: left;
}

.support-footer h3,
.support-footer h4 {
    margin-bottom: 12px;
    color: var(--heading);
    font-weight: 900;
}

.support-footer p,
.support-footer a {
    color: var(--text-secondary);
    font-size: 14px;
    line-height: 1.8;
}

.support-footer a {
    display: block;
    width: fit-content;
    text-decoration: none;
}

.support-footer a:focus-visible {
    outline: 3px solid color-mix(in srgb, var(--primary) 65%, transparent);
    outline-offset: 3px;
}

.support-footer-copy {
    margin-top: 26px;
    padding-top: 22px;
    border-top: 1px solid var(--border);
    text-align: center;
}

/* ==========================================
   PHASE 16.3 LIGHT THEME READABILITY CLOSURE
========================================== */

body.theme-light .support-page {
    color: var(--text);
}

body.theme-light .support-hero,
body.theme-light .support-card,
body.theme-light .category-card,
body.theme-light .faq-item,
body.theme-light .contact-item,
body.theme-light .status-item,
body.theme-light .ticket-item,
body.theme-light .empty-tickets {
    background-color: var(--card);
    border-color: var(--border);
    color: var(--text);
}

body.theme-light .support-hero h1,
body.theme-light .section-heading h2,
body.theme-light .status-card h2,
body.theme-light .category-card strong,
body.theme-light .faq-question,
body.theme-light .support-form label,
body.theme-light .contact-item strong,
body.theme-light .status-item strong,
body.theme-light .ticket-title,
body.theme-light .ticket-reply,
body.theme-light .ticket-reply p {
    color: var(--text);
}

body.theme-light .support-subtitle,
body.theme-light .category-card small,
body.theme-light .faq-answer,
body.theme-light .faq-question i,
body.theme-light .support-form input::placeholder,
body.theme-light .support-form textarea::placeholder,
body.theme-light .contact-item small,
body.theme-light .status-item small,
body.theme-light .ticket-tab,
body.theme-light .my-tickets,
body.theme-light .ticket-meta,
body.theme-light .ticket-message,
body.theme-light .empty-tickets,
body.theme-light .support-footer {
    color: var(--text-muted);
}

body.theme-light .support-form input,
body.theme-light .support-form select,
body.theme-light .support-form textarea {
    background: var(--surface-strong);
    border-color: var(--border);
    color: var(--text);
}

body.theme-light .support-form input[type="file"] {
    color: var(--text-secondary);
}

body.theme-light .ticket-tab:hover {
    color: var(--text);
}

body.theme-light .support-msg {
    color: var(--text-muted);
}

body.theme-light .support-msg.success {
    color: var(--success);
}

body.theme-light .support-msg.error {
    color: var(--danger);
}

/* ==========================================
   RESPONSIVE
========================================== */

@media (max-width: 1180px) {
    .support-page {
        grid-template-columns: 1fr;
    }

    .support-right {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    .support-categories {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 820px) {
    .support-page {
        width: min(100% - 28px, 720px);
        margin-top: 96px;
        gap: 22px;
    }

    .support-hero {
        padding: 28px;
        align-items: flex-start;
    }

    .support-hero h1 {
        font-size: 42px;
    }

    .hero-icon {
        width: 96px;
        height: 96px;
        font-size: 40px;
    }

    .support-categories {
        grid-template-columns: repeat(2, 1fr);
    }

    .support-right {
        display: flex;
    }

    .form-grid,
    .contact-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 560px) {
    .support-page {
        width: calc(100% - 22px);
        margin-top: 86px;
    }

    .support-hero {
        padding: 24px;
        border-radius: 24px;
    }

    .support-hero h1 {
        font-size: 36px;
        letter-spacing: -1.2px;
    }

    .support-subtitle {
        font-size: 14px;
    }

    .hero-icon {
        display: none;
    }

    .support-card {
        padding: 22px;
        border-radius: 22px;
    }

    .support-categories {
        grid-template-columns: 1fr;
    }

    .category-card {
        padding: 18px;
    }

    .section-heading h2,
    .status-card h2 {
        font-size: 22px;
    }

    .ticket-top {
        flex-direction: column;
    }

    .ticket-status {
        width: fit-content;
    }

    .support-footer {
        width: calc(100% - 22px);
        margin-bottom: 90px;
    }

    .support-footer-grid {
        grid-template-columns: 1fr;
    }

    .support-footer-copy {
        text-align: left;
    }
}
