/* ====================================
   LEGAL PAGE STYLES - Food2Grow (with Modals)
   ==================================== */

/* Legal Navigation Section */
.legal-nav-section {
    padding: 80px 20px;
    background-color: var(--white);
    margin-top: 0;
}

.legal-nav-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    max-width: 1000px;
    margin: 0 auto;
}

.legal-card {
    background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
    padding: 3rem;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    border: none;
    text-decoration: none;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    text-align: left;
}

.legal-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(46, 139, 87, 0.1) 0%, rgba(22, 163, 74, 0.1) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.legal-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.legal-card:hover::before {
    opacity: 1;
}

.card-icon {
    width: 80px;
    height: 80px;
    margin-bottom: 1.5rem;
    position: relative;
    z-index: 1;
}

.card-icon svg {
    width: 100%;
    height: 100%;
    color: var(--primary-green);
    transition: all 0.3s ease;
}

.legal-card:hover .card-icon svg {
    transform: scale(1.1);
    color: var(--primary-green-dark);
}

.legal-card h2 {
    color: var(--primary-green);
    margin-bottom: 1rem;
    font-size: 1.75rem;
    position: relative;
    z-index: 1;
}

.legal-card p {
    color: var(--text-dark);
    line-height: 1.7;
    flex-grow: 1;
    margin-bottom: 1rem;
    position: relative;
    z-index: 1;
}

.card-arrow {
    font-size: 2rem;
    color: var(--primary-green);
    align-self: flex-end;
    transition: transform 0.3s ease;
    position: relative;
    z-index: 1;
}

.legal-card:hover .card-arrow {
    transform: translateX(10px);
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    overflow-y: auto;
}

.modal.active {
    display: block;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    animation: fadeIn 0.3s ease;
}

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

.modal-content {
    position: relative;
    max-width: 900px;
    margin: 60px auto;
    background: var(--white);
    border-radius: 16px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.4s ease;
    z-index: 10001;
}

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

.modal-close {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    width: 40px;
    height: 40px;
    border: none;
    background: rgba(0, 0, 0, 0.1);
    color: var(--text-dark);
    font-size: 2rem;
    line-height: 1;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
}

.modal-close:hover {
    background: var(--primary-green);
    color: var(--white);
    transform: rotate(90deg);
}

.modal-body {
    padding: 4rem;
    max-height: calc(100vh - 120px);
    overflow-y: auto;
}

/* Scrollbar styling for modal */
.modal-body::-webkit-scrollbar {
    width: 10px;
}

.modal-body::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.modal-body::-webkit-scrollbar-thumb {
    background: var(--primary-green);
    border-radius: 10px;
}

.modal-body::-webkit-scrollbar-thumb:hover {
    background: var(--primary-green-dark);
}

/* Modal Content Styling */
.modal-body h2 {
    color: var(--primary-green);
    margin-bottom: 0.5rem;
    font-size: 2.25rem;
}

.last-updated {
    color: var(--text-light);
    font-size: 0.9rem;
    font-style: italic;
    margin-bottom: 2rem;
}

.modal-body h3 {
    color: var(--primary-green);
    margin-top: 2rem;
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.modal-body h4 {
    color: var(--text-dark);
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
    font-size: 1.2rem;
}

.modal-body p {
    color: var(--text-dark);
    line-height: 1.8;
    margin-bottom: 1.25rem;
}

.modal-body ul {
    margin: 1.5rem 0;
    padding-left: 2rem;
}

.modal-body li {
    color: var(--text-dark);
    line-height: 1.8;
    margin-bottom: 0.75rem;
}

.modal-body a {
    color: var(--primary-green);
    text-decoration: underline;
    transition: color 0.3s ease;
}

.modal-body a:hover {
    color: var(--primary-green-dark);
}

.modal-body strong {
    color: var(--primary-green);
}

/* Info Divider */


/* ANBI Badge - nu met groene kleuren */
.anbi-badge {
    background: linear-gradient(135deg, #f0fdf4 0%, #dcfce7 100%);
    padding: 2rem;
    border-radius: 16px;
    text-align: center;
    margin: 2rem 0;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    border: 2px solid var(--primary-green);
}

.badge-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1rem;
}

.badge-icon svg {
    width: 100%;
    height: 100%;
    color: var(--primary-green);
}

.anbi-badge h3 {
    color: var(--primary-green);
    margin: 0;
    font-size: 1.75rem;
}

/* ANBI Details Box - nu met groene kleuren */
.anbi-details {
    background: #f9fafb;
    padding: 2rem;
    border-radius: 12px;
    margin: 2rem 0;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    border-left: 4px solid var(--primary-green);
}

.anbi-details p {
    margin-bottom: 0.75rem;
}

.anbi-details strong {
    color: var(--primary-green);
}

/* Modal Footer */
.modal-footer {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 2px solid var(--gray-light);
    text-align: center;
}

.modal-footer .btn {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
}

.modal-footer .btn svg {
    color: currentColor;
    transition: transform 0.3s ease;
}

.modal-footer .btn:hover svg {
    transform: translateY(2px);
}

/* Animations within Modal */
@keyframes modalFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal.active .modal-body > * {
    animation: modalFadeIn 0.5s ease forwards;
}

.modal.active .modal-body > *:nth-child(1) { animation-delay: 0.1s; }
.modal.active .modal-body > *:nth-child(2) { animation-delay: 0.15s; }
.modal.active .modal-body > *:nth-child(3) { animation-delay: 0.2s; }
.modal.active .modal-body > *:nth-child(4) { animation-delay: 0.25s; }

/* Responsive */
@media (max-width: 1024px) {
    .legal-nav-grid {
        grid-template-columns: 1fr;
        gap: 25px;
    }
}

@media (max-width: 768px) {
    .legal-nav-section {
        padding: 60px 20px;
    }
    
    .legal-card {
        padding: 2.5rem;
    }
    
    .card-icon {
        width: 60px;
        height: 60px;
    }
    
    .modal-content {
        margin: 20px;
        border-radius: 12px;
    }
    
    .modal-body {
        padding: 2.5rem;
    }
    
    .modal-close {
        top: 1rem;
        right: 1rem;
        width: 35px;
        height: 35px;
        font-size: 1.75rem;
    }
}

@media (max-width: 480px) {
    .legal-card {
        padding: 2rem;
    }
    
    .legal-card h2 {
        font-size: 1.5rem;
    }
    
    .modal-body {
        padding: 2rem;
    }
    
    .modal-body h2 {
        font-size: 1.875rem;
    }
    
    .modal-body h3 {
        font-size: 1.3rem;
    }
    
    
}


/* 1️⃣ Haal alle marge van de divider af */


/* 2️⃣ Zorg dat de hero strak tegen de divider eindigt */
.page-hero {
    padding-bottom: 40px; /* of 0 voor helemaal strak */
}


/* 3️⃣ Haal de top-padding weg van de eerste sectie NA de divider */
.info-divider + .legal-nav-section {
    padding-top: 0;
}
