/* General Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f4f6f9;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.hidden {
    display: none;
}

/* Header */
.header {
    text-align: center;
    margin-bottom: 30px;
}

.header h1 {
    font-size: 2rem;
    color: #444;
    margin-bottom: 5px;
}

.header p {
    color: #666;
}

/* Auth Screens */
.auth-card {
    max-width: 500px;
    margin: 0 auto;
    padding: 30px;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 15px;
}

/* Buttons */
.btn {
    background: #667eea;
    color: white;
    padding: 10px 15px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: 0.3s;
    font-size: 15px;
}

.btn:hover {
    background: #5661b3;
}

.btn-secondary {
    background: #6c757d;
}

.btn-secondary:hover {
    background: #5a6268;
}

.btn-danger {
    background: #dc3545;
}

.btn-danger:hover {
    background: #c82333;
}

.btn-small {
    padding: 5px 10px;
    font-size: 13px;
}

/* Cards */
.card {
    background: white;
    padding: 25px;
    border-radius: 10px;
    margin-bottom: 20px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}

/* Tabs */
.tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.tab {
    flex: 1;
    padding: 10px;
    border: none;
    background: #f4f6f9;
    cursor: pointer;
    border-radius: 6px;
    font-weight: 600;
    transition: 0.3s;
}

.tab.active {
    background: #667eea;
    color: white;
}

/* Dashboard Navigation */
.dashboard-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: white;
    padding: 15px 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}

.dashboard-nav .logo {
    font-weight: bold;
    font-size: 18px;
    color: #333;
}

.dashboard-nav .user-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #667eea;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
}

/* Tables */
.records-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
}

.records-table th,
.records-table td {
    border: 1px solid #ddd;
    padding: 10px;
    text-align: left;
}

.records-table th {
    background: #f4f6f9;
    font-weight: bold;
}

.records-table tr:nth-child(even) {
    background: #fafafa;
}

.actions button {
    margin-right: 5px;
}

/* Stats */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin-bottom: 20px;
}

.stat-card {
    background: white;
    border-radius: 10px;
    padding: 20px;
    text-align: center;
    box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}

.stat-number {
    font-size: 28px;
    font-weight: bold;
    margin-bottom: 5px;
    color: #667eea;
}

.stat-label {
    color: #666;
}

/* Search Section */
.search-section {
    margin-bottom: 20px;
}

.search-form {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.search-form .form-group {
    flex: 1;
    min-width: 200px;
}

/* Alerts */
#alertContainer {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
}

.alert {
    padding: 12px 20px;
    border-radius: 6px;
    margin-bottom: 10px;
    animation: fadeIn 0.3s ease-in-out;
}

.alert-success {
    background: #28a745;
    color: white;
}

.alert-error {
    background: #dc3545;
    color: white;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Setup Notice */
.setup-notice {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeeba;
    padding: 15px;
    border-radius: 6px;
    margin-bottom: 20px;
}

.setup-notice h3 {
    margin-bottom: 10px;
}

/* Business Status */
.business-status {
    display: inline-block;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
}

.status-active {
    background: #d4edda;
    color: #155724;
}

.status-pending {
    background: #fff3cd;
    color: #856404;
}

.status-suspended {
    background: #f8d7da;
    color: #721c24;
}

/* Loading */
.loading {
    text-align: center;
    padding: 20px;
    color: #666;
    font-style: italic;
}

/* Two Column Layout */
.two-column {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

/* Responsive */
@media (max-width: 768px) {
    .two-column {
        grid-template-columns: 1fr;
    }
    
    .search-form {
        flex-direction: column;
    }
    
    .search-form .form-group {
        min-width: 100%;
    }

    .dashboard-nav {
        flex-direction: column;
        gap: 15px;
    }
}
