:root {
  --accent-1: #ff6b6b;
  --accent-2: #ff8e53;
  --bg-light: #ffffff;
  --bg-dark: #0f0f10;
  --card-light: #ffffff;
  --card-dark: #1e1f24;
  --text-light: #000000;
  --text-dark: #ffffff;
  --radius-xl: 18px;
  --shadow-1: 0 14px 30px rgba(0,0,0,.15);
}

body {
  font-family: 'Inter', 'Noto Sans JP', sans-serif;
  background: var(--bg-light);
  color: var(--text-light);
  transition: background .2s ease, color .2s ease;
}

body.theme-dark {
  background: var(--bg-dark);
  color: var(--text-dark);
}

.app-bar {
  background: linear-gradient(90deg, var(--accent-1), var(--accent-2));
  color: #fff;
}
.app-logo { font-weight:600; color:#fff; }
.app-bar .btn-link { color:#fff; }

.bottom-nav { position:sticky; left:0; right:0; bottom:0; background:var(--bg-light); border-top:1px solid #ddd; display:flex; justify-content:space-around; z-index:1050; backdrop-filter:saturate(140%) blur(6px); }
.bottom-nav a,
.bottom-nav form{ flex:1; }
.bottom-nav a,
.bottom-nav form button{ text-align:center; padding:.5rem 0; color:#666; text-decoration:none; font-size:.75rem; background:none; border:0; width:100%; }
.bottom-nav a i,
.bottom-nav form button i{ display:block; font-size:1.2rem; }
.bottom-nav a.active{ color:var(--accent-1); }
.bottom-nav form button:disabled{opacity:.6;}
body.theme-dark .bottom-nav{ background:var(--card-dark); border-color:#333; }
body.theme-dark .bottom-nav a,
body.theme-dark .bottom-nav form button{ color:#aaa; }

.fab { position:fixed; right:1rem; bottom:4.5rem; width:56px; height:56px; border-radius:50%; background:linear-gradient(135deg, var(--accent-1), var(--accent-2)); color:#fff; display:flex; align-items:center; justify-content:center; font-size:1.5rem; text-decoration:none; z-index:1030; box-shadow:var(--shadow-1); }

.card { border:none; border-radius:var(--radius-xl); box-shadow:var(--shadow-1); }
.card:hover { transform:translateY(-2px); box-shadow:0 20px 40px rgba(0,0,0,.2); }

.toast-container { z-index:1050; }
.text-bg-error { background-color:#dc3545 !important; }

.calendar-table table td { border:0; padding:.5rem; }
.calendar-table table td a { font-weight:600; text-decoration:none; }
.calendar-table table td { border-radius:var(--radius-xl); box-shadow:var(--shadow-1); }
.calendar-table table td.bg-light { box-shadow:none; }

.card-table-row { display:flex; justify-content:space-between; padding:.75rem 1rem; border-bottom:1px solid rgba(0,0,0,.05); }
.card-table-row:last-child { border-bottom:none; }

.transaction-cards .tx-card { position:relative; }
.transaction-cards .tx-card .badge { color:#fff; }

body.theme-dark .card { background:var(--card-dark); color:var(--text-dark); }
body.theme-dark .bottom-nav a.active { color:var(--accent-2); }
body.theme-dark .fab { box-shadow:0 14px 30px rgba(0,0,0,.5); }

.dropzone { border:2px dashed var(--accent-1); border-radius:var(--radius-xl); text-align:center; }
.dropzone input[type=file] { display:block; margin:1rem auto; }

@media (min-width:768px){
  .bottom-nav, .fab { display:none; }
}
/* avoid auth page collision */
body.auth-body .bottom-nav,
body.auth-body .fab { display:none !important; }
