*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; font-family: system-ui, sans-serif; background: #f5f5f5; color: #111; }

/* Login */
.login-wrap {
  display: flex; flex-direction: column; align-items: center;
  justify-content: center; min-height: 100vh; padding: 1rem;
}
.login-wrap h1 { margin: 0 0 1.5rem; font-size: 2rem; }
.login-wrap form {
  background: #fff; padding: 2rem; border-radius: 12px;
  box-shadow: 0 2px 12px rgba(0,0,0,.1); width: 100%; max-width: 320px;
  display: flex; flex-direction: column; gap: .75rem;
}
.login-wrap input[type=password] {
  padding: .6rem .8rem; font-size: 1rem; border: 1px solid #ccc;
  border-radius: 8px; width: 100%;
}
.login-wrap button {
  padding: .65rem; font-size: 1rem; background: #2563eb; color: #fff;
  border: none; border-radius: 8px; cursor: pointer;
}
.login-wrap button:hover { background: #1d4ed8; }
.error { color: #dc2626; font-size: .9rem; }

/* Header */
.site-header { background: #1e293b; color: #fff; padding: .75rem 1rem; }
.header-inner { max-width: 900px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; }
.logo { font-size: 1.2rem; font-weight: 600; }
.header-right { display: flex; align-items: center; gap: 1rem; }
.role-badge {
  background: #334155; padding: .25rem .6rem; border-radius: 6px;
  font-size: .8rem; text-transform: uppercase; letter-spacing: .05em;
}
.logout-link { color: #94a3b8; font-size: .9rem; text-decoration: none; }
.logout-link:hover { color: #fff; }

/* Index */
.index-main { max-width: 900px; margin: 2rem auto; padding: 0 1rem; }
.section-title { font-size: 1.4rem; margin: 0 0 1rem; }
.demo-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 1rem; }
.demo-card {
  display: block; background: #fff; padding: 1.25rem; border-radius: 10px;
  box-shadow: 0 1px 4px rgba(0,0,0,.08); text-decoration: none; color: inherit;
  transition: box-shadow .15s;
}
.demo-card:hover { box-shadow: 0 4px 16px rgba(0,0,0,.12); }
.demo-name { font-size: 1.1rem; font-weight: 600; margin-bottom: .4rem; }
.demo-desc { font-size: .9rem; color: #555; }
