/* ============================================================
   SISTEMA DE CONSERVAÇÃO — Design System
   Premium Dark Theme with Indigo/Violet Accents
   ============================================================ */

/* --- CSS VARIABLES --- */
:root {
    /* Colors — Dark Theme */
    --bg-primary: #0a0c10;
    --bg-secondary: #11141d;
    --bg-card: #171c26;
    --bg-card-hover: #1f2634;
    --bg-input: #1e2533;
    --bg-sidebar: #07090d;

    --text-primary: #e5e7eb;
    --text-secondary: #9ca3af;
    --text-muted: #6b7280;
    --text-heading: #ffffff;

    --accent-primary: #6366f1;
    --accent-primary-hover: #4f46e5;
    --accent-primary-dim: rgba(99, 102, 241, 0.12);

    --accent-gold: #f59e0b;
    --accent-gold-dim: rgba(245, 158, 11, 0.1);
    
    --accent-green: #10b981;
    --accent-green-dim: rgba(16, 185, 129, 0.1);
    
    --accent-red: #ef4444;
    --accent-red-dim: rgba(239, 68, 68, 0.1);
    
    --accent-blue: #06b6d4;
    --accent-blue-dim: rgba(6, 182, 212, 0.1);
    
    --border-color: #262e3d;
    --border-light: #374151;

    /* Shadows & Topbar Background Variables */
    --topbar-bg: rgba(17, 20, 29, 0.85);
    --card-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);

    /* Glass Effect */
    --glass-bg: rgba(17, 20, 29, 0.85);
    --glass-border: rgba(255, 255, 255, 0.05);
    --glass-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);

    /* Dimensions */
    --sidebar-width: 260px;
    --topbar-height: 70px;
    
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;

    /* Transitions */
    --transition-fast: 0.15s ease;
    --transition-normal: 0.25s ease;
    --transition-slow: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* --- RESET & BASE --- */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 14px;
    scroll-behavior: smooth;
}

body {
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    display: flex;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Outfit', sans-serif;
    color: var(--text-heading);
    font-weight: 600;
}

/* --- SCROLLBAR --- */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: var(--radius-sm);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

/* --- SIDEBAR --- */
.sidebar {
    width: var(--sidebar-width);
    height: 100vh;
    position: fixed;
    left: 0;
    top: 0;
    background: var(--bg-sidebar);
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    z-index: 100;
    transition: transform var(--transition-slow);
}

.sidebar-header {
    padding: 24px;
    border-bottom: 1px solid var(--border-color);
}

.logo {
    display: flex;
    align-items: center;
    gap: 16px;
}

.logo-icon {
    width: 44px;
    height: 44px;
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-blue));
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 16px;
    color: white;
    font-family: 'Outfit', sans-serif;
    letter-spacing: -0.5px;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.logo-title {
    font-family: 'Outfit', sans-serif;
    font-size: 16px;
    font-weight: 800;
    color: var(--text-heading);
    display: block;
    letter-spacing: 0.5px;
    line-height: 1.2;
}

.logo-subtitle {
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 10px;
    font-weight: 600;
    color: var(--accent-primary);
    display: block;
    letter-spacing: 2px;
    margin-top: 2px;
}

.sidebar-nav {
    padding: 24px 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex-grow: 1;
    overflow-y: auto;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 12px 16px;
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: var(--radius-md);
    font-weight: 500;
    transition: all var(--transition-fast);
}

.nav-item:hover {
    background: var(--bg-card);
    color: var(--text-heading);
}

.nav-item.active {
    background: var(--accent-primary);
    color: white;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.2);
}

.nav-icon {
    font-size: 18px;
    flex-shrink: 0;
}

.sidebar-footer {
    padding: 24px;
    border-top: 1px solid var(--border-color);
}

.sidebar-info {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* --- MAIN CONTENT & TOPBAR --- */
.main-content {
    margin-left: var(--sidebar-width);
    width: calc(100% - var(--sidebar-width));
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    transition: margin-left var(--transition-slow), width var(--transition-slow);
}

.topbar {
    height: var(--topbar-height);
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    padding: 0 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 90;
    backdrop-filter: blur(10px);
    background: var(--topbar-bg);
}

.topbar-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 24px;
    cursor: pointer;
}

.page-title {
    font-size: 22px;
    font-weight: 700;
}

.page-container {
    padding: 32px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 32px;
    background: var(--bg-primary);
}

/* --- CARDS & GRIDS --- */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--card-shadow);
    display: flex;
    flex-direction: column;
    gap: 20px;
    transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 16px;
}

.card-title {
    font-size: 18px;
    font-weight: 600;
}

.grid-cols-2 {
    display: grid;
    grid-template-cols: repeat(2, 1fr);
    gap: 24px;
}

.grid-cols-3 {
    display: grid;
    grid-template-cols: repeat(3, 1fr);
    gap: 24px;
}

.grid-cols-4 {
    display: grid;
    grid-template-cols: repeat(4, 1fr);
    gap: 24px;
}

/* --- DASHBOARD STATS --- */
.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 20px;
    position: relative;
    overflow: hidden;
}

.stat-icon {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.stat-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.stat-value {
    font-size: 28px;
    font-weight: 700;
    line-height: 1;
}

.stat-label {
    font-size: 13px;
    color: var(--text-secondary);
    font-weight: 500;
}

.stat-blue { background-color: var(--accent-blue-dim); color: var(--accent-blue); }
.stat-gold { background-color: var(--accent-gold-dim); color: var(--accent-gold); }
.stat-green { background-color: var(--accent-green-dim); color: var(--accent-green); }
.stat-purple { background-color: var(--accent-primary-dim); color: var(--accent-primary); }

/* --- FORM ELEMENTS --- */
.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-label {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
}

.form-control {
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 12px 16px;
    color: var(--text-primary);
    font-family: inherit;
    font-size: 14px;
    width: 100%;
    outline: none;
    transition: border-color var(--transition-fast);
}

.form-control:focus {
    border-color: var(--accent-primary);
}

.form-control::placeholder {
    color: var(--text-muted);
}

.form-control-sm {
    padding: 6px 12px !important;
    font-size: 13px !important;
    height: 34px !important;
    line-height: 1.4 !important;
}

.form-row {
    display: flex;
    gap: 16px;
}

.form-row > * {
    flex: 1;
}

/* --- BUTTONS --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 24px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    border: none;
    transition: all var(--transition-fast);
    outline: none;
}

.btn-primary {
    background: var(--accent-primary);
    color: white;
}

.btn-primary:hover {
    background: var(--accent-primary-hover);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.btn-secondary {
    background: var(--bg-input);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
}

.btn-secondary:hover {
    background: var(--bg-card-hover);
}

.btn-danger {
    background: var(--accent-red);
    color: white;
}

.btn-danger:hover {
    background: #dc2626;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

.btn-sm {
    padding: 8px 16px;
    font-size: 12px;
    border-radius: 6px;
}

/* --- TABLE --- */
.table-container {
    overflow-x: auto;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
}

.table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 14px;
}

.table th,
.table td {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-color);
}

.table th {
    background: var(--bg-secondary);
    font-weight: 600;
    color: var(--text-secondary);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.table tbody tr {
    transition: background-color var(--transition-fast);
}

.table tbody tr:hover {
    background: var(--bg-card-hover);
}

/* --- STATUS BADGES --- */
.badge {
    display: inline-flex;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge-rascunho { background-color: var(--accent-blue-dim); color: var(--accent-blue); }
.badge-assinaturas { background-color: var(--accent-purple-dim || rgba(124, 58, 237, 0.1)); color: #8b5cf6; }
.badge-prefeitura { background-color: var(--accent-gold-dim); color: var(--accent-gold); }
.badge-concluido { background-color: var(--accent-green-dim); color: var(--accent-green); }

/* --- TIMELINE (PREFEITURA PROCESS TRACKING) --- */
.timeline {
    position: relative;
    padding-left: 24px;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 7px;
    top: 6px;
    bottom: 6px;
    width: 2px;
    background: var(--border-color);
}

.timeline-item {
    position: relative;
}

.timeline-marker {
    position: absolute;
    left: -24px;
    top: 4px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--bg-card);
    border: 3px solid var(--accent-primary);
    z-index: 1;
}

.timeline-item.active .timeline-marker {
    background: var(--accent-primary);
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.2);
}

.timeline-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
    background: var(--bg-secondary);
    padding: 16px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-color);
}

.timeline-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.timeline-title {
    font-weight: 600;
    font-size: 15px;
}

.timeline-date {
    font-size: 11px;
    color: var(--text-muted);
}

.timeline-desc {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.4;
}

/* --- TABS SYSTEM --- */
.tabs {
    display: flex;
    gap: 8px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 16px;
    margin-bottom: 8px;
    overflow-x: auto;
    scrollbar-width: thin;
}

.tab-btn {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 13.5px;
    padding: 8px 18px;
    cursor: pointer;
    border-radius: 30px;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.tab-btn:hover {
    color: var(--text-heading);
    background: var(--bg-card-hover);
    border-color: var(--accent-primary);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

.tab-btn.active {
    color: white;
    background: var(--accent-primary);
    border-color: var(--accent-primary);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.35);
}

.tab-content {
    display: none;
    flex-direction: column;
    gap: 24px;
    animation: fadeIn var(--transition-normal);
}

.tab-content.active {
    display: flex;
}

/* --- UPLOAD ZONE / PHOTOS GRID --- */
.upload-zone {
    border: 2px dashed var(--border-color);
    border-radius: var(--radius-lg);
    padding: 40px;
    text-align: center;
    cursor: pointer;
    background: var(--bg-secondary);
    transition: border-color var(--transition-fast);
}

.upload-zone:hover {
    border-color: var(--accent-primary);
}

.upload-icon {
    font-size: 40px;
    margin-bottom: 16px;
}

.upload-text {
    font-size: 15px;
    font-weight: 500;
    color: var(--text-secondary);
}

.upload-hint {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 8px;
}

.photos-grid {
    display: grid;
    grid-template-cols: repeat(auto-fill, minmax(240px, 1fr));
    gap: 24px;
}

.photo-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    position: relative;
}

.photo-preview-img {
    width: 100%;
    height: 240px;
    object-fit: contain;
    background: var(--bg-primary);
}

.photo-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
}

.photo-details {
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.photo-caption {
    font-size: 13px;
    color: var(--text-primary);
    border: none;
    background: var(--bg-input);
    border-radius: 4px;
    padding: 6px 10px;
    width: 100%;
    outline: none;
}

.photo-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.photo-order {
    font-size: 11px;
    color: var(--text-muted);
}

/* --- LOADER --- */
.loader-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px;
    gap: 16px;
    text-align: center;
}

.spinner {
    width: 48px;
    height: 48px;
    border: 4px solid var(--border-color);
    border-top-color: var(--accent-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* --- TOAST NOTIFICATIONS --- */
.toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 1000;
}

.toast {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-left: 4px solid var(--accent-primary);
    padding: 16px 24px;
    border-radius: var(--radius-sm);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
    color: var(--text-primary);
    font-size: 14px;
    font-weight: 500;
    min-width: 280px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    animation: slideIn 0.3s ease;
}

.toast-success { border-left-color: var(--accent-green); }
.toast-error { border-left-color: var(--accent-red); }

/* --- MODAL SYSTEM --- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    backdrop-filter: blur(4px);
}

.modal {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    animation: scaleUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-title {
    font-size: 18px;
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 24px;
    cursor: pointer;
}

.modal-close:hover {
    color: var(--text-heading);
}

.modal-body {
    padding: 24px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.modal-footer {
    padding: 20px 24px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

/* --- ANIMATIONS --- */
@keyframes spin {
    to { transform: rotate(360deg); }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(4px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes slideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

@keyframes scaleUp {
    from { transform: scale(0.95); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

/* --- RESPONSIVE DESIGN --- */
@media (max-width: 1024px) {
    .grid-cols-3, .grid-cols-4 {
        grid-template-cols: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }
    
    .sidebar.open {
        transform: translateX(0);
    }

    .main-content {
        margin-left: 0;
        width: 100%;
    }

    .menu-toggle {
        display: block;
    }

    .grid-cols-2, .grid-cols-3, .grid-cols-4 {
        grid-template-cols: 1fr;
    }

    .page-container {
        padding: 16px;
    }

    .topbar-mobile-logo {
        display: flex !important;
    }
}


/* ============================================================
   SISTEMA DE CONSERVAÇÃO — Light Theme Class overrides
   Premium Light Mode Theme (Linear & Stripe aesthetic)
   ============================================================ */
body.light-theme {
    --bg-primary: #f8fafc;
    --bg-secondary: #f1f5f9;
    --bg-card: #ffffff;
    --bg-card-hover: #f8fafc;
    --bg-input: #ffffff;
    --bg-sidebar: #ffffff;

    --text-primary: #334155;
    --text-secondary: #64748b;
    --text-muted: #94a3b8;
    --text-heading: #0f172a;

    --border-color: #e2e8f0;
    --border-light: #f1f5f9;

    --accent-primary: #4f46e5;
    --accent-primary-hover: #3730a3;
    --accent-primary-dim: rgba(79, 70, 229, 0.08);

    --accent-gold-dim: rgba(217, 119, 6, 0.08);
    --accent-green-dim: rgba(5, 150, 105, 0.08);
    --accent-red-dim: rgba(220, 38, 38, 0.08);
    --accent-blue-dim: rgba(8, 145, 178, 0.08);

    --topbar-bg: rgba(255, 255, 255, 0.85);
    --card-shadow: 0 4px 20px rgba(15, 23, 42, 0.05), 0 2px 4px rgba(15, 23, 42, 0.02);

    --glass-bg: rgba(255, 255, 255, 0.85);
    --glass-border: rgba(15, 23, 42, 0.08);
    --glass-shadow: 0 8px 32px rgba(15, 23, 42, 0.08);
}

/* Light Theme refinements */
body.light-theme .logo-icon {
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.25);
}

body.light-theme input, 
body.light-theme select, 
body.light-theme textarea {
    background: #ffffff;
    border-color: #cbd5e1;
    color: #0f172a;
}

body.light-theme input:focus, 
body.light-theme select:focus, 
body.light-theme textarea:focus {
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.15);
}

body.light-theme .badge-rascunho {
    background: #f1f5f9;
    color: #475569;
    border: 1px solid #cbd5e1;
}

body.light-theme .badge-assinaturas {
    background: #fef3c7;
    color: #b45309;
    border: 1px solid #fde68a;
}

body.light-theme .badge-prefeitura {
    background: #e0f2fe;
    color: #0369a1;
    border: 1px solid #bae6fd;
}

body.light-theme .badge-concluido {
    background: #d1fae5;
    color: #047857;
    border: 1px solid #a7f3d0;
}

body.light-theme .toast {
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

body.light-theme .timeline-item::before {
    background: #e2e8f0;
}

body.light-theme .nav-item:hover {
    background: #f1f5f9;
}

/* ============================================================
   ESTILOS DE AUTENTICAÇÃO — LOGIN E RECUPERAÇÃO DE SENHA
   ============================================================ */
.auth-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100vw;
    height: 100vh;
    background: radial-gradient(circle at 50% 20%, #1e293b 0%, #0f172a 70%, #020617 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    padding: 20px;
    overflow-y: auto;
}

.auth-card {
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 20px;
    width: 100%;
    max-width: 440px;
    padding: 36px 32px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.05);
    animation: authFadeIn 0.3s ease-out;
}

@keyframes authFadeIn {
    from {
        opacity: 0;
        transform: translateY(12px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.auth-header {
    text-align: center;
    margin-bottom: 28px;
}

.auth-logo-box {
    width: 108px;
    height: 108px;
    background: #ffffff;
    border-radius: 18px;
    padding: 6px;
    margin: 0 auto 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
}

.auth-logo-box img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.auth-title {
    font-size: 22px;
    font-weight: 700;
    color: #f8fafc;
    letter-spacing: -0.5px;
    margin: 0 0 6px 0;
}

.auth-subtitle {
    font-size: 13px;
    color: #94a3b8;
    margin: 0;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.auth-input-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.auth-label {
    font-size: 12px;
    font-weight: 600;
    color: #cbd5e1;
    letter-spacing: 0.3px;
}

.auth-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.auth-input-icon {
    position: absolute;
    left: 14px;
    color: #64748b;
    font-size: 15px;
    pointer-events: none;
}

.auth-input {
    width: 100%;
    padding: 12px 14px 12px 42px;
    background: rgba(30, 41, 59, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 10px;
    color: #f8fafc;
    font-size: 14px;
    font-family: inherit;
    transition: all 0.2s ease;
}

.auth-input:focus {
    outline: none;
    border-color: #3b82f6;
    background: rgba(30, 41, 59, 0.95);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.25);
}

.auth-btn-password-toggle {
    position: absolute;
    right: 12px;
    background: none;
    border: none;
    color: #94a3b8;
    cursor: pointer;
    padding: 4px;
    font-size: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s;
}

.auth-btn-password-toggle:hover {
    color: #f8fafc;
}

.auth-btn-submit {
    width: 100%;
    padding: 13px;
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    color: #ffffff;
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.3px;
    cursor: pointer;
    box-shadow: 0 4px 14px rgba(37, 99, 235, 0.4);
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 6px;
}

.auth-btn-submit:hover {
    background: linear-gradient(135deg, #1d4ed8, #1e40af);
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(37, 99, 235, 0.5);
}

.auth-btn-submit:active {
    transform: translateY(0);
}

.auth-btn-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.auth-footer-links {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 12px;
    margin-top: 4px;
}

.auth-link {
    color: #38bdf8;
    text-decoration: none;
    cursor: pointer;
    transition: color 0.2s;
}

.auth-link:hover {
    color: #7dd3fc;
    text-decoration: underline;
}

.auth-divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 20px 0 16px;
    color: #64748b;
    font-size: 11px;
    letter-spacing: 1px;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.auth-divider span {
    padding: 0 10px;
}

.auth-quick-actions {
    display: flex;
    gap: 8px;
}

.auth-btn-secondary {
    flex: 1;
    padding: 10px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: #cbd5e1;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: all 0.2s;
}

.auth-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.2);
}

.auth-code-box {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin: 12px 0;
}

.auth-code-input {
    width: 100%;
    text-align: center;
    font-size: 24px;
    font-weight: 700;
    letter-spacing: 8px;
    padding: 12px;
    font-family: monospace;
}

.auth-message {
    padding: 10px 14px;
    border-radius: 8px;
    font-size: 13px;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.auth-message.error {
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #fca5a5;
}

.auth-message.success {
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: #6ee7b7;
}

.auth-message.info {
    background: rgba(59, 130, 246, 0.15);
    border: 1px solid rgba(59, 130, 246, 0.3);
    color: #93c5fd;
}

/* ============================================================
   ESTILOS: EDITAR CONTRATANTE & COLETA DE CAMPO (PADRÃO FLIP)
   ============================================================ */

.contratante-editor-wrapper {
    display: flex;
    flex-direction: column;
    gap: 16px;
    width: 100%;
}

.contratante-top-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    padding: 12px 18px;
    border-radius: var(--radius-md);
}

.contratante-context-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    background: rgba(59, 130, 246, 0.08);
    border: 1px solid rgba(59, 130, 246, 0.25);
    padding: 12px 18px;
    border-radius: var(--radius-md);
}

.contratante-tabs-nav {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 4px;
}

.contratante-tab-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: var(--bg-card);
    color: var(--text-primary);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.contratante-tab-btn.active {
    border-color: #3b82f6;
    background: rgba(59, 130, 246, 0.12);
    color: #3b82f6;
    box-shadow: 0 0 0 1px #3b82f6;
}

.contratante-section-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 18px 20px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.contratante-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 10px;
}

.contratante-section-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 15px;
    font-weight: 700;
    color: var(--text-primary);
}

.contratante-badge-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 6px;
    background: rgba(59, 130, 246, 0.15);
    color: #3b82f6;
    font-size: 13px;
    font-weight: 800;
}

/* Slots de Fotos */
.photo-slots-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
    gap: 12px;
}

.photo-slot-box {
    border: 2px dashed var(--border-color);
    border-radius: var(--radius-md);
    padding: 10px;
    text-align: center;
    background: var(--bg-secondary);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    min-height: 140px;
    position: relative;
    transition: all 0.2s;
}

.photo-slot-box.has-photo {
    border-style: solid;
    border-color: #10b981;
    background: rgba(16, 185, 129, 0.04);
}

.photo-slot-img {
    width: 100%;
    height: 80px;
    object-fit: cover;
    border-radius: 6px;
    cursor: pointer;
}

/* Card Mobile de Coleta */
.coleta-mobile-layout {
    max-width: 600px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding-bottom: 40px;
}

.coleta-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 16px 18px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
}

.coleta-card-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 15px;
    font-weight: 700;
    color: var(--text-primary);
}

/* ============================================================
   COLETA DE CAMPO — SEÇÕES RECOLHÍVEIS (SANFONA) POR TEMA
   ============================================================ */
.coleta-secoes-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; padding: 2px; }
.coleta-secoes-toolbar-titulo { font-size: 13px; font-weight: 700; color: var(--text-secondary); letter-spacing: 0.2px; }
.coleta-secoes-toolbar-btn { font-size: 11.5px !important; padding: 5px 10px !important; font-weight: 500 !important; }

.coleta-secao {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-left: 4px solid var(--coleta-secao-cor, #64748b);
    border-radius: 12px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
    overflow: hidden;
    transition: box-shadow 0.2s ease;
}
.coleta-secao.aberta { box-shadow: 0 6px 18px rgba(0, 0, 0, 0.08); }

.coleta-secao-header {
    display: flex; align-items: center; gap: 12px;
    min-height: 56px; padding: 10px 14px;
    cursor: pointer; user-select: none; -webkit-tap-highlight-color: transparent;
}
.coleta-secao-header:active { background: var(--bg-secondary); }

.coleta-secao-num {
    width: 30px; height: 30px; border-radius: 50%;
    background: var(--coleta-secao-cor, #64748b); color: #ffffff;
    font-size: 14px; font-weight: 700;
    display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.coleta-secao-titulos { flex: 1; min-width: 0; }
.coleta-secao-titulo { font-size: 14.5px; font-weight: 700; color: var(--text-primary); line-height: 1.25; }
.coleta-secao-resumo { font-size: 11.5px; color: var(--text-secondary); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.coleta-secao-selo { font-size: 10.5px; font-weight: 600; padding: 3px 8px; border-radius: 999px; white-space: nowrap; flex-shrink: 0; }
.coleta-secao-selo.selo-ok { background: #dcfce7; color: #166534; }
.coleta-secao-selo.selo-pendente { background: #ffedd5; color: #c2410c; }
.coleta-secao-selo.selo-vazio { background: var(--bg-secondary); color: var(--text-muted); }

.coleta-secao-seta { font-size: 12px; color: var(--text-secondary); transition: transform 0.2s ease; flex-shrink: 0; }
.coleta-secao.aberta .coleta-secao-seta { transform: rotate(180deg); }

.coleta-secao-corpo { display: none; flex-direction: column; gap: 12px; padding: 14px 16px 16px; border-top: 1px solid var(--border-color); }
.coleta-secao.aberta .coleta-secao-corpo { display: flex; animation: coletaSecaoAbrir 0.2s ease; }
@keyframes coletaSecaoAbrir { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: translateY(0); } }

.coleta-secao-acoes { display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }

.coleta-secao-proximo {
    width: 100%; min-height: 46px; margin-top: 4px;
    font-size: 13.5px; font-weight: 600; border-radius: 10px;
    background: var(--bg-secondary); color: var(--text-primary);
    border: 1.5px solid var(--coleta-secao-cor, var(--border-color));
}

.coleta-subbloco { display: flex; flex-direction: column; gap: 10px; padding: 12px; border: 1px dashed var(--border-color); border-radius: 10px; background: rgba(148, 163, 184, 0.04); }
.coleta-subbloco-titulo { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; font-size: 13.5px; font-weight: 700; color: var(--text-primary); }

.coleta-btn-captura {
    min-height: 48px; padding: 12px 6px !important;
    font-size: 13px !important; font-weight: 600 !important;
    display: flex !important; align-items: center; justify-content: center; gap: 6px;
}

@media (max-width: 480px) {
    .coleta-secao-header { gap: 10px; padding: 10px 12px; }
    .coleta-secao-titulo { font-size: 14px; }
    .coleta-secao-selo { font-size: 10px; padding: 2px 6px; }
    .coleta-secao-corpo { padding-left: 12px; padding-right: 12px; }
}
.vistoriador-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border: 1px solid rgba(16, 185, 129, 0.3);
    background: rgba(16, 185, 129, 0.05);
    border-radius: 10px;
}

.vistoriador-avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: #0f766e;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 16px;
    flex-shrink: 0;
}

/* ============================================================
   GRUPOS DO MENU LATERAL & HELP PILL
   ============================================================ */
.sidebar-section-label {
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.4px;
    text-transform: uppercase;
    color: #64748b;
    padding: 12px 18px 4px 18px;
    user-select: none;
}

.help-mode-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.28);
    color: var(--accent-primary);
    padding: 5px 12px;
    border-radius: 999px;
    font-size: 11.5px;
    cursor: help;
    transition: all 0.2s ease;
}

.help-mode-pill:hover {
    background: rgba(59, 130, 246, 0.18);
    transform: translateY(-1px);
}

@media (max-width: 900px) {
    .help-mode-pill-text {
        display: none;
    }
}

/* ============================================================
   SISTEMA DE HELP INTERATIVO (HOVER TOOLTIP + CLIQUE DIREITO)
   ============================================================ */
.agy-quick-tooltip {
    position: fixed;
    z-index: 99990;
    max-width: 330px;
    background: rgba(15, 23, 42, 0.96);
    color: #f8fafc;
    border: 1px solid rgba(59, 130, 246, 0.45);
    border-radius: 10px;
    padding: 9px 13px;
    font-size: 12px;
    line-height: 1.45;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.35);
    pointer-events: none;
    backdrop-filter: blur(8px);
    animation: agyFadeIn 0.14s ease-out;
}

.agy-quick-tooltip-title {
    font-weight: 700;
    color: #60a5fa;
    margin-bottom: 3px;
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12.5px;
}

.agy-quick-tooltip-hint {
    margin-top: 6px;
    padding-top: 5px;
    border-top: 1px dashed rgba(148, 163, 184, 0.25);
    font-size: 10.5px;
    color: #93c5fd;
    display: flex;
    align-items: center;
    gap: 4px;
}

.agy-detailed-help-popover {
    position: fixed;
    z-index: 99999;
    width: 390px;
    max-width: calc(100vw - 24px);
    background: var(--bg-card, #1e293b);
    color: var(--text-primary, #f8fafc);
    border: 2px solid var(--accent-primary, #3b82f6);
    border-radius: 14px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    overflow: hidden;
    animation: agyPopIn 0.18s cubic-bezier(0.16, 1, 0.3, 1);
}

.agy-help-pop-header {
    background: linear-gradient(135deg, #1e3a8a, #0f172a);
    color: #ffffff;
    padding: 14px 16px;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.agy-help-pop-title {
    font-size: 14.5px;
    font-weight: 800;
    color: #ffffff;
    display: flex;
    align-items: center;
    gap: 8px;
}

.agy-help-pop-subtitle {
    font-size: 11px;
    color: #93c5fd;
    margin-top: 3px;
}

.agy-help-pop-close {
    background: rgba(255, 255, 255, 0.12);
    border: none;
    color: #ffffff;
    width: 26px;
    height: 26px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.agy-help-pop-close:hover {
    background: rgba(239, 68, 68, 0.8);
}

.agy-help-pop-body {
    padding: 14px 16px;
    font-size: 13px;
    line-height: 1.55;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 70vh;
    overflow-y: auto;
}

.agy-help-pop-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.agy-help-badge {
    font-size: 11px;
    font-weight: 700;
    padding: 3px 9px;
    border-radius: 999px;
    background: rgba(59, 130, 246, 0.12);
    color: var(--accent-primary, #3b82f6);
    border: 1px solid rgba(59, 130, 246, 0.25);
}

.agy-help-section {
    background: var(--bg-secondary, rgba(15, 23, 42, 0.4));
    border: 1px solid var(--border-color, rgba(148, 163, 184, 0.2));
    border-radius: 8px;
    padding: 10px 12px;
}

.agy-help-section-label {
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: var(--text-muted, #94a3b8);
    margin-bottom: 4px;
}

@keyframes agyFadeIn {
    from { opacity: 0; transform: translateY(3px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes agyPopIn {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

/* ============================================================
   ESTEIRA OPERACIONAL DE 6 ETAPAS (PIPELINE, KANBAN & STEPPER)
   ============================================================ */
.pipeline-6-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 10px;
    margin-bottom: 20px;
}

@media (max-width: 1200px) {
    .pipeline-6-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 680px) {
    .pipeline-6-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.pipeline-stage-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 8px;
}

.pipeline-stage-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
    border-color: var(--accent-primary);
}

.pipeline-stage-card.active-filter {
    border: 2px solid var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.18);
}

.pipeline-stage-num {
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    padding: 2px 8px;
    border-radius: 99px;
    display: inline-block;
}

.pipeline-stage-count {
    font-size: 26px;
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1;
}

/* Kanban de 6 Colunas */
.kanban-esteira-board {
    display: grid;
    grid-template-columns: repeat(6, minmax(255px, 1fr));
    gap: 12px;
    overflow-x: auto;
    padding-bottom: 14px;
    align-items: start;
}

.kanban-esteira-col {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 12px;
    min-height: 420px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.kanban-esteira-col-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--border-color);
}

.kanban-project-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 12px;
    cursor: pointer;
    transition: all 0.18s ease;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.kanban-project-card:hover {
    border-color: var(--accent-primary);
    transform: translateY(-2px);
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.1);
}

/* Stepper Guiado de 6 Etapas dentro do Projeto */
.workspace-stepper-bar {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 8px;
    margin-bottom: 16px;
}

@media (max-width: 1100px) {
    .workspace-stepper-bar {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 640px) {
    .workspace-stepper-bar {
        grid-template-columns: repeat(2, 1fr);
    }
}

.workspace-step-btn {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 10px 12px;
    text-align: left;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    gap: 4px;
    position: relative;
}

.workspace-step-btn:hover {
    border-color: var(--accent-primary);
}

.workspace-step-btn.active-view {
    border: 2px solid var(--accent-primary);
    background: rgba(59, 130, 246, 0.08);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.14);
}

.workspace-step-btn.current-stage {
    border-bottom: 3px solid #f59e0b;
}

.workspace-step-btn.step-done {
    border-left: 4px solid #10b981;
}

/* Barra de Passagem de Bastão (Handoff Banner) */
.handoff-control-bar {
    background: linear-gradient(135deg, rgba(30, 58, 138, 0.14), rgba(15, 23, 42, 0.22));
    border: 1px solid rgba(59, 130, 246, 0.35);
    border-radius: 12px;
    padding: 14px 18px;
    margin-bottom: 18px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.checklist-chips-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}

.checklist-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 11px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 600;
    border: 1px solid var(--border-color);
    background: var(--bg-card);
}

.checklist-chip.ok {
    background: rgba(16, 185, 129, 0.1);
    border-color: rgba(16, 185, 129, 0.35);
    color: #10b981;
}

.checklist-chip.pending {
    background: rgba(245, 158, 11, 0.1);
    border-color: rgba(245, 158, 11, 0.35);
    color: #f59e0b;
}

/* Bot?es do Stepper de 6 Etapas e Cards da Esteira */
.stepper-node,
.workspace-step-btn {
    appearance: none;
    -webkit-appearance: none;
    font-family: inherit;
    width: 100%;
    background: var(--bg-card, #ffffff);
    border: 1.5px solid var(--border-color, #e2e8f0);
    border-top: 4px solid var(--step-color, var(--accent-primary, #3b82f6));
    border-radius: 12px;
    padding: 11px 13px;
    text-align: left;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    flex-direction: column;
    gap: 5px;
    position: relative;
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.06);
}

.stepper-node:hover,
.workspace-step-btn:hover {
    transform: translateY(-2px);
    border-color: var(--step-color, var(--accent-primary, #3b82f6));
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.12);
    background: rgba(59, 130, 246, 0.03);
}

.stepper-node:active,
.workspace-step-btn:active {
    transform: translateY(0);
}

.stepper-node.active-stage,
.workspace-step-btn.active-view {
    border: 2px solid var(--step-color, var(--accent-primary, #3b82f6));
    border-top: 4px solid var(--step-color, var(--accent-primary, #3b82f6));
    background: rgba(59, 130, 246, 0.08);
    box-shadow: 0 6px 16px rgba(59, 130, 246, 0.18), 0 0 0 3px rgba(59, 130, 246, 0.12);
}

.stepper-node.completed-stage {
    background: linear-gradient(180deg, rgba(16, 185, 129, 0.05) 0%, var(--bg-card, #ffffff) 100%);
}

.stepper-node.blocked-stage {
    border-color: #ef4444;
    border-top-color: #ef4444;
    background: rgba(239, 68, 68, 0.06);
}

.stepper-node .step-badge {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    width: 100%;
}

.stepper-node .step-pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 11px;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: 999px;
    background: rgba(59, 130, 246, 0.1);
    color: var(--text-primary);
}

.stepper-node.active-stage .step-pill {
    background: var(--step-color, var(--accent-primary, #3b82f6));
    color: #ffffff;
}

.stepper-node .step-state-tag {
    font-size: 10.5px;
    font-weight: 700;
    color: var(--text-secondary);
    white-space: nowrap;
}

.stepper-node.completed-stage .step-state-tag {
    color: #059669;
}

.stepper-node.active-stage .step-state-tag {
    color: var(--step-color, var(--accent-primary, #2563eb));
}

.stepper-node .step-name {
    font-size: 13px;
    font-weight: 800;
    color: var(--text-primary);
    line-height: 1.25;
    margin-top: 2px;
}

.stepper-node .step-status {
    font-size: 11px;
    font-weight: 500;
    color: var(--text-secondary);
    line-height: 1.2;
}

.handoff-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.stage-checklist-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
}

.handoff-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.kanban-esteira-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 12px;
    cursor: pointer;
    transition: all 0.18s ease;
    display: flex;
    flex-direction: column;
    gap: 6px;
    box-shadow: 0 2px 5px rgba(15, 23, 42, 0.05);
}

.kanban-esteira-card:hover {
    border-color: var(--accent-primary);
    transform: translateY(-2px);
    box-shadow: 0 6px 14px rgba(15, 23, 42, 0.1);
}

.kanban-esteira-card .k-title {
    font-size: 13px;
    font-weight: 700;
    color: var(--text-primary);
}

.kanban-esteira-card .k-sub {
    font-size: 11.5px;
    color: var(--text-secondary);
}

.kanban-esteira-card .k-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 11px;
    color: var(--text-secondary);
    padding-top: 6px;
    border-top: 1px dashed var(--border-color);
    margin-top: 2px;
}


/* ============================================================
   ESQUEMA DE ÍCONES A. LINEAR MINIMALISTA (LUCIDE SVG INLINE)
   ============================================================ */
.nav-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.nav-icon svg,
.agy-icon {
    width: 18px;
    height: 18px;
    stroke: currentColor;
    stroke-width: 1.75;
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex-shrink: 0;
    vertical-align: -3px;
    transition: color 0.18s ease, stroke 0.18s ease, transform 0.18s ease;
}

.coleta-secao-titulo {
    display: inline-flex;
    align-items: center;
    gap: 7px;
}

.coleta-secao-titulo .agy-icon {
    color: var(--text-secondary);
}

.coleta-secao.aberta .coleta-secao-titulo .agy-icon {
    color: var(--coleta-secao-cor, #059669);
}

.coleta-secao-selo {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.coleta-secao-selo .agy-icon {
    width: 13px;
    height: 13px;
    stroke-width: 2;
    vertical-align: -2px;
}

.tab-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
}

.tab-btn .agy-icon {
    width: 16px;
    height: 16px;
    opacity: 0.82;
}

.tab-btn.active .agy-icon {
    opacity: 1;
}

.stepper-node .step-pill {
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.stepper-node .step-pill .agy-icon {
    width: 14px;
    height: 14px;
    stroke-width: 2;
}
