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

body {
    font-family: Georgia, 'Times New Roman', serif;
    line-height: 1.6;
    background-color: #fafafa;
    color: #333;
}

.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
}

.navbar {
    background: #2c3e50;
    color: white;
    padding: 1rem 0;
    margin-bottom: 2rem;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.brand {
    font-size: 1.25rem;
    font-weight: 600;
    color: white;
    text-decoration: none;
}

.nav-links {
    list-style: none;
    display: flex;
    gap: 1.5rem;
}

.nav-links a {
    color: white;
    text-decoration: none;
    font-size: 0.95rem;
}

.nav-links a:hover {
    text-decoration: underline;
}

main {
    min-height: calc(100vh - 150px);
}

.alert {
    padding: 1rem 1.25rem;
    border-radius: 4px;
    margin-bottom: 1.5rem;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.card {
    background: white;
    border-radius: 6px;
    padding: 1.5rem 2rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    margin-bottom: 1.5rem;
    border: 1px solid #e8e8e8;
}

h1, h2 {
    margin-bottom: 1rem;
    font-weight: 400;
    color: #2c3e50;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.form-group {
    margin-bottom: 1rem;
}

label {
    display: block;
    margin-bottom: 0.4rem;
    font-weight: 500;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 0.9rem;
    color: #555;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="date"],
select {
    width: 100%;
    padding: 0.65rem 0.85rem;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 1rem;
    font-family: inherit;
}

input:focus {
    outline: none;
    border-color: #4a6fa5;
    box-shadow: 0 0 0 2px rgba(74, 111, 165, 0.1);
}

.btn {
    display: inline-block;
    padding: 0.65rem 1.25rem;
    background: #4a6fa5;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 0.95rem;
    cursor: pointer;
    text-decoration: none;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.btn:hover {
    background: #3d5c8a;
}

.btn-secondary {
    background: #7f8c8d;
}

.btn-secondary:hover {
    background: #6c7a7d;
}

.btn-danger {
    background: #c0392b;
}

.btn-danger:hover {
    background: #a93226;
}

.btn-small {
    padding: 0.4rem 0.85rem;
    font-size: 0.85rem;
}

.table-container {
    background: white;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    border: 1px solid #e8e8e8;
    overflow: hidden;
    margin-bottom: 1.5rem;
}

table {
    width: 100%;
    border-collapse: collapse;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

th {
    background: #f7f7f7;
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: #555;
    padding: 0.85rem 1rem;
    text-align: left;
    border-bottom: 2px solid #e8e8e8;
}

th a {
    color: #555;
    text-decoration: none;
}

th a:hover {
    color: #2c3e50;
    text-decoration: underline;
}

td {
    padding: 0.85rem 1rem;
    border-bottom: 1px solid #f0f0f0;
    font-size: 0.95rem;
}

tbody tr:nth-child(even) {
    background: #fafafa;
}

tbody tr:hover {
    background: #f5f5f5;
}

tr:last-child td {
    border-bottom: none;
}

.book-title {
    font-weight: 500;
    color: #2c3e50;
}

.book-author {
    color: #555;
}

.book-date {
    color: #777;
    font-size: 0.9rem;
}

.actions {
    display: flex;
    gap: 0.5rem;
}

.text-center {
    text-align: center;
}

.text-muted {
    color: #777;
}

.mt-1 { margin-top: 1rem; }
.mt-2 { margin-top: 2rem; }
.mb-1 { margin-bottom: 1rem; }
.mb-2 { margin-bottom: 2rem; }

footer {
    text-align: center;
    padding: 2rem 0;
    color: #999;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 0.85rem;
    margin-top: 2rem;
}

.search-form {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

.search-form input[type="text"] {
    flex: 1;
    max-width: 300px;
}

.results-info {
    color: #777;
    font-size: 0.9rem;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.book-list-card {
    background: white;
    border-radius: 6px;
    padding: 1rem 1.25rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    border: 1px solid #e8e8e8;
    margin-bottom: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.book-list-card:hover {
    border-color: #ccc;
}

.book-list-info {
    flex: 1;
}

.book-list-title {
    font-weight: 500;
    color: #2c3e50;
    margin-bottom: 0.25rem;
}

.book-list-author {
    color: #666;
    font-size: 0.9rem;
}

.book-list-date {
    color: #888;
    font-size: 0.85rem;
    margin-top: 0.25rem;
}

@media (max-width: 768px) {
    .table-container {
        display: none;
    }
    
    .book-list-card {
        display: flex;
    }
    
    .search-form input[type="text"] {
        max-width: none;
    }
}

@media (min-width: 769px) {
    .mobile-book-list {
        display: none;
    }
}
