/* ==========================================================================
   LFDH Studio - CSS Puro con Dark/Light Theme
   ========================================================================== */

/* CSS Property for animated border */
@property --angle {
    syntax: '<angle>';
    initial-value: 0deg;
    inherits: false;
}

/* Variables CSS */
:root {
    --primary-color: #000000;
    --accent-color: #5de3f4;
    --text-light: #000000;
    --text-dark: #ffffff;
    --bg-light: #ffffff;
    --bg-dark: #000000;
    --gray-50: #f9f9f9;
    --gray-100: #f0f0f0;
    --gray-200: #e0e0e0;
    --gray-300: #b0b0b0;
    --gray-400: #808080;
    --gray-500: #606060;
    --gray-600: #404040;
    --gray-700: #303030;
    --gray-800: #202020;
    --gray-900: #101010;

    /* Theme-specific variables */
    --bg-primary: var(--bg-light);
    --bg-secondary: var(--gray-50);
    --text-primary: var(--text-light);
    --text-secondary: var(--gray-600);
    --border-color: var(--gray-200);
}

/* Dark Theme */
body.dark {
    --bg-primary: var(--bg-dark);
    --bg-secondary: var(--gray-900);
    --text-primary: var(--text-dark);
    --text-secondary: var(--gray-400);
    --border-color: var(--gray-700);
}

/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Ubuntu', system-ui, -apple-system, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    transition: background-color 0.3s ease, color 0.3s ease;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Ubuntu', system-ui, -apple-system, sans-serif;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

p {
    margin-bottom: 1rem;
}

a {
    color: var(--accent-color);
    text-decoration: none;
    transition: opacity 0.3s ease;
}

a:hover {
    opacity: 0.8;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Section */
.section {
    padding: 80px 0;
}

.section-dark {
    background-color: var(--bg-secondary);
}

.text-center {
    text-align: center;
}

.text-accent {
    color: var(--accent-color);
}

.subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.small {
    font-size: 0.875rem;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 12px 30px;
    font-weight: 600;
    text-align: center;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    font-family: 'Ubuntu', sans-serif;
}

.btn-primary {
    background-color: var(--text-primary);
    color: var(--bg-primary);
}

.btn-primary:hover {
    opacity: 0.9;
    transform: translateY(-2px);
}

.btn-secondary {
    background-color: transparent;
    color: var(--text-primary);
    border: 2px solid var(--text-primary);
}

.btn-secondary:hover {
    background-color: var(--text-primary);
    color: var(--bg-primary);
}

.btn-full {
    width: 100%;
}

/* Header */
#header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background-color: var(--bg-primary);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    transition: all 0.3s ease;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
}

.logo img {
    height: 40px;
    width: auto;
    transition: all 0.3s ease;
}

/* Logo changes handled by JavaScript */

.nav-menu {
    display: flex;
    list-style: none;
    gap: 30px;
}

.nav-menu a {
    color: var(--text-primary);
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-menu a:hover {
    color: var(--accent-color);
}

.nav-buttons {
    display: flex;
    align-items: center;
    gap: 20px;
}

.theme-toggle {
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
    transition: transform 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.theme-toggle:hover {
    transform: scale(1.1);
}

.theme-toggle svg {
    width: 20px;
    height: 20px;
    fill: var(--text-primary);
    stroke: var(--text-primary);
    transition: all 0.3s ease;
}

.sun-icon { display: none; }
.moon-icon { display: block; }
body.dark .sun-icon { display: block; }
body.dark .moon-icon { display: none; }

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 4px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
}

.menu-toggle span {
    width: 25px;
    height: 2px;
    background-color: var(--text-primary);
    transition: all 0.3s ease;
}

/* Hero Section */
#hero {
    margin-top: 81px;
    height: calc(100vh - 81px);
    position: relative;
    overflow: hidden;
    background-color: var(--bg-primary);
}

.hero-intro {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    animation: fadeIn 0.5s ease;
}

.intro-logo {
    width: 200px;
    margin-bottom: 30px;
    animation: scaleIn 0.8s ease;
}

/* Logo changes handled by JavaScript */

.intro-text {
    font-size: 18px;
    color: var(--text-secondary);
    margin-bottom: 30px;
    animation: fadeIn 1s ease 0.5s both;
}

.loading-bar-container {
    width: 300px;
    height: 4px;
    background: var(--gray-700);
    border-radius: 10px;
    margin: 0 auto 30px;
    overflow: hidden;
    opacity: 0;
    animation: fadeIn 0.5s ease 1s forwards;
}

.loading-bar {
    height: 100%;
    width: 0%;
    background: var(--accent-color);
    border-radius: 10px;
    animation: loadProgress 5s ease forwards;
    box-shadow: 0 0 10px var(--accent-color);
}

@keyframes loadProgress {
    0% { width: 0%; }
    100% { width: 100%; }
}

.intro-numbers {
    font-size: 24px;
    font-weight: 400;
    color: var(--accent-color);
    opacity: 0;
    animation: fadeIn 0.5s ease 2s forwards;
    text-align: center;
}

.intro-numbers div {
    margin: 10px 0;
}

.intro-numbers span {
    font-size: 32px;
    font-weight: 700;
}

.hero-content {
    height: 100%;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* SEO Introduction */
#seo-intro {
    background-color: var(--bg-primary);
}

#seo-intro h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

#seo-intro .intro-text {
    max-width: 900px;
    margin: 0 auto 20px;
    color: var(--text-secondary);
    line-height: 1.8;
}

/* Video in Hero Section */
.hero-content .video-container {
    position: relative;
    height: 100%;
    width: 100%;
    background-color: #000;
    overflow: hidden;
    padding-bottom: 0;
    margin-top: 0;
}

.hero-content .video-placeholder,
.hero-content .video-iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.hero-content .video-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-color);
    font-size: 18px;
}

.hero-content .video-iframe {
    border: none;
    /* Ingrandisce il video per nascondere titolo superiore e logo YouTube inferiore */
    width: 120%;
    height: 120%;
    top: -10%;
    left: -10%;
}

/* SVG Section */
.svg-container {
    position: relative;
    margin-top: 40px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 20px 0;
}

.studio-svg {
    width: 100%;
    height: auto;
    max-height: 600px;
    object-fit: contain;
    object-position: center;
    display: block;
    margin: 0 auto;
}

/* Portfolio Section */
#portfolio {
    position: relative;
}

.portfolio-grid {
    display: flex;
    gap: 10px;
    margin-top: 40px;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    padding: 40px calc(50% - 200px);
    scrollbar-width: thin;
    scrollbar-color: var(--accent-color) var(--gray-200);
    scroll-snap-type: x mandatory;
    align-items: center;
    height: 380px;
}

.portfolio-title-display {
    text-align: center;
    margin-top: 10px;
    min-height: 30px;
    color: var(--text-primary);
    font-size: 18px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.portfolio-grid::-webkit-scrollbar {
    display: none;
}

.portfolio-grid {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.portfolio-item {
    position: relative;
    overflow: hidden;
    min-width: 250px;
    width: 250px;
    height: 180px;
    background-color: var(--bg-secondary);
    cursor: pointer;
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    flex-shrink: 0;
    opacity: 0.4;
    filter: blur(3px) grayscale(50%);
    transform: scale(0.85);
    scroll-snap-align: center;
}

.portfolio-item.active {
    min-width: 400px;
    width: 400px;
    height: 280px;
    opacity: 1;
    filter: blur(0) grayscale(0);
    transform: scale(1);
    box-shadow: 0 10px 40px rgba(93, 227, 244, 0.4);
    z-index: 10;
}

.portfolio-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.portfolio-item:hover img {
    transform: scale(1.02);
}

.portfolio-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    color: white;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
}

.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
    transform: translateY(0);
}

/* Lightbox */
.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0,0,0,0.95);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease;
}

.lightbox.active {
    display: flex;
}

.lightbox-content {
    max-width: 90vw;
    max-height: 90vh;
    position: relative;
}

.lightbox-content img {
    max-width: 100%;
    max-height: 90vh;
    object-fit: contain;
}

.lightbox-prev,
.lightbox-next {
    position: absolute;
    background: rgba(0,0,0,0.5);
    color: white;
    border: 1px solid rgba(255,255,255,0.2);
    padding: 15px 20px;
    cursor: pointer;
    font-size: 32px;
    transition: all 0.3s ease;
    top: 50%;
    transform: translateY(-50%);
}

.lightbox-prev:hover,
.lightbox-next:hover {
    background: rgba(0,0,0,0.7);
    transform: translateY(-50%) scale(1.1);
}

.lightbox-prev {
    left: 20px;
}

.lightbox-next {
    right: 20px;
}

/* Pricing Section */
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin: 40px 0;
}

.pricing-card {
    position: relative;
    padding: 40px;
    background-color: transparent;
    border-radius: 0;
    transition: all 0.3s ease;
}

.pricing-card::before {
    content: '';
    position: absolute;
    inset: -1.5px;
    border-radius: 0;
    z-index: -2;
    padding: 1.5px;
    background: conic-gradient(
        from var(--angle),
        var(--accent-color),
        var(--accent-color) 30%,
        transparent 50%,
        transparent 80%,
        var(--accent-color)
    );
    animation: rotateBorder 4s linear infinite;
    --angle: 0deg;
}

.pricing-card::after {
    content: '';
    position: absolute;
    inset: 0;
    background-color: var(--bg-primary);
    border-radius: 0;
    z-index: -1;
}

.pricing-card:hover {
    transform: translateY(-5px);
}

.pricing-card h3 {
    color: var(--text-primary);
    margin-bottom: 10px;
}

.pricing-subtitle {
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.price {
    margin: 30px 0;
}

.amount {
    display: block;
    font-size: 3rem;
    font-weight: 700;
    color: var(--text-primary);
}

.detail {
    display: block;
    color: var(--text-secondary);
    margin-top: 5px;
}

.savings {
    display: block;
    color: var(--accent-color);
    font-weight: 600;
    margin-top: 5px;
}

.features {
    list-style: none;
    margin: 30px 0;
}

.features li {
    padding: 10px 0;
    color: var(--text-secondary);
}

.ideal {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin: 20px 0;
}

.pricing-notes {
    text-align: center;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

/* FAQ Section */
.faq-container {
    max-width: 800px;
    margin: 40px auto;
}

.faq-item {
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.faq-item.revised {
    opacity: 1;
}

.faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    padding: 15px 0;
    transition: color 0.3s ease;
}

.faq-question:hover {
    color: var(--accent-color);
}

.faq-question h3 {
    margin: 0;
    font-size: 1.1rem;
}

.faq-arrow {
    transition: transform 0.3s ease;
    color: var(--accent-color);
}

.faq-item.active .faq-arrow {
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.faq-item.active .faq-answer {
    max-height: 500px;
}

.faq-answer p {
    padding: 15px 0;
    color: var(--text-secondary);
}

/* Contact Section */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-top: 40px;
    align-items: stretch;
}

.contact-form,
.info-card {
    height: 100%;
}

.map-container-full {
    margin-top: 40px;
    background-color: var(--bg-secondary);
    border-radius: 8px;
    overflow: hidden;
}

.map-container-full iframe {
    display: block;
    width: 100%;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-primary);
    font-weight: 500;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px;
    background-color: var(--bg-primary);
    border: none;
    border-bottom: 2px solid var(--border-color);
    color: var(--text-primary);
    font-family: 'Ubuntu', sans-serif;
    transition: border-color 0.3s ease;
}

.form-group select option {
    background-color: var(--bg-primary);
    color: var(--text-primary);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-color);
}

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

.checkbox {
    display: flex;
    align-items: center;
    gap: 10px;
}

.checkbox input {
    width: auto;
}

.info-card {
    background-color: var(--bg-secondary);
    padding: 30px;
    border-radius: 8px;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
    color: var(--text-primary);
}

.icon {
    font-size: 20px;
}

.schedule {
    margin-top: 30px;
    padding-top: 30px;
    border-top: 1px solid var(--border-color);
}

.schedule h4 {
    margin-bottom: 10px;
}

.map-placeholder {
    background-color: var(--bg-secondary);
    padding: 40px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 250px;
}

.map-placeholder .icon {
    font-size: 48px;
    margin-bottom: 20px;
    color: var(--text-secondary);
}

/* Footer */
#footer {
    background-color: var(--bg-secondary);
    padding: 60px 0 20px;
    border-top: 1px solid var(--border-color);
}

.footer-logo-row {
    text-align: center;
    margin-bottom: 40px;
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
    align-items: start;
}

.footer-column h4 {
    margin-bottom: 20px;
    color: var(--text-primary);
}

.footer-column ul {
    list-style: none;
}

.footer-column ul li {
    margin-bottom: 10px;
}

.footer-column a {
    color: var(--text-secondary);
    transition: color 0.3s ease;
}

.footer-column a:hover {
    color: var(--accent-color);
}

.footer-logo {
    height: 50px;
    margin-bottom: 20px;
}

/* Logo changes handled by JavaScript */

.newsletter-form {
    display: flex;
    margin-top: 10px;
}

.newsletter-form input {
    flex: 1;
    padding: 10px;
    background-color: var(--bg-primary);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
}

.newsletter-form button {
    padding: 10px 20px;
    background-color: var(--text-primary);
    color: var(--bg-primary);
    border: none;
    cursor: pointer;
    transition: opacity 0.3s ease;
}

.newsletter-form button:hover {
    opacity: 0.8;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.footer-bottom p {
    margin-bottom: 5px;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes scaleIn {
    from {
        transform: scale(0.8);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes rotateBorder {
    0% {
        --angle: 0deg;
    }
    100% {
        --angle: 360deg;
    }
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }

    .section {
        padding: 60px 0;
    }

    h1 { font-size: 2rem; }
    h2 { font-size: 1.5rem; }
    h3 { font-size: 1.25rem; }

    /* Mobile Navigation */
    .nav-menu {
        position: fixed;
        top: 81px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 81px);
        background-color: var(--bg-primary);
        flex-direction: column;
        justify-content: start;
        padding: 40px;
        transition: left 0.3s ease;
    }

    .nav-menu.active {
        left: 0;
    }

    .menu-toggle {
        display: flex;
    }

    .nav-buttons .btn {
        display: none;
    }

    /* Mobile Grids */
    .portfolio-item {
        min-width: 180px;
        width: 180px;
        height: 130px;
    }

    .portfolio-item.active {
        min-width: 280px;
        width: 280px;
        height: 200px;
    }

    .pricing-grid {
        grid-template-columns: 1fr;
    }

    .contact-grid,
    .footer-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .map-container-full {
        margin-top: 30px;
    }

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

    /* Mobile Hero */
    #hero {
        margin-top: 61px;
        height: 50vh;
        min-height: 300px;
        max-height: 400px;
    }

    .hero-content {
        height: 100%;
    }

    .intro-logo {
        width: 150px;
    }

    .intro-text {
        font-size: 16px;
        text-align: center;
        padding: 0 20px;
    }

    .loading-bar-container {
        width: 200px;
        height: 3px;
    }

    .intro-numbers {
        font-size: 20px;
    }

    .intro-numbers span {
        font-size: 28px;
    }

    /* Mobile Hero Video */
    .hero-content .video-container {
        width: 100%;
        height: 100%;
        position: relative;
    }

    .hero-content .video-placeholder,
    .hero-content .video-iframe {
        width: 100%;
        height: 100%;
    }

    /* Mobile SVG Section */
    .svg-container {
        display: flex;
        align-items: flex-start;
        justify-content: flex-start;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none; /* Firefox */
        -ms-overflow-style: none; /* IE/Edge */
        padding: 20px 0;
    }

    .svg-container::-webkit-scrollbar {
        display: none; /* Chrome/Safari */
    }

    .studio-svg {
        max-height: 400px;
        width: auto;
        min-width: 150%;
        flex-shrink: 0;
    }

    /* Mobile FAQ */
    .faq-question h3 {
        font-size: 1rem;
        padding-right: 20px;
    }

    /* Mobile Footer */
    .footer-content {
        text-align: center;
    }

    .footer-column ul {
        margin-bottom: 20px;
    }
}

/* Form submission feedback */
.form-message {
    display: none;
    padding: 1rem 1.25rem;
    margin-top: 1rem;
    border-radius: 6px;
    font-size: 0.95rem;
    line-height: 1.5;
}
.form-message-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}
.form-message-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* ===========================
   Cookie consent banner
   =========================== */
.cookie-banner {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10000;
    background: #111;
    color: #fff;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.35);
    transform: translateY(100%);
    transition: transform 0.3s ease;
}
.cookie-banner.is-visible {
    transform: translateY(0);
}
.cookie-banner-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 18px 24px;
    display: flex;
    gap: 24px;
    align-items: center;
    flex-wrap: wrap;
}
.cookie-banner-text {
    flex: 1 1 360px;
    font-size: 0.9rem;
    line-height: 1.5;
}
.cookie-banner-text a {
    color: var(--accent-color, #5de3f4);
    text-decoration: underline;
}
.cookie-banner-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}
.cookie-banner-actions .btn {
    padding: 10px 22px;
    font-size: 0.9rem;
}
@media (max-width: 640px) {
    .cookie-banner-inner {
        padding: 16px;
        gap: 14px;
    }
    .cookie-banner-actions {
        width: 100%;
        justify-content: stretch;
    }
    .cookie-banner-actions .btn {
        flex: 1;
    }
}

/* ===========================
   Legal pages (privacidad, cookies, aviso-legal)
   =========================== */
.legal-page main.legal-content {
    padding: 120px 0 80px;
    min-height: 70vh;
}
.legal-content .container {
    max-width: 860px;
}
.legal-content h1 {
    font-size: 2.2rem;
    margin-bottom: 8px;
    line-height: 1.2;
}
.legal-content h2 {
    font-size: 1.35rem;
    margin: 2.2rem 0 0.8rem;
    line-height: 1.3;
}
.legal-content h3 {
    font-size: 1.08rem;
    margin: 1.6rem 0 0.6rem;
}
.legal-content p,
.legal-content li {
    font-size: 1rem;
    line-height: 1.7;
}
.legal-content ul {
    padding-left: 1.4rem;
    margin: 0.6rem 0 1rem;
}
.legal-content li {
    margin-bottom: 0.35rem;
}
.legal-content a {
    color: var(--accent-color, #5de3f4);
    text-decoration: underline;
}
.legal-updated {
    opacity: 0.65;
    font-size: 0.9rem;
    margin-bottom: 1.6rem;
}
.legal-table {
    width: 100%;
    border-collapse: collapse;
    margin: 0.8rem 0 1.4rem;
    font-size: 0.92rem;
}
.legal-table th,
.legal-table td {
    padding: 10px 12px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    text-align: left;
    vertical-align: top;
}
.legal-table thead th {
    background: rgba(255, 255, 255, 0.05);
    font-weight: 500;
}
body:not(.dark) .legal-table th,
body:not(.dark) .legal-table td {
    border-color: rgba(0, 0, 0, 0.12);
}
body:not(.dark) .legal-table thead th {
    background: rgba(0, 0, 0, 0.04);
}
@media (max-width: 640px) {
    .legal-page main.legal-content {
        padding: 100px 0 60px;
    }
    .legal-content h1 {
        font-size: 1.7rem;
    }
    .legal-table {
        display: block;
        overflow-x: auto;
    }
}