/*
 * SkyHub Portal CSS Split: app-layout.css
 * Source: assets/css/aop-app.css lines 559-809
 * Purpose: Early layout refinements, action boards, order/profile density and product drawer foundation.
 * Phase: v0.12.2.9 Architecture Stabilisation Phase 2 — CSS split only.
 */

/* v0.1.3 final shell CSS additions from Ryno feedback. */
.aop-app, .aop-app * { box-sizing: border-box; font-size: 15px; }

/* Action board refinement */
.aop-action-board-panel .aop-action-list a {
  background: rgba(255,255,255,.90);
  border-color: rgba(255,255,255,.72);
}
.aop-action-board-panel .aop-action-list strong {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--aop-navy);
  font-size: 18px;
  font-weight: 700;
}
.aop-action-arrow {
  margin-left: auto;
  color: var(--aop-cyan-dark);
  font-size: 20px;
  font-weight: 950;
  line-height: 1;
}
@media (min-width: 901px) {
  .aop-action-board-panel .aop-action-list small {
    font-size: 16px;
    line-height: 1.35;
  }
}

/* New order header and form density */
.aop-order-header-card {
  display: flex;
  justify-content: flex-end;
  text-align: right;
}
.aop-order-header-card strong {
  color: var(--aop-navy);
  font-size: 25px;
  letter-spacing: -.04em;
  font-weight: 900;
}
.aop-form-section {
  background: var(--aop-card);
  border: 1px solid rgba(255, 255, 255, .88);
  border-radius: 22px;
  box-shadow: var(--aop-shadow-soft);
  padding: 20px;
  margin-bottom: 20px;
}
.aop-section-intro h2 {
  margin: 0 0 3px;
  color: var(--aop-navy);
  font-size: inherit;
}
.aop-radio-field {
  border: 1px solid var(--aop-line);
  border-radius: 14px;
  padding: 10px 12px;
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 48px;
  background: #fff;
  flex-wrap: wrap;
}
.aop-radio-field legend {
  padding: 0 5px;
  color: var(--aop-muted);
  font-size: 11px;
  font-weight: 950;
  text-transform: uppercase;
  letter-spacing: .08em;
}
.aop-radio-field label {
  width: auto;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin: 0;
  color: var(--aop-ink);
  font-weight: 750;
  letter-spacing: 0;
  text-transform: none;
}
.aop-radio-field input { width: auto; margin: 0; }

/* Compact inline order lines */
.aop-line-table-wrap { overflow-x: visible; }
.aop-line-table {
  min-width: 0;
  width: 100%;
  table-layout: fixed;
}
.aop-line-table th,
.aop-line-table td {
  padding: 7px 6px;
  font-size: 12px;
}
.aop-line-table th:nth-child(1), .aop-line-table td:nth-child(1) { width: 34px; }
.aop-line-table th:nth-child(2), .aop-line-table td:nth-child(2) { width: 18%; }
.aop-line-table th:nth-child(3), .aop-line-table td:nth-child(3) { width: 20%; }
.aop-line-table th:nth-child(4), .aop-line-table td:nth-child(4) { width: 7%; }
.aop-line-table th:nth-child(5), .aop-line-table td:nth-child(5) { width: 8%; }
.aop-line-table th:nth-child(6), .aop-line-table td:nth-child(6) { width: 10%; }
.aop-line-table th:nth-child(7), .aop-line-table td:nth-child(7) { width: 10%; }
.aop-line-table th:nth-child(8), .aop-line-table td:nth-child(8) { width: 16%; }
.aop-line-table th:nth-child(9), .aop-line-table td:nth-child(9) { width: 42px; text-align: center; }
.aop-line-table input,
.aop-line-table select {
  min-height: 34px;
  padding: 7px 8px;
  border-radius: 10px;
  font-size: 12px;
}
.aop-line-no {
  font-weight: 500;
  color: #111;
  font-size: 13px;
}
.aop-line-delete {
  width: 30px;
  height: 30px;
  border-radius: 999px;
  border: 1px solid rgba(200,77,93,.20);
  background: rgba(200,77,93,.08);
  color: var(--aop-red);
  cursor: pointer;
  font-weight: 950;
  line-height: 1;
}
.aop-line-delete:hover { background: rgba(200,77,93,.16); }

/* Live summary refinement */
.aop-summary-dl dd {
  margin: 0;
  color: var(--aop-ink);
  font-weight: 900;
  text-align: right;
  font-size: medium;
}
.aop-live-summary h2 {
  margin: 5px 0 5px;
  color: var(--aop-navy);
  text-align: right;
  font-weight: 500;
}
.aop-live-summary > strong {
  display: block;
  font-size: 32px;
  letter-spacing: -.05em;
  margin-bottom: 14px;
  text-align: right;
  color: coral;
}

/* Price list table and product drawer */
.aop-product-thumb {
  width: 50px;
  height: 50px;
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 950;
  background: lightgray;
}
.aop-product-detail { text-align: left; }
.aop-product-hero-row {
  display: grid;
  grid-template-columns: auto;
  gap: 10px;
  align-items: center;
  justify-items: center;
  margin-bottom: 18px;
  text-align: center;
}
.aop-product-image-large {
  width: 200px;
  height: 200px;
  border-radius: 24px;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 84px;
  font-weight: 950;
  background: linear-gradient(135deg, var(--aop-cyan), var(--aop-navy));
}
.aop-product-detail .aop-eyebrow { margin-bottom: 2px; }
.aop-product-detail h2 { margin: 2px 0 4px; line-height: 1.05; }
.aop-product-detail p { margin: 0; color: var(--aop-muted); line-height: 1.35; }
.aop-product-detail .aop-dl {
  grid-template-columns: minmax(150px, .58fr) minmax(0, 1fr);
  align-items: center;
  gap: 10px 18px;
}
.aop-dl dd {
  margin: 0;
  font-weight: 500;
  font-size: 18px;
}
.aop-product-note {
  margin-top: 16px;
  color: var(--aop-red);
  font-weight: 600;
  background: rgba(200, 77, 93, .08);
  border-radius: 14px;
  padding: 12px;
  font-size: 15px;
}
.aop-reserved-control-box strong {
  color: var(--aop-navy);
  font-size: 17px;
  font-weight: 500;
}
.aop-product-add-order { width: 100%; margin-top: 14px; }

/* Profile refinement */
.aop-profile-main-card { grid-column: span 2; }
.aop-profile-photo-row {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 8px 0 16px;
}
.aop-profile-photo { margin: 0; }
.aop-profile-dl {
  grid-template-columns: minmax(88px, 120px) minmax(0, 1fr);
  gap: 8px 10px;
}
.aop-profile-dl dt { font-size: 10px; }
.aop-profile-dl dd { font-size: 14px; }
.aop-muted-copy { color: var(--aop-muted); line-height: 1.5; margin: 0 0 14px; }

@media (max-width: 1220px) {
  .aop-line-table-wrap { overflow-x: auto; }
  .aop-line-table { min-width: 980px; }
  .aop-profile-main-card { grid-column: span 2; }
}
@media (max-width: 620px) {
  .aop-order-header-card { justify-content: flex-start; text-align: left; }
  .aop-profile-main-card { grid-column: span 1; }
  .aop-profile-photo-row { align-items: flex-start; }
  .aop-product-image-large { width: 150px; height: 150px; font-size: 54px; }
  .aop-product-detail .aop-dl { grid-template-columns: 1fr; }
  .aop-dl dd { font-size: 15px; }
}



/* v0.23.2.8.7.1 — Desktop-only gate for portal app/login routes */
.aop-desktop-gate {
  display: none;
}
@media (max-width: 1179px) {
  .aop-app,
  .aop-login-screen {
    min-height: 100vh;
    background: linear-gradient(135deg, #071433, #0c274b 56%, #0f99b6);
  }
  .aop-app > :not(.aop-desktop-gate),
  .aop-login-screen > :not(.aop-desktop-gate) {
    display: none !important;
  }
  .aop-desktop-gate {
    position: fixed;
    inset: 0;
    z-index: 2147483000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: linear-gradient(135deg, #071433, #0c274b 56%, #0f99b6);
    color: #fff;
    text-align: center;
  }
  .aop-desktop-gate div {
    width: min(520px, 100%);
    padding: 28px;
    border: 1px solid rgba(255,255,255,.20);
    border-radius: 28px;
    background: rgba(255,255,255,.10);
    box-shadow: 0 28px 80px rgba(0,0,0,.26);
    backdrop-filter: blur(14px);
  }
  .aop-desktop-gate strong {
    display: block;
    margin-bottom: 10px;
    font-size: 24px;
    line-height: 1.12;
    letter-spacing: -.03em;
  }
  .aop-desktop-gate p {
    margin: 0;
    color: rgba(255,255,255,.82);
    font-size: 15px;
    line-height: 1.55;
  }
}
