/* Caselaws UI Styles - Hyper-HUD Premium Edition */

.caselaws-container {
    padding: 2.5rem;
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 2rem;
    overflow: hidden;
    animation: HUDentrance 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
    background: radial-gradient(circle at 50% 0%, rgba(59, 130, 246, 0.08) 0%, transparent 70%),
        linear-gradient(rgba(15, 23, 42, 0.5) 1px, transparent 1px),
        linear-gradient(90deg, rgba(15, 23, 42, 0.5) 1px, transparent 1px);
    background-size: 100% 100%, 35px 35px, 35px 35px;
    position: relative;
}

/* Scanline Overlay */
.caselaws-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(18, 16, 16, 0) 50%,
            rgba(0, 0, 0, 0.05) 50%), linear-gradient(90deg,
            rgba(255, 0, 0, 0.01),
            rgba(0, 255, 0, 0.005),
            rgba(0, 0, 255, 0.01));
    background-size: 100% 2px, 3px 100%;
    pointer-events: none;
    z-index: 5;
}

@keyframes HUDentrance {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.98);
        filter: blur(10px) brightness(2);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0) brightness(1);
    }
}

.caselaws-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(30px);
    padding: 2rem;
    border-radius: 20px;
    border: 1px solid rgba(59, 130, 246, 0.2);
    box-shadow: 0 0 40px rgba(0, 0, 0, 0.6), inset 0 0 20px rgba(59, 130, 246, 0.05);
    position: relative;
}

.caselaws-header::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 10%;
    width: 80%;
    height: 1px;
    background: linear-gradient(90deg, transparent, #3b82f6, #60a5fa, #3b82f6, transparent);
    box-shadow: 0 0 15px #3b82f6;
}

.hud-title-main {
    font-size: 2rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 4px;
    background: linear-gradient(180deg, #fff 0%, #94a3b8 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 0.25rem;
}

.cl-search-wrapper {
    position: relative;
    width: 480px;
}

.cl-search-input {
    width: 100%;
    background: rgba(15, 23, 42, 0.5);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 14px;
    padding: 1.2rem 1.2rem 1.2rem 3.5rem;
    color: #fff;
    font-family: 'Outfit', sans-serif;
    font-size: 1.1rem;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    box-shadow: inset 0 4px 10px rgba(0, 0, 0, 0.3);
}

.cl-search-input:focus {
    outline: none;
    border-color: #60a5fa;
    background: rgba(30, 41, 59, 0.8);
    box-shadow: 0 0 30px rgba(59, 130, 246, 0.2), inset 0 4px 10px rgba(0, 0, 0, 0.3);
    transform: translateY(-2px);
}

.cl-search-icon {
    position: absolute;
    left: 1.25rem;
    top: 50%;
    transform: translateY(-50%);
    color: #3b82f6;
    font-size: 1.3rem;
    filter: drop-shadow(0 0 5px rgba(59, 130, 246, 0.5));
}

.caselaws-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(520px, 1fr));
    grid-auto-rows: min-content;
    gap: 2.5rem;
    overflow-y: auto;
    padding: 0.5rem 1.5rem 3rem 0;
    flex-grow: 1;
}

/* Custom Scrollbar */
.caselaws-grid::-webkit-scrollbar {
    width: 4px;
}

.caselaws-grid::-webkit-scrollbar-track {
    background: transparent;
}

.caselaws-grid::-webkit-scrollbar-thumb {
    background: linear-gradient(to bottom, transparent, #3b82f6, transparent);
    border-radius: 10px;
}

.cl-card {
    background: rgba(30, 41, 59, 0.3);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(59, 130, 246, 0.15);
    border-radius: 24px;
    padding: 2.5rem;
    display: flex;
    flex-direction: column;
    gap: 2rem;
    transition: all 0.5s cubic-bezier(0.165, 0.84, 0.44, 1);
    position: relative;
}

.cl-card:hover {
    transform: scale(1.02) translateY(-10px);
    background: rgba(30, 41, 59, 0.5);
    border-color: rgba(59, 130, 246, 0.5);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.5), 0 0 30px rgba(59, 130, 246, 0.2);
}

.cl-card::before {
    content: '';
    position: absolute;
    top: 2rem;
    left: 0;
    width: 4px;
    height: calc(100% - 4rem);
    background: #3b82f6;
    border-radius: 0 4px 4px 0;
    box-shadow: 0 0 20px #3b82f6;
    transition: all 0.3s;
}

.cl-card.juris-federal::before {
    background: #3b82f6;
    box-shadow: 0 0 20px #3b82f6;
}

.cl-card.juris-local::before {
    background: #10b981;
    box-shadow: 0 0 20px #10b981;
}

.cl-card.juris-civil::before {
    background: #f59e0b;
    box-shadow: 0 0 20px #f59e0b;
}

.cl-card-header {
    display: flex;
    flex-direction: column;
    gap: 100.5rem;
}

.cl-title {
    font-size: 1.75rem;
    font-weight: 800;
    color: #fff;
    font-family: 'Outfit', sans-serif;
    letter-spacing: -0.03em;
    line-height: 1.3;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.cl-meta {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.cl-badge {
    padding: 0.45rem 1rem;
    border-radius: 10px;
    font-size: 0.8rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    background: rgba(59, 130, 246, 0.15);
    border: 1px solid rgba(59, 130, 246, 0.3);
    color: #60a5fa;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.cl-card.juris-local .cl-badge {
    color: #34d399;
    background: rgba(16, 185, 129, 0.15);
    border-color: rgba(16, 185, 129, 0.3);
}

.cl-year {
    font-size: 1rem;
    color: #94a3b8;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.cl-content-section {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.cl-label {
    font-size: 0.85rem;
    font-weight: 800;
    color: #3b82f6;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    opacity: 0.9;
}

.cl-label::after {
    content: '';
    height: 1px;
    flex-grow: 1;
    background: linear-gradient(90deg, rgba(59, 130, 246, 0.4), transparent);
}

.cl-summary {
    font-size: 1.1rem;
    color: #e2e8f0;
    line-height: 1.8;
    font-family: 'Inter', sans-serif;
}

.cl-implication {
    background: rgba(15, 23, 42, 0.4);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    border: 1px solid rgba(59, 130, 246, 0.15);
    padding: 1.5rem;
    font-size: 1.1rem;
    color: #93c5fd;
    font-style: italic;
    line-height: 1.7;
    position: relative;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.cl-implication::before {
    content: '\f10d';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    top: -12px;
    left: 25px;
    background: #1e293b;
    padding: 0 12px;
    font-size: 1rem;
    color: #3b82f6;
    font-style: normal;
    text-shadow: 0 0 10px rgba(59, 130, 246, 0.5);
}

.cl-footer {
    margin-top: auto;
    padding-top: 1rem;
}

.cl-link {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    color: #fff;
    text-decoration: none;
    font-size: 1rem;
    font-weight: 800;
    padding: 0.8rem 1.75rem;
    background: linear-gradient(to right, #3b82f6, #60a5fa);
    border-radius: 12px;
    transition: all 0.4s;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.cl-link:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.5);
    filter: brightness(1.1);
}

/* No Results State */
.cl-no-results {
    grid-column: 1 / -1;
    text-align: center;
    padding: 8rem 2rem;
    color: #64748b;
    background: rgba(15, 23, 42, 0.3);
    border-radius: 32px;
    border: 2px dashed rgba(59, 130, 246, 0.1);
}

.cl-no-results i {
    font-size: 5rem;
    margin-bottom: 2.5rem;
    color: #3b82f6;
    opacity: 0.4;
    filter: drop-shadow(0 0 20px rgba(59, 130, 246, 0.2));
}

.cl-no-results p {
    font-size: 1.25rem;
    font-weight: 600;
    letter-spacing: 1px;
}