/* Основные стили */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

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

/* Заголовки */
h1 {
    color: #333;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #007bff;
}

h2 {
    color: #444;
    margin-bottom: 20px;
}

/* Сообщения */
.message {
    padding: 12px 15px;
    margin: 15px 0;
    border-radius: 4px;
    font-weight: 500;
}

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

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

/* Информация о пользователе */
.user-info {
    background: #e9ecef;
    padding: 12px 15px;
    border-radius: 4px;
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logout-btn {
    color: #dc3545;
    text-decoration: none;
    padding: 5px 10px;
    border-radius: 4px;
}

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

/* Таблица сайтов */
.sites-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    background: white;
}

.sites-table th {
    background: #007bff;
    color: white;
    padding: 12px;
    text-align: left;
    font-weight: 600;
}

.sites-table td {
    padding: 10px 12px;
    border-bottom: 1px solid #ddd;
}

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

/* Кнопки и ссылки */
.btn {
    display: inline-block;
    padding: 10px 20px;
    background: #007bff;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    text-decoration: none;
    transition: background 0.3s;
}

.btn:hover {
    background: #0056b3;
}

.btn-add {
    background: #28a745;
}

.btn-add:hover {
    background: #218838;
}

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

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

.btn-edit {
    color: #007bff;
    text-decoration: none;
}

.btn-edit:hover {
    text-decoration: underline;
}

/* Заголовок дашборда */
.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

/* Пустое состояние */
.empty-state {
    text-align: center;
    padding: 40px;
    background: #f8f9fa;
    border-radius: 4px;
}

.empty-state p {
    font-size: 16px;
    color: #666;
    margin-bottom: 20px;
}

/* Формы */
.form {
    max-width: 600px;
}

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

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

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="password"],
.form-group input[type="number"],
.form-group select {
    padding: 8px 12px;
    width: 100%;
    max-width: 400px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 2px rgba(0,123,255,0.25);
}

.form-actions {
    margin-top: 30px;
    display: flex;
    gap: 10px;
    align-items: center;
}

.note {
    color: #666;
    font-size: 12px;
    margin-top: 5px;
}

/* Ссылки */
a {
    color: #007bff;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* Футер */
footer {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid #ddd;
    text-align: center;
    color: #666;
    font-size: 14px;
}

/* Адаптивность */
@media (max-width: 768px) {
    .container {
        margin: 10px;
        padding: 15px;
    }
    
    .sites-table {
        font-size: 14px;
    }
    
    .sites-table th,
    .sites-table td {
        padding: 8px;
    }
    
    .dashboard-header {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }
}
/* Обновим стили для user-info */
.user-info {
    background: #e9ecef;
    padding: 12px 15px;
    border-radius: 4px;
    margin-bottom: 20px;
}

.user-links {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.user-links strong {
    color: #333;
}

.docs-link {
    color: #17a2b8;
    text-decoration: none;
    padding: 5px 10px;
    border-radius: 4px;
    transition: all 0.3s;
}

.docs-link:hover {
    background: #17a2b8;
    color: white;
    text-decoration: none;
}

.logout-btn {
    color: #dc3545;
    text-decoration: none;
    padding: 5px 10px;
    border-radius: 4px;
    transition: all 0.3s;
}

.logout-btn:hover {
    background: #dc3545;
    color: white;
    text-decoration: none;
}

/* Стили для документации */
.docs-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 20px;
}

.docs-section {
    margin-bottom: 30px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #007bff;
}

.docs-section h3 {
    color: #007bff;
    margin-bottom: 15px;
    font-size: 1.3em;
}

.docs-section h4 {
    color: #17a2b8;
    margin: 15px 0 10px;
}

.docs-section ul, .docs-section ol {
    margin-left: 20px;
    line-height: 1.8;
}

.docs-section li {
    margin-bottom: 8px;
}

.docs-note {
    background: #fff3cd;
    border: 1px solid #ffeeba;
    color: #856404;
    padding: 15px;
    border-radius: 4px;
    margin: 15px 0;
}

.docs-tip {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
    padding: 15px;
    border-radius: 4px;
    margin: 15px 0;
}

.docs-table {
    width: 100%;
    border-collapse: collapse;
    margin: 15px 0;
}

.docs-table th {
    background: #007bff;
    color: white;
    padding: 10px;
    text-align: left;
}

.docs-table td {
    padding: 10px;
    border-bottom: 1px solid #ddd;
}

.docs-table tr:hover {
    background: #f5f5f5;
}

.docs-code {
    background: #272822;
    color: #f8f8f2;
    padding: 15px;
    border-radius: 4px;
    font-family: monospace;
    overflow-x: auto;
    margin: 10px 0;
}

.docs-badge {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: bold;
    margin-right: 5px;
}

.badge-success {
    background: #28a745;
    color: white;
}

.badge-warning {
    background: #ffc107;
    color: #333;
}

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

.badge-info {
    background: #17a2b8;
    color: white;
}
.ping-enabled {
    color: #28a745;
    font-weight: bold;
    font-size: 1.2em;
}

.ping-disabled {
    color: #dc3545;
    font-weight: bold;
    font-size: 1.2em;
}

/* Альтернативный вариант с эмодзи */
.ping-enabled {
    color: #28a745;
}

.ping-disabled {
    color: #dc3545;
}

/* Для отображения времени отклика */
.ping-enabled span {
    font-size: 0.9em;
    color: #666;
    margin-left: 5px;
}
.check-yes {
    color: #28a745;  /* зеленый для галочек */
}

.check-no {
    color: #dc3545;  /* красный для крестиков */
}

.ping-time {
    color: inherit;  /* наследует цвет от родителя (обычный текст) */
    font-weight: normal;
    font-size: inherit;
}
.ssl-date {
    color: inherit;
    font-weight: normal;
    font-size: inherit;
    margin-left: 5px;
}
.sites-grid{
display:grid;
grid-template-columns:repeat(auto-fill,minmax(260px,1fr));
gap:16px;
margin-top:20px;
}

.site-card{
background:#fff;
border:1px solid #e5e5e5;
border-radius:10px;
padding:16px;
box-shadow:0 2px 6px rgba(0,0,0,0.05);
}

.site-title{
font-weight:600;
font-size:16px;
margin-bottom:10px;
}

.site-status{
font-size:14px;
}

.status-line{
display:flex;
justify-content:space-between;
padding:3px 0;
}

.ok{
color:#1a9c38;
font-weight:500;
}

.off{
color:#999;
}

.site-footer{
margin-top:10px;
padding-top:10px;
border-top:1px solid #eee;
display:flex;
justify-content:space-between;
align-items:center;
font-size:13px;
}

.btn-edit{
text-decoration:none;
font-size:13px;
color:#555;
}

.btn-edit:hover{
color:#000;
}
