/* =============================================================================
   GUIDE & BUILD CREATOR
   ============================================================================= */

.gc-modal .gc-panel {
    background: var(--tool-surface);
    border: 1px solid var(--tool-border);
    border-radius: var(--tool-radius);
    width: min(1340px, calc(100vw - 24px));
    max-height: calc(100vh - 32px);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: var(--tool-shadow);
    animation: gc-panel-in 0.22s cubic-bezier(0.2, 0.8, 0.3, 1);
}

@keyframes gc-panel-in {
    from { opacity: 0; transform: translateY(8px) scale(0.99); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes gc-fade-in {
    from { opacity: 0; transform: translateY(4px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* Smooth view/section transitions */
.gc-library,
.gc-wizard,
.gc-editor,
.gc-viewer { animation: gc-fade-in 0.2s ease; }

.gc-editor-content { animation: gc-fade-in 0.18s ease; }

.gc-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid var(--tool-border-subtle);
    background: var(--tool-surface-raised);
    flex-shrink: 0;
}

.gc-header h3 {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    font-size: 1.05rem;
    color: var(--tool-accent);
    font-weight: 700;
}

.gc-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.gc-body {
    flex: 1;
    overflow-y: auto;
    padding: 14px 20px 18px;
    min-height: 0;
}

.gc-wip-banner,
.gc-welcome-banner {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 0 20px;
    padding: 10px 14px;
    border-radius: var(--radius-sm, 6px);
    border: 1px solid color-mix(in srgb, var(--accent, #ff9800) 35%, transparent);
    background: color-mix(in srgb, var(--accent, #ff9800) 10%, transparent);
    color: var(--text-main, #e0e0e0);
    font-size: 0.82rem;
    line-height: 1.45;
}

.gc-welcome-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex: 1;
}

.gc-welcome-text strong {
    color: var(--accent, #ff9800);
    font-size: 0.88rem;
}

.gc-welcome-emoji {
    flex-shrink: 0;
    font-size: 1.2rem;
    line-height: 1.4;
    display: inline-flex;
}

/* Work-in-progress banner emphasis + feedback affordances */
.gc-wip-banner { align-items: center; }
.gc-wip-badge {
    align-self: center;
    font-size: 0.62rem;
    font-weight: 800;
    letter-spacing: 0.6px;
    padding: 3px 7px;
    border-radius: 5px;
    color: #1a1206;
    background: linear-gradient(180deg, #ffd591, var(--accent, #ff9800));
    box-shadow: 0 0 10px color-mix(in srgb, var(--accent, #ff9800) 45%, transparent);
}
.gc-wip-feedback { flex-shrink: 0; white-space: nowrap; }
.gc-feedback-btn { border-color: color-mix(in srgb, var(--accent, #ff9800) 45%, transparent); }

/* ── In-game icons (replace emojis everywhere) ─────────────────────── */
.gc-ico, .gc-type-ico, .gc-sec-ico, .gc-h2-ico, .gc-quick-img,
.gc-tip-ico, .gc-hero-img, .gc-wizard-type-img, .gc-type-radio-img,
.gc-welcome-img, .gc-link-ico, .gc-eyebrow-ico {
    object-fit: contain;
    vertical-align: middle;
    flex-shrink: 0;
}
.gc-ico { width: 18px; height: 18px; }
.gc-type-ico { width: 30px; height: 30px; }
.gc-eyebrow-ico { width: 16px; height: 16px; margin-right: 2px; }
.gc-sec-ico { width: 20px; height: 20px; }
.gc-h2-ico { width: 24px; height: 24px; }
.gc-quick-img { width: 16px; height: 16px; }
.gc-tip-ico { width: 18px; height: 18px; margin-top: 1px; }
.gc-hero-img { width: 46px; height: 46px; }
.gc-wizard-type-img { width: 36px; height: 36px; }
.gc-type-radio-img { width: 18px; height: 18px; margin-right: 2px; }
.gc-welcome-img { width: 22px; height: 22px; }
.gc-link-ico { width: 15px; height: 15px; margin-right: 5px; }

.gc-welcome-dismiss {
    flex-shrink: 0;
    background: transparent;
    border: none;
    color: var(--text-muted, #666);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 0 4px;
    line-height: 1;
}

.gc-welcome-dismiss:hover {
    color: var(--text-main, #e0e0e0);
}

/* Buttons */
.gc-btn {
    padding: 8px 14px;
    border-radius: var(--radius-sm, 6px);
    border: 1px solid var(--border-color, #333);
    background: var(--bg-input, #111);
    color: var(--text-main, #e0e0e0);
    cursor: pointer;
    font-size: 0.85rem;
    transition: background 0.15s, border-color 0.15s, transform 0.1s, box-shadow 0.15s;
    white-space: nowrap;
}

.gc-btn:hover { background: var(--bg-hover, rgba(255,255,255,0.05)); border-color: var(--border-light, #444); }
.gc-btn:active { transform: translateY(1px); }
.gc-btn-primary { background: var(--accent, #ff9800); border-color: var(--accent, #ff9800); color: #111; font-weight: 600; }
.gc-btn-primary:hover { background: var(--accent-hover, #ffb74d); border-color: var(--accent-hover, #ffb74d); box-shadow: 0 4px 14px color-mix(in srgb, var(--accent, #ff9800) 30%, transparent); }
.gc-btn-danger { border-color: #6e1818; color: #ff6666; }
.gc-btn-danger:hover { background: rgba(255,50,50,0.1); }
.gc-btn-ghost { background: transparent; border-color: transparent; color: var(--text-sub, #888); }
.gc-btn-ghost:hover { color: var(--text-main, #e0e0e0); background: var(--bg-hover, rgba(255,255,255,0.05)); }
.gc-btn-sm { padding: 4px 10px; font-size: 0.78rem; }
.gc-btn-lg { padding: 10px 20px; font-size: 0.92rem; }

.gc-input-lg { font-size: 1rem; padding: 10px 14px; }

/* Toast */
.gc-toast {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    padding: 10px 18px;
    border-radius: var(--radius-full, 50px);
    background: #1a1a1a;
    border: 1px solid var(--green, #4caf50);
    color: var(--text-main, #e0e0e0);
    font-size: 0.85rem;
    font-weight: 600;
    z-index: 10000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s, transform 0.25s;
    box-shadow: 0 8px 24px rgba(0,0,0,0.4);
}

.gc-toast-show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.gc-toast-warn { border-color: var(--accent, #ff9800); }
.gc-toast-success { border-color: var(--green, #4caf50); }

/* Empty hero */
.gc-empty-hero {
    text-align: center;
    padding: 36px 24px;
    border: 1px dashed color-mix(in srgb, var(--accent, #ff9800) 40%, transparent);
    border-radius: 12px;
    background: color-mix(in srgb, var(--accent, #ff9800) 5%, transparent);
}

.gc-empty-hero-icon { display: flex; justify-content: center; margin-bottom: 8px; }
.gc-empty-hero h4 { margin: 0 0 8px; font-size: 1.05rem; color: var(--text-main, #e0e0e0); }
.gc-empty-hero p { margin: 0 0 20px; color: var(--text-sub, #888); font-size: 0.88rem; line-height: 1.5; max-width: 420px; margin-left: auto; margin-right: auto; }
.gc-empty-actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }

/* Wizard */
.gc-wizard { display: flex; flex-direction: column; gap: 20px; min-height: 360px; max-width: 580px; width: 100%; margin: 0 auto; }
.gc-wizard-header { text-align: center; }
.gc-wizard-step-label { display: inline-block; font-size: 0.72rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em; color: var(--accent, #ff9800); margin-bottom: 8px; }
.gc-wizard-header h4 { margin: 0 0 8px; font-size: 1.15rem; color: var(--text-main, #e0e0e0); }
.gc-wizard-header p { margin: 0; color: var(--text-sub, #888); font-size: 0.88rem; }

.gc-wizard-type-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.gc-wizard-type {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 20px 12px;
    border: 2px solid var(--border-color, #333);
    border-radius: 12px;
    background: var(--bg-input, #111);
    color: var(--text-main, #e0e0e0);
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s, transform 0.15s;
}

.gc-wizard-type:hover { border-color: var(--accent, #ff9800); transform: translateY(-2px); }
.gc-wizard-type.selected { border-color: var(--accent, #ff9800); background: rgba(255,152,0,0.1); box-shadow: 0 0 0 1px var(--accent, #ff9800); }
.gc-wizard-type-icon { display: flex; align-items: center; justify-content: center; height: 38px; }
.gc-wizard-type-label { font-size: 0.85rem; font-weight: 600; }

.gc-wizard-form { max-width: 480px; margin: 0 auto; width: 100%; }
.gc-wizard-footer { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; margin-top: auto; padding-top: 8px; }

/* Inputs */
.gc-input {
    width: 100%;
    padding: 8px 12px;
    border-radius: var(--radius-sm, 6px);
    border: 1px solid var(--border-color, #333);
    background: var(--bg-input, #111);
    color: var(--text-main, #e0e0e0);
    font-size: 0.88rem;
    box-sizing: border-box;
}

.gc-input:focus { outline: none; border-color: var(--accent, #ff9800); }
.gc-textarea { resize: vertical; min-height: 60px; font-family: inherit; }
.gc-label { display: block; margin: 10px 0 5px; font-size: 0.82rem; color: var(--text-sub, #888); font-weight: 600; }
.gc-label-sm { display: block; margin: 4px 0 4px; font-size: 0.75rem; color: var(--text-muted, #666); }
.gc-hint { font-weight: 400; color: var(--text-muted, #666); font-size: 0.75rem; }
.gc-hint-block { padding: 16px; text-align: center; color: var(--text-muted, #666); font-size: 0.85rem; border: 1px dashed var(--border-color, #333); border-radius: var(--radius-sm, 6px); }

/* Library */
.gc-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.gc-tabs, .gc-toolbar-actions { display: flex; gap: 6px; flex-wrap: wrap; }

.gc-tab {
    padding: 7px 14px;
    border-radius: var(--radius-full, 50px);
    border: 1px solid var(--border-color, #333);
    background: transparent;
    color: var(--text-sub, #888);
    cursor: pointer;
    font-size: 0.82rem;
    transition: all 0.15s;
}

.gc-tab.active, .gc-tab:hover { background: var(--accent, #ff9800); border-color: var(--accent, #ff9800); color: #111; }
.gc-tab.active { font-weight: 600; }

.gc-search-row { margin-bottom: 14px; }

.gc-guide-list { display: flex; flex-direction: column; gap: 10px; }

.gc-card {
    display: flex;
    gap: 14px;
    padding: 14px 16px;
    background: var(--bg-input, #111);
    border: 1px solid var(--border-color, #333);
    border-radius: 10px;
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s, transform 0.15s, box-shadow 0.15s;
}

.gc-card:hover {
    border-color: color-mix(in srgb, var(--accent, #ff9800) 60%, transparent);
    background: rgba(255,152,0,0.04);
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(0,0,0,0.25);
}

.gc-card-icon { display: flex; align-items: center; justify-content: center; width: 34px; height: 34px; flex-shrink: 0; }
.gc-card-main { flex: 1; min-width: 0; }
.gc-card-title { font-weight: 600; font-size: 0.95rem; margin-bottom: 4px; color: var(--text-main, #e0e0e0); }
.gc-card-meta { font-size: 0.75rem; color: var(--text-muted, #666); display: flex; flex-wrap: wrap; gap: 4px; }
.gc-card-desc { font-size: 0.82rem; color: var(--text-sub, #888); margin: 6px 0; line-height: 1.4; }
.gc-card-tags { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 6px; }
.gc-card-author { font-size: 0.75rem; color: var(--text-muted, #666); margin-top: 4px; }
.gc-card-actions { display: flex; flex-direction: column; gap: 6px; flex-shrink: 0; justify-content: center; }

.gc-tag {
    padding: 2px 8px;
    border-radius: var(--radius-full, 50px);
    background: rgba(255,152,0,0.12);
    color: var(--accent, #ff9800);
    font-size: 0.7rem;
}

.gc-diff { font-size: 0.7rem; color: var(--gold, #ffd700); letter-spacing: 1px; }
.gc-empty { padding: 40px 20px; text-align: center; color: var(--text-muted, #666); }

/* Editor — single scrollable page */
.gc-editor { display: flex; flex-direction: column; gap: 12px; max-width: 920px; width: 100%; margin: 0 auto; }

.gc-editor-head {
    display: flex;
    align-items: center;
    gap: 12px;
}

.gc-title-input {
    font-size: 1.2rem;
    font-weight: 700;
    padding: 12px 14px;
    border-radius: 10px;
}

.gc-editor-tagline {
    margin: -4px 2px 2px;
    font-size: 0.8rem;
    color: var(--text-muted, #777);
}

.gc-autosave-status {
    flex-shrink: 0;
    font-size: 0.72rem;
    color: var(--green, #4caf50);
    opacity: 0;
    transition: opacity 0.3s;
}

.gc-autosave-status.is-visible { opacity: 1; }

/* Section cards (required = <section>, optional = <details>) */
.gc-sec {
    border: 1px solid var(--tool-border-subtle, #2a2a2a);
    border-radius: 12px;
    background: var(--tool-surface-raised, rgba(255,255,255,0.02));
    overflow: hidden;
}

.gc-sec-head {
    display: flex;
    align-items: center;
    gap: 11px;
    padding: 12px 16px;
    color: var(--text-main, #e0e0e0);
}

.gc-sec-icon { display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.gc-sec-heading { display: flex; flex-direction: column; gap: 1px; flex: 1; min-width: 0; }
.gc-sec-title { font-weight: 700; font-size: 0.95rem; line-height: 1.2; }
.gc-sec-desc { font-size: 0.74rem; color: var(--text-muted, #777); line-height: 1.2; }
.gc-sec-tag {
    flex-shrink: 0;
    font-size: 0.6rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted, #666);
    border: 1px solid var(--border-color, #333);
    border-radius: 50px;
    padding: 2px 8px;
}
.gc-sec-chevron { color: var(--text-muted, #666); transition: transform 0.2s; font-size: 1rem; flex-shrink: 0; }

.gc-sec-body { padding: 4px 16px 16px; }
.gc-sec:not(.gc-sec-optional) .gc-sec-body { border-top: 1px solid var(--tool-border-subtle, #2a2a2a); padding-top: 14px; }

/* Optional <details> */
.gc-sec-optional > summary { cursor: pointer; list-style: none; user-select: none; }
.gc-sec-optional > summary::-webkit-details-marker { display: none; }
.gc-sec-optional > summary:hover { background: var(--bg-hover, rgba(255,255,255,0.03)); }
.gc-sec-optional[open] > summary { border-bottom: 1px solid var(--tool-border-subtle, #2a2a2a); }
.gc-sec-optional[open] .gc-sec-chevron { transform: rotate(180deg); }
.gc-sec-optional[open] > summary .gc-sec-tag { color: var(--accent, #ff9800); border-color: color-mix(in srgb, var(--accent, #ff9800) 45%, transparent); }
.gc-sec-optional .gc-sec-body { padding-top: 14px; }

.gc-editor-footer {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    justify-content: flex-start;
    padding-top: 6px;
}
.gc-editor-footer .gc-btn-primary { margin-left: auto; }

.gc-form { display: flex; flex-direction: column; }
.gc-form > .gc-label:first-child { margin-top: 0; }

/* Gear: body layout (left) + input list (right) */
.gc-gear-layout {
    display: grid;
    grid-template-columns: minmax(0, 210px) 1fr;
    gap: 16px;
    align-items: start;
    margin: 4px 0;
}

.gc-gear-fields { display: flex; flex-direction: column; gap: 6px; }

.gc-gear-row {
    display: grid;
    grid-template-columns: 96px 1fr;
    align-items: center;
    gap: 10px;
    cursor: text;
}

.gc-gear-row-label {
    font-size: 0.78rem;
    color: var(--text-sub, #888);
    text-align: right;
}

.gc-gear-row .gc-equip-input { font-size: 0.8rem; padding: 6px 9px; }

@media (max-width: 600px) {
    .gc-gear-layout { grid-template-columns: 1fr; gap: 14px; }
    .gc-gear-row { grid-template-columns: 84px 1fr; }
}

.gc-type-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 6px;
}

.gc-type-option {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 9px 10px;
    border: 1px solid var(--border-color, #333);
    border-radius: 9px;
    cursor: pointer;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-sub, #aaa);
    background: var(--bg-input, #111);
    text-align: center;
    transition: border-color 0.15s, background 0.15s, color 0.15s;
}
.gc-type-option span { display: inline-flex; align-items: center; gap: 7px; }
.gc-type-option:hover { border-color: var(--border-light, #444); color: var(--text-main, #e0e0e0); }
.gc-type-option input { display: none; }
.gc-type-option.selected, .gc-type-option:has(input:checked) {
    border-color: var(--accent, #ff9800);
    background: rgba(255,152,0,0.1);
    color: var(--text-main, #e6e6e6);
}

@media (max-width: 620px) {
    .gc-type-grid { grid-template-columns: 1fr 1fr; }
}

.gc-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    margin: 20px 0 10px;
    padding-bottom: 8px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--accent, #ff9800);
    border-bottom: 1px solid var(--tool-border-subtle, #2a2a2a);
}

.gc-section-header .gc-btn { text-transform: none; letter-spacing: 0; }

.gc-row { display: flex; gap: 8px; margin-bottom: 8px; align-items: center; }
.gc-row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

.gc-equip-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 10px;
}

.gc-equip-slot .gc-input { font-size: 0.82rem; }

/* ── Equipment paperdoll (player body layout) ───────────────────────── */
.gc-doll-hint {
    font-size: 0.78rem;
    color: var(--text-sub, #888);
    margin: 0 0 14px;
    text-align: center;
}

.gc-paperdoll {
    position: relative;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-template-areas:
        ".      helmet  ammo"
        "cape   amulet  pocket"
        "weapon body    offhand"
        ".      legs    ."
        "gloves boots   ring";
    gap: 12px;
    max-width: 420px;
    margin: 0 auto 8px;
    padding: 20px;
    border: 1px solid var(--tool-border, rgba(255, 255, 255, 0.08));
    border-radius: 16px;
    background:
        radial-gradient(120% 80% at 50% 0%, rgba(255, 152, 0, 0.05), transparent 60%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.025), rgba(0, 0, 0, 0.08));
}

/* Soft glow down the center column to suggest the player's body */
.gc-paperdoll::before {
    content: "";
    position: absolute;
    top: 10%;
    bottom: 10%;
    left: 50%;
    width: 30%;
    transform: translateX(-50%);
    border-radius: 999px;
    background: radial-gradient(ellipse at center, rgba(255, 152, 0, 0.07), transparent 70%);
    pointer-events: none;
    z-index: 0;
}

.gc-doll-slot-helmet  { grid-area: helmet; }
.gc-doll-slot-ammo    { grid-area: ammo; }
.gc-doll-slot-cape    { grid-area: cape; }
.gc-doll-slot-amulet  { grid-area: amulet; }
.gc-doll-slot-pocket  { grid-area: pocket; }
.gc-doll-slot-weapon  { grid-area: weapon; }
.gc-doll-slot-body    { grid-area: body; }
.gc-doll-slot-offhand { grid-area: offhand; }
.gc-doll-slot-legs    { grid-area: legs; }
.gc-doll-slot-gloves  { grid-area: gloves; }
.gc-doll-slot-boots   { grid-area: boots; }
.gc-doll-slot-ring    { grid-area: ring; }

.gc-doll-slot {
    position: relative;
    z-index: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    /* button reset (editor tiles are <button>) */
    margin: 0;
    padding: 0;
    border: none;
    background: none;
    color: inherit;
    font: inherit;
}

/* Editor body-layout: clickable icon tiles only */
.gc-paperdoll-edit { max-width: 220px; gap: 8px; padding: 14px; }
.gc-paperdoll-edit .gc-doll-slot { cursor: pointer; }
.gc-paperdoll-edit .gc-doll-icon { max-width: 48px; }
.gc-paperdoll-edit .gc-doll-slot:hover .gc-doll-icon { border-color: color-mix(in srgb, var(--accent, #ff9800) 55%, transparent); }
.gc-paperdoll-edit .gc-doll-slot.is-active .gc-doll-icon {
    border-color: var(--accent, #ff9800);
    box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent, #ff9800) 55%, transparent);
}
.gc-paperdoll-edit .gc-doll-slot.is-armed .gc-doll-icon {
    border-color: var(--accent, #ff9800);
    box-shadow: 0 0 0 2px var(--accent, #ff9800), 0 0 12px color-mix(in srgb, var(--accent, #ff9800) 50%, transparent);
    animation: gcArmPulse 1.2s ease-in-out infinite;
}
@keyframes gcArmPulse {
    0%, 100% { box-shadow: 0 0 0 2px var(--accent, #ff9800), 0 0 6px color-mix(in srgb, var(--accent, #ff9800) 35%, transparent); }
    50%      { box-shadow: 0 0 0 2px var(--accent, #ff9800), 0 0 14px color-mix(in srgb, var(--accent, #ff9800) 65%, transparent); }
}
.gc-equip-target-hint:empty { display: none; }
.gc-equip-target-hint {
    margin: -2px 0 8px;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--accent, #ff9800);
    background: color-mix(in srgb, var(--accent, #ff9800) 12%, transparent);
    border: 1px solid color-mix(in srgb, var(--accent, #ff9800) 35%, transparent);
}

/* The icon "button" — a clean inset square that holds the item image */
.gc-doll-icon {
    width: 100%;
    aspect-ratio: 1 / 1;
    max-width: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    border: 1px solid var(--tool-border, rgba(255, 255, 255, 0.09));
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(0, 0, 0, 0.22));
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.35);
    transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.gc-doll-slot.is-filled .gc-doll-icon {
    border-color: color-mix(in srgb, var(--accent, #ff9800) 70%, transparent);
    box-shadow:
        inset 0 1px 2px rgba(0, 0, 0, 0.3),
        0 0 0 1px color-mix(in srgb, var(--accent, #ff9800) 35%, transparent),
        0 0 14px color-mix(in srgb, var(--accent, #ff9800) 18%, transparent);
    background:
        radial-gradient(circle at 50% 35%, rgba(255, 152, 0, 0.16), transparent 70%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(0, 0, 0, 0.2));
}

.gc-doll-icon.gc-doll-empty::before {
    content: attr(data-glyph);
    font-size: 1.5rem;
    opacity: 0.35;
}

.gc-doll-img {
    width: 70%;
    height: 70%;
    object-fit: contain;
    image-rendering: -webkit-optimize-contrast;
}

/* Empty RuneScape slot placeholder images render subdued vs equipped items */
.gc-doll-slot-img { opacity: 0.4; }
.gc-doll-slot.is-filled .gc-doll-slot-img { opacity: 1; }

/* Editor input lives clearly below the icon — no overlap */
.gc-doll-slot .gc-equip-input {
    width: 100%;
    font-size: 0.7rem;
    padding: 5px 6px;
    text-align: center;
    border-radius: 7px;
    text-overflow: ellipsis;
}

.gc-doll-slot .gc-equip-input::placeholder { color: var(--text-muted, #666); }

/* Read-only paperdoll (viewer) */
.gc-doll-name {
    font-size: 0.7rem;
    line-height: 1.3;
    text-align: center;
    color: var(--text-main, #ddd);
    font-weight: 600;
    word-break: break-word;
}

.gc-doll-slot-label {
    color: var(--text-muted, #666);
    font-weight: 500;
}

/* Read-only paperdoll: compact, uniform cells for a balanced grid */
.gc-paperdoll-ro { max-width: 340px; gap: 10px; padding: 16px; margin: 0 auto; }
.gc-paperdoll-ro .gc-doll-icon { max-width: 50px; }
.gc-paperdoll-ro .gc-doll-name {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    overflow-wrap: anywhere;
    max-width: 100%;
    font-size: 0.66rem;
}

@media (max-width: 480px) {
    .gc-paperdoll { gap: 8px; padding: 14px; }
    .gc-doll-icon { max-width: 52px; }
    .gc-doll-slot .gc-equip-input { font-size: 0.62rem; padding: 4px; }
}

/* ── Skill icons (requirements) ─────────────────────────────────────── */
.gc-skill-row { align-items: center; }
.gc-skill-icon { width: 22px; height: 22px; object-fit: contain; flex-shrink: 0; }
.gc-skill-chip { display: inline-flex; align-items: center; gap: 6px; }
.gc-skill-chip img { width: 16px; height: 16px; object-fit: contain; }

/* ── Book picker (prayers) ──────────────────────────────────────────── */
.gc-book {
    border: 1px solid var(--tool-border, rgba(255,255,255,0.08));
    border-radius: 12px;
    background: radial-gradient(140% 120% at 50% 0%, rgba(255,152,0,0.04), transparent 55%),
                linear-gradient(180deg, rgba(0,0,0,0.18), rgba(0,0,0,0.28));
    padding: 12px;
    margin: 4px 0 6px;
}

.gc-book-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }

.gc-book-tab {
    padding: 5px 12px;
    border-radius: 50px;
    border: 1px solid var(--border-color, #333);
    background: var(--bg-input, #111);
    color: var(--text-sub, #888);
    font-size: 0.76rem;
    cursor: pointer;
    transition: all 0.15s;
}
.gc-book-tab:hover { color: var(--text-main, #e0e0e0); border-color: var(--border-light, #444); }
.gc-book-tab.active { background: var(--accent, #ff9800); border-color: var(--accent, #ff9800); color: #111; font-weight: 600; }

.gc-book-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(74px, 1fr));
    gap: 6px;
}

.gc-book-tile {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 8px 4px 6px;
    border: 1px solid var(--tool-border, rgba(255,255,255,0.08));
    border-radius: 8px;
    background: rgba(255,255,255,0.02);
    color: var(--text-sub, #999);
    cursor: pointer;
    transition: border-color 0.12s, background 0.12s, transform 0.12s;
}
.gc-book-tile:hover { border-color: color-mix(in srgb, var(--accent, #ff9800) 50%, transparent); transform: translateY(-1px); }
.gc-book-tile.selected {
    border-color: var(--accent, #ff9800);
    background: rgba(255,152,0,0.12);
    color: var(--text-main, #e0e0e0);
    box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--accent, #ff9800) 40%, transparent);
}
.gc-book-tile.selected::after {
    content: "✓";
    position: absolute;
    margin-top: -4px;
    margin-left: 44px;
    color: var(--green, #4caf50);
    font-size: 0.7rem;
}
.gc-book-icon { width: 30px; height: 30px; object-fit: contain; }
.gc-book-name { font-size: 0.62rem; line-height: 1.15; text-align: center; word-break: break-word; }

.gc-chosen {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    margin-top: 12px;
    padding-top: 10px;
    border-top: 1px solid var(--tool-border-subtle, #2a2a2a);
}
.gc-chosen-label { font-size: 0.68rem; text-transform: uppercase; letter-spacing: 0.04em; color: var(--text-muted, #666); }
.gc-chosen-chip {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 8px;
    border-radius: 50px;
    background: rgba(255,152,0,0.12);
    border: 1px solid color-mix(in srgb, var(--accent, #ff9800) 35%, transparent);
    color: var(--text-main, #e0e0e0);
    font-size: 0.72rem;
    cursor: pointer;
}
.gc-chosen-chip img { width: 14px; height: 14px; object-fit: contain; }
.gc-chosen-chip b { color: var(--text-muted, #888); }
.gc-chosen-chip:hover { border-color: #ff6666; }
.gc-chosen-chip:hover b { color: #ff6666; }

/* Icon abbreviation fallback inside book tiles */
.gc-book-iconwrap {
    display: flex; align-items: center; justify-content: center;
    width: 30px; height: 30px;
}
.gc-book-iconwrap.gc-noimg::after {
    content: attr(data-abbr);
    font-size: 0.72rem; font-weight: 800; text-transform: uppercase;
    color: var(--text-sub, #b8ad90);
}

/* ── RuneScape-style prayer book ────────────────────────────────────── */
.gc-prayerbook {
    background:
        radial-gradient(120% 100% at 50% 0%, rgba(255,200,80,0.07), transparent 62%),
        linear-gradient(180deg, #2b2218, #1a140d);
    border: 2px solid #6b5526;
    border-radius: 10px;
    box-shadow: inset 0 0 0 1px rgba(0,0,0,0.55), inset 0 0 26px rgba(0,0,0,0.55);
    padding: 12px;
}
.gc-prayerbook .gc-book-tab {
    background: rgba(0,0,0,0.32);
    border-color: #4a3d23;
    color: #cabf9f;
}
.gc-prayerbook .gc-book-tab:hover { color: #f2e7c6; border-color: #8a6f2f; }
.gc-prayerbook .gc-book-tab.active {
    background: linear-gradient(180deg, #d8a93a, #ad7a1c);
    border-color: #ecc965;
    color: #1c1305;
}
.gc-prayerbook .gc-book-grid {
    grid-template-columns: repeat(auto-fill, minmax(58px, 1fr));
    gap: 5px;
}
.gc-prayerbook .gc-book-tile {
    position: relative;
    aspect-ratio: 1 / 1;
    justify-content: center;
    gap: 3px;
    padding: 5px 3px;
    border: 1px solid #3a2f1c;
    border-radius: 6px;
    background: radial-gradient(120% 120% at 50% 28%, rgba(255,255,255,0.05), rgba(0,0,0,0.32));
    box-shadow: inset 0 0 6px rgba(0,0,0,0.5);
    color: #b8ad90;
}
.gc-prayerbook .gc-book-tile:hover {
    border-color: #c9a23a;
    transform: none;
    background: radial-gradient(120% 120% at 50% 28%, rgba(255,210,90,0.12), rgba(0,0,0,0.32));
}
.gc-prayerbook .gc-book-tile.selected {
    border-color: #f3cf5e;
    background: radial-gradient(120% 120% at 50% 28%, rgba(255,210,90,0.3), rgba(120,80,10,0.28));
    box-shadow: inset 0 0 0 1px rgba(255,210,90,0.5), 0 0 9px rgba(243,207,94,0.45);
    color: #fff3d6;
}
.gc-prayerbook .gc-book-tile.selected::after { display: none; }
.gc-prayerbook .gc-book-iconwrap { width: 26px; height: 26px; }
.gc-prayerbook .gc-book-icon { width: 26px; height: 26px; }
.gc-prayerbook .gc-book-name { font-size: 0.55rem; color: inherit; }
.gc-prayerbook .gc-chosen { border-top-color: rgba(255,210,90,0.18); }
.gc-prayerbook .gc-chosen-chip {
    background: rgba(255,210,90,0.14);
    border-color: rgba(243,207,94,0.4);
    color: #f2e7c6;
}

/* ── Ability action-bar builder ─────────────────────────────────────── */
.gc-ability-builder { display: flex; flex-direction: column; gap: 12px; margin: 4px 0 6px; }

.gc-ability-palette {
    border: 1px solid var(--tool-border, rgba(255,255,255,0.08));
    border-radius: 12px;
    background: linear-gradient(180deg, rgba(0,0,0,0.18), rgba(0,0,0,0.26));
    padding: 12px;
}

.gc-ability-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(40px, 1fr));
    gap: 6px;
}

.gc-ability-tile,
.gc-ab-slot {
    position: relative;
    aspect-ratio: 1 / 1;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 7px;
    border: 1px solid var(--tool-border, rgba(255,255,255,0.09));
    background: linear-gradient(180deg, rgba(255,255,255,0.04), rgba(0,0,0,0.25));
    box-shadow: inset 0 1px 2px rgba(0,0,0,0.35);
}

.gc-ability-tile { cursor: grab; transition: transform 0.1s, border-color 0.12s; }
.gc-ability-tile:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--accent, #ff9800) 55%, transparent); }
.gc-ability-tile:active { cursor: grabbing; }
.gc-ability-tile img,
.gc-ab-slot img { width: 82%; height: 82%; object-fit: contain; pointer-events: none; }

/* Text fallback when an ability icon fails to load */
.gc-ability-tile.gc-noimg::after,
.gc-ab-slot.gc-noimg::after {
    content: attr(data-abbr);
    font-size: 0.62rem;
    font-weight: 700;
    color: var(--text-sub, #999);
    text-transform: uppercase;
}

.gc-ability-hint { margin: 10px 0 0; font-size: 0.72rem; color: var(--text-muted, #666); }

.gc-ability-bars { display: flex; flex-direction: column; gap: 8px; }

.gc-ab-bar {
    border: 1px solid var(--tool-border-subtle, #2a2a2a);
    border-radius: 10px;
    background: var(--tool-surface-raised, rgba(255,255,255,0.02));
    padding: 8px 10px;
    transition: border-color 0.15s, box-shadow 0.15s;
}
.gc-ab-bar.active {
    border-color: color-mix(in srgb, var(--accent, #ff9800) 60%, transparent);
    box-shadow: 0 0 0 1px color-mix(in srgb, var(--accent, #ff9800) 30%, transparent);
}
.gc-ab-bar-head { font-size: 0.72rem; font-weight: 600; color: var(--text-sub, #888); margin-bottom: 6px; }
.gc-ab-bar.active .gc-ab-bar-head { color: var(--accent, #ff9800); }
.gc-ab-bar-name {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px dashed transparent;
    color: var(--text-main, #e0e0e0);
    font-size: 0.78rem;
    font-weight: 600;
    padding: 2px 0;
    outline: none;
}
.gc-ab-bar-name::placeholder { color: var(--text-muted, #666); font-weight: 500; }
.gc-ab-bar-name:hover { border-bottom-color: var(--border-light, #444); }
.gc-ab-bar-name:focus { border-bottom-color: var(--accent, #ff9800); }

.gc-ab-slots {
    display: grid;
    grid-template-columns: repeat(14, 1fr);
    gap: 2px;
    padding: 4px;
    border-radius: 6px;
    background: linear-gradient(180deg, #4c4c4c, #1b1b1b);
    border: 1px solid #050505;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.09), inset 0 -1px 0 rgba(0,0,0,0.6), 0 2px 6px rgba(0,0,0,0.5);
}
.gc-ab-slots-view { grid-template-columns: repeat(auto-fill, minmax(30px, 32px)); }

/* RuneScape-style bar slots (override the lighter palette-tile look) */
.gc-ab-slot {
    cursor: default;
    border: 1px solid #000;
    border-radius: 3px;
    background: radial-gradient(120% 120% at 50% 28%, #2c2c2c, #0c0c0c);
    box-shadow: inset 0 0 0 1px rgba(255,255,255,0.05), inset 0 0 6px rgba(0,0,0,0.8);
}
.gc-ab-slot.is-filled { cursor: pointer; }
.gc-ab-slot.is-filled:hover { border-color: #ff6666; box-shadow: inset 0 0 0 1px rgba(255,80,80,0.5), 0 0 0 1px rgba(255,80,80,0.4); }
.gc-ab-slot.drag-over { border-color: var(--accent, #ff9800); box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--accent, #ff9800) 55%, transparent); }
.gc-ab-key {
    position: absolute; top: 0; left: 2px;
    font-size: 0.52rem; line-height: 1.3; font-weight: 700;
    color: #fff; text-shadow: 0 1px 1px #000, 0 0 2px #000;
    pointer-events: none; z-index: 1;
}

@media (max-width: 600px) {
    .gc-ab-slots { grid-template-columns: repeat(7, 1fr); }
}

/* ---- Quick add + inventory side by side ---- */
.gc-stash-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 14px;
    align-items: start;
    margin: 4px 0 6px;
}
.gc-stash-palette, .gc-stash-inv { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.gc-stash-cap {
    font-size: 0.64rem; text-transform: uppercase; letter-spacing: 0.05em;
    color: var(--text-muted, #777); font-weight: 700;
}
@media (max-width: 760px) {
    .gc-stash-layout { grid-template-columns: 1fr; }
}

/* ---- Quick-add item palette ---- */
.gc-item-palette {
    border: 1px solid var(--tool-border-subtle, #2a2a2a);
    border-radius: 12px;
    background: var(--tool-surface-raised, rgba(255,255,255,0.02));
    padding: 10px;
}
.gc-item-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(38px, 1fr));
    gap: 5px;
    max-height: 248px;
    overflow-y: auto;
    margin-top: 8px;
}
.gc-item-tile {
    position: relative;
    aspect-ratio: 1 / 1;
    display: flex; align-items: center; justify-content: center;
    border-radius: 7px;
    border: 1px solid var(--tool-border, rgba(255,255,255,0.09));
    background: linear-gradient(180deg, rgba(255,255,255,0.04), rgba(0,0,0,0.25));
    box-shadow: inset 0 1px 2px rgba(0,0,0,0.35);
    cursor: grab;
    transition: transform 0.1s, border-color 0.12s;
}
.gc-item-tile:hover { transform: translateY(-2px); border-color: color-mix(in srgb, var(--accent, #ff9800) 55%, transparent); }
.gc-item-tile:active { cursor: grabbing; }
.gc-item-tile img { width: 84%; height: 84%; object-fit: contain; pointer-events: none; }
.gc-item-tile.gc-noimg::after { content: attr(data-abbr); font-size: 0.6rem; font-weight: 700; color: var(--text-sub, #999); text-transform: uppercase; }

/* ---- RuneScape-style inventory grid ---- */
.gc-inventory-wrap { display: flex; flex-direction: column; gap: 10px; }
.gc-inventory {
    display: grid;
    grid-template-columns: repeat(4, 42px);
    gap: 4px;
    width: max-content;
    max-width: 100%;
    padding: 8px;
    border-radius: 8px;
    background: linear-gradient(180deg, #3a2f24, #2b2219);
    border: 1px solid #4a3d2e;
    box-shadow: inset 0 0 12px rgba(0,0,0,0.5);
}
.gc-inv-slot {
    position: relative;
    width: 42px; height: 42px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 4px;
    border: 1px solid rgba(0,0,0,0.35);
    background: rgba(0,0,0,0.18);
}
.gc-inv-slot.is-filled { cursor: pointer; background: rgba(0,0,0,0.28); }
.gc-inv-slot.is-filled:hover { border-color: #ff6666; box-shadow: 0 0 0 1px rgba(255,80,80,0.5); }
.gc-inv-slot.drag-over { border-color: var(--accent, #ff9800); box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--accent, #ff9800) 55%, transparent); }
.gc-inv-slot img { width: 34px; height: 34px; object-fit: contain; pointer-events: none; }
.gc-inv-slot.gc-noimg::after { content: attr(data-abbr); font-size: 0.58rem; font-weight: 700; color: var(--text-sub, #aaa); text-transform: uppercase; }

.gc-inv-add { display: flex; gap: 6px; align-items: stretch; flex-wrap: wrap; }
.gc-inv-add .gc-input { flex: 1 1 100%; min-width: 0; }
.gc-inv-add .gc-btn { flex: 1 1 auto; }

/* Read-only inventory in the guide view */
.gc-inventory-view { margin-bottom: 6px; }
.gc-inventory-view .gc-inv-slot.is-filled { cursor: default; }
.gc-inventory-view .gc-inv-slot.is-filled:hover { border-color: rgba(0,0,0,0.35); box-shadow: none; }

/* Drop feedback on equipment targets */
.gc-gear-row.drag-over { outline: 2px dashed var(--accent, #ff9800); outline-offset: 2px; border-radius: 6px; }
.gc-doll-slot.drag-over { box-shadow: 0 0 0 2px var(--accent, #ff9800); border-radius: 8px; }

.gc-steps-editor { display: flex; flex-direction: column; gap: 12px; }

.gc-steps-quick-add {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
    padding: 10px 12px;
    background: rgba(255,152,0,0.06);
    border: 1px dashed color-mix(in srgb, var(--accent, #ff9800) 35%, transparent);
    border-radius: var(--radius-sm, 6px);
}

.gc-quick-add-label { font-size: 0.78rem; color: var(--text-muted, #666); font-weight: 600; }

.gc-quick-chip {
    padding: 5px 10px;
    border-radius: var(--radius-full, 50px);
    border: 1px solid var(--border-color, #333);
    background: var(--bg-input, #111);
    color: var(--text-main, #e0e0e0);
    font-size: 0.78rem;
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s;
}

.gc-quick-chip:hover { border-color: var(--accent, #ff9800); background: rgba(255,152,0,0.1); }

.gc-steps-empty { text-align: center; }
.gc-steps-empty strong { display: block; margin-bottom: 6px; color: var(--text-main, #e0e0e0); }
.gc-steps-empty p { margin: 0; font-size: 0.82rem; }

.gc-step-details-toggle {
    align-self: flex-start;
    background: transparent;
    border: none;
    color: var(--blue, #4fc3f7);
    font-size: 0.78rem;
    cursor: pointer;
    padding: 4px 0;
}

.gc-step-details-toggle:hover { text-decoration: underline; }

.gc-step-details {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-top: 4px;
}

.gc-step-details.is-collapsed { display: none; }

.gc-step-edit {
    padding: 12px;
    border: 1px solid var(--border-color, #333);
    border-radius: var(--radius-sm, 6px);
    background: rgba(0,0,0,0.2);
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.gc-step-edit-header { display: flex; justify-content: space-between; align-items: center; }
.gc-step-num { font-size: 0.78rem; font-weight: 600; color: var(--accent, #ff9800); }
.gc-step-move { display: flex; gap: 4px; }

.gc-range { width: 100%; accent-color: var(--accent, #ff9800); }

/* ============================================================
   VIEWER — PvME-style guide document
   ============================================================ */
.gc-guide {
    display: grid;
    grid-template-columns: 210px minmax(0, 1fr) 210px;
    gap: 22px;
    align-items: start;
    animation: gc-fade-in 0.2s ease;
}
.gc-guide-rail { min-width: 0; }

.gc-guide-doc { min-width: 0; max-width: 880px; margin: 0 auto; }

/* Header — a banner with flair */
.gc-guide-head {
    position: relative;
    overflow: hidden;
    text-align: center;
    padding: 24px 22px 18px;
    margin-bottom: 6px;
    border: 1px solid color-mix(in srgb, var(--accent, #ff9800) 22%, var(--border-color, #333));
    border-radius: 16px;
    background:
        radial-gradient(135% 110% at 50% -15%, color-mix(in srgb, var(--accent, #ff9800) 17%, transparent), transparent 62%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(0, 0, 0, 0.14));
}
/* Animated shimmer accent line across the top */
.gc-guide-head::before {
    content: "";
    position: absolute;
    left: 0; right: 0; top: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--accent, #ff9800), var(--green, #4caf50), var(--accent, #ff9800), transparent);
    background-size: 200% 100%;
    animation: gcHeadShimmer 6s linear infinite;
}
@keyframes gcHeadShimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }

.gc-guide-eyebrow {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 4px 13px; margin: 0 auto 12px; border-radius: 50px;
    font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1px;
    color: var(--accent, #ff9800);
    background: color-mix(in srgb, var(--accent, #ff9800) 13%, transparent);
    border: 1px solid color-mix(in srgb, var(--accent, #ff9800) 38%, transparent);
}
.gc-guide-title {
    font-size: 2rem;
    font-weight: 900;
    line-height: 1.12;
    letter-spacing: 0.4px;
    margin: 0 0 6px;
    background: linear-gradient(180deg, #ffffff 0%, #ffe0a8 52%, var(--accent, #ff9800) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    text-shadow: 0 2px 22px color-mix(in srgb, var(--accent, #ff9800) 32%, transparent);
}
/* Decorative divider flourish beneath the title */
.gc-guide-title::after {
    content: "";
    display: block;
    width: 70px; height: 2px;
    margin: 12px auto 2px;
    border-radius: 2px;
    background: linear-gradient(90deg, transparent, var(--accent, #ff9800), transparent);
    box-shadow: 0 0 10px color-mix(in srgb, var(--accent, #ff9800) 45%, transparent);
}
.gc-guide-byline { font-size: 0.78rem; color: var(--text-muted, #888); margin-bottom: 6px; }
.gc-guide-intro { font-size: 0.9rem; color: var(--text-sub, #bbb); line-height: 1.55; margin: 8px auto 0; max-width: 620px; }

.gc-progress-bar-wrap {
    position: relative;
    height: 18px;
    background: var(--bar-bg, #2a2a2a);
    border-radius: var(--radius-full, 50px);
    overflow: hidden;
    margin-top: 10px;
}

.gc-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--accent, #ff9800), var(--green, #4caf50));
    border-radius: var(--radius-full, 50px);
    transition: width 0.3s ease;
}

.gc-progress-label {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--text-main, #e0e0e0);
    text-shadow: 0 1px 2px rgba(0,0,0,0.8);
}

/* Sections + headings */
.gc-guide-section { padding: 14px 0 4px; scroll-margin-top: 12px; }
.gc-guide-h2 {
    display: flex; align-items: center; justify-content: center; gap: 8px;
    font-size: 1.05rem; font-weight: 800;
    color: var(--text-main, #e0e0e0);
    margin: 0 0 12px; padding-bottom: 6px;
    border-bottom: 2px solid rgba(255,152,0,0.35);
}
.gc-guide-h4 { font-size: 0.74rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.6px; color: var(--accent, #ff9800); margin: 12px 0 6px; text-align: center; }

/* Walkthrough step block */
.gc-guide-step {
    padding: 10px 12px; margin-bottom: 7px;
    border: 1px solid var(--border-color, #333);
    border-left: 3px solid var(--border-light, #444);
    border-radius: var(--radius-sm, 6px);
    background: rgba(255,255,255,0.015);
    scroll-margin-top: 12px;
    transition: border-color 0.15s, background 0.15s;
}
.gc-guide-step:hover { border-left-color: var(--accent, #ff9800); }
.gc-guide-step.done { border-left-color: var(--green, #4caf50); background: rgba(76,175,80,0.05); }
.gc-guide-step.done .gc-step-name { text-decoration: line-through; opacity: 0.7; }

.gc-guide-h3 { display: flex; align-items: center; gap: 9px; font-size: 0.92rem; font-weight: 700; margin: 0; color: var(--text-main, #e0e0e0); }
.gc-step-num { display: inline-flex; align-items: center; justify-content: center; width: 22px; height: 22px; flex-shrink: 0; border-radius: 50%; background: rgba(255,152,0,0.15); color: var(--accent, #ff9800); font-size: 0.74rem; font-weight: 700; }
.gc-guide-step.done .gc-step-num { background: rgba(76,175,80,0.2); color: var(--green, #4caf50); }
.gc-step-name { flex: 1; }

.gc-step-toggle { position: relative; flex-shrink: 0; width: 20px; height: 20px; cursor: pointer; }
.gc-step-toggle input { position: absolute; inset: 0; opacity: 0; width: 100%; height: 100%; cursor: pointer; margin: 0; }
.gc-step-tick { display: block; width: 20px; height: 20px; border: 2px solid var(--border-light, #555); border-radius: 6px; transition: all 0.15s; }
.gc-step-toggle input:checked + .gc-step-tick { background: var(--green, #4caf50); border-color: var(--green, #4caf50); }
.gc-step-toggle input:checked + .gc-step-tick::after { content: '✓'; position: absolute; inset: 0; line-height: 20px; text-align: center; color: #111; font-size: 13px; font-weight: 800; }

.gc-guide-step-body { padding-left: 31px; margin-top: 6px; }
.gc-guide-p { font-size: 0.86rem; color: var(--text-sub, #bbb); line-height: 1.5; margin: 0 0 6px; }

/* PvME-style diamond bullets */
.gc-guide-bullets { list-style: none; margin: 0 0 6px; padding: 0; }
.gc-guide-bullets li { position: relative; padding-left: 18px; font-size: 0.86rem; color: var(--text-sub, #bbb); line-height: 1.5; margin-bottom: 4px; }
.gc-guide-bullets li::before { content: '⬥'; position: absolute; left: 0; top: 1px; color: var(--accent, #ff9800); font-size: 0.7rem; }

/* Inline item icons */
.gc-guide-items { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0; }
.gc-guide-item { display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px 3px 6px; background: var(--bg-input, #111); border: 1px solid var(--border-color, #333); border-radius: var(--radius-full, 50px); font-size: 0.78rem; color: var(--text-main, #e0e0e0); }
.gc-guide-item img { width: 18px; height: 18px; object-fit: contain; }

/* Tip callout */
.gc-guide-tip { display: flex; gap: 8px; align-items: flex-start; margin-top: 10px; padding: 10px 12px; background: rgba(255,215,0,0.07); border-left: 3px solid var(--gold, #ffd700); border-radius: 0 6px 6px 0; font-size: 0.85rem; color: #d9c876; line-height: 1.5; }
.gc-tip-icon { flex-shrink: 0; }

.gc-wiki-link { display: inline-block; margin-top: 8px; font-size: 0.82rem; color: var(--blue, #4fc3f7); text-decoration: none; }
.gc-wiki-link:hover { text-decoration: underline; }

/* Loadout layout (viewer) */
.gc-loadout { display: flex; flex-direction: column; gap: 14px; }
.gc-loadout-top {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    align-items: stretch;
}
.gc-loadout-top.is-single { grid-template-columns: minmax(0, 460px); justify-content: center; }
.gc-loadout-col {
    display: flex;
    flex-direction: column;
    border: 1px solid var(--tool-border-subtle, #2a2a2a);
    border-radius: 14px;
    background: rgba(255,255,255,0.015);
    padding: 12px 14px 16px;
}
.gc-loadout-col .gc-guide-h4 { text-align: center; margin: 0 0 10px; }
.gc-loadout-col-body { flex: 1; display: flex; align-items: center; justify-content: center; }
/* Inside the balanced card the paperdoll drops its own frame to avoid double borders */
.gc-loadout-col-body .gc-paperdoll {
    margin: 0;
    border: none;
    background: none;
    padding: 4px;
    width: 100%;
    max-width: 300px;
}
.gc-loadout-col-body .gc-inventory { margin: 0; }

.gc-loadout-info { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 2px; }
.gc-info-chip {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 5px 12px; border-radius: 50px;
    background: var(--bg-input, #111); border: 1px solid var(--border-color, #333);
    font-size: 0.8rem; color: var(--text-main, #e0e0e0);
}
.gc-info-chip .gc-info-label { color: var(--text-muted, #888); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.03em; }
.gc-info-fam-img { width: 18px; height: 18px; object-fit: contain; vertical-align: middle; }

/* ----- Familiar picker (click-to-open dropdown) ----- */
.gc-familiar-picker { position: relative; max-width: 360px; }
.gc-familiar-current {
    display: flex; align-items: center; gap: 8px; width: 100%;
    padding: 8px 12px; border-radius: 8px; cursor: pointer;
    background: var(--bg-input, #111); border: 1px solid var(--border-color, #333);
    color: var(--text-main, #e0e0e0); font-size: 0.88rem; text-align: left;
}
.gc-familiar-current:hover { border-color: color-mix(in srgb, var(--accent, #ff9800) 55%, transparent); }
.gc-familiar-picker.open .gc-familiar-current { border-color: var(--accent, #ff9800); }
.gc-familiar-cur-img { width: 26px; height: 26px; object-fit: contain; }
.gc-familiar-cur-name { flex: 1; }
.gc-familiar-placeholder { color: var(--text-muted, #777); }
.gc-familiar-caret { color: var(--text-muted, #888); transition: transform 0.15s ease; }
.gc-familiar-picker.open .gc-familiar-caret { transform: rotate(180deg); }

.gc-familiar-menu {
    position: absolute; z-index: 50; top: calc(100% + 4px); left: 0; right: 0;
    display: flex; flex-direction: column; gap: 6px; padding: 8px;
    background: var(--bg-card, #1a1a1a); border: 1px solid var(--border-color, #333);
    border-radius: 10px; box-shadow: 0 12px 30px rgba(0,0,0,0.5);
}
.gc-familiar-menu[hidden] { display: none; }
.gc-familiar-search {
    width: 100%; padding: 7px 10px; border-radius: 7px;
    background: var(--bg-input, #111); border: 1px solid var(--border-color, #333);
    color: var(--text-main, #e0e0e0); font-size: 0.82rem;
}
.gc-familiar-search:focus { outline: none; border-color: var(--accent, #ff9800); }
.gc-familiar-opts {
    display: grid; grid-template-columns: 1fr 1fr; gap: 2px;
    max-height: 280px; overflow-y: auto;
}
.gc-familiar-opt[hidden] { display: none; }
.gc-familiar-empty { grid-column: 1 / -1; text-align: center; padding: 14px; color: var(--text-muted, #888); font-size: 0.82rem; }
.gc-familiar-opt {
    display: flex; align-items: center; gap: 8px; width: 100%;
    padding: 6px 8px; border-radius: 6px; cursor: pointer;
    background: transparent; border: 1px solid transparent;
    color: var(--text-main, #e0e0e0); font-size: 0.82rem; text-align: left;
}
.gc-familiar-opt:hover { background: rgba(255,255,255,0.06); }
.gc-familiar-opt.is-selected { border-color: var(--accent, #ff9800); background: color-mix(in srgb, var(--accent, #ff9800) 14%, transparent); }
.gc-familiar-opt-img { width: 24px; height: 24px; object-fit: contain; flex-shrink: 0; }
.gc-familiar-opt-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gc-familiar-opt-none { grid-column: 1 / -1; justify-content: center; color: var(--text-muted, #aaa); }
@media (max-width: 560px) { .gc-familiar-opts { grid-template-columns: 1fr; } }

/* ----- Generic icon dropdown (category, combat style, …) ----- */
.gc-iconsel { position: relative; max-width: 360px; }
.gc-iconsel-current {
    display: flex; align-items: center; gap: 8px; width: 100%;
    padding: 8px 12px; border-radius: 8px; cursor: pointer;
    background: var(--bg-input, #111); border: 1px solid var(--border-color, #333);
    color: var(--text-main, #e0e0e0); font-size: 0.88rem; text-align: left;
}
.gc-iconsel-current:hover { border-color: color-mix(in srgb, var(--accent, #ff9800) 55%, transparent); }
.gc-iconsel.open .gc-iconsel-current { border-color: var(--accent, #ff9800); }
.gc-iconsel-cur-img { width: 26px; height: 26px; object-fit: contain; flex-shrink: 0; }
.gc-iconsel-cur-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gc-iconsel-placeholder { color: var(--text-muted, #777); }
.gc-iconsel-caret { color: var(--text-muted, #888); transition: transform 0.15s ease; }
.gc-iconsel.open .gc-iconsel-caret { transform: rotate(180deg); }

.gc-iconsel-menu {
    position: absolute; z-index: 200; top: calc(100% + 4px); left: 0; right: 0;
    display: flex; flex-direction: column; gap: 6px; padding: 8px;
    background: var(--bg-card, #1a1a1a); border: 1px solid var(--border-color, #333);
    border-radius: 10px; box-shadow: 0 12px 30px rgba(0,0,0,0.5);
}
.gc-iconsel-menu[hidden] { display: none; }
/* Let an open dropdown escape the section's clip so the full list shows */
.gc-sec:has(.gc-iconsel.open) { overflow: visible; }
.gc-iconsel-search {
    width: 100%; padding: 7px 10px; border-radius: 7px;
    background: var(--bg-input, #111); border: 1px solid var(--border-color, #333);
    color: var(--text-main, #e0e0e0); font-size: 0.82rem;
}
.gc-iconsel-search:focus { outline: none; border-color: var(--accent, #ff9800); }
.gc-iconsel-opts {
    display: grid; grid-template-columns: 1fr 1fr; gap: 2px;
    max-height: min(440px, 60vh); overflow-y: auto;
}
.gc-iconsel-opt[hidden] { display: none; }
.gc-iconsel-empty { grid-column: 1 / -1; text-align: center; padding: 14px; color: var(--text-muted, #888); font-size: 0.82rem; }
.gc-iconsel-opt {
    display: flex; align-items: center; gap: 8px; width: 100%; min-width: 0;
    padding: 6px 8px; border-radius: 6px; cursor: pointer;
    background: transparent; border: 1px solid transparent;
    color: var(--text-main, #e0e0e0); font-size: 0.82rem; text-align: left;
}
.gc-iconsel-opt:hover { background: rgba(255,255,255,0.06); }
.gc-iconsel-opt.is-selected { border-color: var(--accent, #ff9800); background: color-mix(in srgb, var(--accent, #ff9800) 14%, transparent); }
.gc-iconsel-opt-img { width: 26px; height: 26px; object-fit: contain; flex-shrink: 0; }
.gc-iconsel-opt-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 560px) { .gc-iconsel-opts { grid-template-columns: 1fr; } }

.gc-info-section { display: flex; flex-direction: column; gap: 2px; margin-top: 8px; }
.gc-info-row { display: flex; justify-content: space-between; gap: 12px; padding: 6px 0; border-bottom: 1px solid rgba(255,255,255,0.05); font-size: 0.85rem; color: var(--text-main, #e0e0e0); }
.gc-info-label { color: var(--text-muted, #888); flex-shrink: 0; }

/* Requirements */
.gc-req-grid { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin-bottom: 6px; }
.gc-req-chip { display: inline-flex; align-items: center; gap: 6px; padding: 5px 11px; background: var(--bg-input, #111); border: 1px solid var(--border-color, #333); border-radius: var(--radius-sm, 6px); font-size: 0.8rem; text-decoration: none; color: var(--text-main, #e0e0e0); }
.gc-req-chip img { width: 16px; height: 16px; object-fit: contain; }
.gc-wiki-chip:hover { border-color: var(--blue, #4fc3f7); color: var(--blue, #4fc3f7); }

/* Prayers */
.gc-prayer-list { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; margin-bottom: 6px; }
.gc-prayer-chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 12px 4px 6px; background: rgba(187,134,252,0.1); border: 1px solid rgba(187,134,252,0.25); color: var(--purple, #bb86fc); border-radius: var(--radius-full, 50px); font-size: 0.78rem; }
.gc-prayer-chip img { width: 18px; height: 18px; object-fit: contain; flex-shrink: 0; }

/* Action bars (read-only) */
.gc-actionbars { display: flex; flex-direction: column; align-items: center; gap: 12px; }
.gc-actionbar { max-width: 100%; }
.gc-actionbar-name { font-size: 0.78rem; font-weight: 700; color: var(--text-sub, #bbb); margin-bottom: 5px; text-align: center; letter-spacing: 0.02em; }
/* Authentic RuneScape action-bar strip */
.gc-actionbar-slots {
    display: inline-flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1px;
    padding: 4px;
    border-radius: 6px;
    background: linear-gradient(180deg, #4c4c4c, #1b1b1b);
    border: 1px solid #050505;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.09), inset 0 -1px 0 rgba(0,0,0,0.6), 0 2px 6px rgba(0,0,0,0.55);
}
.gc-actionbar-slot {
    position: relative;
    width: 38px; height: 38px;
    display: flex; align-items: center; justify-content: center;
    background: radial-gradient(120% 120% at 50% 28%, #2c2c2c, #0c0c0c);
    border: 1px solid #000;
    border-radius: 3px;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,0.05), inset 0 0 6px rgba(0,0,0,0.85);
}
.gc-actionbar-slot img { width: 30px; height: 30px; object-fit: contain; }
.gc-actionbar-key {
    position: absolute; top: 1px; left: 3px;
    font-size: 0.6rem; line-height: 1; font-weight: 700;
    color: #fff; text-shadow: 0 1px 1px #000, 0 0 2px #000;
    pointer-events: none;
}
.gc-actionbar-slot.gc-noimg::after { content: attr(data-abbr); font-size: 0.6rem; color: #ccc; text-transform: uppercase; }

/* Stats */
.gc-stats-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; }
.gc-stat-card { padding: 14px; background: var(--bg-input, #111); border: 1px solid var(--border-color, #333); border-radius: var(--radius-sm, 6px); text-align: center; }
.gc-stat-label { display: block; font-size: 0.72rem; color: var(--text-muted, #888); margin-bottom: 4px; }
.gc-stat-val { font-size: 1rem; font-weight: 700; color: var(--text-main, #e0e0e0); }

/* Footer actions */
.gc-guide-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; padding-top: 12px; border-top: 1px solid var(--border-color, #333); }
.gc-backtotop { margin-left: auto; }

/* Table of contents */
.gc-guide-toc { position: sticky; top: -14px; align-self: start; padding-left: 16px; border-left: 1px solid var(--border-color, #333); }
.gc-toc-title { font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.8px; color: var(--text-muted, #888); margin-bottom: 10px; }
.gc-toc-nav { display: flex; flex-direction: column; gap: 2px; max-height: 72vh; overflow-y: auto; }
.gc-toc-link { display: block; padding: 4px 10px; font-size: 0.82rem; color: var(--text-sub, #999); text-decoration: none; border-left: 2px solid transparent; border-radius: 0 4px 4px 0; transition: all 0.12s; }
.gc-toc-link:hover { color: var(--text-main, #e0e0e0); background: rgba(255,255,255,0.03); }
.gc-toc-link.gc-toc-sub { padding-left: 22px; font-size: 0.78rem; color: var(--text-muted, #777); }
.gc-toc-link.active { color: var(--accent, #ff9800); border-left-color: var(--accent, #ff9800); background: rgba(255,152,0,0.07); font-weight: 600; }

@media (max-width: 880px) {
    .gc-guide { grid-template-columns: 1fr; }
    .gc-guide-toc, .gc-guide-rail { display: none; }
}

@media (max-width: 720px) {
    .gc-loadout-top, .gc-loadout-top.is-single { grid-template-columns: 1fr; justify-content: stretch; }
}

@media (max-width: 640px) {
    .gc-card { flex-direction: column; }
    .gc-card-actions { flex-direction: row; flex-wrap: wrap; }
    .gc-row-2 { grid-template-columns: 1fr; }
    .gc-type-grid { grid-template-columns: 1fr 1fr; }
    .gc-equip-grid { grid-template-columns: 1fr; }
    .gc-wizard-type-grid { grid-template-columns: 1fr; }
    .gc-editor-stepper { justify-content: center; }
    .gc-stepper-item { min-width: 58px; padding: 6px 8px; }
    .gc-editor-guide-name { max-width: 200px; }
}

/* =============================================================================
   SITE-WIDE MOTION POLISH - GUIDE CREATOR
   Avoids drag-only ability tile transforms while polishing panels and controls.
   ============================================================================= */
.gc-panel,
.gc-card,
.gc-section,
.gc-guide-card,
.gc-wizard-type,
.gc-btn,
.gc-input,
.gc-stepper-item,
.gc-toc-link,
.gc-empty-hero {
    transition: var(--transition-interactive);
}

.gc-card:hover,
.gc-section:hover,
.gc-guide-card:hover,
.gc-wizard-type:hover,
.gc-btn:hover,
.gc-stepper-item:hover,
.gc-toc-link:hover,
.gc-empty-hero:hover {
    transform: translateY(var(--hover-lift-y));
    border-color: var(--accent);
    box-shadow: var(--shadow-glow-soft);
}

.gc-panel {
    animation: arcanePanelIn var(--duration-normal) var(--ease-emphasis);
}

.gc-btn-primary,
.gc-wizard-type.selected,
.gc-stepper-item.active {
    animation: runeBorderPulse 3.4s ease-in-out infinite;
}

.gc-card,
.gc-section,
.gc-wizard-type {
    position: relative;
    overflow: hidden;
}

.gc-card::after,
.gc-section::after,
.gc-wizard-type::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(115deg, transparent, color-mix(in srgb, var(--accent) 12%, transparent), transparent);
    transform: translateX(-130%) skewX(-18deg);
    pointer-events: none;
}

.gc-card:hover::after,
.gc-section:hover::after,
.gc-wizard-type:hover::after {
    animation: energySweep 760ms var(--ease-standard);
}
