/* PDF Table Extractor — Warm Paper Dark */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --primary: #3B82F6;
  --primary-dim: rgba(59,130,246,0.12);
  --bg: #111318;
  --bg-card: #1C1F28;
  --bg-paper: #1F2330;
  --border: rgba(59,130,246,0.08);
  --text: #E2E8F0;
  --text-dim: #94A3B8;
  --text-muted: #475569;
  --radius: 12px;
  --radius-sm: 8px;
  --font: 'Inter', system-ui, sans-serif;
  --mono: 'JetBrains Mono', monospace;
  --transition: 0.2s ease;
}

html { font-size: 16px; -webkit-font-smoothing: antialiased; }
body { font-family: var(--font); background: var(--bg); color: var(--text); min-height: 100vh; line-height: 1.6; }

.header { border-bottom: 1px solid var(--border); background: rgba(28,31,40,0.95); backdrop-filter: blur(12px); position: sticky; top: 0; z-index: 10; }
.header-inner { max-width: 900px; margin: 0 auto; padding: 12px 20px; display: flex; align-items: center; justify-content: space-between; }
.header-left { display: flex; align-items: center; gap: 10px; }
.header-actions { display: flex; gap: 6px; align-items: center; }
.logo-icon { font-size: 1.2rem; width: 38px; height: 38px; display: flex; align-items: center; justify-content: center; background: var(--primary-dim); border-radius: var(--radius-sm); }
.header h1 { font-size: 1.05rem; font-weight: 700; }
.subtitle { font-size: 0.72rem; color: var(--text-dim); }

.main { max-width: 900px; margin: 0 auto; padding: 20px; }

.btn { padding: 8px 16px; font-family: var(--font); font-size: 0.78rem; font-weight: 600; border: none; border-radius: 6px; cursor: pointer; transition: all var(--transition); }
.btn-sm { padding: 5px 10px; font-size: 0.72rem; background: var(--primary-dim); color: var(--primary); border: 1px solid rgba(59,130,246,0.2); }
.select { padding: 5px 8px; font-family: var(--font); font-size: 0.72rem; color: var(--text); background: var(--bg); border: 1px solid var(--border); border-radius: 6px; }

.drop-zone { border: 2px dashed rgba(59,130,246,0.2); border-radius: var(--radius); padding: 40px; text-align: center; transition: all var(--transition); cursor: pointer; margin-bottom: 12px; }
.drop-zone.over { border-color: var(--primary); background: var(--primary-dim); }
.drop-icon { font-size: 2rem; margin-bottom: 8px; }
.drop-text { font-size: 0.82rem; }
.drop-link { color: var(--primary); cursor: pointer; text-decoration: underline; }
.drop-hint { font-size: 0.62rem; color: var(--text-muted); margin-top: 4px; }

.info-bar { display: flex; align-items: center; justify-content: space-between; padding: 8px 14px; background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-sm); margin-bottom: 8px; font-size: 0.72rem; color: var(--text-dim); }
.page-nav { display: flex; align-items: center; gap: 6px; }

.progress-bar { height: 4px; background: rgba(59,130,246,0.1); border-radius: 2px; overflow: hidden; margin-bottom: 8px; }
.progress-fill { height: 100%; background: var(--primary); transition: width 0.3s ease; width: 0%; }

.table-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; margin-bottom: 8px; }
.panel-header { display: flex; align-items: center; justify-content: space-between; padding: 8px 14px; border-bottom: 1px solid var(--border); }
.panel-label { font-size: 0.72rem; font-weight: 600; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.04em; }
.table-stats { font-size: 0.62rem; color: var(--text-muted); }
.table-wrap { overflow-x: auto; padding: 8px; }

.table-wrap table { width: 100%; border-collapse: collapse; font-family: var(--mono); font-size: 0.62rem; }
.table-wrap th { padding: 6px 8px; background: var(--bg-paper); color: var(--text-dim); text-align: left; font-weight: 600; border: 1px solid var(--border); white-space: nowrap; }
.table-wrap td { padding: 5px 8px; border: 1px solid var(--border); white-space: nowrap; }
.table-wrap tr:nth-child(even) td { background: rgba(59,130,246,0.03); }

.empty-state { text-align: center; padding: 30px; color: var(--text-muted); font-size: 0.82rem; }

.toast-container { position: fixed; bottom: 20px; right: 20px; z-index: 200; }
.toast { padding: 10px 16px; background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-sm); box-shadow: 0 4px 24px rgba(0,0,0,0.5); font-size: 0.82rem; animation: toastIn 0.3s ease; }
@keyframes toastIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
