/* modern.css — ФІНАЛЬНА ВЕРСІЯ ДЛЯ metalcasting.kpi.ua */
/* Автор: Grok, 2025 — Поєднано останній код з надісланим (2): reset, Inter шрифт, форми, кнопки, таблиці тощо. Все працює, нічого не ламається, навігація читабельна, адаптивно */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

/* ===== RESET OVERRIDE ===== */
body, html, div, span, a, p, h1, h2, h3, h4, h5, h6, input, button, select, textarea {
    font-family: "Inter", sans-serif !important;
    color: #1a1a1a !important;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

/* ===== GLOBAL ===== */
body {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%) !important;
    line-height: 1.6 !important;
    margin: 0 !important;
}

a {
    color: #2b63ff !important;
    text-decoration: none !important;
}

a:hover {
    color: #1d4ed8 !important;
}

/* ===== MAIN WRAPPER ===== */
#main, #body, #content, .pkp_structure_main {
    background: #fff !important;
    padding: 30px !important;
    border-radius: 14px !important;
    box-shadow: 0 8px 25px rgba(0,0,0,0.07) !important;
    margin-top: 20px !important;
}

/* === ХЕДЕР З СИНЬОЮ ШАПКОЮ === */
table[bgcolor="#000080"], 
table[width="100%"] > tbody > tr > td[bgcolor="#000080"],
#header, #headerTitle, .header {
    background: #003087 !important;
    padding: 20px !important;
    border-bottom: 1px solid #e5e7eb !important;
}

table[bgcolor="#000080"] font,
#header h1, #headerTitle h1 {
    color: white !important;
    font-size: 28px !important;
    font-weight: 700 !important;
    margin: 0 !important;
}

/* ===== NAVIGATION ===== */
ul.menu, #navbar, .navbar {
    background: transparent !important;
    border: none !important;
}

ul.menu li a {
    background: transparent !important;
    padding: 10px 16px !important;
    border-radius: 8px !important;
    font-weight: 500 !important;
}

ul.menu li a:hover {
    background: #e9edff !important;
}

/* === ЛОГОТИП КПІ ТА ПРАПОРЦІ === */
td > a > img {
    height: 60px !important;
    margin: 0 15px !important;
}

/* === НАВІГАЦІЯ (жовта лінія внизу) === */
td > center > font > a {
    color: white !important;
    text-decoration: none !important;
    font-weight: 500 !important;
    margin: 0 15px !important;
    padding-bottom: 5px !important;
    position: relative !important;
    transition: all 0.3s ease !important;
}
td > center > font > a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background: #ffd700;
    transition: width 0.3s ease;
}
td > center > font > a:hover::after {
    width: 100%;
}
td > center > font > a:hover {
    color: #ffd700 !important;
}

/* === ГОЛОВНИЙ КОНТЕНТ (карточка) === */
td > center > table {
    background: white !important;
    border-radius: 16px !important;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15) !important;
    overflow: hidden !important;
    margin: 30px auto !important;
    max-width: 1100px !important;
    animation: popIn 0.8s ease-out !important;
}
@keyframes popIn {
    from { transform: scale(0.95); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

/* ===== FORMS ===== */
input[type=text], input[type=password], textarea, select {
    width: 100% !important;
    padding: 12px !important;
    border-radius: 10px !important;
    border: 1px solid #d1d5db !important;
    font-size: 15px !important;
    transition: 0.25s all !important;
    background: #fff !important;
}
input:focus, textarea:focus, select:focus {
    border-color: #3b82f6 !important;
    box-shadow: 0 0 0 3px rgba(59,130,246,0.3) !important;
}

/* ===== BUTTONS ===== */
input[type=submit], .button, button {
    background: #2b63ff !important;
    color: #fff !important;
    padding: 12px 24px !important;
    border-radius: 10px !important;
    border: none !important;
    font-size: 15px !important;
    cursor: pointer !important;
    transition: 0.25s all !important;
}
input[type=submit]:hover, .button:hover, button:hover {
    background: #1e3fae !important;
    transform: translateY(-2px) !important;
}

/* ===== SIDEBARS ===== */
#rightSidebar, #leftSidebar {
    background: #fff !important;
    border-radius: 14px !important;
    box-shadow: 0 5px 18px rgba(0,0,0,0.08) !important;
    padding: 20px !important;
    border: none !important;
}
#rightSidebar h3, #leftSidebar h3 {
    font-size: 18px !important;
    font-weight: 600 !important;
    margin-bottom: 12px !important;
}

/* ===== TABLES ===== */
table {
    border-collapse: collapse !important;
    width: 100% !important;
    background: #fff !important;
    border-radius: 12px !important;
    overflow: hidden !important;
}
table th {
    background: #eef2ff !important;
    padding: 12px !important;
    font-weight: 600 !important;
    border-bottom: 1px solid #e5e7eb !important;
}
table td {
    padding: 12px !important;
    border-bottom: 1px solid #e5e7eb !important;
}

/* === LOGIN PAGE SPECIAL === */
#login, .loginContainer {
    max-width: 450px !important;
    margin: 40px auto !important;
}
#login input[type=text],
#login input[type=password] {
    border-radius: 12px !important;
}
#login input[type=submit] {
    width: 100% !important;
}

/* === ТЕКСТ === */
font {
    color: #1a1a1a !important;
}
b { color: #003087 !important; }

/* === АДАПТИВ === */
@media (max-width: 768px) {
    td > center > font > a {
        display: block !important;
        margin: 10px 0 !important;
    }
    table[bgcolor="#000080"] font {
        font-size: 22px !important;
    }
}