:root {
  --blue: #1155c7;
  --blue-dark: #061d4f;
  --green: #05c989;
  --primary: #1155c7;
  --secondary: #05c989;
  --accent: #00bad1;
  --ink: #272a3d;
  --muted: #6f7282;
  --line: #e5e8f0;
  --soft: #f6f8fc;
  --white: #ffffff;
  --danger: #d94848;
  --shadow: 0 18px 46px rgba(18, 37, 71, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  background: #ffffff;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

a {
  color: inherit;
  text-decoration: none;
}

.shell {
  min-height: 100vh;
  display: grid;
  grid-template-rows: auto 1fr auto;
}

.topbar {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 24px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  color: var(--blue);
  font-size: 1.6rem;
  letter-spacing: 0;
}

.brand-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  color: var(--white);
  background: linear-gradient(135deg, var(--blue), var(--green));
}

.secure-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border: 1px solid rgba(17, 85, 199, 0.16);
  border-radius: 999px;
  color: #43506a;
  background: rgba(255, 255, 255, 0.72);
  font-size: 0.84rem;
  font-weight: 700;
}

.main {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 26px 0 54px;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 420px;
  align-items: center;
  gap: 42px;
}

.hero h1 {
  max-width: 720px;
  margin: 0 0 18px;
  color: var(--blue-dark);
  font-size: clamp(2.3rem, 6vw, 4.8rem);
  line-height: 0.96;
  letter-spacing: 0;
}

.hero p {
  max-width: 620px;
  margin: 0;
  color: var(--muted);
  font-size: 1.08rem;
  line-height: 1.7;
}

.panel {
  border: 1px solid rgba(229, 232, 240, 0.92);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: var(--shadow);
}

.access-panel {
  padding: 26px;
}

.panel-title {
  margin: 0 0 8px;
  color: var(--blue-dark);
  font-size: 1.2rem;
  font-weight: 800;
}

.panel-subtitle {
  margin: 0 0 22px;
  color: var(--muted);
  font-size: 0.94rem;
  line-height: 1.55;
}

.form-group {
  display: grid;
  gap: 8px;
  margin-bottom: 16px;
}

label {
  color: #464b60;
  font-size: 0.84rem;
  font-weight: 800;
}

input {
  width: 100%;
  height: 48px;
  padding: 0 14px;
  border: 1px solid #d8deea;
  border-radius: 8px;
  color: var(--ink);
  background: var(--white);
  font: inherit;
  outline: none;
}

input:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(17, 85, 199, 0.12);
}

.button {
  width: 100%;
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 0;
  border-radius: 8px;
  color: var(--white);
  background: var(--primary);
  font: inherit;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 14px 30px rgba(17, 85, 199, 0.24);
}

.button:hover {
  filter: brightness(0.92);
}

.link-button {
  display: inline-flex;
  margin-top: 18px;
  color: var(--blue);
  font-size: 0.9rem;
  font-weight: 800;
}

.notice {
  margin: 0 0 18px;
  padding: 12px 14px;
  border-radius: 8px;
  font-size: 0.9rem;
  line-height: 1.45;
}

.notice.error {
  color: #8a1f1f;
  background: #fff0f0;
  border: 1px solid #ffd5d5;
}

.notice.info {
  color: #2d4774;
  background: #eef5ff;
  border: 1px solid #d7e6ff;
}

.login-page .shell {
  min-height: 100vh;
  grid-template-rows: 1fr;
}

.login-page .topbar,
.login-page .footer {
  display: none;
}

.login-page .main {
  width: min(100% - 32px, 520px);
  padding: 28px 0;
  display: grid;
  align-items: center;
}

.system-page {
  background: #f8f7fb;
}

.system-page .shell {
  min-height: 100vh;
  grid-template-rows: 1fr;
}

.system-page .topbar,
.system-page .footer {
  display: none;
}

.system-page .main {
  width: 100%;
  padding: 0;
}

.app-layout {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  color: #5d596c;
}

.app-sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 26px 14px;
  border-right: 1px solid #ebeaf2;
  background: #fff;
  box-shadow: 0 8px 24px rgba(37, 34, 64, 0.06);
}

.app-sidebar-brand {
  min-height: 58px;
  margin: 0 10px 18px;
  display: flex;
  align-items: center;
}

.app-sidebar-brand img {
  width: 138px;
  height: auto;
}

.app-menu {
  display: grid;
  gap: 4px;
}

.app-menu a {
  min-height: 40px;
  padding: 0 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-radius: 8px;
  color: #6f6b7d;
  font-weight: 500;
}

.app-menu a:hover,
.app-menu a.active {
  color: #fff;
  background: var(--primary);
  box-shadow: 0 4px 14px rgba(37, 34, 64, 0.22);
}

.app-menu span {
  width: 20px;
  display: inline-flex;
  justify-content: center;
  font-weight: 700;
}

.app-content {
  min-width: 0;
  padding: 30px 24px;
}

.app-navbar {
  min-height: 64px;
  margin-bottom: 24px;
  padding: 12px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 4px 18px rgba(37, 34, 64, 0.08);
}

.app-search {
  width: min(560px, 52vw);
  min-height: 40px;
  display: flex;
  align-items: center;
  padding: 0 16px;
  border-radius: 8px;
  color: #a5a2b2;
  background: #fbfbfd;
}

.app-user {
  display: flex;
  align-items: center;
  gap: 14px;
  white-space: nowrap;
}

.app-user span {
  color: #302d43;
  font-weight: 700;
}

.app-user a {
  color: var(--primary);
  font-weight: 800;
}

.app-hero {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 24px;
  padding: 28px 24px;
  border: 1px solid color-mix(in srgb, var(--secondary) 24%, #ebeaf2);
  border-radius: 8px;
  background: linear-gradient(90deg, #fff 0%, #f0fbf7 100%);
}

.app-hero h1 {
  margin: 0;
  color: #302d43;
  font-size: 1.58rem;
  line-height: 1.2;
}

.app-hero p {
  margin: 8px 0 0;
  color: #6f6b7d;
}

.app-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 24px;
}

.app-metric-card {
  min-height: 120px;
  padding: 18px;
  border: 1px solid #ebeaf2;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 8px 22px rgba(37, 34, 64, 0.05);
}

.app-metric-card span {
  display: block;
  margin-bottom: 12px;
  color: #77738a;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.app-metric-card strong {
  display: block;
  color: #302d43;
  font-size: 1.34rem;
  line-height: 1.2;
}

.app-grid {
  display: grid;
  grid-template-columns: minmax(360px, 460px) minmax(0, 1fr);
  gap: 24px;
  align-items: stretch;
}

.vuexy-auth {
  min-height: calc(100vh - 56px);
  display: grid;
  place-items: center;
}

.vuexy-login-card {
  width: min(450px, 100%);
  margin: 0 auto;
  padding: 34px;
  border: 1px solid #ebeaf2;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 8px 28px rgba(47, 43, 61, 0.12);
}

.login-logo {
  display: block;
  width: 178px;
  max-width: 72%;
  height: auto;
  margin: 0 auto 24px;
}

.login-title {
  margin: 0;
  color: #4a4d64;
  font-size: 1.38rem;
  line-height: 1.25;
  text-align: center;
  font-weight: 500;
}

.login-subtitle {
  margin: 8px 0 28px;
  color: #62677e;
  text-align: center;
  font-size: 0.95rem;
}

.vuexy-login-card .notice {
  margin-bottom: 18px;
  text-align: left;
}

.vuexy-login-card label {
  font-weight: 500;
}

.vuexy-login-card input {
  height: 42px;
  border-color: #d7d9e2;
}

.vuexy-login-card .button {
  min-height: 42px;
  margin-top: 2px;
}

.profile-card {
  overflow: hidden;
  margin-bottom: 24px;
  border: 1px solid #ebeaf2;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 8px 22px rgba(37, 34, 64, 0.05);
}

.profile-cover {
  position: relative;
  height: 210px;
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--primary) 88%, #000), color-mix(in srgb, var(--secondary) 72%, transparent)),
    radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.28), transparent 32%),
    var(--primary);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.cover-upload-form {
  position: absolute;
  right: 18px;
  bottom: 18px;
}

.cover-upload-form input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
}

.cover-upload-form label {
  min-height: 36px;
  padding: 0 14px;
  display: inline-flex;
  align-items: center;
  border-radius: 6px;
  color: #fff;
  background: rgba(47, 43, 61, 0.72);
  box-shadow: 0 8px 18px rgba(47, 43, 61, 0.18);
  cursor: pointer;
}

.profile-head {
  min-height: 120px;
  padding: 20px 24px;
  display: flex;
  align-items: center;
  gap: 18px;
}

.profile-avatar {
  width: 112px;
  height: 112px;
  margin-top: 0;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  border: 5px solid #fff;
  border-radius: 8px;
  overflow: hidden;
  color: #fff;
  background: var(--primary);
  box-shadow: 0 6px 18px rgba(47, 43, 61, 0.16);
  font-size: 2rem;
  font-weight: 800;
}

.profile-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.profile-title {
  min-width: 0;
  flex: 1 1 auto;
}

.profile-title h1 {
  margin: 0;
  color: #302d43;
  font-size: 1.6rem;
  line-height: 1.2;
}

.profile-title p {
  margin: 8px 0 0;
  color: #6f6b7d;
}

.profile-actions {
  margin-left: auto;
}

.profile-status {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 14px;
  border-radius: 6px;
  color: var(--secondary);
  background: color-mix(in srgb, var(--secondary) 14%, transparent);
  font-weight: 800;
}

.profile-tabs {
  padding: 0 24px 18px;
  display: flex;
  gap: 10px;
  overflow-x: auto;
}

.profile-tabs a {
  min-height: 38px;
  padding: 0 14px;
  display: inline-flex;
  align-items: center;
  border-radius: 6px;
  color: #6f6b7d;
  font-weight: 700;
  white-space: nowrap;
}

.profile-tabs a.active,
.profile-tabs a:hover {
  color: #fff;
  background: var(--primary);
}

.profile-grid {
  display: grid;
  grid-template-columns: minmax(300px, 0.85fr) minmax(300px, 1.15fr);
  gap: 24px;
  align-items: stretch;
}

.profile-panel-title {
  margin: 0;
  padding: 22px 24px 0;
  color: #302d43;
  font-size: 1.05rem;
}

.digital-card {
  margin: 24px;
  min-height: 280px;
  overflow: hidden;
  border-radius: 8px;
  color: #302d43;
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--primary) 18%, transparent), color-mix(in srgb, var(--secondary) 16%, transparent)),
    #dff6ff;
  border: 1px solid color-mix(in srgb, var(--primary) 24%, #d8deea);
  box-shadow: 0 12px 28px rgba(47, 43, 61, 0.14);
}

.id-card {
  position: relative;
}

.id-card::before,
.id-card::after {
  content: "";
  position: absolute;
  inset: auto auto -90px -60px;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  background: color-mix(in srgb, var(--primary) 15%, transparent);
}

.id-card::after {
  inset: -90px -80px auto auto;
  background: color-mix(in srgb, var(--secondary) 22%, transparent);
}

.id-card-top,
.id-card-body {
  position: relative;
  z-index: 1;
}

.id-card-top {
  min-height: 72px;
  padding: 16px 18px;
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
}

.id-card-top img {
  max-width: 92px;
  max-height: 42px;
  object-fit: contain;
  padding: 4px 6px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.92);
}

.id-card-top strong,
.id-card-top span,
.id-card-top b {
  display: block;
}

.id-card-top strong {
  color: #fff;
  font-size: 0.95rem;
  line-height: 1.15;
}

.id-card-top span {
  margin-top: 3px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.78rem;
  font-weight: 700;
}

.id-card-top b {
  padding: 8px 10px;
  border-radius: 6px;
  color: #fff;
  background: rgba(0, 0, 0, 0.18);
  white-space: nowrap;
}

.id-card-body {
  padding: 20px;
  display: grid;
  grid-template-columns: 116px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.id-card-photo {
  width: 116px;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  display: grid;
  place-items: center;
  border: 4px solid #fff;
  border-radius: 8px;
  background: var(--primary);
  box-shadow: 0 8px 20px rgba(47, 43, 61, 0.16);
}

.id-card-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.id-card-photo span {
  color: #fff;
  font-size: 2rem;
  font-weight: 800;
}

.id-card-data label {
  color: #6f6b7d;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.id-card-data h3 {
  margin: 4px 0 16px;
  color: #1f2340;
  font-size: 1.32rem;
  line-height: 1.15;
}

.id-card-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 16px;
}

.id-card-fields span,
.id-card-fields strong {
  display: block;
}

.id-card-fields span {
  margin-bottom: 2px;
  color: #6f6b7d;
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
}

.id-card-fields strong {
  color: #302d43;
  font-size: 0.88rem;
  line-height: 1.25;
}

.profile-wide {
  grid-column: 1 / -1;
}

.association-name {
  display: inline-flex;
  margin-bottom: 18px;
  padding: 8px 11px;
  border-radius: 999px;
  color: var(--blue-dark);
  background: #eaf3ff;
  font-size: 0.84rem;
  font-weight: 800;
}

.card-page {
  display: grid;
  grid-template-columns: 420px minmax(0, 1fr);
  gap: 28px;
  align-items: start;
}

.member-card {
  overflow: hidden;
}

.member-card-head {
  padding: 24px;
  color: var(--white);
  background: linear-gradient(135deg, var(--blue-dark), var(--blue) 72%, var(--green));
}

.member-card-head small {
  display: block;
  margin-bottom: 22px;
  color: rgba(255, 255, 255, 0.72);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.member-name {
  margin: 0;
  font-size: 1.55rem;
  line-height: 1.15;
}

.member-number {
  margin-top: 16px;
  font-size: 0.96rem;
  font-weight: 800;
}

.member-card-body {
  padding: 24px;
  display: grid;
  gap: 16px;
}

.data-row {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.data-row:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.data-row span {
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 800;
}

.data-row strong {
  text-align: right;
}

.status-ok {
  color: #047857;
}

.dashboard-panel {
  padding: 28px;
}

.dashboard-panel h2 {
  margin: 0 0 10px;
  color: var(--blue-dark);
}

.dashboard-panel p {
  margin: 0 0 22px;
  color: var(--muted);
  line-height: 1.6;
}

.quick-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.quick-item {
  min-height: 112px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
}

.quick-item strong {
  display: block;
  margin-bottom: 8px;
  color: var(--blue-dark);
}

.quick-item span {
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.5;
}

.footer {
  width: min(1120px, calc(100% - 32px));
  min-height: 74px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border-top: 1px solid rgba(20, 47, 88, 0.1);
  color: #7b8395;
  font-size: 0.84rem;
}

.logout {
  color: var(--blue);
  font-weight: 800;
}

@media (max-width: 860px) {
  .hero-grid,
  .card-page {
    grid-template-columns: 1fr;
  }

  .quick-grid {
    grid-template-columns: 1fr;
  }

  .app-layout {
    grid-template-columns: 1fr;
  }

  .app-sidebar {
    position: relative;
    height: auto;
  }

  .app-menu {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .app-content {
    padding: 18px 14px 28px;
  }

  .app-navbar {
    align-items: stretch;
    flex-direction: column;
  }

  .app-search {
    width: 100%;
  }

  .app-metrics,
  .app-grid,
  .profile-grid {
    grid-template-columns: 1fr;
  }

  .profile-head {
    align-items: center;
    flex-direction: column;
    text-align: center;
  }

  .profile-actions {
    margin-left: 0;
  }

  .id-card-top,
  .id-card-body,
  .id-card-fields {
    grid-template-columns: 1fr;
  }

  .id-card-top b {
    width: fit-content;
  }
}

@media (max-width: 560px) {
  .topbar,
  .footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .login-page .main {
    width: min(100% - 24px, 520px);
    padding: 12px 0 28px;
  }

  .access-panel,
  .vuexy-login-card,
  .dashboard-panel {
    padding: 22px;
  }
}
