/* PS3 World - PS3 Error Codes (loaded after style.css) */

.ec-search {
  position: sticky;
  top: 72px;
  z-index: 5;
  margin: 8px 0 28px;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: var(--card);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.45);
}

.ec-box input {
  width: 100%;
  padding: 14px 18px 14px 48px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--bg-2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237a849c' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.5-3.5'/%3E%3C/svg%3E") 16px 50% / 20px no-repeat;
  color: var(--text);
  font: inherit;
  font-size: 18px;
  outline: none;
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

.ec-box input:focus { border-color: var(--ps-blue-2); box-shadow: var(--ring); }

.ec-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }

.ec-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 34px;
  padding: 5px 10px 5px 13px;
  border: 1px solid var(--border);
  border-radius: var(--pill);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-2);
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: color 0.2s var(--ease), background 0.2s var(--ease), border-color 0.2s var(--ease);
}

.ec-chip:hover { color: #fff; border-color: color-mix(in srgb, var(--ps-sky) 55%, transparent); }
.ec-chip:focus-visible { outline: none; box-shadow: var(--ring); }
.ec-chip[aria-pressed="true"] {
  border-color: var(--ps-sky);
  background: color-mix(in srgb, var(--ps-sky) 16%, transparent);
  color: #fff;
}

.ec-chip-count {
  min-width: 20px;
  padding: 1px 6px;
  border-radius: var(--pill);
  background: rgba(255, 255, 255, 0.07);
  color: var(--text-3);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  text-align: center;
}

.ec-chip[aria-pressed="true"] .ec-chip-count { background: rgba(0, 0, 0, 0.25); color: #fff; }

.ec-status { min-height: 1.4em; margin: 12px 0 0; color: var(--text-3); font-size: 13px; }

.ec-fallback {
  margin-top: 12px;
  padding: 14px 16px;
  border: 1px solid color-mix(in srgb, #f5a524 40%, var(--border));
  border-radius: 12px;
  background: rgba(245, 165, 36, 0.08);
  color: var(--text-2);
  font-size: 14px;
  line-height: 1.6;
}
.ec-fallback p { margin: 0 0 6px; }
.ec-fallback p:last-child { margin: 0; }
.ec-fallback strong { color: var(--text); font-family: var(--font-mono); }

/* ---- List ---- */
.ec-sec { margin: 0 0 36px; }
.ec-sec[hidden], .ec[hidden] { display: none; }
.ec-sec h2 { margin: 0 0 14px; font-size: 22px; }

.ec-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 360px), 1fr));
  gap: 14px;
}

.ec {
  padding: 18px 20px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--card);
  scroll-margin-top: 220px;
  transition: border-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

.ec.is-exact {
  border-color: var(--ps-sky);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--ps-sky) 25%, transparent);
}

.ec h3 {
  margin: 0 0 8px;
  font-size: 17px;
  line-height: 1.3;
}

.ec-code {
  display: inline-block;
  margin: 0 10px 4px 0;
  padding: 3px 9px;
  border-radius: 8px;
  background: color-mix(in srgb, var(--ps-sky) 14%, transparent);
  color: #9fcbff;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.6px;
}

.ec p { margin: 0 0 8px; color: var(--text-2); font-size: 14.5px; line-height: 1.6; }
.ec p:last-child { margin: 0; }
.ec-fix strong { color: #3ddc84; }
.ec .ec-fix > strong:first-child { margin-right: 2px; }
.ec-fix strong:not(:first-child) { color: var(--text); }

.ec-note { margin: 0 0 56px; color: var(--text-3); font-size: 14px; line-height: 1.6; }

@media (max-width: 860px) {
  .ec-search { top: 62px; padding: 14px; }
  .ec-box input { font-size: 16px; }
  .ec-chips { flex-wrap: nowrap; overflow-x: auto; margin-right: -14px; padding-right: 14px; scrollbar-width: none; }
  .ec-chips::-webkit-scrollbar { display: none; }
  .ec-chip { flex: none; }
}
@media (max-width: 860px) { .ec-search { position: static; } }

/* Isaac is taller than he is wide: size by height so he stays behind the hero */
.page-hero .page-char { width: auto; height: 640px; max-width: none; }
@media (max-width: 600px) { .page-hero .page-char { height: 440px; } }
