﻿:root {
  --bg: #f5f2ea;
  --card: #ffffff;
  --accent: #1f6f5b;
  --accent-dark: #134638;
  --text: #1a1a1a;
  --muted: #6f6f6f;
  --border: #e3ded2;
  --panel: #fbf8f2;
  --panel-strong: #f7f1e3;
  --shadow: rgba(0, 0, 0, 0.08);
}

.theme-dark {
  --bg: #131519;
  --card: #1c2026;
  --accent: #7aa89b;
  --accent-dark: #a6c5bc;
  --text: #eef1f4;
  --muted: #9aa5b1;
  --border: #2b3138;
  --panel: #1a1f26;
  --panel-strong: #222a33;
  --shadow: rgba(0, 0, 0, 0.4);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "PT Serif", "Georgia", serif;
  background: radial-gradient(circle at top left, #f7efe0, var(--bg));
  color: var(--text);
}

.theme-dark body {
  background: radial-gradient(circle at top left, #1f232a, var(--bg));
}
.page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 40px 20px 80px;
  gap: 24px;
}

.hero {
  text-align: center;
  max-width: 680px;
  position: relative;
}

.hero-brand {
  font-family: "Playfair Display", "Times New Roman", serif;
  font-size: 20px;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--accent);
}

h1 {
  margin: 12px 0 8px;
  font-size: 38px;
}

.muted {
  color: var(--muted);
}

.card {
  width: min(720px, 92vw);
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 24px;
  box-shadow: 0 18px 40px var(--shadow);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

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

.banner {
  padding: 10px 14px;
  border-radius: 10px;
  background: #fff4d6;
  border: 1px solid #f1d18a;
}

.theme-dark .banner {
  background: #2b2a22;
  border-color: #5a5135;
  color: #f5e9c2;
}
.hidden {
  display: none;
}

.dropzone {
  border: 2px dashed var(--border);
  border-radius: 16px;
  padding: 30px;
  text-align: center;
  background: var(--panel);
  transition: border-color 0.2s ease, background 0.2s ease;
}

.dropzone.dragover {
  border-color: var(--accent);
  background: #f0faf6;
}

.theme-dark .dropzone.dragover {
  background: #1f2a27;
}
.dropzone-inner input[type="file"] {
  margin-top: 16px;
}

.progress {
  width: 100%;
  height: 8px;
  background: #eee7db;
  border-radius: 999px;
  overflow: hidden;
}

.theme-dark .progress {
  background: #2a2f36;
}
.progress-bar {
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--accent), #2f8f75);
  transition: width 0.2s ease;
}

.actions {
  display: flex;
  justify-content: flex-end;
}

.btn {
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 9px 18px;
  border-radius: 14px;
  background: linear-gradient(180deg, #2b2f38, #1f232b);
  color: #f2f4f7;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 6px 14px rgba(0, 0, 0, 0.12);
}

.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn-secondary {
  background: linear-gradient(180deg, #dfe4e7, #c9d1d6);
  color: #1b1f24;
  border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.4), 0 6px 14px rgba(0, 0, 0, 0.08);
}

.theme-dark .btn {
  background: linear-gradient(180deg, #2f3641, #262c34);
  color: #eef1f4;
  border-color: rgba(255, 255, 255, 0.08);
}

.theme-dark .btn-secondary {
  background: linear-gradient(180deg, #313845, #2a313b);
  color: #e7eaee;
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 6px 14px rgba(0, 0, 0, 0.2);
}
.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.field input {
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid var(--border);
  font-size: 15px;
  background: transparent;
  color: var(--text);
}

.tiny-status {
  margin-top: 8px;
  font-size: 12px;
  color: #7b6d59;
}

.status {
  min-height: 20px;
  color: var(--accent-dark);
}

.file-count {
  margin-top: 10px;
  color: var(--muted);
  font-size: 14px;
}

.file-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.file-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--panel);
  font-size: 14px;
}

.file-item-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 70%;
}

.link-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--panel);
}

.link-title {
  font-weight: 600;
  margin-bottom: 4px;
}

.link-actions {
  display: flex;
  gap: 10px;
}

.link-box {
  padding: 12px 14px;
  border-radius: 12px;
  background: #f0faf6;
  border: 1px solid #c9e8da;
  font-family: "Courier New", monospace;
  word-break: break-all;
}

.theme-dark .link-box {
  background: #1f2a27;
  border-color: #2f4a40;
}
.link-meta {
  display: flex;
  gap: 24px;
  font-size: 14px;
  color: var(--muted);
}

.admin-panel {
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--panel);
  padding: 16px;
}

.admin-panel h3 {
  margin: 0 0 4px;
  font-size: 22px;
}

.admin-create {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) minmax(180px, 1fr) auto;
  gap: 12px;
  align-items: end;
  margin-top: 14px;
}

.admin-table {
  margin-top: 14px;
}

.admin-password-input {
  width: 100%;
  padding: 9px 12px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
}

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

.qr-box {
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px dashed var(--border);
  background: #fff;
  max-width: 220px;
}

.qr-box svg {
  width: 200px;
  height: 200px;
}

.qr-box img {
  width: 200px;
  height: 200px;
}

.totp-confirm {
  display: flex;
  gap: 12px;
  align-items: flex-end;
  flex-wrap: wrap;
}

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

.table th,
.table td {
  text-align: left;
  padding: 10px 8px;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
}

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

.group-row td {
  background: var(--panel-strong);
  color: #6b5b45;
  font-weight: 600;
  border-bottom: 1px solid var(--border);
}

.theme-dark .group-row td {
  color: #c7b79b;
}

.security {
  margin-top: 16px;
}

.security details {
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--panel);
  padding: 12px 14px;
}

.security summary {
  cursor: pointer;
  list-style: none;
  font-weight: 600;
  color: #5c4a32;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.security summary::-webkit-details-marker {
  display: none;
}

.security summary::after {
  content: "v";
  font-size: 14px;
  color: #7b6d59;
}

.security details[open] summary::after {
  content: "^";
}

.security-body {
  margin-top: 12px;
  color: #3f3528;
  font-size: 14px;
}

.security-body h3 {
  margin: 0 0 10px;
  font-size: 16px;
}

.security-block {
  margin-bottom: 12px;
}

.security-title {
  font-weight: 600;
  margin-bottom: 6px;
}

.security-body ul {
  margin: 0 0 8px 18px;
  padding: 0;
  color: #5f5446;
}

.security-body p {
  margin: 8px 0 0;
  color: #5f5446;
}

.theme-dark .security summary {
  color: #c7b79b;
}

.theme-dark .security summary::after {
  color: #a59a86;
}

.theme-dark .security-body {
  color: #d8dde3;
}

.theme-dark .security-body ul,
.theme-dark .security-body p {
  color: #b8c0ca;
}

.btn-compact {
  padding: 6px 12px;
  font-size: 12px;
}

@media (max-width: 640px) {
  h1 {
    font-size: 30px;
  }

  .card {
    padding: 18px;
  }

  .card-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .link-panel {
    flex-direction: column;
    align-items: flex-start;
  }

  .admin-create {
    grid-template-columns: 1fr;
  }

  .link-actions {
    width: 100%;
    justify-content: flex-start;
    flex-wrap: wrap;
  }
}




