/* TrustHost sign-in, sign-up and account-setup pages (trusthost_otp clienthome.tpl).
   The page covers the theme with a full-screen split layout: the form on the
   right, a brand panel on the left that is dropped below 900px. Dark mode
   follows the panel's own .body__dark switch. */

.thotp-shell{
  --th-blue:#1A7BFF;--th-blue-2:#0866F2;--th-blue-soft:#e8f1ff;--th-ring:0 0 0 4px rgba(26,123,255,.16);
  --th-ink:#0d1b2e;--th-ink-2:#44546b;--th-ink-3:#7a8aa1;
  --th-line:#e3e9f1;--th-field:#f5f8fc;--th-card:#fff;
  --th-ok:#12a150;--th-warn:#e08a00;--th-bad:#e5484d;
  --th-brand:#07142a;--th-brand-ink:#e8f0ff;--th-brand-ink-2:#9db0cf;
  --th-r:14px;
}
.body__dark .thotp-shell{
  --th-ink:#eef3fb;--th-ink-2:#b4c1d6;--th-ink-3:#7f8ea8;
  --th-line:#26324a;--th-field:#121c2e;--th-card:#0f1828;--th-blue-soft:#13264a;
}

.thotp-standalone,.thotp-standalone body{overflow:hidden}
.thotp-shell{position:fixed;inset:0;z-index:2147483000;display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.05fr);overflow:auto;background:var(--th-card);color:var(--th-ink);text-align:right;-webkit-font-smoothing:antialiased}
.thotp-shell *,.thotp-shell *::before,.thotp-shell *::after{box-sizing:border-box}
.thotp-shell a{color:var(--th-blue);text-decoration:none}
.thotp-shell a:hover{text-decoration:underline}
.thotp-shell svg{display:block}

/* ---------- form side ---------- */
.thotp-panel{display:flex;flex-direction:column;justify-content:center;align-items:center;min-height:100%;padding:48px 24px}
.thotp-inner{width:100%;max-width:400px;animation:thotp-in .4s cubic-bezier(.2,.8,.2,1)}
.thotp-inner-wide{max-width:600px}
@keyframes thotp-in{from{opacity:0;transform:translateY(10px)}to{opacity:1;transform:none}}
.thotp-logo{display:none;justify-content:center;margin:0 auto 22px;width:max-content}
.thotp-logo svg{width:54px;height:auto}

.thotp-head h1:only-child{margin-bottom:26px}
.thotp-head h1{margin:0 0 6px;font-size:27px;font-weight:800;line-height:1.5;color:var(--th-ink)}
.thotp-head p{margin:0 0 26px;font-size:15px;line-height:1.9;color:var(--th-ink-2)}
.thotp-head bdi{font-weight:700;color:var(--th-ink)}
.thotp-badge{display:flex;align-items:center;justify-content:center;width:56px;height:56px;margin-bottom:18px;border-radius:16px;background:var(--th-blue-soft);color:var(--th-blue)}
.thotp-badge svg{width:28px;height:28px}

.thotp-steps{display:flex;gap:6px;margin-bottom:20px}
.thotp-steps i{flex:1;height:4px;border-radius:4px;background:var(--th-line);transition:background .3s}
.thotp-steps i.on{background:var(--th-blue)}

.thotp-alert{margin:0 0 18px;padding:12px 14px;border-radius:12px;font-size:14px;line-height:1.9;border:1px solid transparent}
.thotp-alert-danger{background:#fdecec;border-color:#f8c9ca;color:#9b1c20}
.thotp-alert-success{background:#e9f7ef;border-color:#bfe6cf;color:#0d6b37}
.thotp-alert-warning{background:#fff5e0;border-color:#f6dca6;color:#7a4b00}
.thotp-alert-info{background:var(--th-blue-soft);border-color:#cfe0fb;color:#0b4fb3}
.body__dark .thotp-alert-danger{background:#3a1518;border-color:#6b2328;color:#ffb4b6}
.body__dark .thotp-alert-success{background:#0f2d1e;border-color:#1d5a3a;color:#9be3b9}
.body__dark .thotp-alert-warning{background:#33260a;border-color:#6a4d10;color:#ffd58a}
.body__dark .thotp-alert-info{border-color:#22406f;color:#a9c8ff}

/* buttons */
.thotp-btn{display:flex;align-items:center;justify-content:center;gap:10px;width:100%;height:52px;margin-top:20px;padding:0 18px;border:1px solid transparent;border-radius:var(--th-r);font-size:15.5px;font-weight:700;line-height:1;cursor:pointer;transition:transform .12s,box-shadow .2s,background .2s,border-color .2s}
.thotp-shell a.thotp-btn{text-decoration:none}
.thotp-btn:active{transform:scale(.985)}
.thotp-btn:focus-visible{outline:none;box-shadow:var(--th-ring)}
.thotp-btn-primary{background:linear-gradient(180deg,var(--th-blue),var(--th-blue-2));color:#fff!important;box-shadow:0 8px 22px -8px rgba(26,123,255,.65)}
.thotp-btn-primary:hover{box-shadow:0 12px 28px -8px rgba(26,123,255,.8)}
.thotp-btn-ghost{background:var(--th-card);border-color:var(--th-line);color:var(--th-ink)!important}
.thotp-btn-ghost:hover{background:var(--th-field)}
.thotp-btn-danger{color:var(--th-bad)!important}
.thotp-btn-google{margin-top:0;background:var(--th-card);border-color:var(--th-line);color:var(--th-ink)}
.thotp-btn-google svg{width:20px;height:20px}
.thotp-btn[disabled]{cursor:default}
.thotp-busy{opacity:.7;cursor:progress}
.thotp-link{padding:0;border:0;background:none;color:var(--th-blue);font-weight:700;cursor:pointer}

/* Google button: our placeholder until Google's own button has rendered over it. */
.thotp-google{position:relative;min-height:52px}
.thotp-google-slot{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;opacity:0;transition:opacity .25s}
.thotp-google.is-ready .thotp-google-slot{opacity:1}
.thotp-google.is-ready .thotp-btn-google{visibility:hidden}
.thotp-google.is-off,.thotp-or.is-off{display:none}

.thotp-or{display:flex;align-items:center;gap:14px;margin:22px 0;color:var(--th-ink-3);font-size:13px}
.thotp-or::before,.thotp-or::after{content:"";flex:1;height:1px;background:var(--th-line)}

/* email / mobile switch */
.thotp-seg{position:relative;display:grid;grid-template-columns:1fr 1fr;margin-bottom:18px;padding:4px;border:1px solid var(--th-line);border-radius:12px;background:var(--th-field)}
.thotp-seg button{position:relative;z-index:1;display:flex;align-items:center;justify-content:center;gap:8px;height:40px;border:0;border-radius:9px;background:none;color:var(--th-ink-2);font-weight:600;cursor:pointer;transition:color .2s}
.thotp-seg button[aria-selected="true"]{color:var(--th-ink)}
.thotp-seg button svg{width:17px;height:17px;opacity:.8}
.thotp-seg-pill{position:absolute;top:4px;bottom:4px;right:4px;width:calc(50% - 4px);border-radius:9px;background:var(--th-card);box-shadow:0 1px 3px rgba(13,27,46,.12);transition:transform .32s cubic-bezier(.3,1.3,.5,1)}
.thotp-seg[data-i="1"] .thotp-seg-pill{transform:translateX(-100%)}
.thotp-pane{display:none}
.thotp-pane.on{display:block;animation:thotp-in .3s ease}

/* fields */
.thotp-label{display:block;margin:14px 0 7px;font-size:13.5px;font-weight:600;color:var(--th-ink-2)}
.thotp-label:first-child,.thotp-pane > .thotp-label:first-of-type{margin-top:0}
.thotp-label-row{display:flex;justify-content:space-between;align-items:baseline;margin-top:14px}
.thotp-label-row .thotp-label{margin:0 0 7px}
.thotp-label-row a{font-size:13px}
.thotp-muted{color:var(--th-ink-3);font-weight:400}
.thotp-input{display:flex;align-items:center;height:52px;border:1px solid var(--th-line);border-radius:var(--th-r);background:var(--th-field);transition:border-color .2s,box-shadow .2s,background .2s}
.thotp-input:focus-within{border-color:var(--th-blue);box-shadow:var(--th-ring);background:var(--th-card)}
.thotp-shell .thotp-input input{flex:1;min-width:0;height:100%;margin:0;padding:0 16px;border:0!important;border-radius:var(--th-r);background:transparent!important;box-shadow:none!important;outline:none;color:var(--th-ink);font-size:15.5px}
.thotp-shell .thotp-input input:focus,.thotp-shell .thotp-input input:hover{border:0!important;box-shadow:none!important;background:transparent!important;outline:none!important}
.thotp-shell .thotp-input input::placeholder{color:var(--th-ink-3)}
.thotp-shell .thotp-ltr{direction:ltr;text-align:left}
.thotp-prefix{display:flex;align-items:center;height:60%;padding:0 14px;border-right:1px solid var(--th-line);color:var(--th-ink-2);font-weight:700}
.thotp-eye{display:flex;padding:0 14px;border:0;background:none;color:var(--th-ink-3);cursor:pointer}
.thotp-eye svg{width:20px;height:20px}
.thotp-eye.is-shown{color:var(--th-blue)}
.thotp-hint{margin:8px 0 0;font-size:12.5px;line-height:1.8;color:var(--th-ink-3)}
.thotp-center{text-align:center;margin-bottom:14px}
.thotp-hidden-field{position:absolute!important;width:1px;height:1px;opacity:0;pointer-events:none}
.thotp-shell .thotp-field{width:100%;height:52px;padding:0 16px;border:1px solid var(--th-line);border-radius:var(--th-r);background:var(--th-field);color:var(--th-ink)}
.thotp-code{direction:ltr;text-align:center;font-size:24px;letter-spacing:.35em}

.thotp-meter{display:grid;grid-template-columns:repeat(4,1fr);gap:5px;margin-top:9px}
.thotp-meter i{height:4px;border-radius:4px;background:var(--th-line);transition:background .25s}
.thotp-meter[data-s="1"] i:nth-child(-n+1){background:var(--th-bad)}
.thotp-meter[data-s="2"] i:nth-child(-n+2){background:var(--th-warn)}
.thotp-meter[data-s="3"] i:nth-child(-n+3){background:#7cc34a}
.thotp-meter[data-s="4"] i{background:var(--th-ok)}

.thotp-chip{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:6px;padding:10px 14px;border-radius:12px;background:var(--th-field);border:1px solid var(--th-line);font-weight:600}
.thotp-chip a{font-size:13px;font-weight:500}

.thotp-who{display:flex;align-items:center;gap:12px;margin-bottom:20px;padding:12px 14px;border-radius:var(--th-r);background:var(--th-blue-soft)}
.thotp-av{display:flex;align-items:center;justify-content:center;flex:none;width:42px;height:42px;border-radius:50%;background:linear-gradient(135deg,#5aa2ff,var(--th-blue-2));color:#fff;font-weight:800;font-size:17px;object-fit:cover}
.thotp-av-g{background:var(--th-card)}
.thotp-av-g svg{width:22px;height:22px}
.thotp-who div{min-width:0}
.thotp-who b{display:block;font-size:14.5px;color:var(--th-ink)}
.thotp-who span{display:block;overflow:hidden;text-overflow:ellipsis;text-align:right;font-size:13px;color:var(--th-ink-2)}
.thotp-who-g{flex:none;width:22px;height:22px;margin-right:auto}

/* code boxes */
.thotp-otp{display:flex;justify-content:center;gap:9px;margin:4px 0 0}
.thotp-shell .thotp-otp-box{width:52px;height:60px;padding:0;border:1px solid var(--th-line);border-radius:14px;background:var(--th-field);color:var(--th-ink);text-align:center;font-size:25px;font-weight:700;outline:none;transition:border-color .2s,box-shadow .2s,transform .15s}
.thotp-shell .thotp-otp-box:focus{border-color:var(--th-blue);box-shadow:var(--th-ring);background:var(--th-card);transform:translateY(-2px)}
.thotp-resend{margin:16px 0 0;text-align:center;font-size:13.5px;color:var(--th-ink-3)}
.thotp-resend b{color:var(--th-ink-2);font-variant-numeric:tabular-nums}

.thotp-back{display:block;width:max-content;margin:20px auto 0;font-size:14px}
.thotp-note{margin:20px 0 0;text-align:center;font-size:12.5px;line-height:1.9;color:var(--th-ink-3)}

/* ---------- account type and profile (kept from the previous card) ---------- */
.thotp-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px}
.thotp-grid label{margin:0;font-size:13.5px;font-weight:600;color:var(--th-ink-2)}
.thotp-wide{grid-column:1/-1}
.thotp-shell .form-control{width:100%;height:48px;margin-top:6px;padding:0 14px;border:1px solid var(--th-line);border-radius:12px;background:var(--th-field);color:var(--th-ink);box-shadow:none;font-size:15px}
.thotp-shell .form-control:focus{border-color:var(--th-blue);box-shadow:var(--th-ring);background:var(--th-card);outline:none}
.thotp-shell .form-control[readonly]{opacity:.75}
.thotp-type{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-bottom:18px;padding:4px;border:1px solid var(--th-line);border-radius:12px;background:var(--th-field)}
.thotp-type-option{position:relative;margin:0;cursor:pointer}
.thotp-type-option input{position:absolute;opacity:0;pointer-events:none}
.thotp-type-option span{display:flex;align-items:center;justify-content:center;min-height:42px;border-radius:9px;color:var(--th-ink-2);font-weight:700;transition:background .15s,color .15s}
.thotp-type-option input:checked+span{background:var(--th-blue);color:#fff;box-shadow:0 4px 12px rgba(18,103,229,.25)}
.thotp-type-option input:focus-visible+span{outline:2px solid var(--th-blue);outline-offset:2px}
.thotp-legal{min-width:0;margin:0;padding:0;border:0}
.thotp-legal[hidden]{display:none}
.thotp-section{margin:4px 0 10px;padding-bottom:6px;border-bottom:1px solid var(--th-line);color:var(--th-blue);font-weight:800;font-size:14px}
.thotp-type-choice{display:grid;gap:12px}
.thotp-type-card{display:block;width:100%;padding:18px 20px;border:1.5px solid var(--th-line);border-radius:var(--th-r);background:var(--th-card);text-align:right;cursor:pointer;transition:border-color .15s,box-shadow .15s,transform .15s}
.thotp-type-card:hover,.thotp-type-card:focus-visible{border-color:var(--th-blue);box-shadow:0 8px 22px rgba(18,103,229,.14);transform:translateY(-1px);outline:none}
.thotp-type-card strong{display:block;margin-bottom:4px;font-size:17px;color:var(--th-ink)}
.thotp-type-card span{display:block;font-size:13px;line-height:1.8;color:var(--th-ink-2)}

/* ---------- brand side ---------- */
.thotp-brand{position:relative;display:flex;flex-direction:column;justify-content:space-between;min-height:100%;padding:48px 56px;overflow:hidden;background:var(--th-brand);color:var(--th-brand-ink)}
.thotp-brand::before{content:"";position:absolute;inset:-2px;background-image:linear-gradient(rgba(120,160,255,.07) 1px,transparent 1px),linear-gradient(90deg,rgba(120,160,255,.07) 1px,transparent 1px);background-size:31px 29px;-webkit-mask-image:radial-gradient(ellipse at 30% 40%,#000,transparent 70%);mask-image:radial-gradient(ellipse at 30% 40%,#000,transparent 70%)}
.thotp-brand::after{content:"";position:absolute;left:-180px;top:-160px;width:640px;height:640px;border-radius:50%;background:radial-gradient(circle,rgba(26,123,255,.42),transparent 62%);filter:blur(10px);animation:thotp-float 12s ease-in-out infinite alternate}
@keyframes thotp-float{to{transform:translate(120px,180px)}}
.thotp-brand > *{position:relative;z-index:1}
.thotp-cells{position:absolute;inset:0;z-index:0;pointer-events:none}
.thotp-cells i{position:absolute;width:31px;height:29px;background:var(--th-blue);opacity:0;animation:thotp-blink 6s infinite}
@keyframes thotp-blink{0%,100%{opacity:0}8%{opacity:.55}30%{opacity:0}}
.thotp-brand-top{display:flex;align-items:center;gap:12px;font-size:18px;font-weight:800;letter-spacing:.02em}
.thotp-brand-top svg{width:40px;height:auto}
.thotp-brand h2{margin:0 0 14px;font-size:clamp(28px,3.1vw,44px);font-weight:800;line-height:1.45;color:var(--th-brand-ink)}
.thotp-brand h2 em{font-style:normal;background:linear-gradient(90deg,#5aa2ff,var(--th-blue));-webkit-background-clip:text;background-clip:text;color:transparent}
.thotp-brand p{max-width:440px;margin:0;font-size:16px;line-height:2;color:var(--th-brand-ink-2)}
.thotp-stats{display:flex;flex-wrap:wrap;gap:10px}
.thotp-stat{display:flex;flex-direction:column;gap:2px;min-width:120px;padding:14px 18px;border:1px solid rgba(255,255,255,.09);border-radius:14px;background:rgba(255,255,255,.05);-webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px)}
.thotp-stat b{font-size:20px}
.thotp-stat span{font-size:12.5px;color:var(--th-brand-ink-2)}

@media (max-width:900px){
  .thotp-shell{grid-template-columns:1fr}
  .thotp-brand{display:none}
  .thotp-logo{display:flex}
  .thotp-head{text-align:center}
  .thotp-badge{margin-left:auto;margin-right:auto}
  .thotp-panel{justify-content:flex-start;padding:40px 16px 48px}
}
@media (max-width:520px){
  .thotp-grid{grid-template-columns:1fr}
  .thotp-wide{grid-column:auto}
  .thotp-head h1{font-size:24px}
}
@media (max-width:380px){
  .thotp-otp{gap:6px}
  .thotp-shell .thotp-otp-box{width:44px;height:54px;font-size:22px}
}
@media (prefers-reduced-motion:reduce){
  .thotp-shell *,.thotp-shell *::before,.thotp-shell *::after,.thotp-brand::after{animation:none!important;transition:none!important}
}
