/* public/css/style.css */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@100..900&display=swap');

:root {
    --primary: #3b82f6;
    --primary-gradient: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    --secondary: #06b6d4;
    --secondary-gradient: linear-gradient(135deg, #22d3ee 0%, #06b6d4 100%);
    --bg-app: #f1f5f9;
    --bg-card: #ffffff;
    --text-main: #1e293b;
    --text-muted: #94a3b8;
    --success: #10b981;
    --warning: #f59e0b;
    --warning-gradient: linear-gradient(135deg, #f59e0b 0%, #ea580c 100%);
    --danger: #ef4444;
    --border: transparent;
    --shadow: 0 15px 35px -5px rgba(0, 0, 0, 0.08), 0 10px 20px -6px rgba(0, 0, 0, 0.05);
    --shadow-btn: 0 8px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', sans-serif;
    -webkit-font-smoothing: antialiased;
}

body {
    background-color: var(--bg-app);
    color: var(--text-main);
    line-height: 1.5;
    -webkit-tap-highlight-color: transparent;
    overflow-x: hidden;
}

/* App Shell */
.app-container {
    max-width: 500px;
    margin: 0 auto;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    padding-bottom: 70px;
    /* Space for bottom nav */
}

/* Header */
.app-header {
    background: white;
    padding: 1rem 1.25rem;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.header-title {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--primary);
}

/* General Layout */
.content {
    padding: 1.25rem;
    flex: 1;
}

/* Cards */
.card {
    background: white;
    border-radius: 28px;
    padding: 1.75rem;
    box-shadow: var(--shadow);
    margin-bottom: 1rem;
    border: none;
}

.route-card {
    background: white;
    border-radius: 12px;
    padding: 1.25rem;
    margin-bottom: 0.75rem;
    border: 1px solid var(--border);
    display: block;
    text-decoration: none;
    color: inherit;
    transition: all 0.2s ease;
}

.route-card:active {
    background: #f8fafc;
    transform: scale(0.98);
}

/* Badges */
.badge {
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
}

.badge-pendente {
    background: #fef3c7;
    color: #92400e;
}

.badge-em_andamento {
    background: #dbeafe;
    color: #1e40af;
}

.badge-finalizada {
    background: #dcfce7;
    color: #166534;
}

.badge-concluida {
    background: #dcfce7;
    color: #166534;
}

/* Buttons */
.btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 20px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
    width: 100%;
}

.btn-primary {
    background: var(--primary);
    color: white;
}

.btn-primary:active {
    background: var(--primary-dark);
}

.btn-outline {
    background: white;
    border: 1.5px solid var(--border);
    color: var(--text-main);
}

.btn-success {
    background: var(--success);
    color: white;
}

.btn-gps {
    text-decoration: none;
    font-size: 15px;
    padding: 14px 20px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-weight: 700;
    transition: all 0.2s ease;
    flex: 1;
    border: none;
}

.btn-waze {
    background: var(--secondary-gradient);
    color: white;
    box-shadow: 0 10px 20px rgba(6, 182, 212, 0.25);
}

.btn-waze i {
    color: white;
}

.btn-maps {
    background: #ffffff;
    border: none;
    color: #3b82f6;
    box-shadow: var(--shadow-btn);
}

.btn-maps i {
    color: #3b82f6;
}

.btn-finalize {
    background: var(--primary-gradient);
    color: white;
    box-shadow: 0 12px 25px rgba(59, 130, 246, 0.35);
    height: 60px !important;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: none;
}

.btn-driving {
    background: var(--warning-gradient);
    color: white;
    box-shadow: 0 12px 25px rgba(234, 88, 12, 0.35);
    height: 60px !important;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: none;
}

.btn-arrived {
    background: var(--secondary-gradient);
    color: white;
    box-shadow: 0 12px 25px rgba(6, 182, 212, 0.35);
    height: 60px !important;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: none;
}

/* Typography */
.label-sm {
    font-size: 11px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    margin-bottom: 4px;
    display: block;
}

.text-lg {
    font-size: 1.125rem;
    font-weight: 700;
}

.text-sm {
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* Navigation Bottom */
.nav-bottom {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    max-width: 500px;
    margin: 0 auto;
    background: white;
    display: flex;
    justify-content: space-around;
    padding: 10px 0;
    border-top: 1px solid var(--border);
    z-index: 1000;
}

.nav-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: var(--text-muted);
    font-size: 10px;
    font-weight: 600;
    gap: 4px;
}

.nav-link.active {
    color: var(--primary);
}

.nav-link i {
    font-size: 20px;
}

/* Stop List */
.stop-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: white;
    border-radius: 10px;
    margin-bottom: 8px;
    border: 1px solid var(--border);
    text-decoration: none;
    color: inherit;
}

.stop-icon {
    width: 36px;
    height: 36px;
    background: #f1f5f9;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
}

.stop-icon.concluida {
    background: #dcfce7;
    color: var(--success);
}

/* Timer */
.timer-container {
    background: #0f172a;
    color: white;
    padding: 12px;
    border-radius: 8px;
    text-align: center;
    margin-bottom: 1rem;
}

.timer-value {
    font-family: 'Courier New', Courier, monospace;
    font-size: 24px;
    font-weight: 700;
    letter-spacing: 2px;
}

/* Gallery Grid */
.receipt-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.receipt-card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid var(--border);
}

.receipt-img {
    width: 100%;
    height: 120px;
    object-fit: cover;
    background: #f1f5f9;
}

.receipt-info {
    padding: 8px;
}

/* Profile Section */
.profile-header {
    text-align: center;
    padding: 2rem 1rem;
}

.avatar {
    width: 80px;
    height: 80px;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 12px;
    font-size: 32px;
    font-weight: 700;
    border: 3px solid white;
    box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1);
}

/* Forms */
.form-field {
    margin-bottom: 1rem;
}

.input {
    width: 100%;
    padding: 16px;
    border-radius: 16px;
    border: none;
    background: #f8fafc;
    font-size: 15px;
    outline: none;
    color: var(--text-main);
}

.input::placeholder {
    color: #cbd5e1;
}

.input:focus {
    background: #f1f5f9;
}

/* Icons fallback for when Lucide is loading */
.lucide {
    width: 20px;
    height: 20px;
    stroke-width: 2.5;
}