/* ============================================
   GLOBAL STYLE & STYLE PORTRAIT (Default)
   ============================================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: #f4f4f4;
    padding: 15px;
    min-height: 100vh;
}

.container {
    max-width: 100%;
    margin: 0 auto;
    background: white;
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 0 15px rgba(0,0,0,0.1);
}

h1 {
    text-align: center;
    color: #333;
    margin-bottom: 20px;
    font-size: 22px;
}

/* --- STYLE PORTRAIT --- */
.upload-section {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 25px;
    border: 1px dashed #ccc;
}

.upload-section h3 {
    margin-bottom: 15px;
    color: #444;
    font-size: 16px;
}

.upload-section form {
    display: flex;
    flex-direction: column; /* Susunan Vertikal */
    gap: 12px;
}

input[type="file"] {
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    background: white;
    font-size: 14px;
    width: 100%;
}

button {
    padding: 12px;
    background: #007bff;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
    font-size: 16px;
    transition: background 0.3s;
}

button:hover {
    background: #0056b3;
}

.file-list h3 {
    margin-bottom: 12px;
    color: #444;
    font-size: 16px;
}

.table-wrapper {
    overflow-x: auto; /* Scroll horizontal jika konten kepanjangan */
    border-radius: 10px;
    border: 1px solid #eee;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th, td {
    padding: 12px 10px;
    text-align: left;
    font-size: 14px;
    border-bottom: 1px solid #eee;
}

th {
    background-color: #007bff;
    color: white;
    white-space: nowrap;
}

.actions {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
}

.btn {
    padding: 6px 8px;
    text-decoration: none;
    border-radius: 6px;
    color: white;
    font-size: 11px; /* Lebih kecil di portrait */
    white-space: nowrap;
}

.view { background: #17a2b8; }
.download { background: #28a745; }
.delete { background: #dc3545; }

.btn:hover {
    opacity: 0.8;
}

/* ============================================
   STYLE LANDSCAPE / LAYAR LEBAR
   ============================================ */
@media screen and (min-width: 768px) and (orientation: landscape),
       screen and (min-width: 992px) {

    body {
        padding: 30px;
    }

    .container {
        max-width: 900px;
        padding: 35px;
    }

    h1 {
        font-size: 28px;
        margin-bottom: 30px;
    }

    /* Layout Form jadi Horizontal */
    .upload-section form {
        flex-direction: row; /* Susunan Mendatar */
        align-items: center;
    }

    input[type="file"] {
        flex: 1;
        padding: 14px;
        font-size: 15px;
    }

    button {
        padding: 14px 30px;
        font-size: 16px;
        width: auto;
    }

    th, td {
        padding: 15px;
        font-size: 15px;
    }

    .btn {
        padding: 8px 12px;
        font-size: 13px; /* Lebih besar di landscape */
    }
}
