/* Automations v3 system-surface pass
   Loaded after the v3 experience. This layer changes presentation only. */

.v3-dashboard{width:min(1180px,100%);padding-top:18px}
.v3-hero{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:22px;padding:16px 0 18px;border-bottom:1px solid var(--v3-line)}
.v3-hero .v3-eyebrow{font-size:10px}
.v3-hero h1{max-width:none;margin:4px 0 4px;font-size:clamp(32px,4vw,42px);line-height:1;letter-spacing:-.045em}
.v3-hero p{max-width:760px;font-size:14px;line-height:1.55}
.v3-hero .v3-primary{min-width:176px;min-height:46px;width:auto;padding:0 18px;border-radius:12px;box-shadow:0 10px 26px rgba(20,113,205,.16)}

.v3-system-deck{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;padding:16px 0 8px}
.v3-system-stat{min-width:0;display:grid;gap:4px;padding:13px 14px;border:1px solid var(--v3-line);border-radius:14px;background:linear-gradient(145deg,var(--v3-panel-2),var(--v3-panel))}
.v3-system-stat>span{color:var(--v3-dim);font-size:10px;font-weight:950;letter-spacing:.11em}
.v3-system-stat>strong{font-size:20px;line-height:1.05;letter-spacing:-.025em}
.v3-system-stat>small{color:var(--v3-muted);font-size:11px;line-height:1.35}
.v3-system-stat.is-safe>strong{color:var(--v3-mint)}

.v3-system-section-head{display:flex;align-items:end;justify-content:space-between;gap:16px;padding:22px 0 8px}
.v3-system-section-head>div{display:grid;gap:3px}
.v3-system-section-head span{color:var(--v3-blue);font-size:10px;font-weight:950;letter-spacing:.12em}
.v3-system-section-head h2{margin:0;font-size:24px;letter-spacing:-.035em}
.v3-system-section-head>small{color:var(--v3-muted);font-size:12px}

.v3-dashboard-bar{padding:0 0 12px}
.v3-tabs{padding:4px;border-radius:12px}
.v3-tabs button{min-height:40px;padding:0 14px;font-size:12px}
.v3-tabs button b{font-size:11px}
.v3-connection{font-size:11px}
.v3-connection small{font-size:11px}

.v3-drafts{gap:10px}
.v3-automation-card{gap:12px;padding:15px 16px;border-radius:15px;box-shadow:0 14px 38px color-mix(in srgb,var(--v3-bg) 55%,transparent)}
.v3-card-head small{font-size:10px}
.v3-card-head strong{font-size:18px}
.v3-card-head em{font-size:10px}
.v3-automation-card>p{font-size:13px;line-height:1.5}
.v3-mini-flow>span{padding:9px 10px}
.v3-mini-flow i{font-size:9px}
.v3-mini-flow b{font-size:11px}
.v3-card-foot{font-size:10px}

.v3-template-section{margin-top:30px;padding:16px 0 8px;border-top:1px solid var(--v3-line);border-bottom:0}
.v3-section-title{align-items:end;margin-bottom:10px}
.v3-section-title span{font-size:10px}
.v3-section-title h2{font-size:20px}
.v3-section-title>small{font-size:11px}
.v3-template-strip{gap:8px;padding-bottom:5px}
.v3-template{flex-basis:250px;min-height:128px;gap:6px;padding:13px 14px;border-radius:14px;box-shadow:none}
.v3-template>span{font-size:9px}
.v3-template>strong{font-size:15px}
.v3-template>small{font-size:11px;line-height:1.42}
.v3-template>b{font-size:10px}

/* Builder hierarchy */
.v3-lab-pill{font-size:10px}
.v3-theme{font-size:10px}
.v3-editor-title-row{grid-template-columns:40px minmax(0,1fr) 56px;padding-top:10px;padding-bottom:9px}
.v3-close,.v3-save{min-height:40px}
.v3-save{font-size:11px}
.v3-title-button>span{font-size:9px}
.v3-title-button>strong{font-size:16px}
.v3-title-button>small{font-size:11px}

.v3-stage-rail{gap:7px;padding-bottom:11px}
.v3-stage-rail button{min-height:48px;padding:7px 10px}
.v3-stage-rail button>b{width:28px;height:28px;font-size:10px}
.v3-stage-rail small{font-size:9px;letter-spacing:.07em}
.v3-stage-rail strong{font-size:11px}

.v3-editor-shell{padding-top:20px}
.v3-step-context{justify-content:flex-end;margin:3px 0 8px}
.v3-step-context>span{display:none}
.v3-step-context small{font-size:11px}
.v3-stage-section{gap:15px}
.v3-stage-section>header{padding:2px 0 14px}
.v3-stage-section>header>span{font-size:10px}
.v3-stage-section>header h2{margin:5px 0 6px;font-size:clamp(29px,4vw,36px);line-height:1.02;letter-spacing:-.04em}
.v3-stage-section>header p{max-width:720px;font-size:14px;line-height:1.5}

/* Cards and controls should never whisper. */
.v3-choice>b{font-size:10px}
.v3-choice strong{font-size:15px}
.v3-choice small{font-size:12px;line-height:1.42}
.v3-info-card>span{font-size:10px}
.v3-info-card>strong{font-size:14px}
.v3-info-card>p{font-size:12px}
.v3-always-card strong{font-size:14px}
.v3-always-card small{font-size:12px}
.v3-rule-mode>span{font-size:11px}
.v3-rule-mode button,.v3-add-rule button{min-height:38px;font-size:10px}
.v3-rule-join{font-size:9px}
.v3-rule-card>b{font-size:9px}
.v3-rule-card strong{font-size:13px}
.v3-rule-card small{font-size:11px}
.v3-add-rule>span{font-size:10px}

.v3-action-rail>span{font-size:9px}
.v3-action-type small{font-size:9px}
.v3-action-type strong{font-size:15px}
.v3-action-controls button{width:32px;height:32px;font-size:11px}
.v3-target-button>span{font-size:9px}
.v3-target-button>strong{font-size:12px}
.v3-target-button>b{font-size:10px}
.v3-action-fields label>span,.v3-details-modal label>span,.v3-precision-card label>span,.v3-custom-repeat label>span,.v3-repeat-zone>span,.v3-picker-search>span{font-size:10px}
.v3-action-fields textarea{font-size:14px;line-height:1.5}
.v3-add-action strong{font-size:13px}
.v3-add-action small{font-size:11px}
.v3-saved-action-body span{font-size:9px}
.v3-saved-action-body strong{font-size:11px}
.v3-saved-action-body p,.v3-saved-action-body a{font-size:11px}

.v3-time-dot>b{font-size:9px}
.v3-time-dot>small{font-size:10px}
.v3-timeline-preview>u>em{font-size:9px}
.v3-timing-modes button strong{font-size:13px}
.v3-timing-modes button small{font-size:11px}
.v3-precision-head small{font-size:9px}
.v3-precision-head strong{font-size:14px}
.v3-precision-head button{min-height:34px;font-size:10px}
.v3-precision-card input,.v3-precision-card select,.v3-custom-repeat input,.v3-custom-repeat select,.v3-repeat-zone select{font-size:13px}
.v3-repeat-card>div:first-child span{font-size:9px}
.v3-repeat-card>div:first-child strong{font-size:14px}
.v3-repeat-pills button{min-height:36px;font-size:10px}

/* Live Flow is a primary system panel, not tiny auxiliary copy. */
.v3-live-panel{padding:16px}
.v3-live-head span,.v3-live-summary>span{font-size:10px}
.v3-live-head small{font-size:10px}
.v3-flow-node{grid-template-columns:56px minmax(0,1fr);padding:11px 12px}
.v3-flow-node>span{font-size:9px}
.v3-flow-node strong{font-size:12px}
.v3-flow-node small{font-size:10px;line-height:1.4}
.v3-flow-line{margin-left:28px}
.v3-live-summary p{font-size:11px;line-height:1.5}

.v3-review-heading small{font-size:9px}
.v3-review-heading>span>strong{font-size:16px}
.v3-review-heading>em{font-size:9px}
.v3-sim-node>b{font-size:9px}
.v3-sim-node strong{font-size:12px}
.v3-sim-node small{font-size:10px}
.v3-sim-log>span{font-size:9px}
.v3-sim-log p,.v3-sim-log strong{font-size:10px}
.v3-finish-card>span,.v3-check-card>span{font-size:9px}
.v3-finish-card h3{font-size:15px}
.v3-finish-card button strong{font-size:11px}
.v3-finish-card button small{font-size:10px}
.v3-check-card p{font-size:10px}

.v3-mobile-flow-toggle small{font-size:9px}
.v3-mobile-flow-toggle strong{font-size:11px}

@media (min-width:700px){
  .v3-dashboard{padding-top:20px}
  .v3-hero{padding-top:18px}
  .v3-template{flex-basis:245px}
}

@media (min-width:980px){
  .v3-editor-shell{grid-template-columns:minmax(0,1fr) 350px;gap:28px;padding-top:20px}
  .v3-editor-main{max-width:760px}
  .v3-stage-section>header h2{font-size:36px}
  .v3-live-panel{top:190px;max-height:calc(100dvh - 214px)}
  .v3-editor-footer>div{width:min(1180px,calc(100% - 48px));display:flex;justify-content:flex-end;gap:8px}
  .v3-editor-footer button{min-width:118px;padding:0 20px}
  .v3-footer-primary{min-width:174px}
}

@media (max-width:760px){
  .v3-dashboard{padding-top:12px}
  .v3-hero{grid-template-columns:1fr;gap:13px;padding:12px 0 15px}
  .v3-hero h1{font-size:34px}
  .v3-hero p{font-size:14px}
  .v3-hero .v3-primary{width:100%;min-height:48px}
  .v3-system-deck{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;padding-top:12px}
  .v3-system-stat{padding:12px}
  .v3-system-stat>strong{font-size:18px}
  .v3-system-stat>small{font-size:10px}
  .v3-system-section-head{align-items:start;padding-top:18px}
  .v3-system-section-head>small{display:none}
  .v3-template-section{margin-top:24px}
  .v3-template{flex-basis:min(76vw,270px)}
  .v3-stage-section>header h2{font-size:30px}
  .v3-stage-section>header p{font-size:14px}
  .v3-stage-rail button{min-width:104px}
  .v3-choice strong{font-size:15px}
  .v3-choice small{font-size:12px}
  .v3-action-fields textarea,.v3-details-modal input,.v3-details-modal textarea,.v3-precision-card input,.v3-precision-card select,.v3-custom-repeat input,.v3-custom-repeat select,.v3-repeat-zone select,.v3-picker-search input{font-size:16px}
}

@media (max-width:430px){
  .v3-system-deck{grid-template-columns:1fr 1fr}
  .v3-system-stat>span{font-size:9px}
  .v3-mini-flow{display:grid;grid-template-columns:1fr;gap:5px}
  .v3-mini-flow>span{padding:9px}
  .v3-mini-flow i{font-size:9px}
  .v3-mini-flow b{font-size:11px;white-space:normal}
}
