/* ==========================================================================
   WEBXMEDIA.CO — LEGAL / POLICY PAGES (terms, privacy, refund policy)
   ========================================================================== */

.legal-meta {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    padding: .45rem .9rem;
    border-radius: 9999px;
    font-size: .8rem;
    font-weight: 600;
    color: #334155;
    background: rgba(255, 255, 255, .85);
    border: 1px solid #E2E8F0;
}
.legal-meta i { color: #0D9488; }

.legal-switch {
    display: flex;
    gap: .35rem;
    width: fit-content;
    max-width: 100%;
    padding: .35rem;
    overflow-x: auto;
    border-radius: 9999px;
    background: #FFFFFF;
    border: 1px solid #E2E8F0;
    box-shadow: 0 10px 24px -16px rgba(15, 23, 42, .2);
    scrollbar-width: none;
}
.legal-switch::-webkit-scrollbar { display: none; }
.legal-switch a {
    display: inline-flex;
    flex-shrink: 0;
    align-items: center;
    gap: .5rem;
    padding: .65rem 1.1rem;
    border-radius: 9999px;
    font-size: .85rem;
    font-weight: 700;
    color: #64748B;
    white-space: nowrap;
    transition: all .2s ease;
}
.legal-switch a:hover { color: #0F172A; background: #F8FAFC; }
.legal-switch a.is-active {
    color: #FFFFFF;
    background: linear-gradient(135deg, #0D9488, #16A34A);
    box-shadow: 0 8px 18px -8px rgba(13, 148, 136, .7);
}

/* Table of contents */
.legal-toc {
    padding: 1.5rem;
    border-radius: 1.5rem;
    background: #FFFFFF;
    border: 1px solid rgba(226, 232, 240, .9);
    box-shadow: 0 12px 30px -20px rgba(15, 23, 42, .2);
}
.legal-toc-link {
    display: flex;
    align-items: flex-start;
    gap: .7rem;
    padding: .5rem .6rem;
    border-radius: .75rem;
    font-size: .875rem;
    font-weight: 500;
    line-height: 1.35;
    color: #475569;
    transition: all .2s ease;
}
.legal-toc-link:hover { color: #0F172A; background: #F8FAFC; }
.legal-toc-num {
    display: flex;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    width: 1.5rem;
    height: 1.5rem;
    border-radius: .5rem;
    font-size: .7rem;
    font-weight: 800;
    color: #64748B;
    background: #F1F5F9;
    transition: all .2s ease;
}
.legal-toc-link.is-current { color: #134E4A; font-weight: 700; background: #F0FDFA; }
.legal-toc-link.is-current .legal-toc-num { color: #FFFFFF; background: linear-gradient(135deg, #0D9488, #16A34A); }
@media (max-width: 1023px) {
    .legal-toc ol { display: grid; grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr)); gap: .25rem; }
}

/* Document sections */
.legal-section {
    scroll-margin-top: 8rem;
    padding: 1.75rem;
    border-radius: 1.5rem;
    background: #FFFFFF;
    border: 1px solid rgba(226, 232, 240, .9);
    box-shadow: 0 10px 26px -20px rgba(15, 23, 42, .2);
    transition: border-color .3s ease;
}
.legal-section + .legal-section { margin-top: 1rem; }
.legal-section:target { border-color: rgba(20, 184, 166, .5); box-shadow: 0 0 0 4px rgba(20, 184, 166, .1); }
@media (min-width: 768px) { .legal-section { padding: 2rem 2.25rem; } }

.legal-heading {
    display: flex;
    align-items: center;
    gap: .85rem;
    margin-bottom: 1rem;
    font-family: var(--font-space-grotesk), system-ui, sans-serif;
    font-size: 1.3rem;
    font-weight: 700;
    color: #0F172A;
}
.legal-num {
    display: flex;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    border-radius: .8rem;
    font-size: .85rem;
    font-weight: 800;
    color: #FFFFFF;
    background: linear-gradient(135deg, #0D9488, #16A34A);
    box-shadow: 0 8px 16px -8px rgba(13, 148, 136, .6);
}
.legal-section p,
.legal-section li { font-size: .95rem; line-height: 1.75; }
.legal-section ul { list-style: disc; padding-left: 1.25rem; }
.legal-section li::marker { color: #14B8A6; }
.legal-section a { text-underline-offset: 3px; }

/* Help card */
.legal-help {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-top: 1.5rem;
    padding: 1.75rem;
    border-radius: 1.5rem;
    background:
        radial-gradient(400px 200px at 100% 0%, rgba(34, 197, 94, .35), transparent 70%),
        linear-gradient(135deg, #0F766E, #16A34A);
    box-shadow: 0 24px 50px -26px rgba(13, 148, 136, .7);
}
.legal-help p { color: #CCFBF1; }
@media (min-width: 768px) {
    .legal-help { flex-direction: row; align-items: center; justify-content: space-between; }
}

/* Print: just the document */
@media print {
    #site-header, footer, .legal-switch, .legal-toc, .legal-help, .home-hero-mesh, [aria-label="Chat directly on WhatsApp"] { display: none !important; }
    main#main-content { padding-top: 0 !important; }
    .legal-section { box-shadow: none; break-inside: avoid; }
    .reveal-on-scroll { opacity: 1 !important; transform: none !important; }
}
