* { margin: 0; padding: 0; box-sizing: border-box; }
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f0f2f5;
    color: #333;
    line-height: 1.7;
    padding: 0;
}

.menu-bar {
    background-color: #243342;
    padding: 10px 20px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    position: sticky;
    top: 0;
    z-index: 1000;
    align-items: center;
}

.menu-left {
    color: #ecf0f1;
    margin-right: 20px;
    padding-right: 20px;
    border-right: 1px solid rgba(255,255,255,0.2);
    display: flex;
    flex-direction: column;
}

.menu-left .general-title {
    font-size: 0.7rem;
    text-transform: uppercase;
    opacity: 0.7;
    letter-spacing: 1px;
    line-height: 1.2;
}

.menu-left .specific-title {
    font-size: 0.85rem;
    font-weight: bold;
    line-height: 1.3;
}

.menu-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    flex: 1;
}

.menu-links a {
    color: #ecf0f1;
    text-decoration: none;
    padding: 6px 14px;
    font-size: 0.9em;
    transition: background-color 0.3s;
    white-space: nowrap;
}

.menu-links a:hover { background-color: #e74c3c; }
.menu-links a.active { background-color: #e74c3c; font-weight: bold; }

.slide {
    width: 80%;
    margin: 30px auto;
    background: #f9f9f9;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.slide .header {
    background-color: #364d63;
    color: white;
    padding: 14px 24px;
    display: flex;
    align-items: center;
    gap: 16px;
}

.slide .header .slide-number {
    background-color: #e74c3c;
    padding: 4px 14px;
    font-weight: bold;
    font-size: 0.95em;
    white-space: nowrap;
    flex-shrink: 0;
}

.slide .header .slide-title {
    font-size: 1.15em;
    font-weight: 600;
    border-bottom: 2px solid #e74c3c;
    padding-bottom: 4px;
}

.content-wrapper {
    display: flex;
    flex-wrap: wrap;
    padding: 24px;
    gap: 24px;
}

.content-text {
    flex: 3;
    min-width: 300px;
    max-width: 100%;
    font-size: 15px;
    line-height: 1.8;
    color: #444;
}

.content-text h3 {
    color: #2c3e50;
    margin-bottom: 12px;
    font-size: 1.15em;
}
.content-text p {
    margin-bottom: 10px;
    text-align: justify;
}
.content-text ul, .content-text ol {
    margin: 10px 0 10px 20px;
}

.content-text li {
    margin-bottom: 8px;
}

.content-text strong { color: #2c3e50; }
.content-text em { color: #e74c3c; }

.content-image {
    flex: 2;
    min-width: 250px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.content-image img {
    max-width: 100%;
    height: auto;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    transition: opacity 0.3s;
}

.content-image img:hover { opacity: 0.85; }

.slide_ext { background-color: #eef5fa; padding: 24px 24px; padding-right: 20%; border-top: 2px solid #2c3e50; display: none; }
.slide_ext p { margin-bottom: 8px; font-size: 0.95em; text-align: justify; }
.slide_ext.hidden { display: block; }
.toggle-ext-btn { margin-left: auto; background: #e74c3c; color: #fff; border: none; padding: 6px 14px; cursor: pointer; font-size: 0.9em; }

.slide.no-illustration .content-wrapper {
    justify-content: center;
}

.slide.no-illustration .content-text {
    flex: 1;
    max-width: 100%;
}

@media (max-width: 768px) {
    .content-wrapper { flex-direction: column; }
    .content-image { order: -1; }
    .menu-links a { padding: 6px 10px; font-size: 0.8em; }
}

/* ===== SIDEBAR (index.html) ===== */

body.index-page {
    display: flex;
    min-height: 100vh;
    background-color: #f4f7f6;
}

.sidebar {
    width: 400px;
    background-color: #1a1a2e;
    color: white;
    padding: 20px;
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    overflow-y: auto;
    top: 0;
    left: 0;
}

.sidebar h1 {
    font-size: 20px;
    margin-bottom: 10px;
    text-align: center;
    border-bottom: 1px solid #0f3460;
    padding-bottom: 15px;
    color: #e94560;
}

.sidebar .subtitle {
    font-size: 12px;
    text-align: center;
    color: #888;
    margin-bottom: 25px;
}

.menu {
    list-style-type: none;
    padding: 0;
    margin: 0;
}

.menu li { margin-bottom: 8px; }

.menu a {
    display: block;
    padding: 12px 15px;
    color: #ecf0f1;
    text-decoration: none;
    background-color: #0f3460;
    transition: background-color 0.3s;
    font-size: 0.9em;
}

.menu a:hover { background-color: #e94560; }

.menu .num {
    font-weight: bold;
    color: #e94560;
    margin-right: 6px;
}

.menu a:hover .num { color: #fff; }

.content-area {
    flex: 1;
    padding: 40px;
    margin-left: 400px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.welcome-box {
    background-color: white;
    padding: 40px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    max-width: 800px;
    width: 100%;
}

.welcome-box h2 {
    color: #1a1a2e;
    margin-bottom: 8px;
}

.welcome-box h3 {
    color: #0f3460;
    margin-top: 0;
    margin-bottom: 20px;
    font-weight: normal;
    border-bottom: 2px solid #e94560;
    padding-bottom: 10px;
}

.welcome-box p {
    font-size: 16px;
    line-height: 1.8;
    color: #555;
    margin-bottom: 14px;
}

.footer {
    margin-top: auto;
    text-align: center;
    padding-top: 20px;
    font-size: 0.85em;
    color: #7f8c8d;
    border-top: 1px solid #0f3460;
    padding-bottom: 20px;
    margin-bottom: 25px;
}

.footer a { color: #7f8c8d; text-decoration: none; }

.section-label {
    margin-top: 20px;
    color: #e94560;
}

@media (max-width: 768px) {
    .sidebar { width: 100%; position: relative; height: auto; }
    .content-area { margin-left: 0; padding: 20px; }
}

/* ===== SLIDE PAGE: no flex on body ===== */

body:not(.index-page) {
    background-color: #f0f2f5;
    line-height: 1.7;
}
