/* Photo split: editor on the left, a fake Instagram profile or Facebook post on the right */
.split { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 28px; padding: 22px 20px 60px; max-width: 1240px; margin: 0 auto; align-items: start; }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; } .sp-preview { justify-self: center; width: 100%; max-width: 420px; } }
.brand { color: inherit; text-decoration: none; }

.sp-drop { border: 2px dashed var(--line); border-radius: var(--radius); padding: 34px 28px; background: var(--card); text-align: center; }
.sp-drop.is-over { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 6%, var(--card)); }
.sp-drop.has-photo { padding: 0; border: 0; background: none; display: none; }
.sp-drop-in h1 { font: 500 clamp(26px, 4vw, 38px)/1.15 var(--serif); margin: 0 0 12px; letter-spacing: -.01em; text-wrap: balance; }
.sp-drop-in p { max-width: 56ch; margin: 0 auto 16px; }
.sp-drop-in .btn { margin-bottom: 10px; }

.sp-modes { margin-bottom: 14px; }
.seg-big button { padding: 7px 18px; font-size: 15px; }
.sp-tools { display: grid; gap: 14px; }
.sp-row { display: flex; align-items: center; gap: 12px 16px; flex-wrap: wrap; }
.seg { display: inline-flex; gap: 2px; padding: 3px; border-radius: 999px; background: color-mix(in srgb, var(--ink) 7%, transparent); }
.seg button { border: 0; background: none; padding: 5px 13px; border-radius: 999px; cursor: pointer; color: var(--muted); font-weight: 500; font-size: 14px; }
.seg button[aria-pressed="true"] { background: var(--card); color: var(--ink); box-shadow: 0 1px 2px rgba(0,0,0,.12); }

.sp-stage { position: relative; background: var(--table); border-radius: var(--radius); padding: 18px; display: grid; justify-items: center; }
#sp-canvas { max-width: 100%; width: min(100%, 720px); height: auto; display: block; box-shadow: 0 10px 30px rgba(0,0,0,.25); cursor: grab; touch-action: none; background: #222; }
#sp-canvas.is-drag { cursor: grabbing; }
.sp-pad { position: absolute; right: 12px; bottom: 12px; display: grid; grid-template-columns: repeat(3, 34px); grid-template-rows: repeat(3, 34px); gap: 2px; }
.sp-pad button, .sp-zoom button { border: 0; border-radius: 8px; background: rgba(20,18,16,.78); color: #fff; font-size: 13px; cursor: pointer; backdrop-filter: blur(6px); }
.sp-pad button:hover, .sp-zoom button:hover { background: var(--accent); }
.sp-pad button[data-move="0,-1"] { grid-column: 2; grid-row: 1; }
.sp-pad button[data-move="-1,0"] { grid-column: 1; grid-row: 2; }
.sp-pad button[data-move="1,0"] { grid-column: 3; grid-row: 2; }
.sp-pad button[data-move="0,1"] { grid-column: 2; grid-row: 3; }
.sp-zoom { position: absolute; left: 12px; bottom: 12px; display: flex; align-items: center; gap: 4px; }
.sp-zoom button { width: 34px; height: 34px; font-size: 18px; }
.sp-zoom #sp-fit { width: auto; padding: 0 12px; font-size: 13px; }
.sp-zoom span { color: #fff; background: rgba(20,18,16,.78); border-radius: 8px; height: 34px; line-height: 34px; padding: 0 10px; font-size: 13px; min-width: 56px; text-align: center; }

.sp-out { border-top: 1px solid var(--line); padding-top: 12px; }
.sp-out p { margin: 0 0 10px; }
.sp-out-list { display: flex; flex-wrap: wrap; gap: 10px; }
.sp-out-list a { display: grid; gap: 4px; justify-items: center; text-decoration: none; color: var(--ink); font-size: 12px; }
.sp-out-list img { width: 96px; border-radius: 4px; box-shadow: 0 2px 8px rgba(0,0,0,.2); display: block; }

/* fake Instagram profile */
.phone { background: #fff; color: #111; border-radius: 26px; border: 8px solid #1a1a1a; box-shadow: 0 20px 50px rgba(0,0,0,.3); overflow: hidden; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; font-size: 13px; }
.ig-top { display: flex; align-items: center; gap: 6px; padding: 12px 14px 8px; font-weight: 700; font-size: 16px; }
.ig-chev { font-size: 12px; } .ig-icons { margin-left: auto; letter-spacing: .3em; font-weight: 400; }
.ig-head { display: flex; align-items: center; gap: 18px; padding: 6px 14px; }
.ig-avatar { width: 76px; height: 76px; border-radius: 50%; overflow: hidden; background: #ddd; flex: none; border: 2px solid #fff; box-shadow: 0 0 0 2px #e6e6e6; }
.ig-avatar canvas { width: 100%; height: 100%; display: block; }
.ig-stats { display: flex; gap: 22px; flex: 1; justify-content: space-around; text-align: center; }
.ig-stats div { display: grid; } .ig-stats b { font-size: 16px; } .ig-stats span { font-size: 12px; color: #444; }
.ig-bio { padding: 6px 14px 2px; } .ig-bio .muted { color: #555; }
.ig-btns { display: flex; gap: 6px; padding: 8px 14px; }
.ig-btns span { flex: 1; text-align: center; background: #efefef; border-radius: 8px; padding: 6px 0; font-weight: 600; }
.ig-tabs { display: flex; margin-top: 4px; border-top: 1px solid #eee; }
.ig-tabs span { flex: 1; text-align: center; padding: 8px 0; color: #999; font-size: 16px; }
.ig-tabs .is-on { color: #111; border-bottom: 1.5px solid #111; }
.ig-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px; background: #fff; }
.ig-grid canvas, .ig-grid .ph { width: 100%; display: block; background: #e9e9e9; }
.ig-grid .cell { position: relative; }
.ig-grid .cell .n { position: absolute; left: 6px; top: 6px; background: rgba(0,0,0,.6); color: #fff; font-size: 11px; font-weight: 700; padding: 1px 6px; border-radius: 999px; }
.ig-grid.no-order .n { display: none; }

/* Facebook layout buttons */
#fb-layout button { display: inline-flex; align-items: center; gap: 7px; }
.lay-ic { width: 18px; height: auto; flex: none; }
.lay-ic rect { fill: currentColor; opacity: .55; }
#fb-layout button[aria-pressed="true"] .lay-ic rect { fill: var(--accent); opacity: 1; }
#sp-hint { flex: 1 1 220px; }

/* fake Facebook post */
.fb-wrap { display: grid; gap: 10px; }
.fb-post { background: #fff; color: #050505; border-radius: 10px; box-shadow: 0 1px 2px rgba(0,0,0,.2), 0 10px 30px rgba(0,0,0,.18); overflow: hidden; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif; font-size: 14px; }
.fb-head { display: flex; align-items: center; gap: 9px; padding: 12px 14px 6px; }
.fb-avatar { width: 40px; height: 40px; border-radius: 50%; overflow: hidden; background: #ddd; flex: none; }
.fb-avatar canvas { width: 100%; height: 100%; display: block; }
.fb-who { display: grid; line-height: 1.25; } .fb-who b { font-size: 14.5px; } .fb-who > span { font-size: 12.5px; color: #65676b; }
.fb-more { margin-left: auto; color: #65676b; font-weight: 700; letter-spacing: .05em; }
.fb-text { padding: 2px 14px 10px; white-space: pre-wrap; outline: none; border-radius: 4px; }
.fb-text:focus { box-shadow: inset 0 0 0 1.5px #1877f2; }
.fb-media { position: relative; width: 100%; background: #fff; }
.fb-media .cell { position: absolute; overflow: hidden; }
.fb-media .cell canvas { width: 100%; height: 100%; display: block; }
.fb-media.hairline .cell { box-shadow: inset 0 0 0 1px #fff; }
.fb-media .cell .n { position: absolute; left: 6px; top: 6px; background: rgba(0,0,0,.6); color: #fff; font-size: 11px; font-weight: 700; padding: 1px 6px; border-radius: 999px; }
.fb-media.no-order .n { display: none; }
.fb-count { display: flex; justify-content: space-between; padding: 9px 14px; color: #65676b; font-size: 13px; }
.fb-r { letter-spacing: -.2em; margin-right: 4px; }
.fb-acts { display: flex; margin: 0 12px; border-top: 1px solid #ced0d4; }
.fb-acts span { flex: 1; text-align: center; padding: 8px 0 9px; color: #65676b; font-weight: 600; font-size: 13.5px; }
.fb-tip { margin: 0; }

.toast { font-family: var(--sans); }
