/* style.css */
:root {
    --bg: #0f1115;
    --panel: #161a22;
    --card: #1c2230;
    --primary: #5865f2; /* Bleu Discord-like */
    --danger: #e5484d;
    --text: #e6e6eb;
    --muted: #9aa0aa;
    --accent: #7289da; /* Accent pour hover */
    --border: #222;
    --shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    --transition: all 0.2s ease;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background: var(--bg);
    color: var(--text);
    font-family: 'Inter', Arial, sans-serif;
    line-height: 1.5;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

a {
    text-decoration: none;
    color: inherit;
}

/* ===== LAYOUT ===== */
.center {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 30px auto;
    padding: 0 15px;
}

.card {
    background: var(--card);
    padding: 20px;
    border-radius: 12px;
    box-shadow: var(--shadow);
}

/* ===== HEADER ===== */
.topbar {
    background: var(--panel);
    padding: 15px 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 10;
}

.brand {
    display: flex;
    align-items: center;
    gap: 10px;
}

.title {
    font-weight: bold;
    font-size: 18px;
}

.topbar-right {
    display: flex;
    gap: 10px;
    align-items: center;
}

/* ===== BUTTONS ===== */
.btn {
    padding: 10px 16px;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    font-weight: 500;
    transition: var(--transition);
}

.btn:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

.btn.primary {
    background: var(--primary);
    color: white;
}

.btn.secondary {
    background: #2b3245;
    color: var(--text);
}

.btn.danger {
    background: var(--danger);
    color: white;
}

.btn.small {
    padding: 6px 10px;
    font-size: 13px;
}

.btn.full {
    width: 100%;
}

/* ===== INPUTS ===== */
input[type="file"],
input[type="number"],
input[type="text"] {
    width: 100%;
    padding: 10px;
    margin: 8px 0;
    background: #111;
    border: 1px solid var(--border);
    border-radius: 6px;
    color: var(--text);
    transition: var(--transition);
}

input:focus {
    border-color: var(--primary);
    outline: none;
}

/* ===== FILE LIST ===== */
.file-card {
    background: var(--panel);
    padding: 15px;
    border-radius: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 15px;
    transition: var(--transition);
}

.file-card:hover {
    box-shadow: var(--shadow);
    transform: translateY(-2px);
}

.file-info {
    display: flex;
    flex-direction: column;
}

.filename {
    font-weight: 500;
    font-size: 16px;
}

.size, .expire {
    font-size: 13px;
    color: var(--muted);
}

.file-actions {
    display: flex;
    gap: 10px;
}

/* ===== SHARE BOX ===== */
.share-box {
    margin-top: 20px;
    background: var(--panel);
    padding: 15px;
    border-radius: 10px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.hidden {
    display: none;
}

/* ===== FOOTER ===== */
.footer {
    text-align: center;
    margin: 30px 0;
    font-size: 13px;
    color: var(--muted);
    margin-top: auto;
}

/* ===== TEXT ===== */
.muted {
    color: var(--muted);
}

.download-card {
    width: 400px;
    text-align: center;
}

.timer {
    margin: 15px 0;
    font-size: 18px;
}

/* ===== ADMIN PAGE ===== */
.admin-section {
    margin-top: 30px;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
}

.admin-table th, .admin-table td {
    padding: 12px;
    border: 1px solid var(--border);
    text-align: left;
}

.admin-table th {
    background: var(--panel);
    font-weight: bold;
}

/* ===== LOGIN PAGE ===== */
.login-card {
    width: 450px;
    text-align: center;
    padding: 30px;
}

.login-card h1 {
    margin-bottom: 15px;
    font-size: 28px;
}

.login-card .subtitle {
    margin-bottom: 20px;
    font-size: 16px;
    color: var(--muted);
}

.login-card .description {
    margin-bottom: 25px;
    font-size: 14px;
    color: var(--text);
}

/* ===== PROGRESS BAR ===== */
.progress-bar {
    position: relative;
    height: 40px;
    background: var(--border);
    border-radius: 8px;
    overflow: hidden;
    margin-top: 15px;
}

.progress-fill {
    height: 100%;
    background: var(--primary);
    width: 0%;
    transition: width 0.3s ease;
}

.progress-text {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 14px;
    text-shadow: 0 1px 2px rgba(0,0,0,0.5);
}

/* ===== STATS ===== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
    margin-top: 15px;
}

.stat-item {
    background: var(--panel);
    padding: 15px;
    border-radius: 8px;
    text-align: center;
}

.stat-label {
    display: block;
    color: var(--muted);
    font-size: 14px;
}

.stat-value {
    font-size: 24px;
    font-weight: bold;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .container {
        padding: 0 10px;
    }

    .file-card {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .file-actions {
        width: 100%;
        justify-content: space-between;
    }

    .download-card, .login-card {
        width: 90%;
    }

    .topbar {
        padding: 10px 15px;
    }

    .stats-grid {
        grid-template-columns: 1fr 1fr;
    }
}