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

body {
    font-family: 'Georgia', 'Times New Roman', serif;
    background: linear-gradient(135deg, #e8e8e8 0%, #d4d4d4 100%);
    padding: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ========== НАВИГАЦИЯ ========== */
nav {
    background: linear-gradient(90deg, #1a1a2e, #16213e);
    padding: 15px 30px;
    margin-bottom: 30px;
    border-radius: 0;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
    align-items: center;
}

nav a {
    color: #e2e2e2;
    text-decoration: none;
    margin: 0;
    padding: 10px 20px;
    font-weight: 500;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    border-radius: 30px;
}

nav a:hover {
    background: #e94560;
    border-radius: 30px;
    transform: translateY(-2px);
}

nav span {
    color: white;
    font-weight: 500;
    padding: 10px 15px;
}

/* ========== КОНТЕЙНЕР ========== */
.container {
    max-width: 1300px;
    margin: 0 auto 40px auto;
    background: #ffffff;
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    flex: 1;
    width: 95%;
}

h1 {
    margin-bottom: 30px;
    color: #16213e;
    font-size: 2.2rem;
    text-align: center;
    position: relative;
    padding-bottom: 15px;
}

h1::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: #e94560;
    border-radius: 3px;
}

h2 {
    color: #16213e;
    margin: 25px 0 15px 0;
    font-size: 1.8rem;
}

/* ========== ФОРМЫ ========== */
form {
    max-width: 500px;
    margin: auto;
    background: #f8f9fa;
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
}

label {
    display: block;
    margin-top: 10px;
    margin-bottom: 5px;
    color: #16213e;
    font-weight: 500;
}

input, textarea, select {
    width: 100%;
    padding: 12px;
    margin: 8px 0 15px 0;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    font-family: inherit;
    transition: all 0.3s;
    font-size: 1rem;
    background: white;
}

input:focus, textarea:focus, select:focus {
    outline: none;
    border-color: #e94560;
    box-shadow: 0 0 0 3px rgba(233,69,96,0.1);
}

button {
    background: linear-gradient(90deg, #16213e, #1a1a2e);
    color: white;
    padding: 12px 25px;
    border: none;
    border-radius: 40px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: bold;
    transition: all 0.3s;
    width: 100%;
}

button:hover {
    background: linear-gradient(90deg, #e94560, #c73e56);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(233,69,96,0.3);
}

/* ========== СООБЩЕНИЯ ========== */
.message {
    padding: 12px 20px;
    margin: 15px 0;
    border-radius: 12px;
    font-weight: 500;
}

.success {
    background: #d4edda;
    color: #155724;
    border-left: 5px solid #28a745;
}

.error {
    background: #f8d7da;
    color: #721c24;
    border-left: 5px solid #dc3545;
}

/* ========== КАРТОЧКИ КУРСОВ ========== */
.products {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
    margin-top: 20px;
}

.product-card {
    border: none;
    padding: 0;
    border-radius: 15px;
    background: white;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.15);
}

.product-card h3 {
    margin: 0;
    padding: 20px 20px 10px 20px;
    font-size: 1.3rem;
    color: #16213e;
}

.price {
    font-size: 24px;
    color: #e94560;
    font-weight: bold;
    margin: 5px 0;
    padding: 0 20px;
}

.product-card p {
    padding: 0 20px 20px 20px;
    color: #666;
    line-height: 1.5;
    flex-grow: 1;
}

.product-card::before {
    content: '';
    display: block;
    height: 4px;
    background: linear-gradient(90deg, #16213e, #e94560);
}

.btn-order {
    display: inline-block;
    background: linear-gradient(90deg, #16213e, #1a1a2e);
    color: white;
    padding: 10px 20px;
    margin: 0 20px 20px 20px;
    border-radius: 30px;
    text-decoration: none;
    text-align: center;
    transition: all 0.3s;
}

.btn-order:hover {
    background: linear-gradient(90deg, #e94560, #c73e56);
    transform: translateY(-2px);
}

/* ========== КАРТОЧКИ ЗАЯВОК (КАБИНЕТ) ========== */
.app-card, .admin-card {
    background: #f9f9f9;
    margin: 15px 0;
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    border-left: 4px solid #e94560;
    transition: all 0.3s;
}

.app-card:hover, .admin-card:hover {
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

/* Статусы заявок */
.status-Новая {
    color: #ff9800;
    font-weight: bold;
}

.status-Идётобучение {
    color: #2196f3;
    font-weight: bold;
}

.status-Обучениезавершено {
    color: #4caf50;
    font-weight: bold;
}

/* ========== СЛАЙДЕР ========== */
.slider-container {
    position: relative;
    max-width: 600px;
    margin: 20px auto;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
}

.slider {
    width: 100%;
    overflow: hidden;
}

.slides img {
    width: 100%;
    display: none;
    border-radius: 15px;
    height: auto;
    object-fit: cover;
}

.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,0.6);
    color: white;
    border: none;
    padding: 12px 18px;
    cursor: pointer;
    font-size: 18px;
    border-radius: 50%;
    transition: all 0.3s;
    width: auto;
}

.slider-btn:hover {
    background: #e94560;
    transform: translateY(-50%) scale(1.1);
}

.prev {
    left: 10px;
}

.next {
    right: 10px;
}

/* ========== АДМИН-ПАНЕЛЬ ========== */
.admin-filters {
    background: #f0f0f0;
    padding: 20px;
    border-radius: 15px;
    margin-bottom: 25px;
}

.admin-filters form {
    max-width: 100%;
    padding: 0;
    background: transparent;
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    align-items: flex-end;
}

.admin-filters select, .admin-filters button {
    width: auto;
    margin: 0;
}

.pagination {
    margin-top: 30px;
    text-align: center;
    display: flex;
    justify-content: center;
    gap: 8px;
    flex-wrap: wrap;
}

.pagination a {
    display: inline-block;
    padding: 8px 14px;
    background: #16213e;
    color: white;
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.3s;
}

.pagination a:hover {
    background: #e94560;
    transform: translateY(-2px);
}

/* Кнопка смены статуса в админке */
.admin-card form {
    max-width: 100%;
    padding: 0;
    background: transparent;
    margin-top: 10px;
    display: inline-block;
}

.admin-card select {
    width: auto;
    display: inline-block;
    margin-right: 10px;
}

.admin-card button {
    width: auto;
    display: inline-block;
    padding: 8px 20px;
}

/* ========== ФУТЕР ========== */
footer {
    background: #0a0a0a;
    color: #e0e0e0;
    padding: 40px 20px 20px 20px;
    margin-top: auto;
    border-top: 1px solid #333;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-bottom: 30px;
}

.footer-section h3 {
    color: #e94560;
    margin-bottom: 15px;
    font-size: 1.2rem;
}

.footer-section h4 {
    color: #ccc;
    margin-bottom: 15px;
    font-size: 1rem;
}

.footer-section p {
    color: #999;
    line-height: 1.6;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 10px;
}

.footer-section ul li a {
    color: #999;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-section ul li a:hover {
    color: #e94560;
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    color: #999;
    text-decoration: none;
    transition: color 0.3s;
}

.social-links a:hover {
    color: #e94560;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #222;
    color: #666;
    font-size: 0.9rem;
}

/* ========== АДАПТИВНОСТЬ (390x844 и мобильные) ========== */
@media (max-width: 768px) {
    nav {
        flex-direction: column;
        align-items: center;
        gap: 8px;
        padding: 12px 20px;
    }
    
    nav a, nav span {
        padding: 8px 16px;
        font-size: 1rem;
    }
    
    .container {
        padding: 20px;
        margin: 0 10px 30px 10px;
        width: auto;
    }
    
    h1 {
        font-size: 1.8rem;
    }
    
    h2 {
        font-size: 1.5rem;
    }
    
    .products {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    form {
        padding: 20px;
        margin: 0;
    }
    
    .slider-container {
        max-width: 100%;
    }
    
    .slider-btn {
        padding: 8px 12px;
        font-size: 14px;
    }
    
    .admin-filters form {
        flex-direction: column;
        align-items: stretch;
    }
    
    .admin-filters select, 
    .admin-filters button,
    .admin-card select,
    .admin-card button {
        width: 100%;
        margin-bottom: 10px;
    }
    
    .app-card, .admin-card {
        padding: 15px;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .social-links {
        justify-content: center;
    }
}

/* для очень маленьких экранов (390px) */
@media (max-width: 480px) {
    .container {
        padding: 15px;
    }
    
    h1 {
        font-size: 1.5rem;
    }
    
    .price {
        font-size: 20px;
    }
    
    button {
        padding: 10px 20px;
    }
}

/* ========== ВСПОМОГАТЕЛЬНЫЕ КЛАССЫ ========== */
.text-center {
    text-align: center;
}

.mt-20 {
    margin-top: 20px;
}

.mb-20 {
    margin-bottom: 20px;
}

.btn {
    background: #e94560;
    color: white;
    padding: 10px 20px;
    border-radius: 30px;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s;
}

.btn:hover {
    background: #c73e56;
    transform: translateY(-2px);
}