/* style.css */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    background: #f5f5f5;
    color: #0a2a66;
}

.container, .login-container {
    max-width: 1200px;
    margin: 20px auto;
    padding: 20px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.login-container {
    max-width: 400px;
    margin: 100px auto;
}

h1, h2 {
    color: #0a2a66;
    margin-bottom: 20px;
}

.title-orange {
    color: #ff6b35;
}

/* Формы */
.form-group {
    margin-bottom: 15px;
}

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

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

.form-row {
    display: flex;
    gap: 20px;
    margin-bottom: 15px;
}

.form-row .form-group {
    flex: 1;
}

/* Кнопки */
.btn, button[type="submit"] {
    background: #4CAF50;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    text-decoration: none;
    display: inline-block;
}

.btn:hover, button[type="submit"]:hover {
    background: #45a049;
}

.btn-small {
    background: #2196F3;
    color: white;
    padding: 5px 10px;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    font-size: 12px;
    text-decoration: none;
    display: inline-block;
    margin: 2px;
}

.btn-small:hover {
    background: #1976D2;
}

/* Таблицы */
.table-responsive {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

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

th {
    background: #f8f9fa;
    font-weight: bold;
}

tr:hover {
    background: #f5f5f5;
}

/* Статусы */
.status-badge {
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 12px;
    font-weight: bold;
    display: inline-block;
}

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

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

.status-expired {
    background: #f8d7da;
    color: #721c24;
}

/* Карточка публичного просмотра */
.public-card .card {
    border: 1px solid #ddd;
    padding: 30px;
    border-radius: 8px;
    margin-top: 20px;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 2px solid #4CAF50;
}

.qr-section {
    text-align: center;
    margin: 30px 0;
}

.qr-image {
    width: 200px;
    height: 200px;
    border: 1px solid #ddd;
    padding: 10px;
    background: white;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin: 30px 0;
}

.info-item {
    padding: 10px;
    background: #f9f9f9;
    border-radius: 4px;
}

.info-item.full-width {
    grid-column: span 2;
}

.info-item .label {
    font-weight: bold;
    color: #666;
    margin-bottom: 5px;
}

.info-item .value {
    font-size: 16px;
}

.footer-note {
    text-align: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #ddd;
    color: #666;
    font-style: italic;
}

/* Сообщения */
.error, .success {
    padding: 10px 15px;
    margin-bottom: 20px;
    border-radius: 4px;
}

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

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

/* Шапка админки */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid #0a2a66;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* Мобильная адаптация */
@media (max-width: 768px) {
    .container, .login-container {
        margin: 10px;
        padding: 15px;
    }
    
    .form-row {
        flex-direction: column;
        gap: 0;
    }
    
    .info-grid {
        grid-template-columns: 1fr;
    }
    
    .info-item.full-width {
        grid-column: span 1;
    }
    
    .card-header {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
    
    table {
        font-size: 14px;
    }
    
    th, td {
        padding: 8px;
    }
    
    .btn-small {
        padding: 3px 6px;
        font-size: 10px;
    }
}

/* Печать */
@media print {
    .btn, .btn-small, .print-button, .no-print {
        display: none !important;
    }
    
    .container {
        margin: 0;
        padding: 0;
        box-shadow: none;
    }
    
    .card {
        border: none;
    }
}
