/* 
   ------------------------------
   RESPONSIVE UTILITIES 
   ------------------------------
*/

/* 2-Column Grid (Stacks on Tablet/Mobile) */
.grid-responsive-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

@media (max-width: 900px) {
    .grid-responsive-2 {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
}

/* Flex Row (Stacks on Tablet/Mobile) */
.flex-responsive {
    display: flex;
    gap: 4rem;
    align-items: center;
    flex-wrap: wrap;
}

/* If using flex-wrap, the browser handles stacking if items have min-width, 
   but sometimes we want to enforce it or change ordering. 
   This helper enforces stacking on smaller screens. */
@media (max-width: 900px) {
    .flex-responsive {
        flex-direction: column;
        gap: 3rem;
    }

    .flex-responsive>* {
        width: 100%;
        min-width: 0;
        /* Reset min-width issues */
    }
}

/* Tablet Override for Contact Page Structure if needed */
@media (max-width: 900px) {
    .premium-card>div {
        grid-template-columns: 1fr !important;
        gap: 3rem !important;
    }
}

/* Sidebar Layout & Statute List */
.page-with-sidebar {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 3rem;
    align-items: start;
    padding-bottom: 4rem;
}

.sidebar {
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    border: 1px solid #e2e8f0;
    position: sticky;
    top: 100px;
    height: fit-content;
    overflow: hidden;
}

.sidebar-header {
    background: var(--primary);
    color: white;
    padding: 1.5rem;
    font-family: 'Playfair Display', serif;
    font-size: 1.25rem;
    text-align: center;
    letter-spacing: 0.05em;
}

.statute-list {
    list-style: none;
    padding: 0;
    margin: 0;
    max-height: 70vh;
    overflow-y: auto;
}

.statute-list li {
    border-bottom: 1px solid #f1f5f9;
}

.statute-list li:last-child {
    border-bottom: none;
}

.statute-list a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.5rem;
    color: var(--text-main);
    transition: all 0.2s;
    font-size: 0.95rem;
    font-weight: 500;
}

.statute-list a:hover {
    background: #f8fafc;
    color: var(--accent);
    padding-left: 2rem;
}

.statute-list a i {
    opacity: 0;
    transform: translateX(-10px);
    transition: 0.2s;
}

.statute-list a:hover i {
    opacity: 1;
    transform: translateX(0);
}

.main-content-section {
    background: #fff;
    border-radius: var(--radius-lg);
    /* box-shadow: var(--shadow-sm); */
    /* padding: 2rem; */
    margin-bottom: 2rem;
}

@media (max-width: 900px) {
    .page-with-sidebar {
        grid-template-columns: 1fr;
    }

    .sidebar {
        position: static;
        margin-bottom: 3rem;
        max-height: none;
    }

    .statute-list {
        max-height: 300px;
    }
}