/* ==========================================================================
   Banco de Normas - Premium Page Styles
   ========================================================================== */

/* Hero Section */
.normas-hero {
    background: linear-gradient(135deg, var(--color-primary) 0%, #1e3a24 100%);
    position: relative;
    overflow: hidden;
    color: #fff;
    min-height: 380px;
    display: flex;
    align-items: center;
}

.normas-hero::before {
    content: '\f24e'; /* Scale icon */
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    right: -5%;
    bottom: -10%;
    font-size: 25rem;
    color: rgba(255, 255, 255, 0.03);
    pointer-events: none;
}

/* Floating Toolbar */
.normas-toolbar {
    margin-top: -60px;
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-lg);
    z-index: 10;
    position: relative;
}

html.dark-theme .normas-toolbar {
    background: rgba(15, 23, 42, 0.8);
    border-color: rgba(255, 255, 255, 0.05);
}

/* Items Grid */
.normas-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

/* Premium Document Card */
.norma-premium-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 16px;
    display: flex;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    box-shadow: 0 4px 15px -10px rgba(0,0,0,0.1);
}

.norma-premium-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 40px -15px rgba(0,0,0,0.15);
    border-color: var(--color-primary-soft);
}

html.dark-theme .norma-premium-card {
    background: rgba(255, 255, 255, 0.03);
    border-color: rgba(255, 255, 255, 0.08);
}

/* Sidebar Column */
.npc-sidebar {
    width: 100px;
    background: rgba(27, 79, 41, 0.03);
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 2rem 1rem;
    border-right: 1px solid var(--color-border);
    flex-shrink: 0;
}

html.dark-theme .npc-sidebar {
    background: rgba(255, 255, 255, 0.02);
    border-color: rgba(255, 255, 255, 0.05);
}

.npc-icon-box {
    width: 60px;
    height: 60px;
    background: var(--color-surface);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: var(--color-primary);
    box-shadow: var(--shadow-sm);
    margin-bottom: 1rem;
}

.npc-year {
    font-size: 0.85rem;
    font-weight: 800;
    color: var(--color-text-muted);
}

/* Main Content Column */
.npc-main {
    flex-grow: 1;
    padding: 2rem;
    display: flex;
    flex-direction: column;
}

.npc-meta {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1rem;
    align-items: center;
}

.npc-type-badge {
    background: var(--color-primary-soft);
    color: var(--color-primary);
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.npc-orgao {
    font-size: 0.8rem;
    color: var(--color-text-muted);
    font-weight: 500;
}

.npc-title {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--color-heading);
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

.npc-number {
    font-size: 0.9rem;
    color: var(--color-text-muted);
    margin-bottom: 1.5rem;
}

.npc-number strong {
    color: var(--color-primary);
}

/* Actions */
.npc-actions {
    display: flex;
    gap: 1rem;
    margin-top: auto;
}

.btn-npc {
    padding: 10px 18px;
    border-radius: 10px;
    font-size: 0.85rem;
    font-weight: 700;
    text-decoration: none !important;
    display: flex;
    align-items: center;
    transition: all 0.3s ease;
}

.btn-npc-pdf {
    background: #ef4444;
    color: white !important;
}

.btn-npc-pdf:hover {
    background: #dc2626;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

.btn-npc-link {
    background: var(--color-primary);
    color: white !important;
}

.btn-npc-link:hover {
    background: #153e20;
    box-shadow: 0 4px 12px rgba(27, 79, 41, 0.3);
}

/* Responsive */
@media (max-width: 768px) {
    .norma-premium-card {
        flex-direction: column;
    }
    
    .npc-sidebar {
        width: 100%;
        flex-direction: row;
        padding: 1rem 1.5rem;
        border-right: none;
        border-bottom: 1px solid var(--color-border);
        justify-content: space-between;
    }
    
    .npc-icon-box {
        width: 40px;
        height: 40px;
        font-size: 1rem;
        margin-bottom: 0;
    }
    
    .npc-actions {
        flex-direction: column;
    }
    
    .btn-npc {
        width: 100%;
        justify-content: center;
    }
}

/* Forms & Selects */
.premium-search-container {
    position: relative;
}

.premium-search-container i {
    position: absolute;
    left: 1.25rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--color-text-muted);
}

.premium-search-input {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 3rem;
    border-radius: 12px;
    border: 1px solid var(--color-border);
    background: var(--color-surface);
    color: var(--color-text-main);
}

.premium-select-container {
    position: relative;
}

.premium-select-container i {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--color-text-muted);
    font-size: 0.8rem;
}

.premium-select {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 2.5rem;
    border-radius: 12px;
    border: 1px solid var(--color-border);
    background: var(--color-surface);
    color: var(--color-text-main);
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2364748b'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1rem;
}

/* Utility Animations */
.animate-fade-in { animation: fadeInGlobal 0.8s ease backwards; }
.animate-slide-up { animation: slideUpGlobal 0.6s ease backwards; }
@keyframes slideUpGlobal {
    from { transform: translateY(30px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}
