/* QuickSettle - Mobile Fintech Styling */
:root {
  --bg-primary: #090d16;
  --bg-card: #131c2e;
  --bg-input: #0a1120;
  --border-color: #23324d;
  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --accent-emerald: #10b981;
  --accent-cyan: #38bdf8;
  --accent-red: #ef4444;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-main);
  line-height: 1.5;
  padding-bottom: 40px;
}

/* Header */
header {
  background: rgba(15, 23, 42, 0.9);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-color);
  padding: 12px 16px;
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.lang-switcher {
  display: flex;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  padding: 2px;
  gap: 2px;
}

.lang-btn {
  border: none;
  background: transparent;
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 700;
  padding: 3px 6px;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.15s;
}

.lang-btn.active {
  background: #10b981;
  color: #fff;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.brand-icon {
  font-size: 20px;
  background: linear-gradient(135deg, #059669, #10b981);
  width: 36px;
  height: 36px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 14px rgba(16, 185, 129, 0.3);
}

.brand-title {
  font-size: 17px;
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.3px;
}

.brand-sub {
  font-size: 11px;
  color: var(--text-muted);
}

.currency-picker {
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  color: var(--accent-emerald);
  font-size: 13px;
  font-weight: 700;
  padding: 5px 8px;
  border-radius: 6px;
  outline: none;
}

/* Container */
.container {
  max-width: 580px;
  margin: 0 auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Card Module */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  padding: 16px;
}

.card-title {
  font-size: 14px;
  font-weight: 700;
  color: #e2e8f0;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Members Tag Input */
.members-input-row {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
}

.form-input {
  flex: 1;
  padding: 10px 12px;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  color: #fff;
  font-size: 13.5px;
  outline: none;
}

.form-input:focus {
  border-color: var(--accent-emerald);
}

.btn-add {
  background: #059669;
  color: #fff;
  font-weight: 700;
  font-size: 13px;
  border: none;
  padding: 0 16px;
  border-radius: 8px;
  cursor: pointer;
  white-space: nowrap;
}
.btn-add:hover {
  background: #10b981;
}

.member-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.member-chip {
  background: #1e293b;
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: 5px 12px;
  font-size: 12.5px;
  color: #cbd5e1;
  display: flex;
  align-items: center;
  gap: 6px;
}

.chip-remove {
  color: #94a3b8;
  cursor: pointer;
  font-weight: bold;
  font-size: 14px;
  line-height: 1;
}
.chip-remove:hover {
  color: var(--accent-red);
}

/* Expense List */
.expense-item {
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 12px;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.exp-left {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.exp-title {
  font-size: 14px;
  font-weight: 700;
  color: #f1f5f9;
}

.exp-meta {
  font-size: 11px;
  color: var(--text-muted);
}

.exp-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.exp-amount {
  font-size: 15px;
  font-weight: 800;
  color: var(--accent-emerald);
  font-family: monospace;
}

.btn-del-exp {
  background: none;
  border: none;
  color: #64748b;
  font-size: 16px;
  cursor: pointer;
}
.btn-del-exp:hover {
  color: var(--accent-red);
}

/* Add Expense Dialog / Form */
.expense-form {
  background: var(--bg-input);
  border: 1px dashed var(--border-color);
  border-radius: 10px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.form-row-2col {
  display: grid;
  grid-template-columns: 1.5fr 1fr;
  gap: 8px;
}

.form-select {
  width: 100%;
  padding: 9px 10px;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  color: #fff;
  font-size: 13px;
  outline: none;
}

.beneficiaries-picker {
  font-size: 12px;
  color: var(--text-muted);
}

.beneficiaries-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}

.ben-checkbox-label {
  display: flex;
  align-items: center;
  gap: 4px;
  background: #1e293b;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 11.5px;
  color: #cbd5e1;
  cursor: pointer;
}

.ben-checkbox-label input {
  accent-color: var(--accent-emerald);
}

/* Settlement Result Card */
.settlement-card {
  background: linear-gradient(180deg, #132238, #0e1726);
  border: 1px solid #10b981;
  box-shadow: 0 8px 24px -10px rgba(16, 185, 129, 0.25);
}

.settlement-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.transfer-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}

.transfer-item {
  background: rgba(15, 23, 42, 0.7);
  border: 1px solid #233857;
  border-radius: 10px;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 13.5px;
}

.transfer-party {
  display: flex;
  align-items: center;
  gap: 6px;
}

.transfer-arrow {
  color: var(--accent-emerald);
  font-weight: 800;
}

.transfer-val {
  font-size: 16px;
  font-weight: 850;
  color: #34d399;
  font-family: monospace;
}

.btn-share {
  width: 100%;
  padding: 12px;
  background: linear-gradient(135deg, #059669, #10b981);
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: transform 0.15s, filter 0.15s;
}
.btn-share:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
}

/* Toast */
.toast {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  background: #10b981;
  color: #000;
  font-weight: 700;
  font-size: 13px;
  padding: 10px 20px;
  border-radius: 30px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 1000;
  pointer-events: none;
}
.toast.show {
  transform: translateX(-50%) translateY(0);
}

/* Mobile Ad Slots */
.ad-mobile-slot {
  margin: 12px 0;
  text-align: center;
}

.ad-mobile-box {
  min-height: 90px;
  background: rgba(15, 23, 42, 0.5);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.ad-subtext {
  font-size: 10px;
  color: #64748b;
  text-transform: uppercase;
  margin-top: 4px;
}
