.auth-shell{
  width:min(calc(100% - 32px), var(--max-width));
  margin:0 auto;
  padding:24px 0 46px;
}

.auth-grid{
  display:grid;
  grid-template-columns:minmax(0, 1.1fr) minmax(320px, .9fr);
  gap:20px;
  align-items:stretch;
}

.auth-card,
.shell-card,
.ticket-shell,
.detail-shell,
.credits-card,
.success-strip{
  border:1px solid var(--line);
  background:linear-gradient(180deg, rgba(16,25,34,0.94), rgba(9,15,22,0.96));
  box-shadow:var(--shadow);
  border-radius:22px;
}

.auth-card,
.shell-card,
.ticket-shell,
.detail-shell,
.credits-card{
  padding:24px;
}

.auth-copy{
  display:grid;
  gap:18px;
  align-content:start;
}

.auth-copy p,
.shell-card p,
.ticket-meta-note,
.credits-card p{
  color:var(--muted);
  line-height:1.75;
}

.service-pill-grid,
.info-stack,
.download-list-live,
.transactions-list-live,
.timeline-live{
  display:grid;
  gap:14px;
}

.service-pill{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  padding:16px 18px;
  border-radius:16px;
  background:rgba(255,255,255,0.025);
  border:1px solid rgba(255,255,255,0.06);
}

.service-pill strong{
  font-family:"Sora",sans-serif;
}

.service-pill span,
.mini-note,
.meta-value-muted{
  color:var(--muted);
}

.alert{
  padding:14px 16px;
  border-radius:16px;
  font-size:.95rem;
  line-height:1.6;
  margin-bottom:14px;
}

.alert.success{
  background:rgba(112,210,138,0.12);
  border:1px solid rgba(112,210,138,0.35);
  color:var(--success);
}

.alert.error{
  background:rgba(255,133,120,0.12);
  border:1px solid rgba(255,133,120,0.35);
  color:var(--danger);
}

.auth-form{
  display:grid;
  gap:16px;
}

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

.form-grid-two .full{
  grid-column:1 / -1;
}

.form-label-block{
  display:grid;
  gap:10px;
}

.form-label-block span{
  color:#dde8f3;
  font-size:.95rem;
}

.form-label-block input,
.form-label-block select,
.form-label-block textarea{
  min-height:52px;
  padding:14px 16px;
  border-radius:16px;
  border:1px solid rgba(255,255,255,0.08);
  background:rgba(5,11,18,0.6);
  color:var(--text);
}

.form-label-block textarea{
  min-height:124px;
  resize:vertical;
}

.form-label-block input:focus,
.form-label-block select:focus,
.form-label-block textarea:focus{
  outline:none;
  border-color:rgba(255,106,61,0.75);
  box-shadow:0 0 0 4px rgba(255,106,61,0.12);
}

.auth-links{
  display:flex;
  flex-wrap:wrap;
  gap:14px;
  color:var(--muted);
}

.auth-links a{
  color:#a83228;
  text-decoration:underline;
  text-underline-offset:3px;
}

.success-strip{
  padding:16px 18px;
  margin-bottom:24px;
}

.portal-frame{
  width:min(calc(100% - 32px), 1380px);
  margin:20px auto;
  display:grid;
  grid-template-columns:270px minmax(0, 1fr);
  gap:20px;
}

.portal-nav{
  position:sticky;
  top:20px;
  align-self:start;
  display:grid;
  gap:14px;
}

.nav-card{
  padding:16px;
  border-radius:20px;
  border:1px solid var(--line);
  background:rgba(10,18,27,0.88);
  box-shadow:var(--shadow);
}

.nav-links{
  display:grid;
  gap:10px;
}

.nav-links a{
  padding:14px 16px;
  border-radius:16px;
  color:var(--muted);
}

.nav-links a:hover,
.nav-links a.active{
  background:rgba(255,255,255,0.05);
  color:var(--text);
}

.nav-meta{
  display:grid;
  gap:10px;
}

.nav-meta strong{
  font-family:"Sora",sans-serif;
}

.portal-content{
  display:grid;
  gap:20px;
}

.portal-hero{
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:20px;
}

.kpi-strip-live{
  display:grid;
  grid-template-columns:repeat(auto-fit, minmax(180px, 1fr));
  gap:16px;
}

.kpi-live{
  padding:20px;
  border-radius:20px;
  border:1px solid var(--line);
  background:linear-gradient(180deg, rgba(16,25,34,0.94), rgba(9,15,22,0.96));
  box-shadow:var(--shadow);
}

.kpi-live span{
  color:var(--muted);
}

.kpi-live strong{
  display:block;
  margin:12px 0 10px;
  font-family:"Sora",sans-serif;
  font-size:1.75rem;
}

.portal-grid-live{
  display:grid;
  grid-template-columns:minmax(0, 1.1fr) minmax(360px, .9fr);
  gap:20px;
}

.column-stack{
  display:grid;
  gap:20px;
}

.card-head-live{
  display:flex;
  justify-content:space-between;
  align-items:flex-start;
  gap:16px;
  margin-bottom:18px;
}

.pill-live{
  padding:10px 14px;
  border-radius:999px;
  background:rgba(255,255,255,0.03);
  border:1px solid var(--line-strong);
  color:#dbe5ef;
  font-size:.92rem;
}

.ticket-shell{
  display:grid;
  gap:16px;
}

.ticket-list-live{
  display:grid;
  gap:12px;
}

.ticket-row-live{
  padding:18px;
  border-radius:18px;
  border:1px solid rgba(255,255,255,0.08);
  background:rgba(255,255,255,0.025);
  cursor:pointer;
  transition:transform .2s ease, border-color .2s ease, background .2s ease;
}

.ticket-row-live:hover,
.ticket-row-live.active{
  transform:translateY(-1px);
  border-color:rgba(255,106,61,0.42);
  background:rgba(255,106,61,0.08);
}

.ticket-row-top{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:14px;
  margin-bottom:10px;
}

.ticket-row-id{
  font-family:"Sora",sans-serif;
  color:var(--accent-soft);
  font-size:.92rem;
}

.ticket-row-subject{
  font-weight:700;
  margin-bottom:8px;
}

.ticket-row-meta{
  display:flex;
  flex-wrap:wrap;
  gap:12px;
  color:var(--muted);
  font-size:.88rem;
}

.ticket-state{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:8px 12px;
  border-radius:999px;
  font-size:.85rem;
}

.ticket-state.open{
  background:rgba(88,214,255,0.14);
  color:var(--highlight);
}

.ticket-state.waiting{
  background:rgba(255,209,102,0.12);
  color:var(--warning);
}

.ticket-state.closed,
.ticket-state.resolved{
  background:rgba(112,210,138,0.14);
  color:var(--success);
}

.ticket-state.payment{
  background:rgba(255,133,120,0.12);
  color:var(--danger);
}

.detail-shell{
  min-height:460px;
}

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

.meta-card-live{
  padding:16px;
  border-radius:16px;
  border:1px solid rgba(255,255,255,0.08);
  background:rgba(255,255,255,0.025);
}

.meta-card-live span{
  display:block;
  margin-bottom:8px;
  color:var(--muted);
  font-size:.85rem;
}

.status-box-live{
  padding:18px;
  border-radius:20px;
  margin-bottom:18px;
}

.status-box-live.payment{
  background:rgba(255,209,102,0.1);
  border:1px solid rgba(255,209,102,0.35);
}

.status-box-live.success{
  background:rgba(112,210,138,0.1);
  border:1px solid rgba(112,210,138,0.35);
}

.status-box-live.info{
  background:rgba(88,214,255,0.1);
  border:1px solid rgba(88,214,255,0.35);
}

.actions-row-live{
  display:flex;
  flex-wrap:wrap;
  gap:12px;
  margin-top:14px;
}

.message-stream-live{
  display:grid;
  gap:14px;
  max-height:400px;
  overflow:auto;
  padding-right:4px;
}

.message-bubble{
  max-width:86%;
  padding:16px 18px;
  border-radius:18px;
  border:1px solid rgba(255,255,255,0.08);
}

.message-bubble.client{
  margin-left:auto;
  background:rgba(255,106,61,0.09);
}

.message-bubble.admin{
  margin-right:auto;
  background:rgba(255,255,255,0.04);
}

.message-bubble.system{
  margin:0 auto;
  max-width:94%;
  background:rgba(88,214,255,0.08);
}

.message-head-live{
  display:flex;
  justify-content:space-between;
  gap:14px;
  margin-bottom:8px;
  font-size:.82rem;
}

.message-head-live span:last-child{
  color:var(--muted);
}

.message-file-live{
  margin-top:12px;
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:10px 12px;
  border-radius:14px;
  background:rgba(255,255,255,0.04);
  color:var(--accent-soft);
}

.reply-box-live{
  margin-top:18px;
  display:grid;
  gap:12px;
}

.reply-box-live textarea{
  min-height:120px;
}

.reply-actions-live{
  display:flex;
  flex-wrap:wrap;
  justify-content:space-between;
  gap:12px;
  align-items:center;
}

.upload-shortcuts{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
}

.ghost-btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  padding:12px 16px;
  border-radius:16px;
  border:1px solid var(--line);
  background:rgba(255,255,255,0.04);
  color:var(--text);
  cursor:pointer;
}

.ghost-btn:hover{
  border-color:rgba(255,106,61,0.45);
}

.ghost-btn.active{
  background:linear-gradient(135deg, rgba(255,106,61,0.18), rgba(255,178,107,0.12));
  border-color:rgba(255,106,61,0.45);
}

.download-card-live,
.transaction-live,
.timeline-item-live{
  padding:18px;
  border-radius:18px;
  border:1px solid rgba(255,255,255,0.08);
  background:rgba(255,255,255,0.025);
}

.download-card-live small,
.transaction-live small,
.timeline-item-live small{
  color:var(--muted);
}

.download-card-live strong,
.transaction-live strong{
  display:block;
  margin-bottom:8px;
}

.credit-banner{
  display:grid;
  gap:14px;
  padding:20px;
  border-radius:18px;
  background:linear-gradient(135deg, rgba(255,209,102,0.12), rgba(255,106,61,0.08));
  border:1px solid rgba(255,209,102,0.22);
}

.transaction-live{
  display:flex;
  justify-content:space-between;
  gap:14px;
  align-items:flex-start;
}

.transaction-live b.plus{
  color:var(--success);
}

.transaction-live b.minus{
  color:var(--danger);
}

.payment-grid-live{
  display:grid;
  grid-template-columns:repeat(auto-fit, minmax(180px, 1fr));
  gap:16px;
}

.method-card-live{
  padding:18px;
  border-radius:16px;
  border:1px solid rgba(255,255,255,0.08);
  background:rgba(255,255,255,0.025);
}

.credits-hero{
  width:min(calc(100% - 32px), 1120px);
  margin:20px auto 36px;
  display:grid;
  grid-template-columns:minmax(0, .95fr) minmax(360px, .85fr);
  gap:20px;
}

.credits-card{
  display:grid;
  gap:18px;
}

.price-summary-live{
  display:grid;
  gap:14px;
  padding:18px;
  border-radius:18px;
  background:rgba(255,255,255,0.025);
  border:1px solid rgba(255,255,255,0.08);
}

.price-row-live{
  display:flex;
  justify-content:space-between;
  gap:12px;
}

.price-row-live span{
  color:var(--muted);
}

.price-row-live strong{
  font-family:"Sora",sans-serif;
}

.radio-stack-live{
  display:grid;
  gap:12px;
}

.radio-box-live{
  display:flex;
  gap:14px;
  padding:16px;
  border-radius:18px;
  border:1px solid rgba(255,255,255,0.08);
  background:rgba(255,255,255,0.03);
}

.radio-box-live input{
  width:18px;
  height:18px;
  accent-color:var(--accent);
  margin-top:4px;
}

.radio-box-live small{
  display:block;
  margin-top:6px;
  color:var(--muted);
}

@media (max-width: 1100px){
  .auth-grid,
  .portal-grid-live,
  .credits-hero{
    grid-template-columns:1fr;
  }

  .portal-frame{
    grid-template-columns:1fr;
  }

  .portal-nav{
    position:static;
  }

  .kpi-strip-live{
    grid-template-columns:repeat(2, minmax(0, 1fr));
  }

  .payment-grid-live{
    grid-template-columns:1fr;
  }
}

@media (max-width: 780px){
  .form-grid-two,
  .meta-grid-live,
  .kpi-strip-live{
    grid-template-columns:1fr;
  }

  .portal-hero,
  .card-head-live,
  .reply-actions-live,
  .transaction-live{
    flex-direction:column;
    align-items:flex-start;
  }

  .message-bubble{
    max-width:100%;
  }
}

/* Client workbench layout inspired by compact ECU order systems. */
body.client-workbench{
  margin:0;
  min-height:100vh;
  background:#fff;
  color:#151b22;
  font-family:Manrope, Arial, sans-serif;
  font-size:13px;
  overflow-x:auto;
}

body.client-workbench::before,
body.client-workbench .site-noise{
  display:none;
}

.workbench-topbar{
  height:38px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:16px;
  padding:0 12px 0 0;
  background:#050505;
  color:#fff;
  border-bottom:1px solid #000;
}

.workbench-logo{
  width:224px;
  height:38px;
  display:flex;
  align-items:center;
  gap:10px;
  padding-left:8px;
  color:#e9eef5;
}

.workbench-mark{
  width:34px;
  height:24px;
  display:grid;
  place-items:center;
  border:2px solid #079ac7;
  border-radius:5px;
  color:#079ac7;
  font-family:Sora, sans-serif;
  font-weight:900;
  font-size:13px;
  line-height:1;
}

.workbench-logo-text{
  display:grid;
  gap:0;
  line-height:1;
}

.workbench-logo-text strong{
  font-family:Sora, sans-serif;
  font-size:12px;
  color:#fff;
}

.workbench-logo-text small{
  font-size:9px;
  color:#b8c2cc;
}

.workbench-global-search{
  margin-right:auto;
  height:32px;
  display:flex;
  align-items:center;
  min-width:288px;
}

.workbench-global-search input,
.workbench-search-line input{
  height:32px;
  border:1px solid #cfd7df;
  background:#fff;
  color:#151b22;
  padding:0 12px;
  border-radius:0;
  box-shadow:none;
}

.workbench-global-search input{
  width:190px;
}

.workbench-global-search a,
.workbench-global-search button,
.workbench-search-line button{
  width:34px;
  height:32px;
  display:grid;
  place-items:center;
  border:none;
  background:#006d68;
  color:#fff;
  font-size:18px;
  cursor:pointer;
}

.workbench-global-search button,
.workbench-search-line button{
  background:#b9121b;
  font-size:17px;
}

.workbench-userbar{
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap:14px;
  min-width:0;
  white-space:nowrap;
  font-size:12px;
  font-weight:800;
}

.workbench-userbar a{
  color:#fff;
}

.notification-dot{
  min-width:26px;
  height:18px;
  display:inline-grid;
  place-items:center;
  border-radius:999px;
  background:#f27622;
  color:#fff;
  font-size:11px;
}

.workbench-layout{
  min-height:calc(100vh - 38px);
  display:grid;
  grid-template-columns:312px minmax(760px, 1fr);
  background:#fff;
}

.workbench-sidebar{
  background:#f1f3f5;
  border-right:1px solid #e2e6ea;
  min-height:calc(100vh - 38px);
}

.workbench-menu{
  display:grid;
  gap:0;
  padding:22px 14px 14px;
  color:#40506a;
  font-size:13px;
}

.workbench-menu span,
.workbench-menu a{
  min-height:30px;
  display:flex;
  align-items:center;
  color:#3f4c5a;
  font-weight:700;
}

.workbench-menu span{
  margin-top:8px;
  color:#667180;
  font-size:12px;
  text-transform:uppercase;
}

.workbench-menu a:hover,
.workbench-menu .menu-active,
.workbench-menu .menu-accent{
  color:#b9121b;
}

.workbench-ad{
  height:602px;
  margin-top:8px;
  padding:40px 22px;
  display:grid;
  align-content:start;
  justify-items:center;
  text-align:center;
  background:
    linear-gradient(160deg, rgba(0,0,0,.88), rgba(0,0,0,.42)),
    repeating-linear-gradient(135deg, #1c2229 0 8px, #11161b 8px 16px);
  color:#fff;
  border-top:1px solid #20262d;
  border-bottom:1px solid #20262d;
  overflow:hidden;
}

.workbench-ad small{
  margin-bottom:46px;
  color:#8fd6ff;
  font-weight:900;
  text-transform:uppercase;
  letter-spacing:.08em;
}

.workbench-ad span{
  font-size:20px;
  margin-bottom:10px;
}

.workbench-ad strong{
  font-family:Sora, sans-serif;
  font-size:56px;
  line-height:.95;
  color:#fff;
  letter-spacing:.03em;
}

.workbench-ad b{
  margin:18px 0 22px;
  font-size:22px;
  letter-spacing:.38em;
}

.workbench-ad em{
  font-style:normal;
  font-weight:900;
  font-size:27px;
}

.workbench-ad p{
  margin:24px 0 0;
  color:#30a9e6;
  font-weight:900;
  text-transform:uppercase;
  line-height:2.05;
  letter-spacing:.04em;
}

.workbench-main{
  width:min(974px, calc(100% - 42px));
  margin:32px auto 80px;
  color:#151b22;
}

.workbench-notice{
  min-height:62px;
  margin:0 0 36px;
  padding:14px 42px 14px 14px;
  position:relative;
  display:flex;
  align-items:center;
  background:#ffd64f;
  color:#1e1e1e;
}

.workbench-notice p{
  margin:0;
  line-height:1.45;
}

.workbench-notice button{
  position:absolute;
  right:12px;
  top:12px;
  width:24px;
  height:24px;
  border:0;
  background:transparent;
  color:#8a6610;
  font-size:26px;
  line-height:1;
  cursor:pointer;
}

.workbench-section{
  margin-bottom:28px;
  border:1px solid #d7dde4;
  background:#fff;
}

.workbench-section#tickets{
  border:none;
}

.workbench-section-head{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:18px;
  padding-bottom:12px;
  margin-bottom:14px;
  border-bottom:1px solid #d7dde4;
}

.workbench-section-head h1{
  margin:0;
  color:#b9121b;
  font-family:Sora, sans-serif;
  font-size:26px;
  line-height:1;
  letter-spacing:.34em;
  font-weight:600;
}

.workbench-section-head h2{
  margin:0;
  color:#5e6a78;
  font-family:Manrope, Arial, sans-serif;
  font-size:13px;
  letter-spacing:.05em;
}

.workbench-section-head span,
.workbench-section-head strong{
  color:#5e6a78;
  font-size:13px;
  font-weight:800;
}

.workbench-section-head.small{
  padding:0 0 10px;
  margin-bottom:12px;
}

.workbench-search-line{
  display:flex;
  align-items:center;
  margin-bottom:12px;
}

.workbench-search-line input{
  flex:1;
}

.order-add-button,
.order-save,
.order-cancel{
  min-height:28px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  border:1px solid transparent;
  border-radius:0;
  padding:0 12px;
  font-weight:900;
  font-size:12px;
  cursor:pointer;
}

.order-add-button,
.order-save{
  background:#b9121b;
  color:#fff;
}

.order-cancel{
  background:#fff;
  color:#111;
  border-color:#202020;
}

.order-list-title{
  display:flex;
  align-items:center;
  gap:8px;
  height:38px;
  color:#5e6a78;
  font-weight:900;
  text-transform:uppercase;
}

.order-list-title button{
  border:0;
  background:transparent;
  color:#6a7682;
  cursor:pointer;
}

.ticket-table-live{
  border:1px solid #cfd7df;
  border-top:2px solid #b9121b;
  overflow:auto;
}

.ticket-table-head,
.ticket-table-row{
  min-width:956px;
  display:grid;
  grid-template-columns:40px 96px 150px 100px 136px 70px 78px 88px 126px 96px 52px;
  align-items:center;
}

.ticket-table-head{
  min-height:44px;
  background:#fff;
  color:#111;
  font-weight:900;
  border-bottom:1px solid #dfe5eb;
}

.ticket-table-head span,
.ticket-table-row span{
  padding:0 8px;
  overflow:hidden;
  white-space:nowrap;
  text-overflow:ellipsis;
}

.ticket-table-row{
  width:100%;
  min-height:40px;
  border:0;
  border-bottom:1px solid #e6ebf0;
  background:#3f83e8;
  color:#111;
  text-align:left;
  font:inherit;
  cursor:pointer;
}

.ticket-table-row:nth-child(odd){
  background:#5a97ee;
}

.ticket-table-row:hover,
.ticket-table-row.active{
  outline:2px solid #b9121b;
  outline-offset:-2px;
}

.ticket-row-live.is-hidden{
  display:none;
}

.ticket-state{
  min-height:22px;
  display:inline-flex;
  align-items:center;
  justify-content:flex-start;
  color:#111;
  border-radius:0;
  padding:0 8px;
  font-size:12px;
  font-weight:800;
  background:transparent;
}

.ticket-state.open{
  color:#164a94;
}

.ticket-state.waiting{
  color:#7b1fa2;
}

.ticket-state.resolved,
.ticket-state.closed{
  color:#1f6c3b;
}

.ticket-state.payment{
  color:#b9121b;
}

.paid-cell{
  display:inline-grid;
  place-items:center;
  color:#fff;
  font-weight:900;
}

.paid-cell:not(:empty){
  width:14px;
  height:14px;
  margin-left:8px;
  border-radius:3px;
  background:#b9121b;
}

.row-info{
  width:28px;
  height:24px;
  margin-left:auto;
  display:grid;
  place-items:center;
  background:#5aa2ff;
  border:2px solid #b9121b;
  color:#b9121b;
  font-weight:900;
}

.ticket-table-empty{
  min-height:84px;
  display:grid;
  place-items:center;
  gap:6px;
  color:#5e6a78;
  text-align:center;
}

.ticket-table-empty strong{
  color:#151b22;
}

.order-table-footer{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:18px;
  margin-top:14px;
  color:#222;
}

.order-table-footer label{
  display:flex;
  align-items:center;
  gap:8px;
}

.order-table-footer select{
  min-width:54px;
  height:28px;
  border:1px solid #cfd7df;
  background:#fff;
}

.status-legend{
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  justify-content:center;
  gap:12px;
  color:#252525;
}

.status-legend span{
  display:inline-flex;
  align-items:center;
  gap:5px;
}

.status-legend span::before{
  content:"";
  width:15px;
  height:15px;
  display:inline-block;
}

.status-legend .late::before{background:#ff6b6b;}
.status-legend .new::before{background:#8c64b8;}
.status-legend .work::before{background:#5fb760;}
.status-legend .done::before{background:#3f83e8;}
.status-legend .claim::before{background:#ffce3a;}
.status-legend .copy::before{background:#1ee889;}

.pager-mini{
  display:flex;
  align-items:center;
  gap:2px;
}

.pager-mini button,
.pager-mini b{
  min-width:25px;
  height:24px;
  display:grid;
  place-items:center;
  border:1px solid #d7dde4;
  background:#fff;
  color:#6a7682;
}

.pager-mini b{
  background:#b9121b;
  color:#fff;
  border-color:#b9121b;
}

.order-editor{
  padding:14px 12px 0;
}

.order-form{
  display:grid;
  gap:10px;
  padding:0;
}

.order-form fieldset{
  display:flex;
  flex-wrap:wrap;
  gap:12px;
  margin:0;
  padding:0 0 4px;
  border:0;
}

.order-form legend,
.order-form label > span:first-child,
.order-comment > span{
  display:block;
  margin-bottom:6px;
  color:#111;
  font-weight:900;
}

.order-form label{
  color:#111;
  font-weight:600;
}

.order-form input,
.order-form select,
.order-form textarea{
  width:100%;
  min-height:30px;
  border:1px solid #c7d0d9;
  border-radius:0;
  background:#fff;
  color:#151b22;
  padding:5px 8px;
  box-shadow:none;
}

.order-form input[type="radio"],
.order-form input[type="checkbox"]{
  width:auto;
  min-height:auto;
  accent-color:#b9121b;
}

.order-form-grid{
  display:grid;
  grid-template-columns:1fr 1fr 1fr 1fr;
  gap:9px 18px;
}

.inline-radios{
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  gap:10px;
  min-height:30px;
}

.inline-radios label{
  display:flex;
  align-items:center;
  gap:5px;
  margin:0;
}

.order-comment{
  display:grid;
  gap:4px;
}

.order-comment textarea{
  min-height:64px;
  resize:vertical;
}

.order-form-actions{
  min-height:70px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  border-top:1px solid #dfe5eb;
  padding:10px 0;
}

.order-required{
  margin:0 -12px;
  padding:8px 12px;
  border-top:1px solid #dfe5eb;
  background:#f8fafc;
  color:#111;
  font-size:12px;
}

.order-detail-section,
.compact-section{
  padding:16px;
}

.workbench-secondary-grid{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:18px;
}

.wide-pay{
  width:100%;
  margin-bottom:14px;
}

.card-head-live{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:14px;
  margin-bottom:16px;
}

.card-head-live h2,
.ticket-meta-note h2{
  color:#151b22;
  font-size:22px;
  letter-spacing:0;
}

.meta-grid-live{
  display:grid;
  grid-template-columns:repeat(4, minmax(0, 1fr));
  gap:10px;
  margin:12px 0;
}

.meta-card-live,
.download-card-live,
.transaction-live,
.message-bubble,
.status-box-live{
  border:1px solid #d7dde4;
  border-radius:0;
  background:#fff;
  box-shadow:none;
}

.meta-card-live{
  padding:12px;
}

.meta-card-live span,
.download-card-live small,
.transaction-live small,
.ticket-meta-note{
  color:#566576;
}

.status-box-live{
  padding:14px;
  margin:14px 0;
}

.status-box-live.info{background:#f4f9ff;}
.status-box-live.success{background:#f1fbf4;}
.status-box-live.payment{background:#fff8e4;}

.message-stream-live{
  max-height:360px;
  overflow:auto;
  display:grid;
  gap:10px;
  margin-top:12px;
}

.message-bubble{
  max-width:78%;
  padding:12px;
}

.message-bubble.client{
  margin-left:auto;
  background:#edf6ff;
}

.message-bubble.admin{
  background:#fff2ec;
}

.message-bubble.system{
  margin-inline:auto;
  background:#fff8e4;
}

.message-head-live{
  display:flex;
  justify-content:space-between;
  gap:12px;
  margin-bottom:6px;
  font-weight:900;
}

.message-file-live{
  display:inline-flex;
  margin-top:8px;
  color:#b9121b;
  font-weight:900;
}

.reply-box-live{
  display:grid;
  gap:10px;
  margin-top:14px;
}

.reply-box-live textarea{
  min-height:86px;
}

.reply-actions-live,
.actions-row-live,
.upload-shortcuts{
  display:flex;
  align-items:center;
  justify-content:space-between;
  flex-wrap:wrap;
  gap:10px;
}

.ghost-btn{
  min-height:30px;
  border:1px solid #c7d0d9;
  border-radius:0;
  background:#fff;
  color:#151b22;
  padding:0 10px;
  font-weight:900;
}

.download-list-live,
.transactions-list-live{
  display:grid;
  gap:10px;
}

.download-card-live,
.transaction-live{
  padding:12px;
}

.transaction-live{
  display:flex;
  justify-content:space-between;
  gap:12px;
}

.transaction-live b.plus{color:#1f8f4d;}
.transaction-live b.minus{color:#b9121b;}

@media (max-width: 1180px){
  .workbench-layout{
    grid-template-columns:250px minmax(720px, 1fr);
  }

  .workbench-logo{
    width:190px;
  }

  .workbench-sidebar{
    min-width:250px;
  }
}

@media (max-width: 860px){
  .workbench-topbar{
    height:auto;
    min-height:44px;
    flex-wrap:wrap;
    padding:6px 10px;
  }

  .workbench-global-search,
  .workbench-userbar{
    width:100%;
  }

  .workbench-layout{
    display:block;
  }

  .workbench-sidebar{
    min-height:auto;
  }

  .workbench-ad{
    display:none;
  }

  .workbench-main{
    width:calc(100% - 24px);
    margin:18px auto 44px;
  }

  .order-form-grid,
  .meta-grid-live,
  .workbench-secondary-grid{
    grid-template-columns:1fr;
  }

  .workbench-section-head{
    align-items:flex-start;
    flex-direction:column;
  }

  .workbench-section-head h1{
    font-size:20px;
    letter-spacing:.18em;
  }

  .order-table-footer{
    align-items:flex-start;
    flex-direction:column;
  }
}

.auth-card,
.shell-card,
.ticket-shell,
.detail-shell,
.credits-card,
.success-strip,
.kpi-live,
.nav-card,
.download-card-live,
.transaction-live,
.meta-card-live,
.message-bubble,
.status-box-live,
.price-summary-live,
.method-card-live,
.radio-box-live,
.credit-banner{
  background:#fff;
  border-color:var(--line);
  box-shadow:var(--shadow);
}

.portal-frame{
  width:min(calc(100% - 28px), 1320px);
  margin:18px auto 34px;
  gap:18px;
}

.portal-nav{
  gap:12px;
}

.nav-card,
.auth-card,
.shell-card,
.ticket-shell,
.detail-shell,
.credits-card{
  border-radius:14px;
}

.portal-hero,
.card-head-live{
  align-items:center;
}

.service-pill,
.ticket-row-live,
.upload-shortcuts .ghost-btn{
  background:#f8fafc;
  border-color:#dfe7ef;
  border-radius:12px;
}

.ticket-row-live:hover,
.nav-links a:hover,
.nav-links a.active{
  background:#fff3ef;
  color:#17202a;
}

.kpi-live strong,
.auth-card h1,
.auth-card h2,
.shell-card h2,
.ticket-shell h2,
.detail-shell h2,
.credits-card h1,
.credits-card h2{
  color:#17202a;
}

.message-bubble.client{
  background:#eef6ff;
  border-color:#cfe5fb;
}

.message-bubble.admin{
  background:#fff3ef;
  border-color:#f4c8bb;
}

.message-bubble.system{
  background:#fff8e6;
  border-color:#efdca5;
}

.form-label-block span,
.checkbox span{
  color:#405167;
}

.form-label-block input,
.form-label-block select,
.form-label-block textarea{
  background:#fff;
  border:1px solid #ccd8e5;
  color:#17202a;
  box-shadow:none;
}

.form-label-block input::placeholder,
.form-label-block textarea::placeholder{
  color:#8a98aa;
}

.form-label-block input:focus,
.form-label-block select:focus,
.form-label-block textarea:focus{
  border-color:#d94a38;
  box-shadow:0 0 0 4px rgba(217,74,56,.12);
}

.portal-frame,
.auth-shell,
.credits-hero{
  --muted:#526173;
  color:#17202a;
  font-weight:600;
}

.portal-frame p,
.portal-frame small,
.auth-shell p,
.auth-shell small,
.credits-hero p,
.credits-hero small,
.ticket-meta-note,
.ticket-row-meta,
.meta-value-muted,
.mini-note,
.message-head-live span:last-child{
  color:#46566a;
  font-weight:600;
}

.nav-links a,
.form-label-block span,
.meta-card-live span,
.ticket-row-id,
.pill-live,
.ghost-btn,
.secondary-btn,
.primary-btn{
  font-weight:700;
}

.brand-copy strong,
.nav-meta strong,
.ticket-row-subject,
.kpi-live strong,
.meta-card-live strong,
.status-box-live strong,
.message-head-live span:first-child,
.download-card-live strong,
.transaction-live strong{
  color:#111923;
  font-weight:800;
}

.form-label-block input,
.form-label-block select,
.form-label-block textarea,
.message-bubble,
.message-bubble div,
.ticket-state,
.price-row-live{
  font-weight:600;
}

.message-file-live{
  font-weight:700;
}
