/* ═══════════════════════════════════════════════════════════════
   VYOMA AI — Enterprise Legal Center Styles (legal.css)
   ─────────────────────────────────────────────────────────────
   Additive only — does not modify any existing CSS.
   Covers:
     1. Modal overlay & backdrop
     2. Modal container (glass card)
     3. Sticky header bar
     4. Section structure
     5. Accordion panels
     6. Expand/collapse animation
     7. Outbound link buttons
     8. Disclaimer override
     9. Responsive breakpoints
    10. Close animation
   ═══════════════════════════════════════════════════════════════ */

/* ── Scoped design tokens ── */
:root {
    --lc-bg-deep: rgba(10, 10, 18, 0.97);
    --lc-bg-card: linear-gradient(168deg,
            rgba(24, 22, 44, 0.97) 0%,
            rgba(12, 12, 24, 0.98) 100%);
    --lc-bg-section: rgba(255, 255, 255, 0.022);
    --lc-bg-section-hover: rgba(255, 255, 255, 0.038);
    --lc-bg-accordion: rgba(255, 255, 255, 0.015);
    --lc-border: rgba(255, 255, 255, 0.06);
    --lc-border-hover: rgba(255, 255, 255, 0.1);
    --lc-text: #e4e2ee;
    --lc-text-secondary: rgba(255, 255, 255, 0.58);
    --lc-text-muted: rgba(255, 255, 255, 0.36);
    --lc-accent: #7c6ff7;
    --lc-accent-soft: rgba(124, 111, 247, 0.1);
    --lc-accent-border: rgba(124, 111, 247, 0.22);
    --lc-radius: 22px;
    --lc-radius-sm: 14px;
    --lc-radius-xs: 10px;
    --lc-shadow: 0 32px 100px rgba(0, 0, 0, 0.65),
        0 0 80px rgba(124, 111, 247, 0.04);
    --lc-font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --lc-ease: cubic-bezier(0.4, 0, 0.2, 1);
    --lc-ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}


/* ═══════════════════════════════════════════════════════════════
   1. OVERLAY / BACKDROP
   ═══════════════════════════════════════════════════════════════ */

.lc-overlay {
    position: fixed;
    inset: 0;
    z-index: 99500;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s var(--lc-ease),
        visibility 0.4s var(--lc-ease);
    padding: 20px;
}

.lc-overlay.lc-active {
    opacity: 1;
    visibility: visible;
}

/* Close-out animation */
.lc-overlay.lc-closing {
    opacity: 0;
    visibility: hidden;
}


/* ═══════════════════════════════════════════════════════════════
   2. MODAL CONTAINER
   ═══════════════════════════════════════════════════════════════ */

.lc-modal {
    position: relative;
    width: 100%;
    max-width: 900px;
    max-height: 88vh;
    background: var(--lc-bg-card);
    border: 1px solid var(--lc-border);
    border-radius: var(--lc-radius);
    box-shadow: var(--lc-shadow);
    display: flex;
    flex-direction: column;
    overflow: hidden;

    /* Entry animation */
    transform: translateY(28px) scale(0.96);
    opacity: 0;
    transition: transform 0.45s var(--lc-ease),
        opacity 0.4s var(--lc-ease);
}

.lc-overlay.lc-active .lc-modal {
    transform: translateY(0) scale(1);
    opacity: 1;
}

.lc-overlay.lc-closing .lc-modal {
    transform: translateY(20px) scale(0.97);
    opacity: 0;
}

/* Top accent bar */
.lc-modal::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg,
            transparent 0%,
            rgba(124, 111, 247, 0.35) 20%,
            rgba(180, 170, 255, 0.5) 50%,
            rgba(124, 111, 247, 0.35) 80%,
            transparent 100%);
    z-index: 2;
}


/* ═══════════════════════════════════════════════════════════════
   3. STICKY HEADER
   ═══════════════════════════════════════════════════════════════ */

.lc-header {
    position: sticky;
    top: 0;
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 22px 28px 18px;
    background: rgba(14, 13, 28, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--lc-border);
    flex-shrink: 0;
}

.lc-header-icon {
    width: 40px;
    height: 40px;
    min-width: 40px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--lc-border);
}

.lc-header-icon.info-type {
    background: linear-gradient(135deg, rgba(124, 111, 247, 0.14), rgba(124, 111, 247, 0.05));
    border-color: var(--lc-accent-border);
}

.lc-header-icon.privacy-type {
    background: linear-gradient(135deg, rgba(0, 184, 148, 0.14), rgba(0, 184, 148, 0.05));
    border-color: rgba(0, 184, 148, 0.22);
}

.lc-header-icon svg {
    width: 20px;
    height: 20px;
    stroke-width: 1.8;
}

.lc-header-text {
    flex: 1;
    min-width: 0;
}

.lc-header-title {
    font-family: var(--lc-font);
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--lc-text);
    letter-spacing: -0.02em;
    margin: 0;
    line-height: 1.3;
}

.lc-header-subtitle {
    font-family: var(--lc-font);
    font-size: 0.76rem;
    color: var(--lc-text-muted);
    margin: 2px 0 0;
    letter-spacing: 0.01em;
}

/* Close button */
.lc-close-btn {
    width: 36px;
    height: 36px;
    min-width: 36px;
    border: 1px solid var(--lc-border);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
    color: var(--lc-text-muted);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    padding: 0;
    flex-shrink: 0;
}

.lc-close-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--lc-border-hover);
    color: var(--lc-text);
    transform: scale(1.06);
}

.lc-close-btn svg {
    width: 16px;
    height: 16px;
}


/* ═══════════════════════════════════════════════════════════════
   4. SCROLLABLE BODY
   ═══════════════════════════════════════════════════════════════ */

.lc-body {
    flex: 1;
    overflow-y: auto;
    padding: 24px 28px 32px;
    scroll-behavior: smooth;
}

/* Custom scrollbar */
.lc-body::-webkit-scrollbar {
    width: 5px;
}

.lc-body::-webkit-scrollbar-track {
    background: transparent;
}

.lc-body::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 10px;
}

.lc-body::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.14);
}


/* ═══════════════════════════════════════════════════════════════
   5. SECTION GROUP
   ═══════════════════════════════════════════════════════════════ */

.lc-section-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Optional preamble text */
.lc-preamble {
    font-family: var(--lc-font);
    font-size: 0.84rem;
    line-height: 1.65;
    color: var(--lc-text-secondary);
    margin-bottom: 18px;
    padding: 0 2px;
}


/* ═══════════════════════════════════════════════════════════════
   6. ACCORDION SECTION
   ═══════════════════════════════════════════════════════════════ */

.lc-accordion {
    border: 1px solid var(--lc-border);
    border-radius: var(--lc-radius-sm);
    overflow: hidden;
    transition: border-color 0.25s ease;
}

.lc-accordion:hover {
    border-color: var(--lc-border-hover);
}

.lc-accordion.lc-open {
    border-color: var(--lc-accent-border);
}

/* ── Accordion trigger ── */
.lc-accordion-trigger {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    padding: 18px 20px;
    background: var(--lc-bg-section);
    border: none;
    cursor: pointer;
    text-align: left;
    transition: background 0.2s ease;
    font-family: var(--lc-font);
}

.lc-accordion-trigger:hover {
    background: var(--lc-bg-section-hover);
}

.lc-accordion-icon {
    width: 36px;
    height: 36px;
    min-width: 36px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--lc-border);
    transition: all 0.25s ease;
}

.lc-accordion.lc-open .lc-accordion-icon {
    background: var(--lc-accent-soft);
    border-color: var(--lc-accent-border);
}

.lc-accordion-icon svg {
    width: 18px;
    height: 18px;
    color: var(--lc-text-secondary);
    transition: color 0.25s ease;
}

.lc-accordion.lc-open .lc-accordion-icon svg {
    color: var(--lc-accent);
}

.lc-accordion-label {
    flex: 1;
    min-width: 0;
}

.lc-accordion-title {
    font-size: 0.92rem;
    font-weight: 620;
    color: var(--lc-text);
    letter-spacing: -0.01em;
    margin: 0;
    line-height: 1.3;
}

.lc-accordion-desc {
    font-size: 0.74rem;
    color: var(--lc-text-muted);
    margin: 3px 0 0;
    line-height: 1.4;
}

/* Chevron */
.lc-accordion-chevron {
    width: 20px;
    height: 20px;
    min-width: 20px;
    color: var(--lc-text-muted);
    transition: transform 0.35s var(--lc-ease), color 0.2s ease;
}

.lc-accordion.lc-open .lc-accordion-chevron {
    transform: rotate(180deg);
    color: var(--lc-accent);
}


/* ── Accordion content panel ── */
.lc-accordion-panel {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s var(--lc-ease);
}

.lc-accordion.lc-open .lc-accordion-panel {
    max-height: 800px;
}

.lc-accordion-content {
    padding: 0 20px 20px 70px;
    /* Left-aligned with icon column */
}

.lc-accordion-content p {
    font-family: var(--lc-font);
    font-size: 0.84rem;
    line-height: 1.72;
    color: var(--lc-text-secondary);
    margin: 0 0 10px;
}

.lc-accordion-content p:last-child {
    margin-bottom: 0;
}

.lc-accordion-content strong {
    color: var(--lc-text);
    font-weight: 600;
}

/* Bulleted list inside accordion */
.lc-accordion-content ul {
    list-style: none;
    padding: 0;
    margin: 8px 0 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.lc-accordion-content ul li {
    position: relative;
    padding-left: 18px;
    font-family: var(--lc-font);
    font-size: 0.84rem;
    line-height: 1.65;
    color: var(--lc-text-secondary);
}

.lc-accordion-content ul li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 8px;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--lc-accent);
    opacity: 0.55;
}


/* ═══════════════════════════════════════════════════════════════
   7. OUTBOUND LINK BUTTONS
   ═══════════════════════════════════════════════════════════════ */

.lc-link-group {
    display: flex;
    gap: 10px;
    margin-top: 8px;
    flex-wrap: wrap;
}

.lc-link-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 22px;
    background: var(--lc-accent-soft);
    border: 1px solid var(--lc-accent-border);
    border-radius: var(--lc-radius-xs);
    color: #b5aeff;
    font-family: var(--lc-font);
    font-size: 0.84rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.25s ease;
    flex: 1;
    justify-content: center;
    min-width: 160px;
}

.lc-link-btn:hover {
    background: rgba(124, 111, 247, 0.18);
    border-color: rgba(124, 111, 247, 0.38);
    color: #d0cbff;
    transform: translateY(-1px);
    box-shadow: 0 6px 24px rgba(124, 111, 247, 0.12);
}

.lc-link-btn svg {
    width: 15px;
    height: 15px;
    flex-shrink: 0;
}


/* ═══════════════════════════════════════════════════════════════
   8. FOOTER NOTE
   ═══════════════════════════════════════════════════════════════ */

.lc-footer {
    padding: 16px 28px;
    border-top: 1px solid var(--lc-border);
    background: rgba(10, 10, 20, 0.5);
    flex-shrink: 0;
}

.lc-footer-text {
    font-family: var(--lc-font);
    font-size: 0.72rem;
    color: var(--lc-text-muted);
    text-align: center;
    line-height: 1.5;
    margin: 0;
}


/* ═══════════════════════════════════════════════════════════════
   9. DISCLAIMER OVERRIDE
   ═══════════════════════════════════════════════════════════════ */

/* Hide old popup.js disclaimer if present */
#akiraDisclaimerNew {
    display: none !important;
}

/* Enterprise disclaimer */
.lc-disclaimer {
    font-family: var(--lc-font);
    font-size: 0.68rem;
    color: var(--text-muted, rgba(255, 255, 255, 0.42));
    margin-top: 8px;
    text-align: center;
    line-height: 1.55;
}

.lc-disclaimer-link {
    color: var(--accent, #7c6ff7);
    cursor: pointer;
    font-weight: 500;
    text-decoration: none;
    border-bottom: 1px dotted transparent;
    transition: color 0.2s ease, border-color 0.2s ease;
}

.lc-disclaimer-link:hover {
    color: var(--accent-hover, #9d93ff);
    border-bottom-color: var(--accent, #7c6ff7);
}

.lc-disclaimer-sep {
    display: inline-block;
    margin: 0 5px;
    color: var(--text-muted, rgba(255, 255, 255, 0.25));
    font-weight: 300;
    user-select: none;
}


/* ═══════════════════════════════════════════════════════════════
   10. RESPONSIVE — TABLET
   ═══════════════════════════════════════════════════════════════ */

@media (max-width: 768px) {
    .lc-overlay {
        padding: 12px;
    }

    .lc-modal {
        max-width: 94%;
        max-height: 92vh;
        border-radius: 18px;
    }

    .lc-header {
        padding: 18px 20px 14px;
        gap: 12px;
    }

    .lc-header-icon {
        width: 36px;
        height: 36px;
        min-width: 36px;
        border-radius: 10px;
    }

    .lc-header-icon svg {
        width: 18px;
        height: 18px;
    }

    .lc-header-title {
        font-size: 1.05rem;
    }

    .lc-body {
        padding: 18px 18px 28px;
    }

    .lc-accordion-trigger {
        padding: 14px 16px;
        gap: 12px;
    }

    .lc-accordion-icon {
        width: 32px;
        height: 32px;
        min-width: 32px;
        border-radius: 8px;
    }

    .lc-accordion-icon svg {
        width: 16px;
        height: 16px;
    }

    .lc-accordion-title {
        font-size: 0.86rem;
    }

    .lc-accordion-content {
        padding: 0 16px 16px 60px;
    }

    .lc-accordion-content p,
    .lc-accordion-content ul li {
        font-size: 0.82rem;
    }

    .lc-footer {
        padding: 12px 18px;
    }

    .lc-link-group {
        flex-direction: column;
    }

    .lc-link-btn {
        width: 100%;
        min-width: 0;
    }
}


/* ═══════════════════════════════════════════════════════════════
   11. RESPONSIVE — SMALL MOBILE
   ═══════════════════════════════════════════════════════════════ */

@media (max-width: 420px) {
    .lc-overlay {
        padding: 6px;
    }

    .lc-modal {
        max-width: 98%;
        max-height: 95vh;
        border-radius: 14px;
    }

    .lc-header {
        padding: 14px 14px 12px;
        gap: 10px;
    }

    .lc-header-title {
        font-size: 0.96rem;
    }

    .lc-header-subtitle {
        font-size: 0.7rem;
    }

    .lc-body {
        padding: 14px 12px 24px;
    }

    .lc-accordion-trigger {
        padding: 12px 12px;
        gap: 10px;
    }

    .lc-accordion-content {
        padding: 0 12px 14px 14px;
    }

    .lc-accordion-title {
        font-size: 0.82rem;
    }

    .lc-accordion-desc {
        display: none;
    }

    .lc-preamble {
        font-size: 0.8rem;
    }

    .lc-footer {
        padding: 10px 12px;
    }

    .lc-footer-text {
        font-size: 0.68rem;
    }

    .lc-disclaimer {
        font-size: 0.62rem;
    }
}


/* ═══════════════════════════════════════════════════════════════
   12. LIGHT MODE SUPPORT
   ═══════════════════════════════════════════════════════════════ */

/* Keep modals always dark — they are overlays */

[data-theme="light"] .lc-disclaimer {
    color: #999;
}

[data-theme="light"] .lc-disclaimer-link {
    color: #6c5ce7;
}

[data-theme="light"] .lc-disclaimer-link:hover {
    color: #5a4bd1;
}