/* Deed Tool — shared styles. Apple-clean meets Facebook-blue. No JS, no web fonts. */

:root {
  --bg:        #f0f2f5;          /* soft Facebook-gray canvas */
  --card:      #ffffff;
  --ink:       #1c1e21;          /* near-black text */
  --muted:     #65676b;          /* secondary gray text */
  --line:      #dfe1e6;          /* hairline borders */
  --blue:      #1877f2;          /* Facebook blue */
  --blue-deep: #4f46e5;          /* indigo, for the "cool" gradient end */
  --blue-soft: rgba(24, 119, 242, 0.14);
  --warn-bg:   #fff8e1;
  --warn-line: #f3d27a;
  --radius:    16px;
  --shadow:    0 10px 40px rgba(0, 0, 0, 0.08), 0 2px 8px rgba(0, 0, 0, 0.04);
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background:
    radial-gradient(1200px 600px at 50% -200px, rgba(79, 70, 229, 0.10), transparent 60%),
    var(--bg);
  color: var(--ink);
  margin: 0;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  line-height: 1.55;
}

/* ---- The brand bar across the top ---- */
.topbar {
  height: 6px;
  background: linear-gradient(90deg, var(--blue), var(--blue-deep));
}

/* ---- Page shell ---- */
.shell {
  max-width: 760px;
  margin: 0 auto;
  padding: 48px 24px 96px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 28px;
}
.brand .dot {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--blue), var(--blue-deep));
  box-shadow: 0 6px 16px rgba(24, 119, 242, 0.35);
  flex: none;
}
.brand .name {
  font-weight: 700;
  letter-spacing: -0.01em;
  font-size: 1.05rem;
}

/* ---- The floating card ---- */
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 40px 40px 44px;
}

h1 {
  font-size: 2.1rem;
  letter-spacing: -0.02em;
  margin: 0 0 6px;
}
.subtitle {
  color: var(--muted);
  margin: 0 0 28px;
  font-size: 1.02rem;
}

h2 {
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin: 34px 0 14px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}
h2:first-of-type { margin-top: 8px; }

.hint { color: var(--muted); font-size: 0.9rem; margin: 0 0 16px; }

/* ---- Form controls ---- */
label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 6px;
}

input[type="text"],
input[type="password"],
input[type="file"],
textarea {
  width: 100%;
  font-family: inherit;
  font-size: 0.98rem;
  color: var(--ink);
  padding: 11px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  margin-bottom: 18px;
  background: #fff;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
input[type="text"]:focus,
input[type="password"]:focus,
textarea:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 4px var(--blue-soft);
}

/* Error banner (e.g. wrong password) */
.alert {
  background: #fdecea;
  border: 1px solid #f5c6cb;
  color: #b3261e;
  border-radius: 10px;
  padding: 12px 16px;
  font-size: 0.92rem;
  margin-bottom: 20px;
}

/* Log out link tucked into the brand row */
.brand .logout {
  margin-left: auto;
  font-size: 0.85rem;
  color: var(--muted);
  text-decoration: none;
  font-weight: 500;
}
.brand .logout:hover { color: var(--ink); text-decoration: underline; }
textarea { resize: vertical; line-height: 1.6; }

.highlight { background: var(--warn-bg); border-color: var(--warn-line); }

/* owner name + deceased checkbox row */
.owner-row { display: flex; align-items: center; gap: 14px; }
.owner-row input[type="text"] { flex: 1; }
.chk {
  display: flex;
  align-items: center;
  gap: 7px;
  white-space: nowrap;
  font-weight: 500;
  color: var(--ink);
  font-size: 0.9rem;
  margin-bottom: 18px;
}
.chk input[type="checkbox"] { width: auto; accent-color: var(--blue); transform: scale(1.15); }

/* ---- Buttons ---- */
.btn,
button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  padding: 13px 30px;
  border: none;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--blue), var(--blue-deep));
  color: #fff;
  cursor: pointer;
  text-decoration: none;
  box-shadow: 0 8px 20px rgba(24, 119, 242, 0.28);
  transition: transform 0.12s ease, box-shadow 0.12s ease, filter 0.12s ease;
}
.btn:hover,
button:hover { transform: translateY(-1px); filter: brightness(1.04); box-shadow: 0 12px 26px rgba(24, 119, 242, 0.34); }
.btn:active,
button:active { transform: translateY(0); }

.upload-row { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.upload-row input[type="file"] { flex: 1; margin-bottom: 0; min-width: 240px; }

/* ---- Drag-and-drop upload area ---- */
.dropzone {
  border: 2px dashed #c9d2e3;
  border-radius: var(--radius);
  background: #f7f9fc;
  padding: 40px 24px;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease, transform 0.12s ease;
}
.dropzone:hover { border-color: var(--blue); background: #f2f6ff; }
.dropzone.is-drag {
  border-color: var(--blue);
  background: var(--blue-soft);
  transform: scale(1.01);
}
.dz-icon {
  font-size: 2.4rem;
  line-height: 1;
  color: var(--blue);
  margin-bottom: 10px;
}
.dz-title { font-size: 1.1rem; font-weight: 600; margin: 0 0 4px; }
.dz-sub { color: var(--muted); font-size: 0.9rem; margin: 0 0 16px; }
.browse {
  display: inline-block;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 9px 22px;
  border-radius: 10px;
  border: 1px solid var(--blue);
  color: var(--blue);
  background: #fff;
  transition: background 0.12s ease, color 0.12s ease;
}
.dropzone:hover .browse { background: var(--blue); color: #fff; }
.dz-name { color: #1b9e4b; font-weight: 600; font-size: 0.92rem; margin: 16px 0 0; min-height: 1.1em; }
.upload-actions { margin-top: 22px; }

/* ---- Read-out boxes (filename, response) ---- */
.panel {
  background: #f7f8fa;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px 18px;
  word-break: break-all;
}
.meta { color: var(--muted); font-size: 0.9rem; margin-bottom: 20px; }
.response-box,
pre {
  background: #f7f8fa;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 20px 22px;
  white-space: pre-wrap;
  font-size: 0.93rem;
  line-height: 1.65;
}

/* ---- Links ---- */
a.plain { color: var(--blue); text-decoration: none; font-weight: 500; }
a.plain:hover { text-decoration: underline; }

.footer-link { margin-top: 30px; }

/* ---- Collapsible raw response ---- */
details { margin-top: 30px; }
summary { cursor: pointer; color: var(--muted); font-size: 0.9rem; font-weight: 500; }
summary:hover { color: var(--ink); }

/* ---- Big success check ---- */
.success-badge {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--blue), var(--blue-deep));
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.7rem;
  margin-bottom: 20px;
  box-shadow: 0 8px 20px rgba(24, 119, 242, 0.3);
}

@media (max-width: 560px) {
  .card { padding: 28px 22px 32px; }
  h1 { font-size: 1.7rem; }
}
