/* Mint Media Client Portal — brand: mint #62e08c, charcoal #282828, white */
:root {
  --mint: #62e08c;
  --mint-2: #44c873;
  --mint-ink: #0a1610;
  --bg: #141414;
  --bg-2: #181818;
  --panel: #1e1e1e;
  --panel-2: #262626;
  --border: rgba(255, 255, 255, 0.10);
  --border-2: rgba(255, 255, 255, 0.16);
  --text: #f3f4f3;
  --muted: #9aa1a0;
  --danger: #ff6b6b;
  --warn: #f4c150;
  --radius: 14px;
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.45);
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Roboto,
    Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  background:
    radial-gradient(1200px 600px at 80% -10%, rgba(98, 224, 140, 0.10), transparent 60%),
    var(--bg);
  color: var(--text);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}
a { color: var(--mint); text-decoration: none; }
a:hover { text-decoration: underline; }
h1 { font-size: clamp(1.6rem, 3vw, 2.1rem); letter-spacing: -0.02em; margin: 0 0 0.2em; }
h2 { font-size: 1.2rem; letter-spacing: -0.01em; margin: 0 0 0.4em; }
.wrap { width: 100%; max-width: 860px; margin: 0 auto; padding: 0 20px; }
.muted { color: var(--muted); }
.small { font-size: 0.82rem; }
.eyebrow {
  text-transform: uppercase; letter-spacing: 0.18em; font-size: 0.72rem;
  font-weight: 700; color: var(--mint); margin: 0 0 0.35em;
}

/* Top bar */
.topbar {
  position: sticky; top: 0; z-index: 20;
  background: rgba(20, 20, 20, 0.82);
  backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--border);
}
.topbar-in { display: flex; align-items: center; justify-content: space-between; height: 62px; }
.brand { font-weight: 700; letter-spacing: -0.02em; color: var(--text); display: flex; align-items: center; gap: 9px; }
.brand:hover { text-decoration: none; }
.brand .muted { font-weight: 500; }
.dot { width: 10px; height: 10px; border-radius: 50%; background: var(--mint); box-shadow: 0 0 14px var(--mint); display: inline-block; }
.topnav { display: flex; gap: 18px; }
.topnav a { color: var(--muted); font-size: 0.92rem; font-weight: 500; }
.topnav a:hover { color: var(--text); text-decoration: none; }
.logout-form { display: flex; align-items: center; margin: 0; }
.navlink-btn { background: none; border: none; padding: 0; font: inherit; color: var(--muted); font-size: 0.92rem; font-weight: 500; cursor: pointer; }
.navlink-btn:hover { color: var(--text); }

main.wrap { padding-top: 30px; padding-bottom: 70px; }

/* Auth */
.auth { min-height: 80vh; display: grid; place-items: center; }
.auth-card {
  width: 100%; max-width: 430px; background: var(--panel);
  border: 1px solid var(--border); border-radius: 20px; padding: 38px 34px;
  box-shadow: var(--shadow);
}
.brand-lg { font-size: 1.15rem; font-weight: 700; letter-spacing: -0.02em; display: flex; align-items: center; gap: 10px; margin-bottom: 18px; }
.auth-card h1 { font-size: 1.5rem; }
.auth-card p { color: var(--muted); }

/* Cards */
.card {
  background: var(--panel); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 24px 24px; margin: 18px 0;
}
.dash-head { display: flex; align-items: flex-end; justify-content: space-between; margin: 6px 0 8px; }

/* Forms */
.stack { display: flex; flex-direction: column; gap: 8px; }
.stack > label, .grid2 label { font-weight: 600; font-size: 0.9rem; margin-top: 6px; }
input, textarea, select {
  width: 100%; font-family: inherit; font-size: 1rem; color: var(--text);
  background: var(--bg-2); border: 1px solid var(--border-2); border-radius: 10px;
  padding: 11px 13px; transition: border-color 0.15s, box-shadow 0.15s;
}
textarea { resize: vertical; }
input:focus, textarea:focus, select:focus {
  outline: none; border-color: var(--mint);
  box-shadow: 0 0 0 3px rgba(98, 224, 140, 0.22);
}
input[type="file"] { padding: 9px; background: var(--bg-2); }
input[type="checkbox"] { width: auto; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.grid2 > div { display: flex; flex-direction: column; gap: 5px; }
.grid2-full { grid-column: 1 / -1; }
.check { display: inline-flex; align-items: center; gap: 8px; font-weight: 500; }
.row-actions { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.sendlink-row { margin-top: 10px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-weight: 600; font-size: 0.95rem; padding: 11px 20px; border-radius: 11px;
  border: 1px solid transparent; cursor: pointer; transition: transform 0.06s, background 0.15s, border-color 0.15s;
  text-decoration: none;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--mint); color: var(--mint-ink); align-self: flex-start; }
.btn-primary:hover { background: var(--mint-2); }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--border-2); }
.btn-ghost:hover { border-color: var(--mint); color: var(--mint); }
.btn-link { background: none; color: var(--mint); padding: 6px 0; border: none; }
.btn-link:hover { text-decoration: underline; }

/* Flash */
.flash { border-radius: 11px; padding: 12px 15px; margin: 0 0 16px; font-size: 0.93rem; border: 1px solid; }
.flash.ok { background: rgba(98, 224, 140, 0.10); border-color: rgba(98, 224, 140, 0.35); color: #b8f2cf; }
.flash.warn { background: rgba(244, 193, 80, 0.10); border-color: rgba(244, 193, 80, 0.35); color: #f3dca0; }
.flash.err { background: rgba(255, 107, 107, 0.10); border-color: rgba(255, 107, 107, 0.35); color: #ffc2c2; }

/* Site card */
.site-card { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; align-items: center; }
.site-frame {
  border: 1px solid var(--border); border-radius: 12px; overflow: hidden;
  aspect-ratio: 16 / 10; background: var(--bg-2);
}
.site-frame iframe { width: 100%; height: 100%; border: 0; }

/* Request list */
.req-list { list-style: none; margin: 0; padding: 0; }
.req-row {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 14px 14px; border: 1px solid var(--border); border-radius: 11px;
  margin-bottom: 10px; color: var(--text);
}
.req-row:hover { border-color: var(--border-2); background: var(--panel-2); text-decoration: none; }
.req-title { font-weight: 600; }
.req-meta { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.chip { font-size: 0.78rem; color: var(--muted); }

/* Badges */
.badge { font-size: 0.74rem; font-weight: 700; padding: 4px 10px; border-radius: 999px; white-space: nowrap; letter-spacing: 0.02em; }
.badge-new { background: rgba(98, 224, 140, 0.16); color: var(--mint); }
.badge-prog { background: rgba(244, 193, 80, 0.16); color: var(--warn); }
.badge-done { background: rgba(120, 200, 255, 0.16); color: #8fd0ff; }
.badge-arch { background: rgba(255, 255, 255, 0.08); color: var(--muted); }

/* Request detail */
.back { display: inline-block; color: var(--muted); margin-bottom: 6px; font-size: 0.9rem; }
.req-head { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.req-body { white-space: pre-wrap; margin-top: 8px; }
.statusform { display: flex; align-items: flex-end; gap: 12px; margin-top: 18px; flex-wrap: wrap; }
.statusform select { width: auto; min-width: 170px; }
.statusform label { font-size: 0.85rem; }

/* Attachments */
.thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 12px; margin-top: 16px; }
.thumb {
  display: flex; flex-direction: column; gap: 6px; align-items: center; text-align: center;
  border: 1px solid var(--border); border-radius: 11px; padding: 10px; color: var(--muted); font-size: 0.78rem;
  background: var(--bg-2);
}
.thumb:hover { border-color: var(--mint); text-decoration: none; }
.thumb img { width: 100%; height: 86px; object-fit: cover; border-radius: 7px; }
.file-ic { font-size: 2rem; height: 86px; display: grid; place-items: center; }
.thumb-name { word-break: break-word; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }

/* Thread */
.thread { list-style: none; margin: 10px 0 20px; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.msg { display: flex; }
.msg.mine { justify-content: flex-end; }
.bubble { max-width: 80%; background: var(--panel-2); border: 1px solid var(--border); border-radius: 14px; padding: 11px 14px; }
.msg.mine .bubble { background: rgba(98, 224, 140, 0.12); border-color: rgba(98, 224, 140, 0.25); }
.bubble p { margin: 0; }
.bubble p:last-child { white-space: pre-wrap; }
.msg-who { font-size: 0.8rem; color: var(--muted); margin-bottom: 3px !important; }
.status-line { width: 100%; text-align: center; color: var(--muted); font-size: 0.82rem; margin: 2px 0; }

/* Admin queue table */
.filterbar { display: flex; gap: 8px; flex-wrap: wrap; margin: 4px 0 4px; }
.pillf { padding: 7px 14px; border: 1px solid var(--border-2); border-radius: 999px; color: var(--muted); font-size: 0.86rem; font-weight: 500; }
.pillf:hover { color: var(--text); text-decoration: none; border-color: var(--mint); }
.pillf.on { background: var(--mint); color: var(--mint-ink); border-color: var(--mint); }
.pillf b { font-weight: 700; }
.qtable { width: 100%; border-collapse: collapse; }
.qtable th { text-align: left; font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); padding: 0 10px 10px; }
.qtable td { padding: 12px 10px; border-top: 1px solid var(--border); vertical-align: middle; }
.qlink { font-weight: 600; color: var(--text); }
.qlink:hover { color: var(--mint); }

/* Client cards */
.client-card.inactive { opacity: 0.55; }

/* Footer */
.foot { border-top: 1px solid var(--border); color: var(--muted); font-size: 0.85rem; padding: 22px 0; text-align: center; }
.foot a { color: var(--muted); }

/* Responsive */
@media (max-width: 680px) {
  .site-card, .grid2 { grid-template-columns: 1fr; }
  .req-row { flex-direction: column; align-items: flex-start; gap: 8px; }
  .req-meta { width: 100%; justify-content: space-between; }
  .qtable thead { display: none; }
  .qtable, .qtable tbody, .qtable tr, .qtable td { display: block; width: 100%; }
  .qtable tr { border: 1px solid var(--border); border-radius: 11px; margin-bottom: 10px; padding: 6px 4px; }
  .qtable td { border: none; padding: 5px 12px; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}
