/* =========================================================================
   Pacewave — SIM Cards page (sim-cards.html)
   Loaded after styles.css and core-network.css (shared solution-page
   pieces: .cn-section, .cn-stats, .cn-table, .cn-related, tokens).
   New classes are prefixed sm-.
   ========================================================================= */

/* ── Hero ───────────────────────────────────────────────────────────────── */
.sm-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 1.5rem 2.5rem;
  align-items: center;
}
.sm-hero .cn-stats, .sm-hero .cn-back { grid-column: 1 / -1; }
.sm-hero .cn-stats { margin-top: .5rem; }
.sm-hero .cn-back { margin-top: 0; justify-self: start; }
.sm-hero-cta { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.5rem; }

.sm-photo {
  margin: 0;
  padding: 1.75rem 1.5rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background:
    radial-gradient(60% 60% at 55% 50%, rgba(20,163,184,.2), transparent 70%),
    linear-gradient(180deg, var(--bg-2), var(--bg-1));
  text-align: center;
}
.sm-photo img { width: 100%; max-width: 480px; height: auto; margin: 0 auto; filter: drop-shadow(0 22px 28px rgba(0,0,0,.5)); }
.sm-photo figcaption { margin-top: .75rem; font-size: .74rem; font-style: italic; color: var(--text-muted); }

.sm-grid4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.sm-kicker { font-weight: 600; color: var(--e2e-teal); font-size: 1.05rem; }
.sm-body { margin-top: .9rem; color: var(--text-muted); font-size: .95rem; }
.sm-body a { color: var(--e2e-teal); text-decoration: underline; text-underline-offset: 3px; }

.sm-ico {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 40px; height: 40px;
  border-radius: 50%;
  background: var(--gradient);
  color: #fff;
}
.sm-ico .material-icons-outlined { font-size: 21px; }

/* ── Profile variables ──────────────────────────────────────────────────── */
.sm-profile { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 1.5rem 2.5rem; align-items: start; }
.sm-vars { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem; }
.sm-var {
  display: flex;
  flex-direction: column;
  gap: .3rem;
  padding: .9rem 1rem;
  border: 1px solid var(--border);
  border-left: 3px solid var(--e2e-teal);
  border-radius: 12px;
  background: linear-gradient(180deg, var(--bg-2), var(--bg-1));
}
.sm-var-k { font-family: var(--font-mono); font-size: .82rem; font-weight: 500; color: var(--e2e-teal); }
.sm-var-v { font-size: .9rem; color: var(--text-muted); }

/* ── Form factors (to scale) ────────────────────────────────────────────── */
.sm-ff {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 1.5rem 2.5rem;
  align-items: center;
  padding: 1.5rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, var(--bg-2), var(--bg-1));
}
.sm-ff-fig { margin: 0; }
.sm-ff-svg { display: block; width: 100%; max-width: 520px; height: auto; margin: 0 auto; }
.sm-ff-svg path, .sm-ff-svg rect { fill: none; stroke-width: 2; stroke-linejoin: round; }
.sm-ff1 { stroke: rgba(255,255,255,.35); fill: rgba(255,255,255,.03) !important; }
.sm-ff2 { stroke: #14a3b8; }
.sm-ff3 { stroke: #5b7cf0; }
.sm-ff4 { stroke: #e6e9ef; }
.sm-chip { fill: rgba(20,163,184,.28) !important; stroke: rgba(20,163,184,.6) !important; stroke-width: 1 !important; }
.sm-chip-lines { stroke: rgba(20,163,184,.6); stroke-width: 1 !important; }
.sm-ff-cap { margin-top: .5rem; text-align: center; font-size: .74rem; font-style: italic; color: var(--text-muted); }

.sm-ff-key { display: flex; flex-direction: column; gap: .9rem; }
.sm-ff-key li { display: flex; align-items: center; gap: .85rem; }
.sm-ff-key i { flex-shrink: 0; width: 26px; height: 18px; border-radius: 3px; border: 2px solid; }
.sm-ff-key .sm-k1 { border-color: rgba(255,255,255,.35); }
.sm-ff-key .sm-k2 { border-color: #14a3b8; }
.sm-ff-key .sm-k3 { border-color: #5b7cf0; }
.sm-ff-key .sm-k4 { border-color: #e6e9ef; }
.sm-ff-key strong { display: block; font-size: .95rem; }
.sm-ff-key span { font-family: var(--font-mono); font-size: .8rem; color: var(--text-muted); }

/* ── Standards table ────────────────────────────────────────────────────── */
.sm-table td { color: var(--text); }
.sm-table td:nth-child(2) { color: var(--text-muted); }
.sm-table td:last-child { white-space: normal; }
.sm-table tbody th { white-space: normal; }
.sm-opt {
  display: inline-block;
  margin-left: .4rem;
  padding: .05rem .5rem;
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .04em;
  color: var(--e2e-teal);
  border: 1px solid rgba(20,163,184,.5);
  border-radius: 999px;
  vertical-align: 1px;
}

/* ── Full specification ─────────────────────────────────────────────────── */
.sm-spec { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.sm-spec-col, .sm-opt-card {
  padding: 1.4rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: linear-gradient(180deg, var(--bg-2), var(--bg-1));
}
.sm-spec-head { display: flex; align-items: center; gap: .75rem; margin-bottom: 1rem; }
.sm-spec-head h3 { font-family: var(--font-display); font-size: 1.08rem; font-weight: 600; line-height: 1.25; }
.sm-spec-row { display: flex; justify-content: space-between; gap: 1rem; padding: .55rem 0; border-bottom: 1px solid var(--border); }
.sm-spec-row:last-child { border-bottom: 0; }
.sm-spec-row dt { font-size: .88rem; font-weight: 600; color: var(--text); }
.sm-spec-row dd { margin: 0; font-size: .88rem; color: var(--text-muted); text-align: right; }
.sm-list { display: flex; flex-direction: column; gap: .5rem; }
.sm-list li { position: relative; padding-left: 1.1rem; font-size: .9rem; color: var(--text); }
.sm-list li::before {
  content: '';
  position: absolute;
  left: 0; top: .55em;
  width: 6px; height: 6px;
  border-radius: 1px;
  background: var(--e2e-teal);
}

.sm-opts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.sm-opt-card p { font-size: .93rem; color: var(--text-muted); }

/* ── Tablet ─────────────────────────────────────────────────────────────── */
@media (max-width: 1000px) {
  .sm-hero { grid-template-columns: minmax(0, 1fr); }
  .sm-photo { max-width: 560px; }
  .sm-grid4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sm-profile { grid-template-columns: minmax(0, 1fr); }
  .sm-ff { grid-template-columns: minmax(0, 1fr); }
  .sm-ff-key { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sm-spec { grid-template-columns: minmax(0, 1fr); }
}

/* ── Phone ──────────────────────────────────────────────────────────────── */
@media (max-width: 640px) {
  .sm-hero-cta { flex-direction: column; }
  .sm-hero-cta .btn { width: 100%; }
  .sm-grid4, .sm-vars, .sm-opts { grid-template-columns: minmax(0, 1fr); }
  .sm-ff { padding: 1.1rem; }
  .sm-ff-key { grid-template-columns: minmax(0, 1fr); }
  .sm-spec-col, .sm-opt-card { padding: 1.1rem; }

  /* standards table → one card per capability */
  .sm-table thead { display: none; }
  .sm-table tr { display: block; padding: .85rem 1rem; border-bottom: 1px solid var(--border); }
  .sm-table tbody tr:last-child { border-bottom: 0; }
  .sm-table th, .sm-table td { display: block; padding: 0; border: 0; white-space: normal; }
  .sm-table th { margin-bottom: .35rem; }
  .sm-table td { margin-top: .45rem; font-size: .9rem; }
  .sm-table td::before {
    content: attr(data-label);
    display: block;
    font-size: .72rem;
    font-weight: 600;
    letter-spacing: .1em;
    text-transform: uppercase;
    color: var(--e2e-teal);
  }
}
