@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;600;700;800&display=swap');

:root {
  --bg: #0d1125;
  --circle1: #c77dff;
  --circle2: #00eaff;
  --circle3: #ffc400;
  --glass-bg: rgba(255,255,255,0.06);
  --border: rgba(255,255,255,0.1);
  --text: #ffffff;
  --muted: #b4b8d1;
  --accent: #5bc0ff;
  --radius: 16px;
  --nav-h: 72px;
  --maxw: 1080px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  height: 100%;
  font-family: 'Manrope', sans-serif;
  background: var(--bg);
  color: var(--text);
  overflow: hidden;
}

/* === APP STRUCTURE === */
.app-shell {
  width: 100%;
  height: 100vh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  position: relative;
  overflow: hidden;
}

/* === BACKGROUND BALLOONS === */
.app-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.circle {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.4;
}

.c1 {
  width: 360px;
  height: 360px;
  left: -120px;
  top: -60px;
  background: radial-gradient(circle, var(--circle1), transparent 70%);
}

.c2 {
  width: 500px;
  height: 500px;
  right: -160px;
  bottom: -140px;
  background: radial-gradient(circle, var(--circle2), transparent 70%);
}

.c3 {
  width: 280px;
  height: 280px;
  left: 60%;
  top: 25%;
  background: radial-gradient(circle, var(--circle3), transparent 75%);
}

/* === HEADER === */
.topbar {
  z-index: 5;
  padding: 14px 18px;
}

.header-card {
  background: linear-gradient(180deg, rgba(255,255,255,0.08), rgba(255,255,255,0.02));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 14px;
  box-shadow: 0 10px 40px rgba(0,0,0,0.45);
  backdrop-filter: blur(14px);
}

.logo {
  width: 60px;
  height: 60px;
  object-fit: contain;
  border-radius: 14px;
  background: rgba(255,255,255,0.04);
  box-shadow: 0 8px 22px rgba(0,0,0,0.4);
}

.title-wrap h1 {
  font-size: 20px;
  font-weight: 800;
}

.subtitle {
  font-size: 13px;
  color: var(--muted);
}

/* === CONTENT === */
.content {
  position: relative;
  z-index: 2;
  overflow-y: auto;
  padding: 20px 16px 90px;
  scrollbar-width: none;
}

.content::-webkit-scrollbar {
  display: none;
}

.content-inner {
  width: 100%;
  max-width: calc(var(--maxw) - 60px);
  margin: 0 auto;
}

.glass-card {
  background: linear-gradient(180deg, rgba(255,255,255,0.07), rgba(255,255,255,0.03));
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 22px;
  margin-bottom: 18px;
  backdrop-filter: blur(10px);
  box-shadow: 0 12px 34px rgba(0,0,0,0.4);
}

.glass-card h2 {
  color: var(--accent);
  font-size: 16px;
  font-weight: 800;
  margin-bottom: 8px;
}

.glass-card p {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.6;
}

.center-card {
  text-align: center;
}

/* === LOGIN === */
.center-content {
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
}

.login {
  max-width: 420px;
  width: 90%;
  text-align: center;
  background: linear-gradient(180deg, rgba(255,255,255,0.08), rgba(255,255,255,0.03));
  border-radius: 16px;
  padding: 30px 24px;
  border: 1px solid var(--border);
  box-shadow: 0 18px 50px rgba(0,0,0,0.45);
  backdrop-filter: blur(16px);
  animation: fadeIn 0.4s ease-out;
}

.login h2 {
  font-weight: 800;
  font-size: 20px;
  margin-top: 10px;
  margin-bottom: 4px;
}

.login .subtitle {
  color: var(--muted);
  margin-bottom: 20px;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* === INPUTS === */
label {
  display: block;
  text-align: left;
  font-size: 13px;
  font-weight: 700;
  color: var(--muted);
  margin-bottom: 6px;
}

input {
  width: 100%;
  border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.08);
  color: var(--text);
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 14px;
  margin-bottom: 14px;
  outline: none;
}

input:focus {
  border-color: var(--accent);
}

.pw {
  position: relative;
}

.pw-btn {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--muted);
  font-size: 16px;
  cursor: pointer;
  line-height: 1;
}

.pw-btn:hover {
  color: var(--accent);
}

/* === BUTTONS === */
.btn {
  flex: 1;
  border: none;
  border-radius: 12px;
  font-weight: 800;
  padding: 10px 14px;
  cursor: pointer;
  transition: 0.25s ease;
}

.btn.primary {
  background: linear-gradient(135deg, var(--accent), #00eaff);
  color: #0a1b3d;
  box-shadow: 0 4px 14px rgba(91,192,255,0.4);
}

.btn.primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(91,192,255,0.55);
}

.btn.ghost {
  background: transparent;
  border: 1px solid rgba(255,255,255,0.08);
  color: var(--muted);
}

.btn.ghost:hover {
  color: var(--accent);
  border-color: var(--accent);
}

.modal-actions {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-top: 14px;
}

/* === MODAL === */
.modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(10,15,30,0.6);
  backdrop-filter: blur(10px);
  justify-content: center;
  align-items: center;
  z-index: 50;
}

.modal-panel {
  width: 90%;
  max-width: 420px;
  border-radius: 16px;
  border: 1px solid rgba(255,255,255,0.1);
  background: linear-gradient(180deg, rgba(255,255,255,0.08), rgba(255,255,255,0.03));
  box-shadow: 0 20px 50px rgba(0,0,0,0.5);
  padding: 26px 24px;
  animation: fadeIn 0.4s ease;
}

.modal-logo {
  width: 70px;
  height: 70px;
  object-fit: contain;
  margin-bottom: 8px;
}

.modal-header {
  position: relative;
  text-align: center;
  margin-bottom: 16px;
}

.modal-header h2 {
  font-size: 20px;
  font-weight: 800;
}

.modal-header p {
  font-size: 13px;
  color: var(--muted);
}

.modal-close {
  position: absolute;
  right: 10px;
  top: 6px;
  background: none;
  border: none;
  color: var(--muted);
  font-size: 22px;
  cursor: pointer;
}

.modal-close:hover {
  color: var(--accent);
  transform: scale(1.2);
}

/* === NAVBAR === */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  height: var(--nav-h);
  z-index: 99;
  display: flex;
  justify-content: center;
  align-items: center;
  backdrop-filter: blur(10px);
  background: linear-gradient(180deg, rgba(8, 15, 35, 0.9), rgba(4, 10, 25, 0.95));
  border-top: 1px solid rgba(255,255,255,0.05);
  box-shadow: 0 -6px 24px rgba(0,0,0,0.5);
}

.nav-inner {
  width: 100%;
  max-width: 1080px;
  display: flex;
  justify-content: space-around;
  align-items: center;
}

.nav-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  color: var(--muted);
  font-weight: 800;
  background: none;
  border: none;
  cursor: pointer;
  transition: all 0.25s ease;
}

.nav-btn:hover,
.nav-btn.active {
  color: var(--accent);
  transform: translateY(-3px);
}

.icon-3d {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: linear-gradient(180deg, rgba(255,255,255,0.08), rgba(255,255,255,0.03));
  box-shadow: 0 6px 18px rgba(0,0,0,0.45);
  position: relative;
  margin-bottom: 4px;
}

.icon-home::before,
.icon-login::before {
  content: "";
  position: absolute;
  left: 9px;
  top: 9px;
  width: 22px;
  height: 22px;
  background: linear-gradient(180deg, #ffffff, #cde7ff);
  filter: drop-shadow(0 3px 6px rgba(0,0,0,0.35));
}

.icon-home::before {
  mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="%23000" d="M3 11.5L12 4l9 7.5V20a1 1 0 0 1-1 1h-5v-6H9v6H4a1 1 0 0 1-1-1V11.5z"/></svg>');
}

.icon-login::before {
  background: linear-gradient(180deg, #ffd8c6, #ffc19a);
  mask: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path fill="%23000" d="M10 17v-2h6v-6h-6V7l-5 5 5 5zM19 3h-8v2h8v14h-8v2h8a2 2 0 0 0 2-2V5a2 2 0 0 0-2-2z"/></svg>');
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
  .header-card {
    padding: 12px 16px;
  }
  .logo {
    width: 50px;
    height: 50px;
  }
  .title-wrap h1 {
    font-size: 18px;
  }
  .subtitle {
    font-size: 12px;
  }
  .glass-card {
    padding: 18px;
  }
  .nav-btn span {
    font-size: 11.5px;
  }
}

@media (max-width: 380px) {
  .header-card {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
  .logo {
    width: 44px;
    height: 44px;
  }
  .title-wrap h1 {
    font-size: 16px;
  }
  .subtitle {
    font-size: 11px;
  }
  .nav-label {
    font-size: 10.5px;
  }
}
