/* Admin Interface Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #f5f5f5;
    color: #333;
    line-height: 1.6;
}

/* Login Page */
.login-page {
    background: linear-gradient(135deg, #981E20 0%, #F15622 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-container {
    width: 100%;
    max-width: 400px;
    padding: 20px;
}

.login-box {
    background: white;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.login-box h1 {
    text-align: center;
    margin-bottom: 30px;
    color: #333;
}

.login-form .form-group {
    margin-bottom: 20px;
}

.login-form label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
}

.login-form input {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
}

.login-form .btn {
    width: 100%;
    padding: 12px;
    background: #981E20;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
    transition: background 0.3s;
}

.login-form .btn:hover {
    background: #7a1819;
}

.login-info {
    margin-top: 30px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 4px;
    font-size: 14px;
}

.login-info p {
    margin-bottom: 5px;
}

/* Admin Layout */
.admin-header {
    background: white;
    padding: 20px;
    border-bottom: 1px solid #ddd;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.admin-header h1 {
    color: #981E20;
    font-size: 24px;
}

.user-info {
    color: #666;
}

.admin-container {
    display: flex;
    min-height: calc(100vh - 80px);
}

.admin-nav {
    width: 250px;
    background: white;
    border-right: 1px solid #ddd;
    padding: 20px 0;
}

.admin-nav a {
    display: block;
    padding: 12px 20px;
    color: #333;
    text-decoration: none;
    border-left: 3px solid transparent;
    transition: all 0.3s;
}

.admin-nav a:hover,
.admin-nav a.active {
    background: #f8f9fa;
    border-left-color: #981E20;
    color: #981E20;
}

.admin-nav a.logout {
    margin-top: 20px;
    border-top: 1px solid #ddd;
    padding-top: 20px;
    color: #dc3545;
}

.admin-content {
    flex: 1;
    padding: 30px;
    background: #f8f9fa;
}

/* Dashboard */
.dashboard-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.stat-card h3 {
    color: #666;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 10px;
}

.stat-number {
    font-size: 36px;
    font-weight: bold;
    color: #981E20;
    margin-bottom: 15px;
}

.stat-text {
    font-size: 18px;
    color: #333;
    margin-bottom: 15px;
}

.quick-actions {
    background: white;
    padding: 25px;
    border-radius: 8px;
    margin-bottom: 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.action-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.recent-pages {
    background: white;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.page-list {
    margin-top: 20px;
}

.page-item {
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    margin-bottom: 10px;
}

.page-item h4 {
    margin-bottom: 5px;
}

.page-meta {
    color: #666;
    font-size: 14px;
    margin-bottom: 10px;
}

/* Forms */
.admin-form {
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.form-section {
    margin-bottom: 30px;
}

.form-section h3 {
    color: #981E20;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f0f0f0;
}

.form-group {
    margin-bottom: 20px;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.form-group small {
    display: block;
    margin-top: 5px;
    color: #666;
    font-size: 12px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    width: auto;
    margin-right: 10px;
}

.form-actions {
    padding-top: 20px;
    border-top: 1px solid #ddd;
    display: flex;
    gap: 15px;
}

/* Buttons */
.btn,
.btn-primary,
.btn-secondary,
.btn-danger,
.btn-small {
    display: inline-block;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    text-decoration: none;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s;
    box-sizing: border-box;
    line-height: 1.5;
    vertical-align: middle;
}

.btn-primary {
    background: #981E20;
    color: white;
}

.btn-primary:hover {
    background: #7a1819;
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #5a6268;
}

.btn-danger {
    background: #dc3545;
    color: white;
}

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

.btn-small {
    padding: 5px 10px;
    font-size: 12px;
    line-height: 1.5;
    vertical-align: middle;
}

/* Tables */
.admin-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.admin-table th,
.admin-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

.admin-table th {
    background: #f8f9fa;
    font-weight: 600;
}

.admin-table tr:hover {
    background: #f8f9fa;
}

.status-badge {
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.status-badge.published {
    background: #d4edda;
    color: #155724;
}

.status-badge.draft {
    background: #fff3cd;
    color: #856404;
}

.action-buttons {
    display: flex;
    gap: 5px;
}

/* Alerts */
.alert {
    padding: 15px;
    border-radius: 4px;
    margin-bottom: 20px;
}

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

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

/* Page Editor */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.content-editor {
    font-family: 'Courier New', monospace;
    font-size: 14px;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #666;
}

.empty-state p {
    margin-bottom: 20px;
    font-size: 18px;
}

/* Responsive */
@media (max-width: 768px) {
    .admin-container {
        flex-direction: column;
    }
    
    .admin-nav {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid #ddd;
    }
    
    .admin-nav a {
        text-align: center;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .action-buttons {
        flex-direction: column;
    }
    
    .admin-table {
        font-size: 14px;
    }
    
    .admin-table th,
    .admin-table td {
        padding: 8px;
    }
}

/* Menu Management Styles */
.menu-items-container {
    min-height: 100px;
}

.empty-menu {
    text-align: center;
    padding: 40px;
    color: #666;
    background: #f9f9f9;
    border: 2px dashed #ddd;
    border-radius: 8px;
}

.menu-item {
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 10px;
    background: white;
    display: flex;
    align-items: center;
    gap: 15px;
    cursor: move;
    transition: all 0.2s ease;
}

.menu-item:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.menu-item.dragging {
    opacity: 0.5;
    transform: rotate(2deg);
}

.menu-item-handle {
    color: #999;
    cursor: grab;
    padding: 5px;
}

.menu-item-handle:active {
    cursor: grabbing;
}

.menu-item-preview {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 10px;
}

.menu-text {
    font-weight: 500;
    color: #333;
}

.menu-type-badge {
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.menu-type-badge.page {
    background: #e3f2fd;
    color: #1976d2;
}

.menu-type-badge.external {
    background: #f3e5f5;
    color: #7b1fa2;
}

.menu-item-actions {
    display: flex;
    gap: 5px;
}

.menu-item-form {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 20px;
    z-index: 10;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.new-menu-item {
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 20px;
    margin-top: 15px;
    background: #f9f9f9;
}

.menu-page-fields,
.menu-external-fields {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #eee;
} 