/* Thushara login — same stitch shell as iPay Video KYC backoffice login */
@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Sans:wght@400;500;600;700&family=Plus+Jakarta+Sans:wght@500;600;700;800&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL,GRAD@24,400,0,0&display=swap');

:root {
  --st-primary: #001629;
  --st-primary-container: #002b49;
  --st-secondary: #005cba;
  --st-secondary-container: #5095fe;
  --st-ice-start: #EBF3FC;
  --st-ice-end: #FFFFFF;
  --st-text-dark: #0B1B2B;
  --st-text-muted: #486581;
  --st-border: #E4E9F0;
  --st-surface: #f7f9fc;
  --st-surface-low: #f2f4f7;
  --st-approved: #2B8A3E;
  --st-pending: #856404;
  --st-shadow-card: 0 2px 12px rgba(0, 51, 102, 0.12);
  --font-display: "Plus Jakarta Sans", system-ui, sans-serif;
  --font-body: "IBM Plex Sans", system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html, body {
  margin: 0;
  min-height: 100%;
  font-family: var(--font-body);
  color: var(--st-text-dark);
  -webkit-font-smoothing: antialiased;
  background: var(--st-ice-end);
}

.material-symbols-outlined {
  font-family: 'Material Symbols Outlined', sans-serif;
  font-weight: normal;
  font-style: normal;
  font-size: 1.25rem;
  line-height: 1;
  letter-spacing: normal;
  font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
  vertical-align: middle;
  display: inline-block;
  font-feature-settings: 'liga';
  -webkit-font-smoothing: antialiased;
}

.stitch-login-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px 24px 56px;
  background: radial-gradient(circle at top right, var(--st-ice-start) 0%, var(--st-ice-end) 100%);
  position: relative;
  overflow: hidden;
}

.stitch-login-bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.stitch-login-bg .pattern {
  position: absolute;
  top: 0;
  right: 0;
  width: 55%;
  height: 100%;
  opacity: 0.08;
  background-color: var(--st-primary);
  background-image: radial-gradient(#002b49 0.5px, transparent 0.5px);
  background-size: 24px 24px;
  transform: skewX(-12deg) translateX(80px);
}

.stitch-login-bg .blob-a {
  position: absolute;
  bottom: -10%;
  left: -5%;
  width: 380px;
  height: 380px;
  border-radius: 50%;
  background: #cfe5ff;
  filter: blur(100px);
  opacity: 0.35;
}

.stitch-login-bg .blob-b {
  position: absolute;
  top: -5%;
  right: -5%;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: var(--st-secondary-container);
  filter: blur(90px);
  opacity: 0.15;
}

.stitch-login-main {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1100px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 48px;
}

.stitch-login-brand {
  flex: 1 1 360px;
  max-width: 480px;
}

.stitch-login-brand .brand-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
}

.stitch-login-brand .brand-icon {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px rgba(0, 22, 41, 0.15);
  overflow: hidden;
  flex-shrink: 0;
  padding: 6px;
}

.stitch-login-brand .ipay-logo-img,
.stitch-login-brand .brand-logo-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.stitch-login-brand .brand-title {
  font-family: var(--font-display);
  font-size: 1.85rem;
  font-weight: 800;
  color: #001629 !important;
  -webkit-text-fill-color: #001629;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.85);
  margin: 0;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

.stitch-login-brand h2 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--st-primary);
  margin: 0 0 12px;
  line-height: 1.3;
}

.stitch-login-brand .brand-desc {
  color: var(--st-text-muted);
  font-size: 0.9375rem;
  line-height: 1.65;
  margin: 0 0 28px;
}

.stitch-feature-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.stitch-feature {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid rgba(228, 233, 240, 0.8);
  backdrop-filter: blur(8px);
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--st-primary);
}

.stitch-feature .material-symbols-outlined { color: var(--st-secondary); }

.stitch-login-card-wrap {
  flex: 0 1 440px;
  width: 100%;
}

.stitch-login-card {
  background: #fff;
  border: 1px solid var(--st-border);
  border-radius: 16px;
  padding: 32px 28px;
  box-shadow: var(--st-shadow-card);
}

.stitch-card-logo {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: contain;
  display: block;
  margin-bottom: 12px;
  box-shadow: 0 2px 10px rgba(0, 22, 41, 0.12);
  background: #fff;
  padding: 4px;
}

.stitch-login-card h3 {
  font-family: var(--font-display);
  font-size: 1.375rem;
  font-weight: 700;
  color: var(--st-primary);
  margin: 0 0 6px;
}

.stitch-login-card .card-sub {
  color: var(--st-text-muted);
  font-size: 0.9375rem;
  margin: 0 0 24px;
}

.stitch-field { margin-bottom: 18px; }

.stitch-field label {
  display: block;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--st-text-muted);
  margin-bottom: 6px;
}

.stitch-field .label-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.stitch-field .label-row label { margin: 0; }

.stitch-input-wrap { position: relative; }

.stitch-input-wrap .material-symbols-outlined.field-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #899199;
  font-size: 1.125rem;
  pointer-events: none;
}

.stitch-input-wrap input {
  width: 100%;
  height: 48px;
  padding: 0 44px 0 44px;
  border: 1px solid var(--st-border);
  border-radius: 10px;
  background: var(--st-surface-low);
  font: inherit;
  font-size: 0.9375rem;
  color: var(--st-primary);
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.stitch-input-wrap input:focus {
  border-color: var(--st-secondary);
  box-shadow: 0 0 0 4px rgba(0, 92, 186, 0.12);
  background: #fff;
}

.stitch-input-wrap .toggle-pass {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  border: 0;
  background: none;
  cursor: pointer;
  color: #899199;
  padding: 4px;
  display: flex;
}

.stitch-input-wrap .toggle-pass:hover { color: var(--st-primary); }

.stitch-forgot {
  font-size: 0.75rem;
  color: var(--st-secondary);
  text-decoration: none;
}

.stitch-forgot:hover { text-decoration: underline; }

.stitch-remember {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin: 0 0 1rem;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--st-text-muted);
  cursor: pointer;
  user-select: none;
}

.stitch-remember input {
  width: 1rem;
  height: 1rem;
  accent-color: var(--st-secondary);
}

.stitch-notice {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 12px;
  margin: 8px 0 20px;
  border-radius: 10px;
  background: rgba(230, 232, 235, 0.45);
  border: 1px solid rgba(228, 233, 240, 0.8);
  font-size: 0.75rem;
  color: var(--st-text-muted);
  line-height: 1.45;
}

.stitch-notice p { margin: 0; }

.stitch-notice .material-symbols-outlined {
  color: var(--st-pending);
  font-size: 1.125rem;
  flex-shrink: 0;
}

.stitch-login-btn {
  width: 100%;
  height: 48px;
  border: none;
  border-radius: 10px;
  background: var(--st-primary);
  color: #fff !important;
  font-family: var(--font-display);
  font-size: 0.9375rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: 0 2px 8px rgba(0, 22, 41, 0.2);
  transition: background 0.15s, transform 0.1s;
}

.stitch-login-btn:hover { background: var(--st-primary-container); }
.stitch-login-btn:active { transform: scale(0.98); }
.stitch-login-btn:disabled { opacity: 0.7; cursor: wait; }

.stitch-card-footer {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--st-border);
  text-align: center;
}

.stitch-card-footer .links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 12px;
  font-size: 0.75rem;
  margin-bottom: 12px;
}

.stitch-card-footer .links a {
  color: var(--st-text-muted);
  text-decoration: none;
}

.stitch-card-footer .links a:hover { color: var(--st-primary); }

.stitch-card-footer .dot {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #c3c7ce;
  align-self: center;
}

.stitch-secure {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 0.75rem;
  color: var(--st-approved);
  font-weight: 600;
}

.stitch-secure .pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--st-approved);
  animation: stitchPulse 1.5s ease-in-out infinite;
}

@keyframes stitchPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

.stitch-powered {
  margin-top: 20px;
  text-align: center;
  opacity: 0.5;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--st-text-muted);
}

.stitch-powered strong {
  font-family: var(--font-display);
  font-style: italic;
  color: var(--st-primary-container);
  font-size: 1rem;
}

.stitch-page-footer {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 2;
  background: var(--st-primary);
  color: rgba(255, 255, 255, 0.75);
  font-size: 0.6875rem;
  padding: 10px 20px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}

.login-error {
  display: none;
  margin-bottom: 14px;
  padding: 10px 12px;
  border-radius: 8px;
  background: #FFE3E3;
  color: #C92A2A;
  font-size: 0.8125rem;
}

.login-error.show { display: block; }

@media (max-width: 900px) {
  .stitch-login-brand { display: none; }
  .stitch-login-page { padding-bottom: 56px; }
}
