/* Reset & Base */
:root {
    --primary-color: #0366d6;
    --primary-hover: #0056b3;
    --success-color: #2ea44f;
    --danger-color: #cb2431;
    --bg-color: #f6f8fa;
    --surface-color: #ffffff;
    --text-color: #24292e;
    --text-muted: #586069;
    --border-color: #e1e4e8;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
    line-height: 1.6;
    margin: 0;
    padding: 0;
    background-color: var(--bg-color);
    color: var(--text-color);
}

.container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px;
}

/* Navbar */
.navbar {
    background: var(--surface-color);
    padding: 15px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.brand {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-color);
}

.nav-links {
    display: flex;
    gap: 10px;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 16px;
    font-size: 14px;
    font-weight: 500;
    border-radius: 6px;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
}
.btn-primary:hover { background-color: var(--primary-hover); }

.btn-view {
    background-color: var(--surface-color);
    color: var(--success-color);
    border-color: var(--success-color);
}
.btn-view:hover { background-color: var(--success-color); color: white; }

.btn-download {
    background-color: var(--surface-color);
    color: var(--primary-color);
    border-color: var(--primary-color);
}
.btn-download:hover { background-color: var(--primary-color); color: white; }

.nav-btn {
    padding: 6px 12px;
    border-radius: 6px;
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    font-size: 14px;
    transition: background 0.2s;
}
.nav-btn:hover { background: #eaecef; }
.nav-btn.outline { border: 1px solid var(--border-color); }

/* Table */
.table-responsive {
    background: var(--surface-color);
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    overflow: hidden;
}

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

th, td {
    padding: 16px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

th {
    background-color: #fafbfc;
    font-weight: 600;
    color: var(--text-muted);
}

tr:last-child td { border-bottom: none; }
tr:hover td { background-color: #fafbfc; }

.file-name { font-weight: 500; display: flex; align-items: center; gap: 8px; }
.icon { font-size: 1.2em; }
.actions { display: flex; gap: 8px; }

/* Login Page */
.login-body {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
}

.login-container {
    background: var(--surface-color);
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    width: 100%;
    max-width: 360px;
}

.login-container h2 {
    margin-top: 0;
    text-align: center;
    margin-bottom: 24px;
}

.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}

.form-group input {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    box-sizing: border-box;
    font-size: 14px;
}

.form-group input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(3,102,214,0.3);
}

.w-100 { width: 100%; }
.text-center { text-align: center; }
.mt-3 { margin-top: 16px; }

/* Upload Page */
.upload-box {
    background: var(--surface-color);
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    max-width: 600px;
    margin: 40px auto;
}

.drop-zone {
    border: 2px dashed var(--border-color);
    border-radius: 8px;
    padding: 40px 20px;
    text-align: center;
    transition: all 0.2s;
    background: #fafbfc;
    margin-top: 20px;
}

.drop-zone.dragover {
    border-color: var(--primary-color);
    background: #e6f0fa;
}

.drop-zone .icon {
    font-size: 48px;
    margin-bottom: 16px;
}

.progress-bar-container {
    width: 100%;
    height: 8px;
    background-color: var(--border-color);
    border-radius: 4px;
    overflow: hidden;
    margin-top: 10px;
}

.progress-bar {
    height: 100%;
    background-color: var(--primary-color);
    width: 0%;
    transition: width 0.1s ease;
}

.progress-text {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 4px;
    text-align: right;
}

/* Alert */
.alert {
    padding: 12px;
    border-radius: 6px;
    margin-bottom: 16px;
    font-size: 14px;
}
.alert.error {
    background-color: #ffeef0;
    color: var(--danger-color);
    border: 1px solid rgba(203, 36, 49, 0.2);
}
