body {
  overflow-y: auto;
}

.profile-layout {
  position: relative;
  min-height: 100vh;
  padding: 1rem 1rem 6.2rem;
  pointer-events: none;
}

.profile-wrap {
  position: relative;
  top: auto;
  left: auto;
  transform: none;
  margin: 0 auto;
  width: min(1500px, calc(100vw - 1.4rem));
  pointer-events: none;
}

.profile-shell {
  width: 100%;
  min-height: min(920px, calc(100vh - 140px));
  padding: 0.25rem 0;
  pointer-events: auto;
}

.dashboard-page {
  width: min(1500px, calc(100vw - 1.4rem));
  margin: 0 auto;
  pointer-events: auto;
}

.dashboard-stage {
  display: grid;
  gap: 0.9rem;
}

.dashboard-content-card {
  padding: 1rem;
}

.profile-hero {
  margin: 0 0 0.85rem;
}

.profile-hero.is-hidden {
  display: none;
}

.login-intro {
  display: grid;
  justify-items: center;
  gap: 0.18rem;
}

.login-id-art {
  width: min(56vw, 290px);
  height: auto;
  object-fit: contain;
}

.login-intro .message {
  text-align: center;
}

.surface {
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.84), rgba(255, 255, 255, 0.64));
  border: 1px solid rgba(255, 255, 255, 0.92);
  border-radius: 20px;
  box-shadow: 0 18px 38px rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.login-surface {
  margin-top: 0;
  padding: 1.2rem;
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
}

.remember-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.2rem;
  color: #383838;
  font-size: 0.92rem;
}

.remember-row input {
  width: 16px;
  height: 16px;
  margin: 0;
}

.ghost-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-width: 220px;
  margin-top: 0.2rem;
  min-height: 44px;
  padding: 0.7rem 1.2rem;
  border-radius: 999px;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.76);
  color: #111;
  border: 1px solid rgba(0, 0, 0, 0.2);
  text-decoration: none;
  text-align: center;
  justify-self: center;
}

.ghost-btn:hover {
  background: rgba(255, 255, 255, 0.9);
  color: #111;
  border-color: rgba(0, 0, 0, 0.28);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.08);
}

.modern-dashboard {
  display: grid;
  gap: 0.9rem;
  min-height: 660px;
}

.dash-header {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 0.65rem;
  padding: 0.2rem 0;
  min-height: 62px;
}

.dash-user {
  display: flex;
  align-items: center;
  gap: 0.72rem;
  justify-self: start;
}

.avatar-circle {
  width: 58px;
  height: 58px;
  border-radius: 999px;
  border: 1px solid rgba(0, 0, 0, 0.17);
  background: radial-gradient(circle at 30% 30%, #ffffff, #dedede);
  display: grid;
  place-items: center;
  font-size: 1.02rem;
  font-weight: 800;
  letter-spacing: 0.03em;
}

.name-stack {
  display: grid;
}

.first-name,
.last-name {
  margin: 0;
  line-height: 1.05;
}

.first-name {
  font-weight: 800;
  font-size: 1.02rem;
}

.last-name {
  font-weight: 600;
  font-size: 0.95rem;
  color: #343434;
}

.dash-tabs {
  justify-self: center;
  width: fit-content;
  min-width: 0;
  max-width: none;
  height: 56px;
  min-height: 56px;
  display: flex;
  align-items: center;
  gap: 0.18rem;
  padding: 0.24rem 0.28rem;
  border-radius: 999px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  background: rgba(255, 255, 255, 0.72);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.dash-tab {
  margin: 0;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: #151515;
  font-weight: 700;
  min-width: 42px;
  height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0 0.58rem;
  cursor: pointer;
  transition: all 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}

.tab-ico {
  font-size: 1rem;
  line-height: 1;
}

.tab-ico i {
  font-size: 1.06rem;
  line-height: 1;
  display: inline-block;
}

.tab-label {
  max-width: 0;
  overflow: hidden;
  white-space: nowrap;
  opacity: 0;
  transform: translateX(-4px);
  transition: max-width 0.3s ease, opacity 0.25s ease, transform 0.25s ease;
}

.dash-tab.is-active {
  background: #111;
  color: #fff;
  border-color: #111;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
  min-width: 128px;
  justify-content: flex-start;
}

.dash-tab.is-active .tab-label {
  max-width: 140px;
  opacity: 1;
  transform: translateX(0);
}

.dash-tab:hover {
  transform: translateY(-1px);
  background: rgba(255, 255, 255, 0.95);
  color: #111;
}

.dash-tab.is-active:hover {
  background: #111;
  color: #fff;
}

.logout-icon {
  width: 46px;
  height: 46px;
  border: 1px solid #111;
  border-radius: 999px;
  background: #111;
  color: #fff;
  display: grid;
  place-items: center;
  margin: 0;
  padding: 0;
  justify-self: end;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.logout-icon:hover {
  background: #111;
  color: #fff;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.2);
}

.logout-icon i {
  font-size: 1.12rem;
  line-height: 1;
}

.logout-icon:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.2);
}

.dash-id-row {
  margin-top: 0.2rem;
  display: grid;
  justify-items: center;
  gap: 0.08rem;
}

.dash-id-art {
  width: min(58vw, 300px);
  height: auto;
  object-fit: contain;
}

.dash-status {
  margin: 0;
  font-size: 1.02rem;
  color: #363636;
  font-weight: 600;
}

.dash-content {
  min-width: 0;
  display: grid;
}

.tab-section {
  display: none;
  opacity: 0;
  transform: translateY(10px) scale(0.995);
}

.tab-section.is-active {
  display: block;
  animation: sectionIn 0.42s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes sectionIn {
  from {
    opacity: 0;
    transform: translateY(14px) scale(0.995);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.home-grid {
  display: grid;
  gap: 0.8rem;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-bottom: 0.86rem;
}

.metric-card {
  padding: 1rem 1rem 1.1rem;
}

.metric-kicker {
  margin: 0;
  font-size: 0.92rem;
  color: #4e4e4e;
}

.metric-value {
  margin: 0.5rem 0 0;
  font-size: clamp(1.9rem, 2.9vw, 2.6rem);
  font-weight: 800;
  letter-spacing: -0.02em;
}

.bank-panel {
  padding: 1rem;
}

.feed-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.6rem;
}

.feed-head h3 {
  margin: 0;
  font-size: 1.02rem;
}

.feed-badge {
  border: 1px solid #111;
  border-radius: 999px;
  padding: 0.22rem 0.62rem;
  font-size: 0.75rem;
  font-weight: 700;
}

.news-feed {
  margin: 0.9rem 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.62rem;
}

.news-feed li {
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 14px;
  padding: 0.8rem;
  background: rgba(255, 255, 255, 0.68);
}

.news-title {
  font-weight: 700;
  margin-bottom: 0.14rem;
}

.news-meta {
  color: #666;
  font-size: 0.9rem;
}

.profile-overview {
  margin-top: 0.9rem;
  display: grid;
  gap: 0.58rem;
}

.profile-row {
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 12px;
  padding: 0.72rem;
  background: rgba(255, 255, 255, 0.72);
  display: flex;
  justify-content: space-between;
  gap: 0.6rem;
}

.profile-key {
  color: #666;
  font-weight: 600;
}

.profile-value {
  color: #111;
  font-weight: 700;
  text-align: right;
}

.apps-grid {
  margin-top: 0.95rem;
  display: grid;
  gap: 0.75rem;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
}

.app-tile {
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 16px;
  padding: 0.78rem;
  background: rgba(255, 255, 255, 0.7);
  display: flex;
  align-items: center;
  gap: 0.66rem;
}

.app-icon {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: linear-gradient(145deg, #111, #3d3d3d);
  color: #fff;
  font-weight: 800;
  font-size: 0.95rem;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}

.app-icon i {
  font-size: 1.18rem;
  line-height: 1;
}

.app-name {
  margin: 0;
  font-weight: 800;
  font-size: 0.98rem;
}

.app-state {
  margin: 0.14rem 0 0;
  color: #626262;
  font-size: 0.85rem;
}

.bank-list {
  margin: 0.95rem 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.62rem;
}

.bank-row {
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 14px;
  padding: 0.8rem;
  background: rgba(255, 255, 255, 0.68);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.65rem;
}

.bank-main {
  display: flex;
  align-items: center;
  gap: 0.62rem;
  min-width: 0;
}

.bank-icon {
  width: 38px;
  height: 38px;
  border-radius: 11px;
  border: 1px solid rgba(0, 0, 0, 0.1);
  background: rgba(255, 255, 255, 0.88);
  display: grid;
  place-items: center;
  color: #101010;
  flex: 0 0 auto;
}

.bank-icon i {
  font-size: 1.08rem;
  line-height: 1;
}

.bank-left {
  min-width: 0;
}

.bank-title {
  margin: 0;
  font-weight: 700;
}

.bank-meta {
  margin: 0.16rem 0 0;
  color: #656565;
  font-size: 0.84rem;
}

.bank-amount {
  margin: 0;
  font-weight: 800;
  font-size: 0.92rem;
  border-radius: 999px;
  padding: 0.36rem 0.62rem;
  border: 1px solid rgba(0, 0, 0, 0.14);
  background: rgba(255, 255, 255, 0.75);
}

.bank-amount.is-positive {
  color: #0d7a38;
  border-color: rgba(13, 122, 56, 0.3);
  background: rgba(13, 122, 56, 0.08);
}

.bank-amount.is-negative {
  color: #c12f2f;
  border-color: rgba(193, 47, 47, 0.3);
  background: rgba(193, 47, 47, 0.08);
}

.dashboard-view {
  margin-top: 0.8rem;
  opacity: 0;
  transform: translateY(8px) scale(0.995);
  pointer-events: none;
  transition: opacity 0.34s ease, transform 0.42s cubic-bezier(0.22, 1, 0.36, 1);
}

.dashboard-view.is-active {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

.loading-wrap {
  min-height: 180px;
  display: grid;
  place-items: center;
  gap: 0.6rem;
  text-align: center;
  color: #2a2a2a;
}

.loading-wrap p {
  animation: textPulse 1.1s ease-in-out infinite;
}

.loader {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  border: 3px solid rgba(0, 0, 0, 0.12);
  border-top-color: #111;
  animation: spin 0.9s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes textPulse {
  0%,
  100% {
    opacity: 0.5;
  }
  50% {
    opacity: 1;
  }
}

.site-footer {
  position: fixed;
  left: 50%;
  bottom: max(10px, env(safe-area-inset-bottom));
  transform: translateX(-50%);
  display: grid;
  justify-items: center;
  align-items: center;
  text-align: center;
  gap: 0.18rem;
  width: max-content;
  pointer-events: none;
}

.site-footer img {
  width: min(20vw, 78px);
  height: auto;
  object-fit: contain;
}

.site-footer .copy {
  font-size: 0.75rem;
  color: #1f1f1f;
  text-align: center;
  line-height: 1.35;
}

@media (max-width: 1120px) {
  .dash-header {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
  }

  .dash-user {
    justify-content: center;
  }

  .logout-icon {
    width: 52px;
    height: 52px;
  }

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

@media (max-width: 640px) {
  .profile-layout {
    padding: 0.72rem 0.72rem 6.2rem;
  }

  .profile-wrap {
    width: calc(100vw - 0.72rem);
  }

  .profile-shell {
    min-height: min(900px, calc(100vh - 110px));
  }

  .dash-tabs {
    width: fit-content;
    max-width: 100%;
    justify-content: center;
  }

  .dash-tab {
    min-width: 0;
    flex: 1 1 0;
    padding: 0 0.5rem;
  }

  .dash-tab.is-active {
    min-width: 0;
  }

  .dash-tab.is-active .tab-label {
    max-width: 74px;
  }

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

  .bank-row,
  .profile-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .profile-value {
    text-align: left;
  }

  .site-footer img {
    width: min(26vw, 74px);
  }

  .site-footer .copy {
    font-size: 0.7rem;
  }
}

.settings-panel {
  padding: 1.05rem;
}

.settings-help {
  margin: 0.72rem 0 0.4rem;
  color: #4e4e4e;
  font-weight: 600;
}

.settings-form {
  margin-top: 0.55rem;
  display: grid;
  gap: 0.55rem;
}

.settings-form input:disabled {
  opacity: 0.62;
  background: rgba(245, 245, 245, 0.92);
  cursor: not-allowed;
}

.settings-actions {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.55rem;
  margin-top: 0.18rem;
}

.settings-edit-btn {
  min-width: 130px;
}

.settings-status {
  margin: 0.35rem 0 0;
  min-height: 1.2rem;
  font-weight: 600;
}

.settings-status.is-ok {
  color: #0d7a38;
}

.settings-status.is-error {
  color: #b00020;
}

@media (max-width: 640px) {
  .settings-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .settings-actions .ghost-btn,
  .settings-actions button {
    width: 100%;
  }
}

/* Mobile coherence patch - desktop untouched */
@media (max-width: 1120px) {
  .profile-layout {
    padding: 0.95rem 0.95rem 6rem;
  }

  .dashboard-page,
  .profile-wrap {
    width: min(980px, calc(100vw - 1.2rem));
  }

  .dash-header {
    grid-template-columns: auto 1fr auto;
    grid-template-areas:
      "user spacer logout"
      "tabs tabs tabs";
    align-items: center;
    gap: 0.6rem;
    text-align: left;
  }

  .dash-user {
    grid-area: user;
    justify-self: start;
  }

  .dash-tabs {
    grid-area: tabs;
    justify-self: center;
  }

  .logout-icon {
    grid-area: logout;
    justify-self: end;
    width: 48px;
    height: 48px;
  }
}

@media (max-width: 640px) {
  .profile-layout {
    padding: 0.68rem 0.62rem 5.6rem;
  }

  .dashboard-page,
  .profile-wrap {
    width: calc(100vw - 0.62rem);
  }

  .profile-shell {
    min-height: min(860px, calc(100vh - 102px));
  }

  .dash-header {
    gap: 0.5rem;
  }

  .dash-user {
    gap: 0.56rem;
  }

  .avatar-circle {
    width: 50px;
    height: 50px;
    font-size: 0.92rem;
  }

  .first-name {
    font-size: 0.94rem;
  }

  .last-name {
    font-size: 0.86rem;
  }

  .dash-tabs {
    width: 100%;
    max-width: 100%;
    height: 52px;
    min-height: 52px;
    padding: 0.2rem 0.22rem;
    gap: 0.12rem;
    overflow-x: auto;
    overflow-y: hidden;
    justify-content: flex-start;
    scrollbar-width: none;
  }

  .dash-tabs::-webkit-scrollbar {
    display: none;
  }

  .dash-tab {
    flex: 0 0 auto;
    min-width: 38px;
    height: 42px;
    padding: 0 0.48rem;
  }

  .dash-tab.is-active {
    min-width: 98px;
  }

  .dash-tab.is-active .tab-label {
    max-width: 56px;
  }

  .dash-id-art {
    width: min(84vw, 280px);
  }

  .dash-status {
    font-size: 0.94rem;
  }

  .dashboard-content-card,
  .bank-panel,
  .settings-panel {
    padding: 0.78rem;
  }

  .home-grid {
    gap: 0.62rem;
  }

  .metric-card {
    padding: 0.78rem 0.78rem 0.88rem;
  }

  .feed-head {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.35rem;
  }

  .settings-form {
    gap: 0.5rem;
  }

  .settings-actions {
    gap: 0.45rem;
  }

  .settings-actions .ghost-btn,
  .settings-actions button {
    width: 100%;
    min-width: 0;
  }
}

/* Mobile tab centering fix (no desktop impact) */
@media (max-width: 640px) {
  .dash-tab {
    justify-content: center;
    text-align: center;
  }

  .dash-tab.is-active {
    justify-content: center;
    padding: 0 0.54rem;
    min-width: 88px;
  }

  .dash-tab .tab-ico,
  .dash-tab.is-active .tab-ico {
    margin: 0;
  }

  .dash-tab.is-active .tab-label {
    max-width: 0;
    opacity: 0;
    transform: translateX(-4px);
  }
}

/* Mobile tabs: icon + text centered in each capsule */
@media (max-width: 640px) {
  .dash-tabs {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    width: 100%;
    max-width: 100%;
    justify-content: stretch;
    gap: 0.12rem;
    overflow: hidden;
  }

  .dash-tab,
  .dash-tab.is-active {
    width: 100%;
    min-width: 0;
    height: 42px;
    padding: 0 0.22rem;
    justify-content: center;
    align-items: center;
    gap: 0.2rem;
  }

  .dash-tab .tab-label,
  .dash-tab.is-active .tab-label {
    max-width: 64px;
    opacity: 1;
    transform: translateX(0);
    font-size: 0.62rem;
    line-height: 1;
  }
}

/* Mobile tabs final tweak: inactive icon-only, centered */
@media (max-width: 640px) {
  .dash-tab,
  .dash-tab.is-active {
    justify-content: center;
    align-items: center;
  }

  .dash-tab .tab-label {
    max-width: 0;
    opacity: 0;
    transform: translateX(-4px);
  }

  .dash-tab.is-active .tab-label {
    max-width: 64px;
    opacity: 1;
    transform: translateX(0);
  }
}

/* Mobile tabs spacing final */
@media (max-width: 640px) {
  .dash-tabs {
    gap: 0.06rem;
    padding: 0.2rem 0.16rem;
  }
}

/* Dashboard entry motion after loading */
@keyframes dashSpringIn {
  0% {
    opacity: 0;
    transform: translate3d(0, 20px, 0) scale(0.986);
  }
  62% {
    opacity: 1;
    transform: translate3d(0, -4px, 0) scale(1.006);
  }
  100% {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
  }
}

#view-dashboard.is-active .dash-header,
#view-dashboard.is-active .dash-id-row,
#view-dashboard.is-active .dashboard-content-card,
#view-dashboard.is-active .home-grid .metric-card,
#view-dashboard.is-active .feed-panel,
#view-dashboard.is-active .profile-panel,
#view-dashboard.is-active .apps-grid .app-tile,
#view-dashboard.is-active .bank-list .bank-row,
#view-dashboard.is-active .settings-panel {
  opacity: 0;
  animation: dashSpringIn 0.64s cubic-bezier(0.22, 1.08, 0.32, 1) forwards;
}

#view-dashboard.is-active .dash-header { animation-delay: 0.02s; }
#view-dashboard.is-active .dash-id-row { animation-delay: 0.10s; }
#view-dashboard.is-active .dashboard-content-card { animation-delay: 0.16s; }
#view-dashboard.is-active .home-grid .metric-card:nth-child(1) { animation-delay: 0.20s; }
#view-dashboard.is-active .home-grid .metric-card:nth-child(2) { animation-delay: 0.25s; }
#view-dashboard.is-active .home-grid .metric-card:nth-child(3) { animation-delay: 0.30s; }
#view-dashboard.is-active .feed-panel,
#view-dashboard.is-active .profile-panel,
#view-dashboard.is-active .settings-panel { animation-delay: 0.34s; }
#view-dashboard.is-active .apps-grid .app-tile,
#view-dashboard.is-active .bank-list .bank-row { animation-delay: 0.28s; }

/* Horizon title text in profile/dashboard */
.brand-title-text {
  font-family: var(--brand-font, "Horizon", "Avenir Next", sans-serif);
  letter-spacing: 0.04em;
  line-height: 0.9;
  text-transform: uppercase;
  color: #0d0d0d;
  text-align: center;
}

.login-id-art.brand-title-text {
  width: auto;
  font-size: clamp(1.7rem, 5.2vw, 2.6rem);
}

.dash-id-art.brand-title-text {
  width: auto;
  font-size: clamp(2.5rem, 5.8vw, 4.3rem);
}

@media (max-width: 640px) {
  .login-id-art.brand-title-text {
    font-size: clamp(1.35rem, 8.8vw, 2.05rem);
  }

  .dash-id-art.brand-title-text {
    font-size: clamp(1.95rem, 10.4vw, 3rem);
  }
}

/* Login panel refinements */
.login-id-art.brand-title-text {
  font-size: clamp(2.8rem, 8.2vw, 5rem);
  letter-spacing: 0.045em;
}

.login-surface {
  display: grid;
  gap: 0.56rem;
}

.login-surface .field-label {
  font-family: var(--brand-font, "Horizon", "Avenir Next", sans-serif);
  font-size: clamp(1rem, 2.2vw, 1.2rem);
  letter-spacing: 0.04em;
  color: #080808;
  font-weight: 700;
}

.login-surface button,
.login-surface .ghost-btn {
  font-family: var(--brand-font, "Horizon", "Avenir Next", sans-serif);
  letter-spacing: 0.035em;
}

#login-btn {
  margin-top: 0.42rem;
}

#forgot-link {
  margin-top: 0.08rem;
}

.remember-row {
  justify-content: center;
  text-align: center;
  width: 100%;
}

@media (max-width: 640px) {
  .login-id-art.brand-title-text {
    font-size: clamp(2.25rem, 12.2vw, 3.2rem);
  }
}

/* Social-login coherence patch */
.login-surface {
  align-items: center;
}

.login-surface #login-btn,
.verify-wrap button:not(.dash-tab):not(.logout-icon),
.settings-actions button:not(.dash-tab):not(.logout-icon),
.settings-actions .ghost-btn {
  height: 52px;
  min-height: 52px;
  border-radius: 999px;
  font-family: var(--brand-font, "Horizon", "Avenir Next", sans-serif);
  letter-spacing: 0.03em;
}

.login-surface #login-btn {
  width: min(100%, 360px);
  margin-top: 0.42rem;
}

.login-surface #forgot-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: auto;
  min-width: 0;
  min-height: auto;
  height: auto;
  margin-top: 0.08rem;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  color: #111;
  text-decoration: none;
  font-family: var(--brand-font, "Horizon", "Avenir Next", sans-serif);
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.025em;
  opacity: 0.72;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

.login-surface #forgot-link:hover {
  opacity: 1;
  transform: translateY(-1px);
  text-decoration: underline;
}

.login-surface .remember-row {
  justify-content: center;
  text-align: center;
  width: 100%;
}

.settings-actions {
  flex-wrap: wrap;
}

@media (max-width: 640px) {
  .login-surface #login-btn {
    width: min(100%, 320px);
  }

  .login-surface #forgot-link {
    font-size: 0.84rem;
  }
}

/* Login clean panel + centered CTA + spring fields */
.login-surface {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  padding: 0.4rem 0.2rem 0.2rem;
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
  display: grid;
  gap: 0.6rem;
  justify-items: stretch;
}

.login-surface #login-email,
.login-surface #login-password {
  width: 100%;
}

.login-surface #login-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-left: auto;
  margin-right: auto;
  width: min(100%, 360px);
}

.login-surface #login-btn.is-disabled,
.login-surface #login-btn:disabled {
  opacity: 0.48;
  transform: none !important;
  box-shadow: none !important;
  cursor: not-allowed;
}

@keyframes loginFieldSpring {
  0% {
    opacity: 0;
    transform: translate3d(0, 18px, 0) scale(0.985);
  }
  62% {
    opacity: 1;
    transform: translate3d(0, -4px, 0) scale(1.005);
  }
  100% {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
  }
}

body.ready #view-login.is-active .login-surface > * {
  opacity: 0;
  animation: loginFieldSpring 0.62s cubic-bezier(0.22, 1.08, 0.32, 1) forwards;
}

body.ready #view-login.is-active .login-surface > *:nth-child(1) { animation-delay: 0.04s; }
body.ready #view-login.is-active .login-surface > *:nth-child(2) { animation-delay: 0.09s; }
body.ready #view-login.is-active .login-surface > *:nth-child(3) { animation-delay: 0.14s; }
body.ready #view-login.is-active .login-surface > *:nth-child(4) { animation-delay: 0.19s; }
body.ready #view-login.is-active .login-surface > *:nth-child(5) { animation-delay: 0.24s; }
body.ready #view-login.is-active .login-surface > *:nth-child(6) { animation-delay: 0.29s; }

@media (max-width: 640px) {
  .login-surface {
    padding: 0.25rem 0;
    gap: 0.54rem;
  }

  .login-surface #login-btn {
    width: min(100%, 320px);
  }
}

/* App logos from provided assets */
.app-logo-wrap {
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.08);
  overflow: hidden;
}

.app-logo {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  padding: 6px;
}

/* Title stretch + bigger profile branding */
.login-id-art.brand-title-text,
.dash-id-art.brand-title-text {
  display: inline-block;
  transform: scaleY(1.14);
  transform-origin: center center;
}

.login-id-art.brand-title-text {
  font-size: clamp(4.2rem, 13.5vw, 8rem);
  letter-spacing: 0.02em;
}

.dash-id-art.brand-title-text {
  font-size: clamp(3.2rem, 8.2vw, 6rem);
  letter-spacing: 0.02em;
}

@media (max-width: 640px) {
  .login-id-art.brand-title-text {
    font-size: clamp(3rem, 16vw, 5rem);
    transform: scaleY(1.1);
  }

  .dash-id-art.brand-title-text {
    font-size: clamp(2.3rem, 12.5vw, 3.8rem);
    transform: scaleY(1.08);
  }
}


/* Connect page final typography lock */
.profile-hero .login-intro {
  justify-items: center;
  text-align: center;
}

.profile-hero .login-id-art.brand-title-text {
  font-family: var(--brand-font, "Horizon", "Avenir Next", sans-serif) !important;
  font-size: clamp(4.8rem, 15vw, 9rem) !important;
  letter-spacing: 0.02em !important;
  line-height: 0.86 !important;
  transform: scaleY(1.16) !important;
  transform-origin: center center !important;
  margin-inline: auto !important;
}

.login-surface .field-label {
  font-family: var(--brand-font, "Horizon", "Avenir Next", sans-serif) !important;
  font-size: clamp(1.06rem, 2.4vw, 1.28rem) !important;
  color: #050505 !important;
  letter-spacing: 0.035em !important;
  font-weight: 700 !important;
}

#status.message {
  font-family: "Avenir Next", "Helvetica Neue", "Segoe UI", sans-serif !important;
  font-size: clamp(1rem, 1.35vw, 1.16rem) !important;
  font-weight: 500 !important;
  letter-spacing: 0 !important;
  text-align: center !important;
  color: #1b1b1b !important;
}

@media (max-width: 640px) {
  .profile-hero .login-id-art.brand-title-text {
    font-size: clamp(3.4rem, 17vw, 5.6rem) !important;
    transform: scaleY(1.12) !important;
  }

  #status.message {
    font-size: clamp(0.94rem, 4.3vw, 1.08rem) !important;
  }
}

