* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    
    align-items: center;
    justify-content: center;
    
}

.container {
    width: 100%;
    max-width: 400px;
    padding: 20px;
}

.auth-container {
    background: white;
    border-radius: 10px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
    padding: 40px;
    text-align: center;
}

.logo h1 {
    color: #333;
    margin-bottom: 10px;
    font-size: 2rem;
}

.logo p {
    color: #666;
    margin-bottom: 30px;
}

.tabs {
    display: flex;
    margin-bottom: 30px;
    border-radius: 5px;
    overflow: hidden;
    background: #f5f5f5;
}

.tab-button {
    flex: 1;
    padding: 10px;
    border: none;
    background: transparent;
    cursor: pointer;
    font-weight: 500;
    transition: background 0.3s;
}

.tab-button.active {
    background: #667eea;
    color: white;
}

.form-container {
    text-align: left;
}

.form-container h2 {
    margin-bottom: 20px;
    color: #333;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    color: #555;
    font-weight: 500;
}

.form-group input {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 16px;
    transition: border-color 0.3s;
}

.form-group input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 2px rgba(102, 126, 234, 0.2);
}

.btn-primary {
    width: 100%;
    padding: 12px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: transform 0.2s;
}

.btn-primary:hover {
    transform: translateY(-2px);
}

.btn-primary:active {
    transform: translateY(0);
}

.message {
    margin-top: 20px;
    padding: 10px;
    border-radius: 5px;
    display: none;
}

.message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.hidden {
    display: none;
}

/* Dashboard Styles */
.dashboard-container {
    height: 100vh;
    background: #f8f9fa;
    margin: 0;
    padding: 0;
    overflow: hidden;
    position: relative;
}

.sidebar {
    width: 250px;
    background: white;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    position: fixed;
    left: 0;
    top: 0;
    height: 100vh;
    z-index: 100;
}

.sidebar-header {
    padding: 20px;
    border-bottom: 1px solid #eee;
}

.sidebar-header h2 {
    color: #667eea;
    margin: 0;
    font-size: 1.5rem;
}

.sidebar-nav {
    flex: 1;
    padding: 20px 0;
}

.sidebar-nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-nav li {
    margin: 0;
}

.sidebar-nav a {
    display: block;
    padding: 12px 20px;
    color: #666;
    text-decoration: none;
    transition: all 0.3s;
    border-left: 3px solid transparent;
}

.sidebar-nav a:hover {
    background: #f8f9fa;
    color: #667eea;
}

.sidebar-nav a.active {
    background: #667eea;
    color: white;
    border-left-color: #4a5ac7;
}

.sidebar-footer {
    padding: 20px;
    border-top: 1px solid #eee;
}

.btn-secondary {
    background: #6c757d;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 500;
    transition: background 0.3s;
    width: 100%;
}

.btn-secondary:hover {
    background: #5a6268;
}

.main-content {
    margin-left: 250px;
    display: flex;
    flex-direction: column;
    height: 100vh;
}

.main-header {
    background: white;
    padding: 20px 30px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    border-bottom: 1px solid #eee;
    display: flex;
    align-items: center;
}

.menu-toggle {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    margin-right: 15px;
    display: none;
}

.main-header h1 {
    margin: 0;
    color: #333;
}

.content-area {
    flex: 1;
    padding: 0;
    overflow-y: auto;
}

.section {
    display: none;
}

.section.active {
    display: block;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    text-align: center;
}

.stat-card h3 {
    margin: 0 0 10px 0;
    color: #667eea;
    font-size: 2rem;
}

.stat-card p {
    margin: 0;
    color: #666;
}

.recent-activity {
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.recent-activity h3 {
    margin-bottom: 15px;
    color: #333;
}

.profile-content {
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.profile-content h3 {
    margin-bottom: 20px;
    color: #333;
}

.browse-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.browse-card {
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    text-decoration: none;
    color: inherit;
    transition: transform 0.3s;
}

.browse-card:hover {
    transform: translateY(-5px);
}

.browse-card h3 {
    margin: 0 0 10px 0;
    color: #667eea;
}

.browse-card p {
    margin: 0;
    color: #666;
}

@media (max-width: 768px) {
    .dashboard-content {
        grid-template-columns: 1fr;
    }

    .dashboard-header {
        flex-direction: column;
        gap: 15px;
    }
}

/* Clinics Page Styles */
.clinics-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 20px 60px;
}

.clinics-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 20px;
    margin-bottom: 20px;
    color: #f9f9f9;
}

.clinics-header h1 {
    margin-bottom: 4px;
    font-size: 2.4rem;
}

.clinics-header .subtitle {
    margin: 0;
    color: rgba(255, 255, 255, 0.9);
    font-size: 1rem;
}

.clinics-header .btn-secondary {
    width: auto;
    padding: 10px 24px;
}

.clinic-search-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 14px;
    padding: 24px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.08);
    margin-bottom: 30px;
}

.clinic-search-description h2 {
    margin: 0;
    font-size: 1.4rem;
    color: #2c2c2c;
}

.clinic-search-description p {
    margin-top: 8px;
    color: #555;
}

.clinic-filters {
    margin-top: 20px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    align-items: end;
}

.clinic-filters .form-group {
    margin: 0;
}

.clinic-filters label {
    font-weight: 600;
    color: #444;
    margin-bottom: 6px;
    display: block;
}

.clinic-filters input {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s;
}

.clinic-filters input:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 2px rgba(102, 126, 234, 0.2);
    outline: none;
}

.search-action {
    grid-column: 1 / -1;
    display: flex;
    justify-content: flex-end;
}

.clinic-search-card .btn-primary {
    width: 180px;
}

.clinic-results-card {
    background: white;
    border-radius: 14px;
    padding: 26px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
}

.results-header {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 20px;
}

.results-header h2 {
    margin: 0;
    font-size: 1.5rem;
    color: #282828;
}

.results-summary {
    font-size: 0.95rem;
    color: #555;
}

.clinics-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.clinic-card {
    background: #fdfdfd;
    padding: 20px;
    border-radius: 12px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.3), 0 10px 24px rgba(0, 0, 0, 0.08);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.clinic-card h3 {
    margin-bottom: 4px;
    color: #2f2f2f;
}

.clinic-card p {
    margin: 0;
    color: #555;
}

.clinic-card h4 {
    margin: 12px 0 6px;
    font-size: 1rem;
    color: #333;
}

.clinic-card ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.clinic-card li {
    margin-bottom: 8px;
    padding-bottom: 8px;
    border-bottom: 1px solid #eee;
}

.clinic-card li:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.clinic-card small {
    color: #888;
    font-size: 0.9rem;
}

.empty-state {
    margin: 0;
    padding: 24px;
    text-align: center;
    color: #666;
    background: #fafafa;
    border-radius: 10px;
    border: 1px dashed #ddd;
}

.suggestions {
    position: absolute;
    background: white;
    border: 1px solid #ddd;
    border-top: none;
    max-height: 200px;
    overflow-y: auto;
    width: 100%;
    z-index: 1000;
    display: none;
}

.suggestions div {
    padding: 8px 12px;
    cursor: pointer;
    border-bottom: 1px solid #eee;
}

.suggestions div:hover {
    background: #f8f9fa;
}

.suggestions div:last-child {
    border-bottom: none;
}

.form-group {
    position: relative;
}

@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }

    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s;
    }

    .sidebar.open {
        transform: translateX(0);
    }

    .main-content {
        margin-left: 0;
    }

    .clinics-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .clinics-header .btn-secondary {
        width: 100%;
    }

    .clinic-filters {
        grid-template-columns: 1fr;
    }

    .search-action {
        justify-content: center;
    }

    .clinic-search-card .btn-primary {
        width: 100%;
        max-width: none;
    }

    .clinics-list {
        grid-template-columns: 1fr;
    }

    .clinic-results-card {
        padding: 20px;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .browse-options {
        grid-template-columns: 1fr;
    }
}
