/* ═══════════════════════════════════════════════════════════════════════════
   GDPR / Cookie Consent Styles
   EasyRefert - ITLand S.r.l.
   Standalone CSS - No Bootstrap dependency
   ═══════════════════════════════════════════════════════════════════════════ */

:root {
    --gdpr-primary: #1d4f5e;
    --gdpr-secondary: #2d6a7e;
    --gdpr-dark: #1a1a2e;
    --gdpr-light: #f8f9fa;
    --gdpr-white: #ffffff;
    --gdpr-gray: #6c757d;
    --gdpr-success: #18c29c;
    --gdpr-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
    --gdpr-radius: 0.75rem;
    --gdpr-transition: all 0.3s ease;
}

/* ═══════════════════════════════════════════════════════════════════════════
   Cookie Consent Bar
   ═══════════════════════════════════════════════════════════════════════════ */

.cookie-consent-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    background: var(--gdpr-dark);
    color: var(--gdpr-white);
    box-shadow: var(--gdpr-shadow);
    animation: slideUp 0.4s ease-out;
    font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
}

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

.cookie-consent-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1.25rem 1.5rem;
}

.cookie-consent-content {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.cookie-consent-text {
    flex: 1;
    min-width: 280px;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.cookie-consent-text .cookie-icon {
    font-size: 1.5rem;
}

.cookie-consent-text p {
    font-size: 0.9rem;
    line-height: 1.5;
    margin: 0;
}

.cookie-consent-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
}

/* Cookie Buttons (standalone) */
.cookie-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    padding: 0.6rem 1.2rem;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--gdpr-transition);
    border: 1px solid transparent;
    font-family: inherit;
    white-space: nowrap;
}

.cookie-btn-primary {
    background: linear-gradient(135deg, var(--gdpr-primary) 0%, var(--gdpr-secondary) 100%);
    color: var(--gdpr-white);
    border: none;
}

.cookie-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(29, 79, 94, 0.4);
}

.cookie-btn-outline {
    border: 1px solid rgba(255, 255, 255, 0.5);
    color: var(--gdpr-white);
    background: transparent;
}

.cookie-btn-outline:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: var(--gdpr-white);
}

.cookie-btn-link {
    background: transparent;
    border: none;
    color: rgba(255, 255, 255, 0.8);
    padding: 0.6rem 0.8rem;
}

.cookie-btn-link:hover {
    color: var(--gdpr-white);
}

.cookie-consent-links {
    margin-top: 0.75rem;
    font-size: 0.8rem;
    opacity: 0.8;
}

.cookie-consent-links a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
}

.cookie-consent-links a:hover {
    color: var(--gdpr-white);
    text-decoration: underline;
}

.cookie-consent-links .mx-2 {
    margin: 0 0.5rem;
}

/* ═══════════════════════════════════════════════════════════════════════════
   Cookie Settings Floating Button
   ═══════════════════════════════════════════════════════════════════════════ */

.cookie-settings-floating-btn {
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 9998;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--gdpr-primary);
    color: var(--gdpr-white);
    border: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    cursor: pointer;
    transition: var(--gdpr-transition);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
}

.cookie-settings-floating-btn:hover {
    background: var(--gdpr-secondary);
    transform: scale(1.1);
}

/* ═══════════════════════════════════════════════════════════════════════════
   Cookie Settings Modal (Standalone - No Bootstrap)
   ═══════════════════════════════════════════════════════════════════════════ */

.cookie-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
}

.cookie-modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
}

.cookie-modal-dialog {
    position: relative;
    z-index: 1;
    width: 90%;
    max-width: 480px;
    max-height: 90vh;
    animation: modalFadeIn 0.3s ease-out;
}

@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: scale(0.95) translateY(-20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.cookie-modal-content {
    background: var(--gdpr-white);
    border-radius: var(--gdpr-radius);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

.cookie-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 1.5rem;
    background: linear-gradient(135deg, var(--gdpr-primary) 0%, var(--gdpr-secondary) 100%);
    color: var(--gdpr-white);
}

.cookie-modal-title {
    margin: 0;
    font-size: 1.15rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.cookie-modal-close {
    background: transparent;
    border: none;
    color: var(--gdpr-white);
    font-size: 1.8rem;
    cursor: pointer;
    padding: 0;
    line-height: 1;
    opacity: 0.8;
    transition: var(--gdpr-transition);
}

.cookie-modal-close:hover {
    opacity: 1;
    transform: scale(1.1);
}

.cookie-modal-body {
    padding: 1.5rem;
    max-height: 60vh;
    overflow-y: auto;
    color: #333;
}

.cookie-modal-desc {
    font-size: 0.9rem;
    color: var(--gdpr-gray);
    line-height: 1.6;
    margin: 0 0 1.5rem 0;
}

/* Cookie Category Items */
.cookie-category-item {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem;
    margin-bottom: 0.75rem;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    transition: var(--gdpr-transition);
}

.cookie-category-item:hover {
    background: var(--gdpr-light);
}

.cookie-category-item.cookie-category-required {
    background: linear-gradient(135deg, rgba(24, 194, 156, 0.08), rgba(24, 194, 156, 0.02));
    border-color: rgba(24, 194, 156, 0.3);
}

.cookie-category-info {
    flex: 1;
}

.cookie-category-title {
    margin: 0 0 0.4rem 0;
    font-size: 1rem;
    font-weight: 600;
    color: #333;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.cookie-category-icon {
    font-size: 1.1rem;
}

.cookie-category-desc {
    margin: 0;
    font-size: 0.85rem;
    color: var(--gdpr-gray);
    line-height: 1.5;
}

/* Toggle Switch (standalone) */
.cookie-toggle {
    flex-shrink: 0;
    padding-top: 0.25rem;
}

.cookie-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 28px;
    cursor: pointer;
}

.cookie-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.cookie-slider {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #ccc;
    border-radius: 28px;
    transition: var(--gdpr-transition);
}

.cookie-slider::before {
    content: '';
    position: absolute;
    width: 22px;
    height: 22px;
    left: 3px;
    bottom: 3px;
    background: var(--gdpr-white);
    border-radius: 50%;
    transition: var(--gdpr-transition);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.cookie-switch input:checked + .cookie-slider {
    background: var(--gdpr-primary);
}

.cookie-switch input:checked + .cookie-slider::before {
    transform: translateX(22px);
}

.cookie-switch.cookie-switch-disabled {
    cursor: not-allowed;
    opacity: 0.7;
}

.cookie-switch.cookie-switch-disabled .cookie-slider {
    background: var(--gdpr-success);
}

.cookie-modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    padding: 1rem 1.5rem;
    background: var(--gdpr-light);
    border-top: 1px solid #e0e0e0;
}

.cookie-modal-footer .cookie-btn-outline {
    color: var(--gdpr-gray);
    border-color: #ccc;
}

.cookie-modal-footer .cookie-btn-outline:hover {
    background: #e0e0e0;
    color: #333;
}

/* ═══════════════════════════════════════════════════════════════════════════
   Footer Public
   ═══════════════════════════════════════════════════════════════════════════ */

.footer-public {
    background: linear-gradient(180deg, #1a1a2e 0%, #16213e 100%);
    color: var(--gdpr-white);
    padding: 3rem 0 0;
    margin-top: auto;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 2rem;
    padding-bottom: 2rem;
}

.footer-heading {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--gdpr-white);
    position: relative;
    padding-bottom: 0.5rem;
}

.footer-heading::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 2px;
    background: var(--gdpr-primary);
}

/* Footer Brand */
.footer-brand {
    max-width: 280px;
}

.footer-logo-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    margin-bottom: 1rem;
}

.footer-logo {
    max-height: 40px;
    width: auto;
}

.footer-brand-text {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--gdpr-white);
    background: linear-gradient(135deg, var(--gdpr-white) 0%, rgba(255,255,255,0.7) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.footer-brand-desc {
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.6;
    margin-bottom: 0.5rem;
}

.footer-brand-by {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.5);
    margin: 0;
}

/* Footer Info List */
.footer-info-list,
.footer-links-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-info-list li,
.footer-links-list li {
    margin-bottom: 0.75rem;
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.7);
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
}

.footer-info-list li i,
.footer-links-list li i {
    color: var(--gdpr-primary);
    font-size: 0.9rem;
    margin-top: 2px;
}

.footer-links-list a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: var(--gdpr-transition);
}

.footer-links-list a:hover {
    color: var(--gdpr-white);
    padding-left: 5px;
}

.footer-info-list a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
}

.footer-info-list a:hover {
    color: var(--gdpr-white);
    text-decoration: underline;
}

/* Footer Bottom */
.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 1.25rem 0;
}

.footer-bottom-content {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.footer-copyright {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.5);
}

.footer-bottom-links {
    font-size: 0.8rem;
}

.footer-bottom-links a {
    color: rgba(255, 255, 255, 0.5);
    text-decoration: none;
}

.footer-bottom-links a:hover {
    color: var(--gdpr-white);
}

.footer-bottom-links span {
    color: rgba(255, 255, 255, 0.3);
}

/* ═══════════════════════════════════════════════════════════════════════════
   Policy Pages
   ═══════════════════════════════════════════════════════════════════════════ */

.policy-page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.policy-page .card {
    border: none;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
}

.language-switcher {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
}

.policy-header {
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    padding-bottom: 2rem;
}

.policy-content section {
    scroll-margin-top: 100px;
}

.policy-content h2 {
    position: relative;
    padding-left: 1rem;
}

.policy-content h2::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, var(--gdpr-primary) 0%, var(--gdpr-secondary) 100%);
    border-radius: 2px;
}

.policy-content ul {
    padding-left: 1.5rem;
}

.policy-content ul li {
    margin-bottom: 0.5rem;
    line-height: 1.6;
}

.policy-company-info {
    background: var(--gdpr-light);
    padding: 1.5rem;
    border-radius: var(--gdpr-radius);
}

/* Cookie Table Section */
.cookie-table-section .card {
    border: 1px solid rgba(0, 0, 0, 0.1);
}

.cookie-table-section .card-header {
    background: var(--gdpr-light);
}

/* ═══════════════════════════════════════════════════════════════════════════
   Responsive
   ═══════════════════════════════════════════════════════════════════════════ */

@media (max-width: 768px) {
    .cookie-consent-container {
        padding: 1rem;
    }

    .cookie-consent-content {
        flex-direction: column;
        text-align: center;
    }

    .cookie-consent-text {
        justify-content: center;
        flex-direction: column;
    }

    .cookie-consent-buttons {
        justify-content: center;
        width: 100%;
    }

    .cookie-consent-links {
        text-align: center;
    }

    .cookie-modal-dialog {
        width: 95%;
        margin: 1rem;
    }

    .cookie-modal-body {
        max-height: 50vh;
    }

    .cookie-category-item {
        flex-direction: column;
        gap: 0.75rem;
    }

    .cookie-toggle {
        align-self: flex-end;
    }

    .cookie-modal-footer {
        flex-direction: column;
    }

    .cookie-modal-footer .cookie-btn {
        width: 100%;
    }

    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-heading::after {
        left: 50%;
        transform: translateX(-50%);
    }

    .footer-brand {
        max-width: 100%;
    }

    .footer-logo-link {
        justify-content: center;
    }

    .footer-info-list li,
    .footer-links-list li {
        justify-content: center;
    }

    .footer-bottom-content {
        flex-direction: column;
        text-align: center;
    }

    .language-switcher {
        justify-content: center;
    }
}

@media (max-width: 576px) {
    .cookie-consent-buttons .cookie-btn {
        font-size: 0.8rem;
        padding: 0.5rem 0.75rem;
    }

    .cookie-settings-floating-btn {
        width: 40px;
        height: 40px;
        font-size: 1.1rem;
        bottom: 15px;
        left: 15px;
    }
}
