/* Buat tinggi halaman minimal penuh layar */
html, body {
    height: 100%;
    margin: 0;
    padding: 0;
}

/* Gunakan Flexbox agar body mengatur isi dan footer secara otomatis */
body {
    display: flex;
    flex-direction: column;
    background-color: #f4f6f9;
    color: #333333;
    font-family: Arial, sans-serif;
}

header {
    background-color: #ffffff;
    padding: 15px 20px;
    border-bottom: 4px solid #d32f2f;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

header h1 {
    margin: 0;
    color: #d32f2f;
    font-size: 22px;
}

.menu-toggle {
    display: none;
    background: none;
    border: none;
    color: #d32f2f;
    font-size: 24px;
    cursor: pointer;
}

nav {
    display: flex;
    gap: 5px;
}

nav a {
    color: #555555;
    text-decoration: none;
    font-size: 13px;
    padding: 6px 10px;
    border-radius: 4px;
    transition: 0.2s;
    font-weight: 500;
}

nav a:hover, nav a.active {
    background-color: #d32f2f;
    color: white;
}

/* Container flex-grow agar konten mendorong footer ke bawah jika layar kosong */
.container {
    width: 90%;
    max-width: 800px;
    margin: 30px auto;
    background-color: #ffffff;
    padding: 25px;
    border-radius: 6px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.08);
    border-top: 3px solid #d32f2f;
    flex: 1; /* KUNCI UTAMA: Membuat container mengisi ruang kosong */
}

h2 {
    color: #d32f2f;
    border-bottom: 1px solid #eeeeee;
    padding-bottom: 8px;
    margin-top: 0;
    font-size: 20px;
}

p, ul {
    color: #444444;
    line-height: 1.6;
    font-size: 14px;
}

ul {
    padding-left: 20px;
}

ul li {
    margin-bottom: 6px;
}

.btn {
    display: inline-block;
    background-color: #d32f2f;
    color: white;
    padding: 8px 16px;
    text-decoration: none;
    border-radius: 4px;
    margin-top: 10px;
    font-weight: bold;
    transition: 0.2s;
}

.btn:hover {
    background-color: #b71c1c;
}

form label {
    display: block;
    margin-top: 12px;
    font-size: 14px;
    color: #333333;
    font-weight: bold;
}

form input, form textarea {
    width: 100%;
    padding: 10px;
    margin-top: 5px;
    background-color: #fafafa;
    border: 1px solid #cccccc;
    color: #333333;
    border-radius: 4px;
    box-sizing: border-box;
}

form input:focus, form textarea:focus {
    border-color: #d32f2f;
    outline: none;
    background-color: #ffffff;
}

form button {
    background-color: #d32f2f;
    color: white;
    border: none;
    padding: 10px 15px;
    margin-top: 15px;
    cursor: pointer;
    border-radius: 4px;
    width: 100%;
    font-size: 14px;
    font-weight: bold;
    transition: 0.2s;
}

form button:hover {
    background-color: #b71c1c;
}

/* Footer otomatis menempel di bawah */
footer {
    text-align: center;
    padding: 20px;
    color: #777777;
    font-size: 12px;
    border-top: 1px solid #dddddd;
    background-color: #ffffff;
    width: 100%;
}

/* ==========================================
   MEDIA QUERIES (Tampilan HP / Layar Sempit)
   ========================================== */
@media screen and (max-width: 768px) {
    header {
        justify-content: flex-start;
        gap: 15px;
    }

    .menu-toggle {
        display: block;
    }

    nav {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 65px;
        left: 0;
        background-color: #ffffff;
        width: 220px;
        padding: 10px;
        border: 1px solid #ddd;
        border-bottom: 3px solid #d32f2f;
        box-shadow: 2px 5px 10px rgba(0,0,0,0.1);
        z-index: 1000;
    }

    nav.active-menu {
        display: flex;
    }

    nav a {
        padding: 10px;
        font-size: 14px;
        border-bottom: 1px solid #f0f0f0;
        color: #333;
    }

    .container {
        width: 95%;
        padding: 15px;
    }
}