/* ═══════════════════════════════════════════════════════════════
   TERIVA URBANISMO - Design System
   ═══════════════════════════════════════════════════════════════ */

:root {
    /* Colors */
    --primary: #0B3F36;
    --primary-light: #1E6F5C;
    --primary-dark: #072A25;
    --accent: #F2C94C;
    --accent-light: #F7DC8C;

    /* Status Colors */
    --status-progress: #3B82F6;
    --status-done: #10B981;
    --status-paused: #F59E0B;
    --status-total: #6366F1;

    /* Neutrals */
    --bg: #F8FAFB;
    --bg-alt: #F1F5F9;
    --card: #FFFFFF;
    --border: #E2E8F0;
    --border-light: #F1F5F9;

    /* Text */
    --text: #0F172A;
    --text-secondary: #64748B;
    --text-muted: #94A3B8;

    /* Feedback */
    --error: #EF4444;
    --success: #10B981;
    --warning: #F59E0B;

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow: 0 1px 3px rgba(0, 0, 0, 0.1), 0 1px 2px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);

    /* Radius */
    --radius-sm: 6px;
    --radius: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;

    /* Spacing */
    --navbar-height: 64px;
    --sidebar-width: 380px;

    /* Transitions */
    --transition: 0.2s ease;
}

/* ═══ Reset ═══ */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    height: 100%;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

/* ═══ Navbar ═══ */
.navbar {
    height: var(--navbar-height);
    background: var(--card);
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    position: sticky;
    top: 0;
    z-index: 100;
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.brand-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
}

.brand-icon svg {
    width: 22px;
    height: 22px;
    color: white;
}

.brand-text {
    display: flex;
    flex-direction: column;
}

.brand-name {
    font-size: 16px;
    font-weight: 700;
    color: var(--primary);
    letter-spacing: -0.3px;
}

.brand-subtitle {
    font-size: 12px;
    color: var(--text-secondary);
}

.navbar-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-menu {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-name {
    font-size: 14px;
    color: var(--text-secondary);
    padding: 6px 12px;
    background: var(--bg-alt);
    border-radius: var(--radius);
}

/* ═══ Buttons ═══ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px 16px;
    font-size: 14px;
    font-weight: 500;
    font-family: inherit;
    border-radius: var(--radius);
    border: none;
    cursor: pointer;
    transition: all var(--transition);
    text-decoration: none;
    white-space: nowrap;
}

.btn-sm {
    padding: 8px 12px;
    font-size: 13px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: white;
}

.btn-primary:hover {
    box-shadow: 0 2px 8px rgba(11, 63, 54, 0.3);
    transform: translateY(-1px);
}

.btn-outline {
    background: transparent;
    border: 1.5px solid var(--border);
    color: var(--text);
}

.btn-outline:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: rgba(11, 63, 54, 0.05);
}

.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
}

.btn-ghost:hover {
    background: var(--bg-alt);
    color: var(--text);
}

.btn-back {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 0;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    background: none;
    border: none;
    cursor: pointer;
    margin-bottom: 16px;
}

.btn-back:hover {
    color: var(--primary);
}

.btn-back svg {
    width: 18px;
    height: 18px;
}

/* ═══ Main Layout ═══ */
.main-layout {
    display: flex;
    height: 100vh;
    margin-left: 240px; /* Menu width */
    transition: margin-left 0.3s ease;
}

.main-layout.menu-collapsed {
    margin-left: 72px; /* Collapsed menu width */
}

@media (max-width: 1024px) {
    .main-layout,
    .main-layout.menu-collapsed {
        margin-left: 0;
    }
}

/* ═══ Sidebar ═══ */
.sidebar {
    width: var(--sidebar-width);
    background: var(--card);
    border-right: 1px solid var(--border);
    overflow-y: auto;
    flex-shrink: 0;
}

.sidebar-section {
    padding: 20px;
}

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.section-header h2 {
    font-size: 18px;
    font-weight: 600;
    color: var(--text);
}

.section-header h3 {
    font-size: 15px;
    font-weight: 600;
    color: var(--text);
}

/* ═══ Stats Grid ═══ */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-bottom: 24px;
}

.stat-card {
    background: var(--bg);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    transition: all var(--transition);
}

.stat-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow);
}

.stat-icon {
    width: 42px;
    height: 42px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
}

.stat-icon svg {
    width: 22px;
    height: 22px;
}

.stat-icon-total {
    background: rgba(99, 102, 241, 0.1);
    color: var(--status-total);
}

.stat-icon-progress {
    background: rgba(59, 130, 246, 0.1);
    color: var(--status-progress);
}

.stat-icon-done {
    background: rgba(16, 185, 129, 0.1);
    color: var(--status-done);
}

.stat-icon-paused {
    background: rgba(245, 158, 11, 0.1);
    color: var(--status-paused);
}

.stat-icon-pontos {
    background: rgba(139, 92, 246, 0.1);
    color: #8B5CF6;
}

.stat-icon-fotos {
    background: rgba(236, 72, 153, 0.1);
    color: #EC4899;
}

.stat-content {
    display: flex;
    flex-direction: column;
}

.stat-value {
    font-size: 24px;
    font-weight: 700;
    color: var(--text);
    line-height: 1;
}

.stat-label {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 4px;
}

/* ═══ Filter Tabs ═══ */
.filter-tabs {
    display: flex;
    gap: 4px;
    background: var(--bg);
    padding: 4px;
    border-radius: var(--radius);
}

.filter-tab {
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 500;
    font-family: inherit;
    color: var(--text-secondary);
    background: none;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all var(--transition);
}

.filter-tab:hover {
    color: var(--text);
}

.filter-tab.active {
    background: var(--card);
    color: var(--primary);
    box-shadow: var(--shadow-sm);
}

/* ═══ Obras List ═══ */
.obras-section {
    margin-top: 8px;
}

.obras-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 12px;
}

.obra-card {
    background: var(--bg);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 14px 16px;
    cursor: pointer;
    transition: all var(--transition);
}

.obra-card:hover {
    border-color: var(--primary);
    background: var(--card);
    box-shadow: var(--shadow);
}

.obra-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.obra-card-info {
    flex: 1;
    min-width: 0;
}

.obra-card-name {
    font-size: 14px;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.obra-card-location {
    font-size: 12px;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 4px;
}

.obra-card-location svg {
    width: 14px;
    height: 14px;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 8px;
    font-size: 11px;
    font-weight: 600;
    border-radius: 999px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.status-badge-progress {
    background: rgba(59, 130, 246, 0.1);
    color: var(--status-progress);
}

.status-badge-done {
    background: rgba(16, 185, 129, 0.1);
    color: var(--status-done);
}

.status-badge-paused {
    background: rgba(245, 158, 11, 0.1);
    color: var(--status-paused);
}

/* ═══ Obra Detail ═══ */
.obra-header {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    border-radius: var(--radius-lg);
    padding: 20px;
    color: white;
    margin-bottom: 20px;
}

.obra-header h2 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 8px;
}

.obra-header-location {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    opacity: 0.9;
}

.obra-header-location svg {
    width: 16px;
    height: 16px;
}

.obra-header .status-badge {
    margin-top: 12px;
    background: rgba(255, 255, 255, 0.2);
    color: white;
}

/* ═══ Pontos Section ═══ */
.pontos-section {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.ponto-card {
    background: var(--bg);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.ponto-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    cursor: pointer;
    transition: background var(--transition);
}

.ponto-header:hover {
    background: var(--card);
}

.ponto-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
    color: var(--text);
}

.ponto-title svg {
    width: 18px;
    height: 18px;
    color: var(--primary);
}

.ponto-count {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 400;
}

.ponto-toggle {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    transition: transform var(--transition);
}

.ponto-toggle svg {
    width: 16px;
    height: 16px;
}

.ponto-card.expanded .ponto-toggle {
    transform: rotate(180deg);
}

.ponto-content {
    padding: 0 16px 16px;
    display: none;
}

.ponto-card.expanded .ponto-content {
    display: block;
}

/* ═══ Timeline ═══ */
.timeline {
    position: relative;
    padding-left: 24px;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 7px;
    top: 8px;
    bottom: 8px;
    width: 2px;
    background: var(--border);
}

.timeline-item {
    position: relative;
    padding-bottom: 20px;
}

.timeline-item:last-child {
    padding-bottom: 0;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -20px;
    top: 6px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--accent);
    border: 2px solid var(--card);
}

.timeline-date {
    font-size: 12px;
    font-weight: 600;
    color: var(--primary);
    margin-bottom: 4px;
}

.timeline-title {
    font-size: 14px;
    font-weight: 500;
    color: var(--text);
    margin-bottom: 4px;
}

.timeline-description {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.timeline-photo {
    width: 100%;
    aspect-ratio: 16/10;
    object-fit: cover;
    border-radius: var(--radius);
    cursor: pointer;
    transition: all var(--transition);
}

.timeline-photo:hover {
    transform: scale(1.02);
    box-shadow: var(--shadow-md);
}

/* ═══ Map Container ═══ */
.map-container {
    flex: 1;
    position: relative;
}

#map {
    width: 100%;
    height: 100%;
}

/* Custom Leaflet Markers */
.leaflet-marker-icon {
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2));
}

/* ═══ Modal ═══ */
.modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1000;
}

.modal.active {
    display: flex;
}

.modal-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.9);
}

.modal-container {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    transition: all var(--transition);
    z-index: 10;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

.modal-close svg {
    width: 24px;
    height: 24px;
}

.modal-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 52px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    transition: all var(--transition);
    z-index: 10;
}

.modal-nav:hover {
    background: rgba(255, 255, 255, 0.2);
}

.modal-nav:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.modal-nav svg {
    width: 24px;
    height: 24px;
}

.modal-prev {
    left: 20px;
}

.modal-next {
    right: 20px;
}

.modal-content {
    max-width: 90vw;
    max-height: 85vh;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.modal-content img {
    max-width: 100%;
    max-height: 75vh;
    object-fit: contain;
    border-radius: var(--radius);
}

.modal-caption {
    text-align: center;
    color: white;
    padding: 20px;
}

.modal-caption h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 8px;
}

.modal-caption p {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
}

.modal-counter {
    display: inline-block;
    margin-top: 12px;
    padding: 4px 12px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 999px;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.7);
}

/* ═══ PDF Carousel Modal ═══ */
.pdf-carousel-content {
    width: 95vw;
    height: 90vh;
    display: flex;
    flex-direction: column;
}

.pdf-dual-view {
    flex: 1;
    display: flex;
    gap: 16px;
    padding: 20px;
    min-height: 0;
}

.pdf-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.pdf-panel.hidden {
    display: none;
}

.pdf-header {
    padding: 12px 16px;
    background: rgba(0, 0, 0, 0.3);
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.pdf-title {
    font-size: 14px;
    font-weight: 600;
    color: white;
}

.pdf-date {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
}

.pdf-container {
    flex: 1;
    min-height: 0;
    background: #2a2a2a;
}

.pdf-container iframe {
    width: 100%;
    height: 100%;
    border: none;
    background: white;
}

.pdf-caption {
    text-align: center;
    padding: 16px;
}

/* PDF Panel placeholder when empty */
.pdf-panel.empty {
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.02);
}

.pdf-panel.empty::after {
    content: 'Sem documento';
    color: rgba(255, 255, 255, 0.3);
    font-size: 14px;
}

/* Responsive - Stack vertically on mobile */
@media (max-width: 900px) {
    .pdf-dual-view {
        flex-direction: column;
    }

    .pdf-panel {
        min-height: 40vh;
    }
}

/* ═══ Loading States ═══ */
.loading-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    color: var(--text-muted);
    gap: 12px;
}

.spinner {
    width: 32px;
    height: 32px;
    border: 3px solid var(--border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ═══ Empty State ═══ */
.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-muted);
}

.empty-state svg {
    width: 48px;
    height: 48px;
    margin-bottom: 12px;
    opacity: 0.5;
}

.empty-state p {
    font-size: 14px;
}

/* ═══ Scrollbar ═══ */
.sidebar::-webkit-scrollbar {
    width: 6px;
}

.sidebar::-webkit-scrollbar-track {
    background: transparent;
}

.sidebar::-webkit-scrollbar-thumb {
    background: var(--border);
    border-radius: 3px;
}

.sidebar::-webkit-scrollbar-thumb:hover {
    background: var(--text-muted);
}

/* ═══ Mobile Toggle Button ═══ */
.mobile-toggle {
    display: none;
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    z-index: 200;
    box-shadow: 0 4px 12px rgba(11, 63, 54, 0.4);
    transition: transform var(--transition);
}

.mobile-toggle:active {
    transform: scale(0.95);
}

.mobile-toggle svg {
    width: 24px;
    height: 24px;
}

.mobile-toggle.active svg:first-child {
    display: none;
}

.mobile-toggle.active svg:last-child {
    display: block;
}

.mobile-toggle svg:last-child {
    display: none;
}

/* ═══ Point Filter Dropdown ═══ */
.point-filter {
    margin-top: 16px;
    padding: 12px;
    background: var(--bg-alt);
    border-radius: var(--radius);
}

.point-filter label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.point-filter select {
    width: 100%;
    padding: 10px 12px;
    font-size: 14px;
    font-family: inherit;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--card);
    color: var(--text);
    cursor: pointer;
}

.point-filter select:focus {
    outline: none;
    border-color: var(--primary);
}

/* ═══ Upload Info Button ═══ */
.btn-upload-info {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    font-size: 11px;
    font-weight: 500;
    color: var(--text-secondary);
    background: var(--bg-alt);
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    margin-top: 8px;
    transition: all var(--transition);
}

.btn-upload-info:hover {
    background: var(--primary);
    color: white;
}

.btn-upload-info svg {
    width: 14px;
    height: 14px;
}

/* ═══ Responsive ═══ */
@media (max-width: 1024px) {
    .main-layout {
        flex-direction: column-reverse;
    }

    .sidebar {
        width: 100%;
        height: 50%;
        border-right: none;
        border-top: 1px solid var(--border);
    }

    .map-container {
        height: 50%;
    }

    .stats-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 768px) {
    :root {
        --navbar-height: 56px;
    }

    .navbar {
        padding: 0 12px;
    }

    .brand-subtitle {
        display: none;
    }

    .brand-name {
        font-size: 14px;
    }

    .brand-icon {
        width: 36px;
        height: 36px;
    }

    .brand-icon svg {
        width: 18px;
        height: 18px;
    }

    .navbar-actions .btn {
        padding: 6px 10px;
        font-size: 12px;
    }

    .user-name {
        display: none;
    }

    /* Mobile layout - sidebar como overlay */
    .main-layout {
        flex-direction: column;
        position: relative;
    }

    .sidebar {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        height: 60vh;
        max-height: calc(100vh - var(--navbar-height));
        z-index: 150;
        transform: translateY(calc(100% - 80px));
        transition: transform 0.3s ease;
        border-radius: var(--radius-xl) var(--radius-xl) 0 0;
        box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
    }

    .sidebar.expanded {
        transform: translateY(0);
    }

    .sidebar::before {
        content: '';
        position: absolute;
        top: 8px;
        left: 50%;
        transform: translateX(-50%);
        width: 40px;
        height: 4px;
        background: var(--border);
        border-radius: 2px;
    }

    .sidebar-section {
        padding: 24px 16px 16px;
    }

    .map-container {
        height: calc(100vh - var(--navbar-height));
    }

    .mobile-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }

    .stat-card {
        padding: 12px;
    }

    .stat-value {
        font-size: 20px;
    }

    .stat-label {
        font-size: 11px;
    }

    .filter-tabs {
        display: flex;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .filter-tabs::-webkit-scrollbar {
        display: none;
    }

    .filter-tab {
        padding: 8px 14px;
        font-size: 13px;
        flex-shrink: 0;
    }

    .obra-card {
        padding: 12px 14px;
    }

    .obra-card-name {
        font-size: 13px;
    }

    /* Modal mobile */
    .modal-close {
        top: 10px;
        right: 10px;
        width: 40px;
        height: 40px;
    }

    .modal-nav {
        width: 44px;
        height: 44px;
    }

    .modal-prev {
        left: 10px;
    }

    .modal-next {
        right: 10px;
    }

    .modal-content img {
        max-height: 60vh;
    }

    .modal-caption {
        padding: 16px;
    }

    .modal-caption h3 {
        font-size: 16px;
    }

    /* Timeline mobile */
    .timeline-photo {
        aspect-ratio: 4/3;
    }

    .ponto-header {
        padding: 12px 14px;
    }

    /* Obra detail mobile */
    .obra-header {
        padding: 16px;
    }

    .obra-header h2 {
        font-size: 16px;
    }

    .btn-back {
        font-size: 13px;
    }

    /* Touch-friendly buttons */
    .btn {
        min-height: 44px;
    }

    .ponto-toggle {
        width: 28px;
        height: 28px;
    }

    .ponto-toggle svg {
        width: 18px;
        height: 18px;
    }
}

/* Extra small screens */
@media (max-width: 375px) {
    .stats-grid {
        grid-template-columns: 1fr 1fr;
    }

    .stat-card {
        flex-direction: column;
        text-align: center;
        gap: 8px;
    }

    .stat-icon {
        width: 36px;
        height: 36px;
    }

    .stat-icon svg {
        width: 18px;
        height: 18px;
    }

    .navbar-actions {
        gap: 6px;
    }

    .obra-header-location {
        font-size: 12px;
    }
}

/* Landscape phone */
@media (max-width: 768px) and (orientation: landscape) {
    .sidebar {
        height: 80vh;
        transform: translateY(calc(100% - 60px));
    }

    .modal-content img {
        max-height: 70vh;
    }
}
