
* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f0f2f5;
    color: #333;
    padding: 30px 20px;
}

h1 {
    font-size: 1.8rem;
    margin-bottom: 6px;
    color: #1a1a2e;
}

.subtitle {
    color: #666;
    margin-bottom: 28px;
    font-size: 0.95rem;
}

nav {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 30px;
}

nav a {
    padding: 8px 16px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
    transition: background 0.2s;
}

.nav-insert { background: #d4edda; color: #155724; }
.nav-insert:hover { background: #b8dac3; }
.nav-delete { background: #f8d7da; color: #721c24; }
.nav-delete:hover { background: #f1b8bc; }
.nav-update { background: #fff3cd; color: #856404; }
.nav-update:hover { background: #f5e6a3; }
.nav-search { background: #d1ecf1; color: #0c5460; }
.nav-search:hover { background: #aedde6; }
.nav-active { outline: 2px solid #333; }

.card {
    background: #fff;
    border-radius: 10px;
    padding: 28px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    max-width: 700px;
    margin-bottom: 24px;
}

h2 {
    font-size: 1.2rem;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f0f2f5;
    color: #1a1a2e;
}

.tab-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 24px;
}

.tab-bar a {
    padding: 6px 14px;
    border-radius: 20px;
    background: #e9ecef;
    color: #495057;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 600;
    transition: background 0.2s;
}

.tab-bar a:hover { background: #ced4da; }
.tab-bar a.active { background: #1a1a2e; color: #fff; }

label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 4px;
    color: #555;
}

input[type="text"],
input[type="email"],
input[type="number"],
select {
    width: 100%;
    padding: 9px 12px;
    border: 1px solid #ced4da;
    border-radius: 6px;
    font-size: 0.95rem;
    margin-bottom: 16px;
    transition: border-color 0.2s;
}

input:focus, select:focus {
    outline: none;
    border-color: #6c9bd2;
    box-shadow: 0 0 0 3px rgba(108,155,210,0.15);
}

.hint {
    font-size: 0.78rem;
    color: #888;
    margin-top: -12px;
    margin-bottom: 14px;
}

button[type="submit"] {
    padding: 10px 24px;
    border: none;
    border-radius: 6px;
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    transition: opacity 0.2s;
}

button[type="submit"]:hover { opacity: 0.85; }

.btn-insert { background: #28a745; color: #fff; }
.btn-delete { background: #dc3545; color: #fff; }
.btn-update { background: #ffc107; color: #333; }
.btn-search { background: #17a2b8; color: #fff; }

.message {
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 20px;
    font-weight: 600;
}

.success { background: #d4edda; color: #155724; border: 1px solid #c3e6cb; }
.error   { background: #f8d7da; color: #721c24; border: 1px solid #f5c6cb; }
.warning { background: #fff3cd; color: #856404; border: 1px solid #ffeeba; }

.results-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    font-size: 0.88rem;
}

.results-table th {
    background: #1a1a2e;
    color: #fff;
    padding: 10px 12px;
    text-align: left;
    font-weight: 600;
}

.results-table td {
    padding: 9px 12px;
    border-bottom: 1px solid #e9ecef;
}

.results-table tr:nth-child(even) td { background: #f8f9fa; }
.results-table tr:hover td { background: #e8f4f8; }

.record-count {
    font-size: 0.85rem;
    color: #666;
    margin-top: 16px;
}
