/* ===================================================
   MIWERE.GE — UNIFIED DESIGN SYSTEM (2026)
   Used by: index.php, status.php, admin.php, login
=================================================== */

/* ========== RESET ========== */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* ========== DESIGN TOKENS ========== */
:root {
  --bg-main: #05060f;
  --bg-card: rgba(255, 255, 255, 0.08);
  --bg-overlay: rgba(2, 6, 23, 0.8);
  --border: rgba(255, 255, 255, 0.15);

  --text-main: #e5e7eb;
  --text-muted: #94a3b8;

  --accent: linear-gradient(135deg, #7c7cff, #22d3ee);
  --accent-solid: #7c7cff;

  --success: #22c55e;
  --danger: #ef4444;
  --warning: #facc15;

  --radius-xl: 26px;
  --radius-lg: 22px;
  --radius-md: 16px;

  --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}
/* ========== LIGHT THEME (REDESIGNED) ========== */
:root[data-theme="light"] {
  /* Backgrounds */
  --bg-main: #f1f5f9; /* soft slate */
  --bg-card: rgba(255, 255, 255, 0.85);
  --bg-overlay: rgba(241, 245, 249, 0.9);

  /* Borders & depth */
  --border: rgba(15, 23, 42, 0.08);

  /* Text */
  --text-main: #0f172a; /* slate-900 */
  --text-muted: #475569; /* slate-600 */

  /* Accent stays SAME (important for brand) */
  --accent-solid: #6366f1;
}
/* Light mode shadows & depth */
:root[data-theme="light"] .title-pill,
:root[data-theme="light"] form,
:root[data-theme="light"] details,
:root[data-theme="light"] .overlay-card {
  box-shadow: 0 10px 25px rgba(15, 23, 42, 0.06),
    0 2px 8px rgba(15, 23, 42, 0.04);
}

/* Light mode header background */
:root[data-theme="light"] .site-header {
  background: rgba(248, 250, 252, 0.85);
}

/* ========== BASE ========== */
html {
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  background: radial-gradient(1200px at 20% -10%, #1e1b4b, transparent),
    radial-gradient(800px at 90% 20%, #155e75, transparent), var(--bg-main);
  color: var(--text-main);
}

body {
  min-height: 100vh;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ===================================================
   HEADER (ALL PAGES)
=================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(16px);
  background: rgba(2, 6, 23, 0.75);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  max-width: 1100px;
  margin: auto;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  font-size: 24px;
  font-weight: 900;
  text-decoration: none;
  color: var(--text-main);
}

.logo span {
  background: var(--accent);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ========== HEADER ACTIONS ========== */
.header-actions {
  display: flex;
  gap: 12px;
  align-items: center;
}

.theme-toggle {
  background: none;
  border: none;
  font-size: 18px;
  cursor: pointer;
  color: var(--text-main);
}

/* ========== MENU BUTTON ========== */
.menu-btn {
  background: none;
  border: none;
  cursor: pointer;
}

.menu-btn span {
  display: block;
  width: 26px;
  height: 2px;
  background: var(--text-main);
  margin: 6px 0;
  border-radius: 3px;
}

/* ===================================================
   MOBILE NAV (ALL PAGES)
=================================================== */
/* ===============================
   MOBILE NAV — MODERN FLOATING
=============================== */
.mobile-nav {
  position: fixed;
  top: 64px;              /* header-ის ქვემოთ */
  right: 16px;
  width: 220px;

  display: none;
  flex-direction: column;
  gap: 6px;

  padding: 10px;
  border-radius: 18px;

  background: var(--bg-card);
  backdrop-filter: blur(18px);
  border: 1px solid var(--border);

  box-shadow:
    0 20px 40px rgba(0,0,0,.35),
    0 4px 12px rgba(0,0,0,.25);

  animation: menuFade .18s ease;
  z-index: 999;
}

.mobile-nav.show {
  display: flex;
}

.mobile-nav a {
  padding: 10px 12px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-main);
  text-decoration: none;
  border-radius: 12px;
  transition: var(--transition);
}

.mobile-nav a:hover {
  background: rgba(124,124,255,.18);
}

.mobile-nav a.active {
  background: linear-gradient(
    135deg,
    rgba(124,124,255,.25),
    rgba(34,211,238,.25)
  );
}
:root[data-theme="light"] .mobile-nav {
  box-shadow:
    0 20px 40px rgba(15,23,42,.15),
    0 4px 12px rgba(15,23,42,.1);
}

/* Animation */
@keyframes menuFade {
  from {
    opacity: 0;
    transform: translateY(-6px) scale(.96);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}


/* ===================================================
   LAYOUT
=================================================== */
.container {
  max-width: 560px;
  margin: 36px auto;
  padding: 0 16px env(safe-area-inset-bottom);
}

/* ===================================================
   TITLES / HEADINGS
=================================================== */
.title-pill {
  background: var(--bg-card);
  border: 1px solid var(--border);
  backdrop-filter: blur(18px);
  border-radius: var(--radius-lg);
  padding: 26px;
  text-align: center;
  margin-bottom: 16px;
}

.subtitle {
  text-align: center;
  color: var(--text-muted);
  font-size: 14px;
  margin-bottom: 28px;
}

/* ===================================================
   FORMS (USER + ADMIN)
=================================================== */
form {
  background: var(--bg-card);
  border: 1px solid var(--border);
  backdrop-filter: blur(20px);
  border-radius: var(--radius-lg);
  padding: 24px;
}

label {
  display: block;
  margin-top: 18px;
  font-size: 13px;
  color: var(--text-muted);
}

input,
textarea,
select {
  width: 100%;
  margin-top: 6px;
  padding: 15px;
  font-size: 16px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-main);
}

textarea {
  resize: none;
  min-height: 120px;
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--accent-solid);
  box-shadow: 0 0 0 3px rgba(124, 124, 255, 0.25);
}

/* COUNTERS / NOTES */
.note {
  font-size: 12px;
  color: var(--text-muted);
  text-align: right;
  margin-top: 6px;
}

/* ===================================================
   BUTTONS (GLOBAL)
=================================================== */
button {
  width: 100%;
  margin-top: 22px;
  padding: 15px;
  border-radius: var(--radius-md);
  border: none;
  font-weight: 700;
  background: var(--accent);
  color: #020617;
  cursor: pointer;
  transition: var(--transition);
}

button:hover {
  transform: translateY(-2px);
}

button.secondary {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-main);
}

/* ===================================================
   STATUS / BADGES
=================================================== */
.status {
  font-size: 11px;
  padding: 4px 12px;
  border-radius: 999px;
  font-weight: 700;
}

.status.pending {
  background: rgba(148, 163, 184, 0.2);
}
.status.sent {
  background: rgba(34, 197, 94, 0.2);
  color: var(--success);
}
.status.rejected {
  background: rgba(239, 68, 68, 0.2);
  color: var(--danger);
}

/* ===================================================
   CARDS / DETAILS (STATUS + ADMIN)
=================================================== */
details {
  margin-top: 14px;
  border-radius: var(--radius-md);
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 12px 14px;
}

summary {
  cursor: pointer;
  font-weight: 700;
}

.details-body {
  margin-top: 14px;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  font-size: 13px;
}

.info-item b {
  display: block;
  color: var(--text-muted);
}

.message-box {
  margin-top: 14px;
  background: rgba(0, 0, 0, 0.35);
  padding: 16px;
  border-radius: var(--radius-md);
}

/* ===================================================
   ADMIN FILTER BUTTONS
=================================================== */
.admin-actions {
  display: flex;
  gap: 10px;
  margin-bottom: 22px;
}

.admin-actions button {
  padding: 10px;
  font-size: 13px;
}

/* ===================================================
   OVERLAYS (SUCCESS / ERROR)
=================================================== */
.overlay {
  position: fixed;
  inset: 0;
  background: var(--bg-overlay);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 200;
}

.overlay-card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  backdrop-filter: blur(24px);
  border-radius: var(--radius-xl);
  padding: 32px;
  width: 90%;
  max-width: 420px;
  text-align: center;
}

.overlay-close {
  position: absolute;
  top: 14px;
  right: 16px;
  background: none;
  border: none;
  font-size: 18px;
  cursor: pointer;
  color: var(--text-muted);
}

/* ===================================================
   RESPONSIVE
=================================================== */
@media (min-width: 768px) {
  .container {
    max-width: 640px;
  }
}
/* ================================
   BANK INFO — PREMIUM CARD
================================ */

.bank-box {
  margin-top: 18px;
  padding: 18px 20px;
  border-radius: 18px;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.06),
    rgba(255, 255, 255, 0.02)
  );
  border: 1px solid var(--border);
  backdrop-filter: blur(8px);
}

/* Header row */
.bank-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.bank-header strong {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.2px;
}

.bank-header span {
  font-size: 20px;
  opacity: 0.85;
}

/* Divider */
.bank-divider {
  height: 1px;
  background: var(--border);
  margin: 10px 0 14px;
}

/* Account line */
.bank-line {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.6;
}

/* IBAN highlight */
.bank-line span {
  display: block;
  margin-top: 4px;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-main);
  letter-spacing: 0.4px;
  word-break: break-all;
}

/* Subtle emphasis */
.bank-line.muted {
  margin-top: 6px;
  font-size: 12px;
}

/* Light mode tuning */
:root[data-theme="light"] .bank-box {
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.9),
    rgba(255, 255, 255, 0.7)
  );
  border-color: rgba(15, 23, 42, 0.08);
}

:root[data-theme="light"] .bank-divider {
  background: rgba(15, 23, 42, 0.08);
}
/* ================================
   COPY IBAN BUTTON
================================ */
.copy-btn {
  margin-top: 10px;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 600;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-main);
  cursor: pointer;
  transition: var(--transition);
}

.copy-btn:hover {
  background: rgba(124, 124, 255, 0.15);
  border-color: rgba(124, 124, 255, 0.4);
}

.copy-btn.copied {
  background: rgba(34, 197, 94, 0.2);
  border-color: rgba(34, 197, 94, 0.4);
  color: var(--success);
}
/* ===============================
   OVERLAY CLOSE BUTTON FIX
=============================== */
.overlay-close {
  width: auto !important;
  margin: 0 !important;
  padding: 6px 10px;
  background: transparent;
  border: none;
  font-size: 18px;
  line-height: 1;
  position: absolute;
  top: 14px;
  right: 16px;
  cursor: pointer;
  color: var(--text-muted);
}

.overlay-close:hover {
  color: var(--text-main);
}
/* ===============================
   MOBILE NAV POSITION FIX (DESKTOP)
=============================== */

/* Desktop & large screens */
@media (min-width: 768px) {
  .mobile-nav {
    right: calc((100vw - 1100px) / 2 + 16px);
  }
}
/* ===================================================
   FOOTER
=================================================== */

.site-footer {
  margin-top: 80px;
  padding: 40px 20px 20px;
  border-top: 1px solid var(--border);
  background: rgba(2, 6, 23, 0.75);
  backdrop-filter: blur(14px);
}

.footer-inner {
  max-width: 1100px;
  margin: auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 30px;
}

.footer-logo {
  font-size: 22px;
  font-weight: 900;
  color: var(--text-main);
}

.footer-logo span {
  background: var(--accent);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.footer-brand p {
  margin-top: 10px;
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.6;
}

.footer-links h4 {
  font-size: 14px;
  margin-bottom: 10px;
  color: var(--text-main);
}

.footer-links a {
  display: block;
  font-size: 13px;
  color: var(--text-muted);
  text-decoration: none;
  margin-bottom: 6px;
  transition: var(--transition);
}

.footer-links a:hover {
  color: var(--text-main);
}

.footer-bottom {
  margin-top: 30px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
  text-align: center;
  font-size: 12px;
  color: var(--text-muted);
}

/* LIGHT MODE */
:root[data-theme="light"] .site-footer {
  background: rgba(248, 250, 252, 0.85);
}
/* ===============================
   TERMS CHECKBOX
================================ */

.terms-box {
  margin-top: 18px;
  padding: 14px;
  border-radius: var(--radius-md);
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border);
}

.terms-label {
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.5;
  cursor: pointer;
}

.terms-label input {
  margin-right: 8px;
  transform: scale(1.1);
}

.terms-label a {
  color: var(--accent-solid);
  text-decoration: none;
  font-weight: 500;
}

.terms-label a:hover {
  text-decoration: underline;
}
/* ===============================
   TERMS CONSENT – PREMIUM UI
================================ */

.terms-card {
  margin-top: 20px;
  padding: 16px 18px;
  border-radius: 16px;
  background: linear-gradient(
    180deg,
    rgba(255,255,255,0.06),
    rgba(255,255,255,0.02)
  );
  border: 1px solid rgba(255,255,255,0.08);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.03);
}

.terms-check {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  cursor: pointer;
}

.terms-check input {
  display: none;
}

/* custom checkbox */
.checkmark {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.25);
  flex-shrink: 0;
  position: relative;
  transition: all 0.2s ease;
}

/* check icon */
.checkmark::after {
  content: "✓";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  color: #0f172a;
  opacity: 0;
  transform: scale(0.6);
  transition: all 0.2s ease;
}

/* checked state */
.terms-check input:checked + .checkmark {
  background: linear-gradient(135deg, #38bdf8, #6366f1);
  border-color: transparent;
}

.terms-check input:checked + .checkmark::after {
  opacity: 1;
  transform: scale(1);
}

/* text */
.terms-text {
  font-size: 13px;
  line-height: 1.6;
  color: #cbd5f5;
}

.terms-text a {
  color: #7dd3fc;
  text-decoration: none;
  font-weight: 500;
}

.terms-text a:hover {
  text-decoration: underline;
}

/* hover */
.terms-card:hover {
  border-color: rgba(255,255,255,0.16);
}
/* error text */
.terms-error {
  margin-top: 10px;
  font-size: 12px;
  color: #f87171;
  display: none;
}

/* error state */
.terms-card.error {
  border-color: rgba(248,113,113,0.6);
  animation: shake 0.4s ease;
}

.terms-card.error .checkmark {
  border-color: #f87171;
}

/* shake animation */
@keyframes shake {
  0% { transform: translateX(0); }
  25% { transform: translateX(-4px); }
  50% { transform: translateX(4px); }
  75% { transform: translateX(-3px); }
  100% { transform: translateX(0); }
}
.char-counter {
  margin-top: 6px;
  font-size: 13px;
  color: #94a3b8;
  text-align: right;
}

.char-counter.limit {
  color: #ef4444;
  font-weight: 600;
}
.char-counter {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
}

.char-counter.limit {
  color: #ef4444;
}

.input-error {
  display: none;
  margin-top: 6px;
  font-size: 13px;
  color: #ef4444;
}
.sender-error {
  display: none;
  color: #ef4444;
  font-size: 13px;
  margin-top: 6px;
}

.input-shake {
  animation: shake 0.35s;
  border-color: #ef4444 !important;
}

@keyframes shake {
  0% { transform: translateX(0); }
  25% { transform: translateX(-4px); }
  50% { transform: translateX(4px); }
  75% { transform: translateX(-4px); }
  100% { transform: translateX(0); }
}
