html,
body {
  height: 100%;
}

body {
  background-color: #f8f9fa;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
   padding-top: 20px;
}
.success-card {
            min-width: 500px;
            max-width: 640px; /* идеально для Full HD: не растянуто, но и не мелкое */
            margin-top: 100px; /* отступ сверху, чтобы не прилипало к header */
        }
        .big-ok {
            font-size: 3.5rem;
            color: #198754; /* success green из Bootstrap */
            line-height: 1;
        }
        .timer-text {
            font-size: 1.1rem;
            color: #6c757d;
            margin-top: 20px;
        }
        .countdown {
            display: inline-block;
            font-weight: 700;
            color: #dc3545;
        }
main {
  flex: 1;
} 
  .modal-content {
    border-radius: 12px;
  }

a .card:hover {
    transform: translateY(-2px);
    transition: transform 0.15s ease;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.1) !important;
}
  
  .value-number {
    font-size: 2.5rem;
    font-weight: 600;
  }
.numpad-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.55);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.numpad-panel {
    background: #fff;
    padding: 12px;
    border-radius: 10px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
    width: 300px;
    max-width: 95vw;
    border: 1px solid #e0e0e0;
}

.numpad-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.numpad-display {
    font-family: monospace;
    font-size: 1.4rem;
    text-align: right;
    min-height: 48px;
    line-height: 48px;
    border: 1px solid #ced4da;
    background: #f1f3f5;
    padding: 0 12px;
    border-radius: 6px;
    color: #212529;
}

.numpad-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}

.numpad-btn {
    padding: 14px 8px;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    border: 1px solid #dee2e6;
    background: #fff;
    color: #495057;
}

.numpad-btn:active {
    transform: scale(0.96);
    background: #e9ecef;
}

.numpad-btn.enter {
    background: #0d6efd;
    color: #fff;
    border-color: #0d6efd;
}
.numpad-btn.delete {
    border-color: #dc3545;
}

/* Стили для кнопки-иконки рядом с полем */
.numpad-trigger-btn {
    border: 1px solid #ccc;
    background: #f8f9fa;
    color: #555;
    padding: 6px 10px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.15s ease;
}
.numpad-trigger-btn:hover {
    background: #e2e6ea;
    border-color: #adb5bd;
}

.card {
            transition: all 0.3s ease;
        }
        /* Подсветка подходящей схемы */
        .scheme-card.highlighted {
            border: 2px solid #0d6efd;
            box-shadow: 0 0 12px rgba(13, 110, 237, 0.4);
            transform: scale(1.01);
        }
        /* Приглушение неподходящих схем (опционально) */
        .scheme-card:not(.highlighted) {
            opacity: 0.7;
            transition: opacity 0.3s, border 0.3s;
        }
        /* Превью: фиксированная высота, заполнение по ширине */
        .preview-img {
            object-fit: cover;
            height: 240px;
            width: 100%;
            display: block;
        }
        /* Подпись поверх превью */
        .code-overlay {
            position: absolute;
            bottom: 0;
            left: 0;
            right: 0;
            background: rgba(0, 0, 0, 0.65);
            color: #fff;
            padding: 6px 12px;
            font-weight: 600;
            font-size: 0.95rem;
        }
        .birthday-banner {
            background-color: #fff3cd;
            border-left: 5px solid #ffc107;
            color: #856404;
            padding: 12px 15px;
            font-size: 25px;
            margin-bottom: 10px;
            font-family: inherit;
            border-radius: 8px;
}

.birthday-banner .btn-close {
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.2s;
}

.birthday-banner .btn-close:hover {
    opacity: 1;
}

thead th {
    white-space: nowrap;
    text-align: center;
    vertical-align: middle;
    font-size: 0.85rem;
    padding: 10px 12px;
}

/* Ячейки с датами: фиксируем минимальную ширину */
.exam-table-cell {
    min-width: 180px !important;
    font-size: 1rem;
}

/* Контент внутри ячейки (дата + бейдж) */
.exam-cell-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    gap: 6px;
}

.exam-date-value {
    font-weight: 700;
    display: block;
}

/* --- Стили для игры 2048  --- */

/* Кнопки-стрелки: 75×75 px — удобно попадать мышкой на 21" мониторе */
.game-btn-control {
    width: 75px;
    height: 75px;
    font-size: 28px;
    border-width: 2px;
    border-radius: 10px;
}

/* Кнопка «Начать заново» — крупная, но не гигантская */
.game-btn-restart {
    padding: 16px 20px;
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 0.5px;
}

/* Клетки игрового поля: 90×90 px — читаемо и компактно */
.grid div {
    width: 90px;
    height: 90px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 26px;
    font-weight: bold;
    color: #333;
    background-color: #afa192;
    transition: background-color 0.1s ease, transform 0.05s ease;
}

.grid div:active {
    transform: scale(0.98);
}