:root {
    --primary-color: #2563eb;
    --secondary-color: #64748b;
    --success-color: #16a34a;
    --warning-color: #f59e0b;
    --danger-color: #dc2626;
    --dark-color: #1e293b;
    --light-gray: #f8fafc;
    --search-bg-color: #aba79b;
    --border-color: #e2e8f0;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --border-radius: 0px;
}

* {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

body {
    /* background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); */
    min-height: 100vh;
    color: var(--dark-color);
}

.main-container {
    background: white;
/*    border-radius: var(--border-radius); */
/*    box-shadow: var(--shadow-lg); */
    margin: 20px auto;
    max-width: 1200px;
    overflow: hidden;
}

.header-section {
    background: linear-gradient(135deg, var(--primary-color), #3b82f6);
    color: white;
    padding: 2rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.header-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="pattern" x="0" y="0" width="20" height="20" patternUnits="userSpaceOnUse"><circle cx="10" cy="10" r="1" fill="rgba(255,255,255,0.1)"/></pattern></defs><rect width="100" height="100" fill="url(%23pattern)"/></svg>');
    opacity: 0.1;
}

.header-section > * {
    position: relative;
    z-index: 1;
}

.app-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

.app-subtitle {
    font-size: 1.1rem;
    opacity: 0.9;
    font-weight: 400;
}

.content-section {
/*    padding: 2rem; */
}

.search-form {
    background: var(--search-bg-color);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-sm);
}

.form-label {
    font-weight: 600;
    color: var(--dark-color);
    margin-bottom: 0.5rem;
}

.form-control, .form-select {
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 0.75rem 1rem;
    font-size: 0.95rem;
    transition: all 0.2s ease;
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.btn-primary {
    background: var(--primary-color);
    border: none;
    padding: 0.75rem 2rem;
    font-weight: 600;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.btn-primary:hover {
    background: #1d4ed8;
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.route-header {
    background: var(--light-gray);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
}

.route-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.route-badge {
    background: var(--primary-color);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1.1rem;
}

.route-name {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--dark-color);
    margin: 0;
}

.nav-tabs {
    border: none;
    gap: 0.5rem;
    margin-bottom: 2rem;
}

.nav-tabs .nav-link {
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--secondary-color);
    font-weight: 500;
    padding: 0.75rem 1.5rem;
    transition: all 0.2s ease;
    background: white;
}

.nav-tabs .nav-link:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateY(-1px);
}

.nav-tabs .nav-link.active {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

.eta-table {
    background: white;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
}

.table {
    margin-bottom: 0;
}

.table thead th {
    background: var(--dark-color);
    color: white;
    font-weight: 600;
    border: none;
    padding: 1rem 1.5rem;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.table tbody tr {
    border-bottom: 1px solid var(--border-color);
    transition: all 0.2s ease;
}

.table tbody tr:hover {
    background: var(--light-gray);
}

.table tbody tr:last-child {
    border-bottom: none;
}

.table td {
    padding: 1.25rem 1.5rem;
    border: none;
    vertical-align: middle;
}

.stop-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.stop-sequence {
    background: var(--secondary-color);
    color: white;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.85rem;
    flex-shrink: 0;
}

.stop-name {
    font-weight: 500;
    font-size: 1.2rem;
    color: var(--dark-color);
    margin: 0;
    line-height: 1.4;
}

.eta-container {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    align-items: flex-end;
}

.eta-time {
    /* display: flex; */
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    background: var(--light-gray);
    border: 1px solid var(--border-color);
    width:100%;
    text-wrap: nowrap;
}

.eta-time.primary {
    background: var(--success-color);
    color: white;
    border-color: var(--success-color);
    font-size: 1.0rem;
}

.eta-time.urgent {
    background: var(--danger-color);
    color: white;
    border-color: var(--danger-color);
    animation: pulse 2s infinite;
}

.eta-time.warning {
    background: var(--warning-color);
    color: white;
    border-color: var(--warning-color);
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.8; }
}

.eta-minutes {
    font-size: 0.85rem;
    opacity: 0.9;
}

.eta-remark {
    font-size: 0.8rem;
    color: var(--secondary-color);
    font-style: italic;
    margin-top: 0.25rem;
}

.no-eta {
    color: var(--secondary-color);
    font-style: italic;
    padding: 0.5rem 1rem;
    background: var(--light-gray);
    border-radius: 6px;
    border: 1px solid var(--border-color);
}

.alert {
    border: none;
    border-radius: var(--border-radius);
    padding: 1.5rem;
    font-weight: 500;
}

.alert-danger {
    background: #fef2f2;
    color: var(--danger-color);
    border-left: 4px solid var(--danger-color);
}

.alert-warning {
    background: #fffbeb;
    color: var(--warning-color);
    border-left: 4px solid var(--warning-color);
}

.footer-section {
    background: var(--light-gray);
    border-top: 1px solid var(--border-color);
    padding: 1.5rem 2rem;
    text-align: center;
    color: var(--secondary-color);
}

.footer-section p {
    margin: 0.25rem 0;
}

.status-indicator {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    font-weight: 500;
}

.status-indicator a {
    text-decoration: none;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--success-color);
    animation: pulse 2s infinite;
}

@media (max-width: 768px) {
    .main-container {
        margin: 10px;
        border-radius: 0;
    }
    
    .header-section {
        padding: 1.5rem;
    }
    
    .app-title {
        font-size: 2rem;
    }
    
    .content-section {
/*        padding: 1rem; */
    }
    
    .search-form {
        padding: 1.5rem;
    }
    
    .route-header {
        flex-direction: column;
        text-align: center;
    }
    
    .eta-container {
        align-items: flex-start;
    }
    
    .stop-info {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .route-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .route-card {
        padding: 1rem;
    }
    
    .route-card-actions {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .route-card-actions .btn {
        width: 100%;
    }

}

/* Route List Styles */
.route-list-section {
    margin-bottom: 2rem;
}

.route-list-header {
    /* text-align: center; */
}

.route-list-header h2 {
    color: var(--light-gray);
    font-weight: 600;
    margin-bottom: 0.5rem;
}
.route-list-header p {
    color: var(--light-gray) !important;
}

.transport-group {
    margin-bottom: 2rem;
}

.transport-title {
    background: var(--border-color);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 1rem;
    margin-bottom: 1rem;
    color: var(--dark-color);
    font-size: 1.2rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.route-count {
    color: var(--secondary-color);
    font-size: 0.9rem;
    font-weight: 400;
}

.route-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.route-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--shadow-sm);
    transition: all 0.2s ease;
}

.route-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary-color);
}

.route-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.route-number {
    background: var(--success-color);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-weight: 700;
    font-size: 1.1rem;
}

.route-company {
    background: var(--light-gray);
    color: var(--secondary-color);
    padding: 0.25rem 0.75rem;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 500;
}

.route-card-body {
    margin-bottom: 1.5rem;
}

.route-description {
    font-size: 0.9rem;
    line-height: 1.5;
}

.route-direction,
.route-origin {
    margin-bottom: 0.5rem;
    color: var(--dark-color);
}

.route-direction strong,
.route-origin strong {
    color: var(--primary-color);
    font-weight: 600;
}

.route-card-actions {
    display: flex;
    flex-direction: row;
    gap: 8px;
    justify-content: space-between;
}

.route-card-actions .btn {
    flex: 1;
    font-size: 1.2rem;
    padding: 0.5rem 1rem;
    font-weight: 500;
}

.direction-tabs {
    display: flex;
    flex-direction: row;
    gap: 8px;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.direction-tabs .btn {
    flex: 1;
    font-size: 1.2rem;
    padding: 0.5rem 1rem;
    font-weight: 500;
}


.btn-outline-primary {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.btn-outline-primary:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
}

/* Header Styles */
.header-section {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    padding: 2rem 0;
    margin-bottom: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

.header-content h1 {
    margin: 0;
    font-size: 2.5rem;
    font-weight: 700;
}

.header-subtitle {
    margin: 0.5rem 0 0 0;
    font-size: 1.1rem;
    opacity: 0.9;
}

.language-toggle {
    display: flex;
    gap: 0.5rem;
}

.language-toggle .btn {
    min-width: 60px;
}

/* Search Form Styles */
.search-form {
    background: var(--search-bg-color);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: var(--shadow-sm);
}

.search-form h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-weight: 600;
}

.search-form .form-label {
    font-weight: 600;
    color: var(--dark-color);
}

.search-form .form-control {
    border-radius: 8px;
    border: 2px solid var(--border-color);
    padding: 0.75rem 1rem;
    transition: all 0.2s ease;
}

.search-form .form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(59, 130, 246, 0.15);
}

/* Welcome Section */
.welcome-section {
    margin: 2rem 0;
}

.welcome-card {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 2rem;
    text-align: center;
    box-shadow: var(--shadow-sm);
}

.welcome-card h3 {
    margin-bottom: 1rem;
    color: var(--dark-color);
}

.welcome-card p {
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 2rem;
    color: var(--text-color);
}

.example-routes {
    border-top: 1px solid var(--border-color);
    padding-top: 1.5rem;
    margin-top: 1.5rem;
}

.example-routes h5 {
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.example-links {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.example-links .btn {
    min-width: 140px;
}

/* Navigation Styles */
.navigation-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem; 
}

.breadcrumb-nav {
    font-size: 0.9rem;
}

.breadcrumb-nav a {
    color: var(--primary-color);
}

/* Table Header */
.table-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding: 0 1rem;
}

.table-header h4 {
    margin: 0;
    color: var(--primary-color);
    font-weight: 600;
}
