/* Career OS™ V7 — interactive 3D bookshelf. Scoped to .shelf3d. */
.shelf3d[hidden],.shelf3d [hidden],.books-grid[hidden]{display:none!important}
.shelf3d{--s3-navy:#091b2a;--s3-cyan:#5dd7cc;--s3-orange:#e99a4a;margin:22px 0 30px;isolation:isolate}
.shelf3d-shell{border:1px solid rgba(122,190,204,.20);border-radius:23px;background:radial-gradient(ellipse at 49% 30%,#214255 0%,#0e2739 36%,#071829 72%,#061321 100%);color:#edf7fa;overflow:hidden;box-shadow:0 32px 75px rgba(0,0,0,.22);position:relative}
.shelf3d-shell:before{content:"";position:absolute;inset:0 0 auto;height:2px;background:linear-gradient(90deg,transparent,#48a3a6 30%,#e1a15e 54%,#48a3a6 70%,transparent);opacity:.85;pointer-events:none}
.shelf3d-heading{text-align:center;padding:30px 20px 0;position:relative;z-index:2}
.shelf3d-eyebrow{font-size:11px;letter-spacing:.2em;font-weight:800;color:#6ae2d6}
.shelf3d-instruction{font-size:13px;color:#bdd2d8;line-height:1.5;margin:9px auto 0;max-width:560px}
.shelf3d-stage{position:relative;height:470px;perspective:1350px;perspective-origin:50% 46%;overflow:hidden;touch-action:pan-y;user-select:none;outline-offset:-5px}
.shelf3d-stage:focus-visible{outline:2px solid #6ae2d6}
.shelf3d-stage:after{content:"";z-index:1;position:absolute;inset:auto 0 0;height:20px;background:linear-gradient(transparent,#071829);pointer-events:none}
.shelf3d-halo{position:absolute;inset:2% 6% 10%;border-radius:50%;background:radial-gradient(ellipse at center,rgba(34,176,170,.16),rgba(35,139,157,.075) 37%,transparent 69%);pointer-events:none;animation:shelf3d-glow 9s ease-in-out infinite alternate}
.shelf3d-beam{position:absolute;left:50%;top:0;width:530px;max-width:95%;height:80%;transform:translateX(-50%);background:conic-gradient(from 190deg at 50% 0%,transparent 0deg,rgba(255,255,255,.02) 18deg,transparent 39deg);opacity:.8;pointer-events:none}
.shelf3d-floor{position:absolute;bottom:27px;left:6%;width:88%;height:90px;transform:perspective(700px) rotateX(61deg);transform-origin:bottom center;border-top:2px solid #9d8a77a0;background:linear-gradient(to bottom,#193545,#0b1a29 55%,#071627);box-shadow:0 -3px 30px rgba(114,230,227,.10),0 25px 38px rgba(0,0,0,.68);border-radius:2px;pointer-events:none}
.shelf3d-books{position:absolute;inset:0;transform-style:preserve-3d;pointer-events:none}
.shelf3d-book{appearance:none;cursor:pointer;border:0;padding:0;position:absolute;top:54%;left:50%;height:var(--book-h,322px);width:calc(var(--book-h,322px) * var(--shelf-ratio,.68));background:transparent;transform-style:preserve-3d;pointer-events:auto;transition:transform 1100ms cubic-bezier(.17,.8,.2,1),opacity 850ms ease,filter 850ms ease;will-change:transform;outline:0}
.shelf3d-book:focus-visible .shelf3d-front{outline:3px solid #61ebdc;outline-offset:5px}
.shelf3d-volume{display:block;position:relative;width:100%;height:100%;transform-style:preserve-3d;transition:transform 1150ms cubic-bezier(.2,.75,.18,1);transform:rotateY(0deg)}
.shelf3d-book.show-rear .shelf3d-volume{transform:rotateY(180deg)}
.shelf3d-face{position:absolute;inset:0;display:block;overflow:hidden;backface-visibility:hidden;-webkit-backface-visibility:hidden;border-radius:2px 4px 4px 2px;background:#0d2636;border:1px solid rgba(230,247,250,.26);box-shadow:inset 2px 0 7px #0006,8px 12px 23px #0009}
.shelf3d-front{transform:translateZ(12px)}
.shelf3d-rear{transform:rotateY(180deg) translateZ(12px)}
.shelf3d-art{display:block;width:100%;height:100%;object-fit:contain;object-position:center;pointer-events:none;-webkit-user-drag:none}
.shelf3d-spine{display:flex;position:absolute;top:0;left:0;height:100%;width:24px;align-items:center;justify-content:space-between;flex-direction:column;gap:14px;padding:12px 3px;background:linear-gradient(90deg,var(--shelf-edge-bottom),var(--shelf-edge-top) 60%,#102434);border:1px solid #b9c8ce45;color:#eaf2f4;transform-origin:left center;transform:translateZ(12px) rotateY(-90deg);box-shadow:inset 2px 0 2px #0005}
.shelf3d-spine-title{font-size:11px;font-weight:650;white-space:nowrap;overflow:hidden;max-height:85%;writing-mode:vertical-rl;text-orientation:mixed;letter-spacing:.04em}
.shelf3d-spine-brand{writing-mode:vertical-rl;font-weight:750;font-size:8px;letter-spacing:.1em;flex-shrink:0}
.shelf3d-pages{position:absolute;inset:3px 0 3px auto;width:24px;transform-origin:right center;transform:translateZ(12px) rotateY(90deg);background:repeating-linear-gradient(0deg,#d2d5d5 0 2px,#aab5ba 2px 3px);box-shadow:inset 0 0 5px #23354488;border:1px solid #c9d0d1}
.shelf3d-blank-rear{display:grid;place-items:center;height:100%;padding:15px;font-family:Georgia,serif;font-size:17px;text-align:center}
.shelf3d-book.is-selected{filter:brightness(1.06);filter:drop-shadow(0 9px 12px #0008) brightness(1.06)}
.shelf3d-nav{position:relative;z-index:3;display:flex;align-items:center;justify-content:center;gap:25px;margin:-8px 0 20px}
.shelf3d-arrow{display:grid;place-items:center;width:42px;height:42px;line-height:1;background:rgba(24,58,76,.9);color:#e6ffff;border:1px solid #7aa5ae80;border-radius:50%;font-size:32px;font-weight:300;cursor:pointer;transition:background .2s,transform .2s}
.shelf3d-arrow:hover{background:#1a6e78;transform:scale(1.06)}
.shelf3d-arrow:focus-visible,.shelf3d-dot:focus-visible,.shelf3d-list-button:focus-visible,.shelf3d-flip:focus-visible{outline:2px solid #61ebdc;outline-offset:3px}
.shelf3d-dots{display:flex;align-items:center;justify-content:center;gap:0}
.shelf3d-dot{cursor:pointer;border:0;background:transparent;border-radius:20px;width:44px;height:44px;padding:18px;position:relative;transition:background .4s}
.shelf3d-dot::before{content:"";display:block;width:8px;height:8px;background:#507887;border-radius:10px;transition:width .4s,background .4s}
.shelf3d-dot.is-current::before{background:#72e5d4;width:26px;transform:translateX(-9px)}
.shelf3d-details{position:relative;z-index:2;display:flex;align-items:center;justify-content:space-between;gap:25px;margin:0 28px;background:rgba(255,255,255,.045);border:1px solid rgba(183,217,228,.18);border-radius:15px;padding:20px 24px;min-height:170px}
.shelf3d-description{flex:1;min-width:0}
.shelf3d-book-number{display:inline-block;color:#75e0d2;font-weight:750;letter-spacing:.16em;font-size:11px}
.shelf3d-book-title{font-family:Georgia,'Times New Roman',serif;color:#f3f9fa!important;font-size:clamp(20px,2.8vw,29px)!important;letter-spacing:-.025em;line-height:1.25!important;margin:7px 0 6px!important}
.shelf3d-book-subtitle{color:#b4c9d2;font-size:12px;line-height:1.4;margin:0 0 9px}
.shelf3d-book-summary{color:#d1e1e6;font-size:13px;line-height:1.6;margin:0 0 10px;max-width:650px}
.shelf3d-access{display:inline-flex;color:#83dfd1;font-size:11px;font-weight:650;letter-spacing:.02em}
.shelf3d-actions{display:flex;flex-direction:column;align-items:stretch;gap:9px;min-width:180px}
.shelf3d-actions .pill{width:100%;font-size:12px!important;text-align:center;white-space:normal;justify-content:center}
.shelf3d-flip{font:inherit;cursor:pointer}
.shelf3d-flip:disabled{opacity:.45;cursor:not-allowed}
.shelf3d-list-button{cursor:pointer;font-size:11px;background:transparent;border:0;color:#add9da;text-decoration:underline;text-underline-offset:4px;padding:4px 6px}
.shelf3d-hints{text-align:center;color:#85a6b5;font-size:10px;letter-spacing:.04em;padding:13px 14px 21px}
@keyframes shelf3d-glow{from{opacity:.35;transform:scale(.9)}to{opacity:1;transform:scale(1.08)}}
@media (max-width:900px){.shelf3d-stage{height:440px}.shelf3d-details{margin:0 18px;padding:18px 20px}}
@media (max-width:620px){.shelf3d{margin:16px 0 24px}.shelf3d-shell{border-radius:16px}.shelf3d-heading{padding:22px 14px 0}.shelf3d-instruction{font-size:12px}.shelf3d-stage{height:372px;perspective:850px}.shelf3d-floor{bottom:18px;height:66px}.shelf3d-nav{margin:-7px 0 14px;gap:22px}.shelf3d-arrow{width:40px;height:40px}.shelf3d-details{margin:0 12px;display:block;padding:17px}.shelf3d-actions{min-width:0;display:grid;grid-template-columns:1fr 1fr;margin-top:17px}.shelf3d-actions .pill{min-height:43px;padding:10px 6px!important}.shelf3d-list-button{grid-column:1/-1;padding:8px}.shelf3d-book-summary{font-size:12px}.shelf3d-hints{font-size:9px;padding-bottom:15px}}
@media (max-width:410px){.shelf3d-stage{height:344px}.shelf3d-heading{padding-top:17px}.shelf3d-instruction{font-size:11px}.shelf3d-hints{font-size:9px}}
@media (prefers-reduced-motion:reduce){.shelf3d *{animation:none!important;transition-duration:0.01ms!important;scroll-behavior:auto!important}}

/* V8: protect original cover proportions and avoid clipping on phones. */
.shelf3d-face{background:#0a1c2d;display:grid;place-items:center}
.shelf3d-art{max-width:100%;max-height:100%;object-fit:contain!important}
.shelf3d-dot:focus-visible{outline:2px solid #61ebdc;outline-offset:1px}

/* Keep the back-cover image itself at its intrinsic proportions. */
.shelf3d-rear .shelf3d-art{width:auto;height:auto;max-width:100%;max-height:100%;object-fit:contain}
