/**
 * Portfolio Displays — Device (2.14, 2.16): a live page inside a drawn laptop, phone or browser window.
 * The page is laid out at the width it was designed for (--pfd-device-w) and scaled by the script to the glass; the
 * glass keeps the page's proportions (aspect-ratio), so the device is as tall as it should be before anything loads.
 */
.pfd-device { --pfd-device-align: center; --pfd-device-accent: var(--pfd-accent, #d81f3a); --pfd-device-screen: #0e0f13; --pfd-device-bezel: #1b1c21; --pfd-device-edge: #34363d; --pfd-device-base: linear-gradient(#6a6d76 0, #3c3e45 14%, #2a2c32 100%); --pfd-device-lip: rgba(0, 0, 0, .28); --pfd-device-foot: linear-gradient(rgba(0, 0, 0, .18), rgba(0, 0, 0, .42));
  position: relative; width: 100%; }
/* In Elementor's wrapping column containers (phones) a widget with no width of its own is measured at a stand-in width,
   so its box came out 30% shorter than the device drawn inside it. The Width control's own variable, 100% by default. */
.elementor-widget-pfd_device { width: var(--container-widget-width, 100%); max-width: 100%; }
.pfd-device--silver { --pfd-device-bezel: #d4d6db; --pfd-device-edge: #b9bcc4; --pfd-device-base: linear-gradient(#fbfbfc 0, #dfe1e5 14%, #c2c4cb 100%); --pfd-device-lip: rgba(0, 0, 0, .12); --pfd-device-foot: linear-gradient(rgba(0, 0, 0, .06), rgba(0, 0, 0, .2)); }
.pfd-device--white { --pfd-device-bezel: #f4f4f6; --pfd-device-edge: #dcdde2; --pfd-device-base: linear-gradient(#ffffff 0, #f0f0f3 14%, #dcdde2 100%); --pfd-device-lip: rgba(0, 0, 0, .08); --pfd-device-foot: linear-gradient(rgba(0, 0, 0, .04), rgba(0, 0, 0, .14)); }

/* Pills: which screen */
.pfd-device__tabs { display: flex; flex-wrap: wrap; gap: 8px; justify-content: var(--pfd-device-align); margin: 0 0 16px; }
.pfd-device .pfd-device__tab { cursor: pointer; border: 0; height: 32px; padding: 0 16px; font-size: 13px; }
.pfd-device .pfd-device__tab.is-current { background: var(--pfd-fg, #111); color: var(--pfd-bg, #fff); }

.pfd-device__screens { margin: 0 auto; max-width: 100%; }
.pfd-device__screen { margin: 0; }
/* themes set display on buttons and figures, which would beat the browser's own [hidden] rule */
.pfd-device [hidden] { display: none !important; }

/* The shell is a size container, so the chrome is measured in cqw (1% of the shell's width): a bezel that is 2.2% of
   the lid at 1140px is 2.2% of the lid at 358px, and the device keeps its shape at every column width. Container units
   resolve against an ancestor, so the shell draws nothing itself: the lid (the drawn body, holding the glass) and the
   laptop's base sit inside it. Layout-affecting parts use percentage padding (no shift before scripts run); radii use
   cqw, with px first for browsers without container units. */
.pfd-device__shell { position: relative; box-sizing: border-box; margin: 0 auto; container-type: inline-size; }
.pfd-device__lid { position: relative; box-sizing: border-box; background: var(--pfd-device-bezel); box-shadow: inset 0 0 0 1px var(--pfd-device-edge); }
.pfd-device--shadow .pfd-device__screen--phone .pfd-device__lid, .pfd-device--shadow .pfd-device__screen--browser .pfd-device__lid { box-shadow: inset 0 0 0 1px var(--pfd-device-edge), 0 30px 60px -28px rgba(0, 0, 0, .5), 0 10px 24px -14px rgba(0, 0, 0, .3); }
/* overflow: clip, not hidden: a clipped box cannot be scrolled, so a page that scrolls itself into view inside the frame
   cannot shift the frame within the glass (hidden boxes can be scrolled by script). */
/* Height from a percentage padding, not aspect-ratio: inside an Elementor flex container, Chromium sized the widget's
   box from an aspect-ratio glass at a stand-in width, leaving the device 32% taller than its box (the footer rode up). */
.pfd-device__glass { position: relative; overflow: clip; height: 0; padding-bottom: calc(var(--pfd-device-h, 800) / var(--pfd-device-w, 1280) * 100%); background: var(--pfd-device-screen); }

/* Laptop (2.16): a lid with a thin bezel and a camera, on a base a little wider than the lid, with a lip to open it
   by and a visible front edge. The shell is as wide as the base; the lid is 93% of it; the glass 88.6%, so a page
   designed at W px fills its glass when the shell is 1.129 W wide. All of it in proportion to the shell. */
.pfd-device__screen--laptop .pfd-device__shell { width: min(100%, calc(var(--pfd-device-w, 1280) * 1.129px)); }
.pfd-device__screen--laptop .pfd-device__lid { width: 93%; margin: 0 auto; padding: 2.4% 2.2% 2.6%; border-radius: 18px 18px 5px 5px; border-radius: 1.7cqw 1.7cqw .5cqw .5cqw; }
.pfd-device__screen--laptop .pfd-device__lid::before { content: ""; position: absolute; left: 50%; top: 10px; top: .85cqw; width: 7px; height: 7px; width: .7cqw; height: .7cqw; transform: translateX(-50%); border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #4a6a8a, #0a0d14 65%); box-shadow: 0 0 0 1px rgba(255, 255, 255, .06); }
.pfd-device--silver .pfd-device__screen--laptop .pfd-device__lid::before, .pfd-device--white .pfd-device__screen--laptop .pfd-device__lid::before { box-shadow: 0 0 0 1px rgba(0, 0, 0, .12); }
.pfd-device__screen--laptop .pfd-device__glass { border-radius: 4px; border-radius: .4cqw; }
.pfd-device__base { position: relative; width: 100%; height: 0; padding-bottom: 2.5%; background: var(--pfd-device-base); border-radius: 0 0 14px 14px; border-radius: 0 0 1.3cqw 1.3cqw; box-shadow: 0 1px 0 var(--pfd-device-edge); }
/* the lip, and the front edge */
.pfd-device__base::before { content: ""; position: absolute; left: 50%; top: 0; width: 12%; height: 40%; transform: translateX(-50%); background: var(--pfd-device-lip); border-radius: 0 0 8px 8px; border-radius: 0 0 .7cqw .7cqw; }
.pfd-device__base::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 22%; background: var(--pfd-device-foot); border-radius: inherit; }
.pfd-device--shadow .pfd-device__base { box-shadow: 0 1px 0 var(--pfd-device-edge), 0 26px 30px -8px rgba(0, 0, 0, .3); box-shadow: 0 1px 0 var(--pfd-device-edge), 0 2.2cqw 2.6cqw -.8cqw rgba(0, 0, 0, .3); }

/* Phone: deep rounded bezel and a notch, in proportion too (bezel 3% of the shell) */
.pfd-device__screen--phone .pfd-device__shell { width: min(100%, calc(var(--pfd-device-w, 390) * 1.064px)); }
.pfd-device__screen--phone .pfd-device__lid { padding: 3%; border-radius: 48px; border-radius: 12cqw; }
.pfd-device__screen--phone .pfd-device__glass { border-radius: 36px; border-radius: 9cqw; }
.pfd-device__notch { position: absolute; z-index: 3; top: 20px; top: 4.8cqw; left: 50%; width: 30%; height: 24px; height: 5.6cqw; transform: translateX(-50%); background: var(--pfd-device-bezel); border-radius: 14px; border-radius: 2.8cqw; pointer-events: none; }

/* Browser window: a title bar with three dots and the address */
.pfd-device__screen--browser .pfd-device__shell { width: min(100%, calc(var(--pfd-device-w, 1280) * 1px + 2px)); }
.pfd-device__screen--browser .pfd-device__lid { border-radius: 12px; border-radius: clamp(6px, .95cqw, 12px); overflow: hidden; }
.pfd-device__bar { display: flex; align-items: center; gap: 7px; height: 38px; height: clamp(22px, 3cqw, 38px); padding: 0 14px; padding: 0 clamp(8px, 1.1cqw, 14px); }
.pfd-device__bar > span { width: 11px; height: 11px; width: clamp(7px, .86cqw, 11px); height: clamp(7px, .86cqw, 11px); border-radius: 50%; background: #ff5f57; }
.pfd-device__bar > span:nth-child(2) { background: #febc2e; }
.pfd-device__bar > span:nth-child(3) { background: #28c840; }
.pfd-device__address { flex: 1; margin-left: 10px; height: 24px; height: clamp(14px, 1.9cqw, 24px); border-radius: 7px; background: rgba(127, 127, 127, .18); color: color-mix(in srgb, var(--pfd-device-edge) 40%, #888); font: 500 12px/1 var(--pfd-font-ui, system-ui, sans-serif); font-size: clamp(9px, .95cqw, 12px); display: flex; align-items: center; justify-content: center; overflow: hidden; white-space: nowrap; }
.pfd-device--graphite .pfd-device__address { color: #9a9ca3; }

/* The page, laid out at its own width and scaled to the glass */
/* max-width: none — themes cap iframes at 100% (Hello does), which would lay the page out at the glass width instead */
.pfd-device .pfd-device__frame { position: absolute; top: 0; left: 0; display: block; width: calc(var(--pfd-device-w, 1280) * 1px); max-width: none; height: calc(var(--pfd-device-h, 800) * 1px); max-height: none; border: 0; background: #fff; transform-origin: 0 0; transform: scale(var(--pfd-device-scale, 1)); }

/* Poster and Start, until the page is live */
.pfd-device__poster { position: absolute; inset: 0; z-index: 2; display: grid; place-items: center; cursor: pointer; background: var(--pfd-device-screen) center top / cover no-repeat; transition: opacity .45s ease; }
.pfd-device__poster::before { content: ""; position: absolute; inset: 0; background: rgba(0, 0, 0, .18); }
.pfd-device__screen.is-live .pfd-device__poster { opacity: 0; pointer-events: none; }
.pfd-device__screen--phone .pfd-device__poster { background-size: 100% auto; }
.pfd-device .pfd-device__start { position: relative; z-index: 1; display: inline-flex; align-items: center; gap: 10px; height: 52px; padding: 0 26px 0 20px; border: 0; border-radius: 999px; cursor: pointer;
  background: var(--pfd-device-accent); color: #fff; font: 600 16px/1 var(--pfd-font-ui, system-ui, sans-serif); letter-spacing: .01em; box-shadow: 0 10px 30px -10px rgba(0, 0, 0, .6), 0 0 0 6px rgba(255, 255, 255, .14); transition: transform .2s ease, box-shadow .2s ease; }
.pfd-device .pfd-device__start svg { width: 20px; height: 20px; }
.pfd-device__poster:hover .pfd-device__start, .pfd-device .pfd-device__start:focus-visible { transform: scale(1.05); box-shadow: 0 14px 34px -10px rgba(0, 0, 0, .65), 0 0 0 9px rgba(255, 255, 255, .18); }
.pfd-device__blank { position: absolute; left: 0; right: 0; bottom: 9%; display: grid; gap: 4px; text-align: center; color: rgba(255, 255, 255, .78); font: 500 13px/1.3 var(--pfd-font-ui, system-ui, sans-serif); }
.pfd-device__blank strong { font-size: 15px; color: #fff; }
.pfd-device--silver .pfd-device__poster:not([style]) , .pfd-device--white .pfd-device__poster:not([style]) { background-image: linear-gradient(160deg, #2a2c33, #0e0f13); }

/* A thin bar across the top of the glass while the page is on its way */
.pfd-device__screen.is-loading .pfd-device__glass::after { content: ""; position: absolute; z-index: 4; top: 0; left: 0; height: 3px; width: 35%; background: var(--pfd-device-accent); border-radius: 0 3px 3px 0; animation: pfd-device-load 1.1s ease-in-out infinite alternate; }
@keyframes pfd-device-load { from { transform: translateX(-100%); } to { transform: translateX(290%); } }
@media (prefers-reduced-motion: reduce) { .pfd-device__screen.is-loading .pfd-device__glass::after { animation: none; width: 100%; opacity: .5; } .pfd-device__poster { transition: none; } }

/* Under the device: Start over, Open full size, caption */
.pfd-device__foot { display: flex; flex-wrap: wrap; gap: 6px 22px; justify-content: var(--pfd-device-align); margin: 14px 0 0; font: 500 13px/1.4 var(--pfd-font-ui, system-ui, sans-serif); color: var(--pfd-muted, #666); }
.pfd-device .pfd-device__again { border: 0; padding: 0; background: none; cursor: pointer; font: inherit; color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.pfd-device .pfd-device__again:hover, .pfd-device .pfd-device__full:hover { color: var(--pfd-fg, #111); }
.pfd-device .pfd-device__full { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.pfd-device__caption { margin: 14px auto 0; max-width: 60ch; text-align: center; font-size: 14px; line-height: 1.5; color: var(--pfd-muted, #666); }
.pfd-device--empty { padding: 24px; text-align: center; border: 1px dashed var(--pfd-line, #ccc); border-radius: 12px; }
