:root {
  --ink: #1d2433;
  --muted: #6b7385;
  --line: #e3e6ec;
  --bg: #f6f7f9;
  --card: #ffffff;
  --accent: #1f6feb;
  --accent-ink: #ffffff;
  --danger: #c0392b;
  --radius: 10px;
}

* { box-sizing: border-box; }

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

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

.wrap { max-width: 1080px; margin: 0 auto; padding: 0 20px; }
main.wrap { padding-top: 28px; padding-bottom: 60px; }

.topbar { background: var(--card); border-bottom: 1px solid var(--line); }
.topbar .wrap { display: flex; align-items: center; justify-content: space-between; height: 60px; }
.brand { font-weight: 800; letter-spacing: .08em; color: var(--ink); }
.brand:hover { text-decoration: none; }
nav { display: flex; align-items: center; gap: 18px; }

.muted { color: var(--muted); }
.center { text-align: center; }
.right { text-align: right; }
.inline { display: inline; margin: 0; }

h1 { margin: 0 0 6px; font-size: 1.6rem; }

.btn {
  display: inline-block; border: 0; border-radius: 8px; cursor: pointer;
  background: var(--accent); color: var(--accent-ink);
  padding: 10px 18px; font: inherit; font-weight: 600;
}
.btn:hover { text-decoration: none; filter: brightness(1.05); }
.btn.secondary { background: transparent; color: var(--accent); border: 1px solid var(--accent); }
.btn.small { padding: 6px 12px; font-size: .9rem; }
.btn.full { width: 100%; margin-top: 18px; }

button.link { background: none; border: 0; padding: 0; font: inherit; color: var(--accent); cursor: pointer; }
button.link:hover { text-decoration: underline; }
button.link.danger { color: var(--danger); }

.hero { text-align: center; padding: 70px 0; }
.hero h1 { font-size: 2.2rem; }
.actions { display: flex; gap: 12px; justify-content: center; margin-top: 22px; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; }
.card.narrow { max-width: 420px; margin: 30px auto; }

label { display: block; margin-top: 14px; font-weight: 600; font-size: .92rem; }
label.check { font-weight: 400; display: flex; gap: 8px; align-items: center; }
input[type=email], input[type=password], input[type=text] {
  width: 100%; padding: 10px 12px; margin-top: 4px;
  border: 1px solid var(--line); border-radius: 8px; font: inherit;
}
input:focus { outline: 2px solid var(--accent); outline-offset: 1px; }

.errors ul { margin: 0; padding-left: 18px; color: var(--danger); }
.field-error { color: var(--danger); font-size: .85rem; }
.notice { background: #e8f1ff; border: 1px solid #c6dafc; border-radius: 8px; padding: 10px 14px; margin: 16px 0; }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; margin-top: 22px; }
.folder {
  display: flex; flex-direction: column; gap: 2px;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 16px 18px; color: var(--ink);
}
.folder:hover { border-color: var(--accent); text-decoration: none; }
.folder .num { font-size: .8rem; font-weight: 700; color: var(--accent); }
.folder .name { font-weight: 700; }
.folder .desc { color: var(--muted); font-size: .88rem; }
.folder .count { margin-top: 8px; font-size: .82rem; color: var(--muted); }

.upload {
  display: flex; flex-wrap: wrap; align-items: center; gap: 12px;
  background: var(--card); border: 1px dashed var(--line); border-radius: var(--radius);
  padding: 16px; margin: 20px 0;
}

.files { width: 100%; border-collapse: collapse; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.files th, .files td { padding: 10px 14px; border-bottom: 1px solid var(--line); text-align: left; font-size: .93rem; }
.files th { background: #fafbfc; color: var(--muted); font-weight: 600; }
.files tr:last-child td { border-bottom: 0; }

.empty { color: var(--muted); padding: 30px 0; text-align: center; }

@media (max-width: 640px) {
  .files th:nth-child(4), .files td:nth-child(4) { display: none; }
}
