/* 시스템 페이지 (/system.php). page.css 위에 얹는다.
   규칙: 글자 크기·굵기·자간·서체는 쓰지 않는다 → 마크업의 t-* 클래스. 값은 foundations 변수만. 전환점 600px. */

/* 주문 → 운영 → 관리 흐름 */
.sy-flow{display:grid;grid-template-columns:minmax(0,1.4fr) auto minmax(0,1fr) auto minmax(0,1fr);align-items:stretch;gap:var(--space-4)}
.sy-step{display:flex;flex-direction:column;justify-content:space-between;gap:var(--space-8);padding:var(--space-8);border-radius:var(--radius-lg);background:var(--color-bg-surface)}
.sy-step--dark{background:var(--color-bg-brand);color:var(--color-text-on-brand)} /* 어드민 박스: 브랜드 파랑(클래스명 dark 는 그대로 둠) */
.sy-step__eyebrow{color:var(--color-text-tertiary)}
/* 흐름 카드 선 아이콘(pages/_icons.php): 카드가 떠오르면 선이 그려진다. 파랑 카드에서는 흰색 */
.sy-ico{display:block;flex:none;width:var(--space-10);height:var(--space-10);color:var(--color-brand-logo-primary)}
.sy-step--dark .sy-ico{color:var(--color-text-on-brand)}
.sy-ico :is(path,circle){stroke-dasharray:1;stroke-dashoffset:0}
.sy-step:not(.is-pre) .sy-ico :is(path,circle){transition:stroke-dashoffset calc(var(--dur-slow) * 4) var(--ease-emphasized) calc(var(--dur-slow) + var(--i, 0) * var(--dur-base))}
.sy-step.is-pre .sy-ico :is(path,circle){stroke-dashoffset:1}
@media (prefers-reduced-motion:reduce){.sy-ico :is(path,circle){transition:none!important;stroke-dashoffset:0!important}}
.sy-step--dark .sy-step__eyebrow{color:var(--color-text-on-brand-secondary)}
.sy-step__body{display:flex;flex-direction:column;gap:var(--space-5)}
.sy-step__desc{color:var(--color-text-secondary)}
.sy-step--dark .sy-step__desc{color:var(--color-text-on-brand-secondary)}
.sy-chips{display:flex;flex-wrap:wrap;gap:var(--space-2)}
.sy-chip{padding:var(--space-3) var(--space-6);border:var(--border-hairline) solid var(--color-border-default);border-radius:var(--radius-pill);background:var(--color-bg-page);color:var(--color-text-primary)}
.sy-arrow{align-self:center;width:var(--space-8);height:var(--space-3);overflow:visible;color:var(--color-neutral-500)}
.sy-arrow path{fill:none;stroke:currentColor;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:1;stroke-dashoffset:0}
.sy-arrow:not(.is-pre) path{transition:stroke-dashoffset var(--dur-slow) var(--ease-emphasized) calc(var(--dur-slow) + var(--i, 0) * var(--dur-base))}
.sy-arrow.is-pre path{stroke-dashoffset:1}

/* 자체 개발 라인업: 기기 틀 + 설명이 좌우로 번갈아 */
.sy-rows{display:flex;flex-direction:column;gap:var(--block-gap)}
.sy-row{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));align-items:center;gap:var(--space-16)}
.sy-row:nth-child(even) .sy-row__media{order:2}
.sy-row__text{display:flex;flex-direction:column;gap:var(--space-4)}
.sy-row__idx{display:flex;align-items:center;gap:var(--space-4)}
.sy-row__no{color:var(--color-neutral-500)}
.sy-row__badge{padding:var(--space-1) var(--space-3);border:var(--border-hairline) solid var(--color-text-primary);border-radius:var(--radius-pill)}
.sy-row__desc{color:var(--color-text-secondary)}
.sy-stage{position:relative;display:grid;place-items:center;aspect-ratio:4/3;overflow:hidden;border-radius:var(--radius-lg);background:var(--color-bg-surface)}
.sy-stage::before{content:"";position:absolute;inset:auto 0 0;height:34%;background:var(--color-neutral-200);opacity:.6}

/* 기기 틀 (CSS 로 그림). 화면 이미지가 있으면 .sy-screen 안에 채운다 */
.sy-stage__bg{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}
.sy-stage.has-bg::before{content:none}
.sy-stage.is-photo::before{content:none} /* 완성 사진(기기 포함)은 칸을 꽉 채운다 */
.sy-stage.has-bg .sy-device{position:relative;z-index:1;margin-top:calc(var(--space-6) * -1)}
.sy-device{position:relative;display:block;border:var(--space-1) solid var(--color-ink);border-radius:var(--radius-md);background:var(--color-bg-page);box-shadow:var(--shadow-md);overflow:hidden}
.sy-device--app{width:30%;aspect-ratio:9/19;border-radius:var(--radius-lg)}
.sy-device--pos{width:60%;aspect-ratio:16/11}
.sy-device--kiosk{width:30%;aspect-ratio:9/16}
.sy-device--table{width:58%;aspect-ratio:4/3;border-radius:var(--radius-lg)}
.sy-device--admin{width:72%;aspect-ratio:16/10}
.sy-screen{position:absolute;inset:0;display:flex;flex-direction:column;gap:var(--space-2);padding:var(--space-4)}
.sy-screen img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}
.sy-screen i{display:block;border-radius:var(--radius-xs);background:var(--color-neutral-200)}
.sy-screen i:nth-child(1){height:18%;background:var(--color-ink)}
.sy-screen i:nth-child(2){height:12%;width:70%}
.sy-screen i:nth-child(3){flex:1}
.sy-screen i:nth-child(4){height:14%;width:45%;align-self:flex-end;background:var(--color-neutral-400)}
.sy-device--admin .sy-screen,.sy-device--pos .sy-screen{flex-direction:row;flex-wrap:wrap;align-content:flex-start}
.sy-device--admin .sy-screen i:nth-child(1),.sy-device--pos .sy-screen i:nth-child(1){height:auto;width:22%;align-self:stretch}
.sy-device--admin .sy-screen i:nth-child(2),.sy-device--pos .sy-screen i:nth-child(2){height:18%;width:70%}
.sy-device--admin .sy-screen i:nth-child(3),.sy-device--pos .sy-screen i:nth-child(3){flex:none;height:46%;width:70%}
.sy-device--admin .sy-screen i:nth-child(4),.sy-device--pos .sy-screen i:nth-child(4){height:16%;width:30%;align-self:auto}

/* 마무리 */
.sy-close{display:flex;flex-direction:column;align-items:center;gap:var(--space-8);padding:var(--block-gap) var(--gutter);border-radius:var(--radius-lg);background:var(--color-bg-inverse);color:var(--color-text-on-inverse);text-align:center}

@media (max-width:600px){
  .sy-flow{grid-template-columns:1fr;justify-items:stretch}
  .sy-arrow{justify-self:center;transform:rotate(90deg)}
  .sy-row{grid-template-columns:1fr;gap:var(--space-8)}
  .sy-row:nth-child(even) .sy-row__media{order:0}
}
