:root {
    --bg: #f4f6f8;
    --card: #ffffff;
    --text: #1f2933;
    --muted: #6b7280;
    --accent: #2563eb;
    --accent-dark: #1d4ed8;
    --danger: #dc2626;
    --border: #e2e8f0;
    --radius: 10px;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    background: var(--bg);
    color: var(--text);
}

.wrap {
    max-width: 1600px;
    margin: 0 auto;
    padding: 32px 16px 64px;
}

header.app-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

header.app-header h1 {
    font-size: 1.4rem;
    margin: 0;
}

.card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}

.login-wrap {
    max-width: 360px;
    margin: 10vh auto;
}

label {
    display: block;
    font-size: 0.9rem;
    margin-bottom: 6px;
    color: var(--muted);
}

input[type="text"],
input[type="password"],
input[type="file"],
select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    font-size: 1rem;
    margin-bottom: 14px;
    background: #fff;
}

button, .btn {
    display: inline-block;
    background: var(--accent);
    color: #fff;
    border: none;
    padding: 10px 18px;
    border-radius: 8px;
    font-size: 0.95rem;
    cursor: pointer;
    text-decoration: none;
}

button:hover, .btn:hover { background: var(--accent-dark); }

button.danger, .btn.danger { background: var(--danger); }
button.secondary, .btn.secondary { background: #64748b; }

.error {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
    padding: 10px 14px;
    border-radius: 8px;
    margin-bottom: 16px;
    font-size: 0.9rem;
}

.notice {
    background: #ecfdf5;
    color: #065f46;
    border: 1px solid #a7f3d0;
    padding: 10px 14px;
    border-radius: 8px;
    margin-bottom: 16px;
    font-size: 0.9rem;
}

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

th, td {
    text-align: left;
    padding: 10px 8px;
    border-bottom: 1px solid var(--border);
    font-size: 0.92rem;
    vertical-align: middle;
}

th { color: var(--muted); font-weight: 600; }

.actions { display: flex; gap: 8px; flex-wrap: wrap; }
.actions form { display: inline; }

.muted { color: var(--muted); font-size: 0.85rem; }

.share-link {
    font-family: monospace;
    background: #f1f5f9;
    padding: 6px 8px;
    border-radius: 6px;
    word-break: break-all;
    display: block;
    margin-top: 6px;
}

footer.hint {
    margin-top: 24px;
    font-size: 0.8rem;
    color: var(--muted);
    text-align: center;
}
