#tide-app .tf-flow-dialog{position:fixed;inset:0;margin:auto;width:min(410px,calc(100vw - 32px));max-height:calc(100dvh - 40px);padding:32px 26px;border:1px solid var(--tf-line);border-radius:30px;background:var(--tf-paper);color:var(--tf-ink);box-shadow:0 24px 80px #0003;overflow:auto}
#tide-app .tf-flow-dialog::backdrop{background:#112b3e66;backdrop-filter:blur(5px);opacity:1;transition:opacity 180ms var(--tf-ease)}
#tide-app .tf-flow-dialog[data-flow-phase="closing"]::backdrop{opacity:0}
@starting-style{#tide-app .tf-flow-dialog[data-flow-phase="open"]::backdrop{opacity:0}}
#tide-app .tf-flow-dialog h2{font-size:22px;line-height:1.4;font-weight:550;margin:8px 28px 18px 0}
#tide-app .tf-flow-dialog p{font-size:14px;line-height:1.7;color:var(--tf-muted);margin:12px 0}
#tide-app .tf-flow-dialog label{display:block;font-size:13px;color:var(--tf-muted);margin:20px 0 10px}
#tide-app .tf-flow-dialog input,#tide-app .tf-flow-dialog select{display:block;width:100%;min-height:48px;margin-top:9px;padding:12px;border:1px solid var(--tf-line);border-radius:14px;background:var(--tf-recent);color:var(--tf-ink);font:inherit;font-size:16px;box-sizing:border-box}
#tide-app .tf-flow-primary{width:100%;min-height:48px;padding:12px!important;border-radius:16px;background:var(--tf-card)!important;color:var(--tf-card-ink)!important;margin-top:10px;font-size:15px!important}
#tide-app .tf-flow-close{position:absolute;right:14px;top:14px;width:44px;height:44px;display:grid;place-items:center;border-radius:50%;background:var(--tf-recent)!important}
#tide-app .tf-flow-eyebrow{font:24px Georgia,serif!important;letter-spacing:.08em;color:var(--tf-ink)!important}
#tide-app .tf-form-error{color:light-dark(#9e3c32,#ffa69a)!important;min-height:1em}
#tide-app .tf-login-note{display:block;line-height:1.6;color:var(--tf-muted);margin-top:16px}
#tide-app .tf-login-form label[hidden]{display:none}
#tide-app .tf-add-menu{position:absolute;z-index:40;width:236px;padding:7px;color:var(--tf-ink);isolation:isolate}
#tide-app .tf-add-menu[hidden]{display:none}
#tide-app .tf-add-menu-glass{position:absolute;inset:0;z-index:-1;transform-origin:0 0;border:.6px solid var(--tf-glass-edge);background:light-dark(#f6f6f0d9,#213847e8);box-shadow:0 12px 30px var(--tf-shadow),inset 0 1px 2px light-dark(#fffffff2,#ecfaff90);backdrop-filter:saturate(1.8) blur(18px);-webkit-backdrop-filter:saturate(1.8) blur(18px)}
#tide-app .tf-add-menu[data-moving="true"] .tf-add-menu-glass{will-change:transform}
#tide-app .tf-add-menu-seed{position:absolute;display:grid;place-items:center;pointer-events:none}
#tide-app .tf-add-menu-seed svg{width:24px;height:24px;stroke-width:1.6}
#tide-app .tf-add-menu-content{position:relative}
#tide-app .tf-add-menu button{display:flex;align-items:center;justify-content:space-between;gap:18px;width:100%;min-height:58px;padding:12px 17px!important;border-radius:21px;font-size:15px!important;text-align:left}
#tide-app .tf-add-menu button svg{width:21px;height:21px;stroke-width:1.6}
#tide-app .tf-add-menu button.is-selected,#tide-app:not([data-pointer-input]) .tf-add-menu button:focus-visible{background:var(--tf-card)!important;color:var(--tf-card-ink)!important}
#tide-app.is-shared .tf-plus{touch-action:none;-webkit-touch-callout:none}
#tide-app .tf-plus.is-menu-open{opacity:0}
#tide-app .tf-upload-caption{line-height:1.5;overflow-wrap:anywhere}
#tide-app .tf-upload-actions{display:flex;flex-wrap:wrap;gap:4px 12px}
#tide-app .tf-upload-actions button{font-size:12px!important;min-height:44px;padding:6px 0!important;color:var(--tf-muted)!important;text-decoration:underline;text-underline-offset:4px}
#tide-app .tf-upload-actions button[data-upload-action="retry"],#tide-app .tf-upload-actions button[data-upload-action="upload"]{color:var(--tf-ink)!important;font-weight:600}
#tide-app .tf-side-actions,#tide-app .tf-signout{min-height:44px;display:block;margin:8px 0;color:inherit;opacity:.8;font-size:13px!important}
#tide-app .tf-action-row{padding:15px 0;border-bottom:1px solid var(--tf-line);display:flex;gap:14px;align-items:center;justify-content:space-between;font-size:14px;line-height:1.5}
#tide-app .tf-action-row small{display:block;color:var(--tf-muted);font-size:11px}
#tide-app .tf-action-row button{min-height:44px;min-width:60px;border-radius:14px;background:var(--tf-recent)!important}
#tide-app.is-shared .tf-account-detail{line-height:1.8}
#tide-app button:disabled{opacity:.45}
#tide-app .tf-resume{display:flex;align-items:center;justify-content:space-between;gap:12px;width:calc(100% - 16px);min-height:48px;margin:-10px 8px 24px;padding:8px 0!important;border-bottom:1px solid var(--tf-line)!important;text-align:left;font-size:13px!important}
#tide-app .tf-resume svg,#tide-app .tf-empty-continue svg{width:18px!important;height:18px!important;flex-shrink:0;transform:rotate(180deg)}
#tide-app .tf-unfinished-empty .tf-empty-symbol{position:relative;isolation:isolate;background:var(--tf-cream);color:var(--tf-icon);transform:rotate(-6deg)}
#tide-app .tf-unfinished-empty .tf-empty-symbol::before{content:"";position:absolute;inset:-3px -6px 3px 6px;border-radius:inherit;background:var(--tf-recent);transform:rotate(12deg);z-index:-1}
#tide-app .tf-unfinished-empty .tf-empty-symbol::after{content:"";position:absolute;inset:0;border-radius:inherit;background:var(--tf-cream);z-index:-1}
#tide-app .tf-unfinished-empty>span{display:block}
#tide-app .tf-empty-continue{display:inline-flex;align-items:center;justify-content:center;gap:10px;min-height:44px;margin-top:15px;padding:6px 8px!important;color:var(--tf-ink)!important}
#tide-app .tf-empty-continue span{font-size:14px;color:inherit}
/* A separate task owns the screen. Navigation returns with its original state. */
#tide-app .tf-footer{gap:20px}
#tide-app .is-entry-task .tf-footer{opacity:0;visibility:hidden;pointer-events:none}
#tide-app .is-entry-task .tf-footer>*{pointer-events:none}
#tide-app .tf-import{z-index:30;inset:0;width:100%;height:100%;max-width:none;max-height:none;padding:calc(20px + env(safe-area-inset-top)) 24px calc(28px + env(safe-area-inset-bottom));background:var(--tf-paper);border-radius:0;box-sizing:border-box}
#tide-app .tf-import[open]{display:flex;flex-direction:column;align-content:normal}
#tide-app .keyboard-open .tf-import{bottom:0}
#tide-app .tf-import-head{display:grid;grid-template-columns:44px minmax(0,1fr) 44px;gap:12px;flex-shrink:0;margin:0 0 28px}
#tide-app .tf-import-head h2{grid-column:2;grid-row:1;text-align:center;font-size:19px;font-weight:550;letter-spacing:-.02em;margin:0}
#tide-app .tf-import-close{grid-column:1;grid-row:1}
#tide-app .tf-import-back,#tide-app .tf-flow-choose{grid-column:3;grid-row:1}
#tide-app .tf-import-head button{display:grid;place-items:center;width:44px;height:44px;margin:0;padding:0!important;border-radius:50%;background:var(--tf-recent)!important}
#tide-app .tf-import-head button svg{width:21px;height:21px;stroke-width:1.6}
#tide-app .tf-import-source{flex:1;display:flex;flex-direction:column;justify-content:center;padding:16px 0 64px;min-height:min-content}
#tide-app .tf-source-summary>.tf-source-choose{display:none}
#tide-app .tf-upload-overview{text-align:center;padding:16px 0 0}
#tide-app .tf-upload-overview h3{font-size:22px;font-weight:550;letter-spacing:-.025em;line-height:1.5;margin:0}
#tide-app .tf-upload-overview[data-processing="true"] h3:before{content:"";display:inline-block;width:13px;height:13px;margin-right:10px;border:1.5px solid var(--tf-line);border-top-color:var(--tf-ink);border-radius:50%;animation:tf-upload-turn 1s linear infinite}
#tide-app.is-shared .tf-source-summary{display:block;text-align:center;margin:8px 0 16px}
#tide-app.is-shared .tf-source-description{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
#tide-app .tf-source-toggle{display:inline-flex;align-items:center;gap:9px;min-height:44px;padding:8px!important;font-size:13px!important;color:var(--tf-muted)!important}
#tide-app .tf-source-toggle:after{content:"";width:6px;height:6px;border-right:1.5px solid currentColor;border-bottom:1.5px solid currentColor;transform:translateY(-2px) rotate(45deg)}
#tide-app .tf-source-toggle[aria-expanded="true"]:after{transform:translateY(2px) rotate(225deg)}
#tide-app.is-shared .tf-source-gallery{display:flex;flex-direction:column;gap:0;border-top:1px solid var(--tf-line)}
#tide-app.is-shared .tf-source-shot{display:grid;grid-template-columns:56px minmax(0,1fr) 44px;grid-template-rows:auto auto;column-gap:14px;padding:16px 0;border-bottom:1px solid var(--tf-line);align-items:center}
#tide-app.is-shared .tf-source-preview{grid-row:1/3;width:56px;height:72px;border-radius:10px;box-shadow:0 3px 8px var(--tf-shadow)}
#tide-app.is-shared .tf-source-shot figcaption{font-size:13px;line-height:1.55;padding:0;color:var(--tf-ink)}
#tide-app.is-shared .tf-upload-actions{grid-column:2;grid-row:2}
#tide-app .tf-upload-discard{grid-column:3;grid-row:1/3;width:44px;height:44px;font-size:22px!important;color:var(--tf-muted)!important;font-weight:300!important}
#tide-app .tf-flight-plane{z-index:35}
#tide-app .tf-import-departure{position:absolute;pointer-events:none;transform-origin:center}
@keyframes tf-upload-turn{to{transform:rotate(360deg)}}
@media(max-width:380px){#tide-app .tf-footer{gap:16px}#tide-app .tf-import{padding-left:18px;padding-right:18px}#tide-app .tf-import-head{gap:8px}}
@media(max-height:650px){#tide-app .tf-flow-dialog{padding:20px}#tide-app .tf-import-head{margin-bottom:20px}#tide-app .tf-import-source{padding:12px 0 24px}#tide-app .tf-import-pager{margin-top:10px}}
@media(prefers-reduced-motion:reduce){#tide-app .tf-flow-dialog::backdrop{transition-duration:100ms}#tide-app .tf-upload-overview h3:before{animation:none}}

/* The empty picker and the review cards use the same TIDE paper and tide blue. */
#tide-app .tf-source-empty { display:grid; place-items:center; padding:0; --print-shadow:var(--tf-shadow); --pick-blue:light-dark(#205c7a,#27536c); }
#tide-app .tf-source-empty > .tf-source-art { display:none; }
#tide-app .tf-source-empty > .tf-source-choose,
#tide-app .tf-source-empty > .tf-picker-stack { grid-area:1/1; }
#tide-app .tf-source-empty > .tf-source-choose {
  display:grid; place-items:center; width:196px; height:196px; padding:0!important; margin:0;
  border-radius:36px; background:transparent!important; font-size:0!important; cursor:pointer;
}
#tide-app .tf-source-empty > .tf-source-choose:focus-visible { outline:3px solid var(--tf-ink); outline-offset:4px; }
#tide-app .tf-picker-stack {
  position: relative;
  width: 156px;
  height: 158px;
  pointer-events: none;
}

#tide-app .tf-picker-back,
#tide-app .tf-picker-print {
  position: absolute;
  left: 9px;
  top: 9px;
  width: 132px;
  height: 137px;
  border-radius: 20px;
  box-shadow: 0 6px 16px var(--print-shadow);
  transition: transform 180ms var(--tf-ease);
}

#tide-app .tf-picker-back {
  background: light-dark(#aecbd3, #466b7b);
  transform: translate(-6px, -3px) rotate(-10deg);
}

#tide-app .tf-picker-print {
  display: grid;
  padding: 9px 9px 18px;
  background: var(--tf-cream);
  transform: translate(2px, 1px) rotate(4deg);
  box-shadow: inset 0 1px 1px #fff9, 0 5px 12px var(--print-shadow);
}

#tide-app .tf-picker-picture {
  position: relative;
  overflow: hidden;
  border-radius: 12px;
  background: linear-gradient(165deg,#aeced6,#c9dbd9);
}

#tide-app .tf-picker-sun {
  position: absolute;
  width: 19px;
  height: 19px;
  top: 17px;
  right: 19px;
  border-radius: 50%;
  background: #faf0ce;
}

#tide-app .tf-picker-far,
#tide-app .tf-picker-near {
  position: absolute;
  inset: 0;
}

#tide-app .tf-picker-far {
  background: #72a0a9;
  clip-path: polygon(0 100%,0 80%,32% 47%,57% 72%,78% 54%,100% 77%,100% 100%);
}

#tide-app .tf-picker-near {
  background: #3b7588;
  clip-path: polygon(0 100%,0 90%,21% 71%,39% 85%,64% 59%,100% 89%,100% 100%);
}

#tide-app .tf-picker-add {
  position: absolute;
  right: -2px;
  bottom: 3px;
  display: grid;
  place-items: center;
  width: 53px;
  height: 53px;
  border: 3px solid var(--tf-paper);
  border-radius: 50%;
  background: var(--pick-blue);
  color: #fff;
  box-shadow: 0 3px 6px var(--print-shadow);
  transition: transform 180ms var(--tf-ease);
}

#tide-app .tf-picker-add svg { width: 25px; height: 25px; stroke-width: 2; }


@media (hover:hover) and (prefers-reduced-motion:no-preference) {
  #tide-app .tf-source-choose:hover + .tf-picker-stack .tf-picker-print { transform:translate(3px,-2px) rotate(2deg); }
  #tide-app .tf-source-choose:hover + .tf-picker-stack .tf-picker-add { transform:translateY(-2px); }
}
#tide-app .tf-source-choose:active + .tf-picker-stack { transform:scale(.97); }
#tide-app .tf-import[data-stage="cards"] { overflow:hidden; }
#tide-app .tf-review-content {
  flex:1 1 0; min-height:0; display:flex; flex-direction:column; overflow-y:auto; overflow-x:hidden; overscroll-behavior:contain;
  --task-inset:24px;
  margin-inline:calc(-1 * var(--task-inset)); padding:12px var(--task-inset) 10px; scrollbar-width:none;
}
#tide-app .tf-review-content {
  --review-height:clamp(278px,36dvh,312px);
}
#tide-app .tf-review-content::before {
  content:""; flex:0 0 max(0px,calc((100dvh - var(--review-height) - 220px) / 2));
}
#tide-app .tf-review-content:has(.tf-review-end:not([hidden])) { justify-content:safe center; }
#tide-app .tf-review-content:has(.tf-review-end:not([hidden]))::before { display:none; }
#tide-app .tf-review-end { display:grid; justify-items:center; gap:16px; }
#tide-app .tf-review-next { min-height:44px; padding-inline:22px; border-radius:16px; background:var(--tf-recent); color:var(--tf-recent-ink); }
#tide-app .tf-review-reason { display:flex; align-items:center; justify-content:center; gap:6px; max-width:100%; }
#tide-app .tf-review-reason:has(.tf-card-reasons[hidden]) { display:none; }
#tide-app .tf-review-source { flex:none; min-height:44px; padding-inline:6px; font-size:13px; color:var(--tf-card-ink); }
#tide-app .tf-review-reason .tf-card-reasons { width:auto; }

#tide-app .tf-import-preview-note { text-align:center; margin:0 0 12px!important; }
#tide-app .tf-import-deck {
  height:var(--review-height); flex:none;
  margin:0 calc(-1 * var(--task-inset)); padding-inline:calc(var(--task-inset) - 12px); overflow-x:clip;
}
#tide-app .tf-import-page { height:100%; }
#tide-app .tf-import-card {
  height:100%; padding:24px 18px; justify-content:center; gap:8px;
}
#tide-app .tf-import-card .tf-figure { flex:none; width:68px; height:72px; margin:0 0 6px; }
#tide-app .tf-import-card h3 { margin:0; }
#tide-app .tf-import-name::before { content:""; flex:0 0 15px; }
#tide-app .tf-import-name-text { min-width:0; }
#tide-app .tf-import-name > svg { width:15px; height:15px; flex:0 0 15px; color:var(--tf-card-sub); }
#tide-app .tf-card-reasons {
  width:min(100%,28em); font-size:12px!important; line-height:1.45; text-align:center;
  max-height:3em; overflow-y:auto; overflow-wrap:anywhere; margin:0!important;
}
#tide-app .tf-review-one { min-height:44px; padding:0 18px!important; border-radius:16px; background:var(--tf-cream)!important; color:var(--tf-icon)!important; font-size:14px!important; }
#tide-app .tf-import-card .tf-join {
  min-height:44px; padding:0 22px!important; border-radius:16px;
  box-shadow:inset 0 0 0 1px color-mix(in srgb,var(--tf-card-ink) 55%,transparent);
  color:var(--tf-card-ink)!important; font-size:14px!important; font-weight:600;
}
#tide-app .tf-import-card .tf-join:active { background:color-mix(in srgb,var(--tf-card-ink) 12%,transparent)!important; }
#tide-app .tf-card-tools { position:absolute; inset:6px 8px auto auto; z-index:3; }
#tide-app .tf-card-tools summary {
  list-style:none; margin-left:auto; width:44px; height:44px; border-radius:50%; display:grid;
  place-items:center; cursor:pointer; font-size:13px; letter-spacing:2px;
}
#tide-app .tf-card-tools summary::-webkit-details-marker { display:none; }
#tide-app .tf-card-tools[open] summary { background:#ffffff22; }
#tide-app .tf-card-menu {
  position:absolute; right:0; top:44px; padding:4px; min-width:142px; border-radius:17px;
  background:var(--tf-paper); color:var(--tf-ink); box-shadow:0 6px 24px var(--tf-shadow);
}
#tide-app .tf-card-menu button {
  display:block; width:100%; min-height:44px; position:static; padding:0 14px!important; margin:0;
  text-align:start; font-size:14px!important; font-weight:500!important; background:transparent!important;
  color:var(--tf-ink)!important; opacity:1; cursor:pointer; border-radius:12px;
}
#tide-app .tf-card-menu button:focus-visible { outline:2px solid var(--tf-ink); }
#tide-app .tf-card-menu .tf-import-remove { color:light-dark(#994e3d,#eba99a)!important; }
#tide-app .tf-import-pager { justify-content:center; min-height:44px; margin:8px 0 0; flex-shrink:0; }
#tide-app .tf-import-dots { display:flex; align-items:center; max-width:100%; }
#tide-app .tf-import-dot { width:32px; height:44px; display:grid; place-items:center; border-radius:12px; }
#tide-app .tf-import-dot::after { content:""; width:6px; height:6px; border-radius:6px; background:var(--tf-muted); opacity:.65; }
#tide-app .tf-import-dot[data-more]::after { width:4px; height:4px; }
#tide-app .tf-import-dot[aria-current="true"]::after { width:16px; background:var(--tf-ink); opacity:1; }
#tide-app .tf-batch-bar { order:2; flex:none; display:grid; justify-items:stretch; gap:7px; margin:0 auto; padding-top:6px; width:min(100%,392px); }
#tide-app .tf-batch-pending { text-align:center; color:var(--tf-muted); font-size:12px; }
#tide-app .tf-batch-bar .tf-join-all {
  width:100%; min-height:54px; margin:0; border-radius:20px; cursor:pointer;
  color:#fff!important; background:light-dark(#245975,#325f79)!important; font-size:16px!important; font-weight:600;
}
#tide-app .tf-batch-bar .tf-join-all:disabled { opacity:.65; }
#tide-app .tf-import-back.needs-attention { position:relative; }
#tide-app .tf-import-back.needs-attention::after { content:""; position:absolute; right:6px; top:5px; width:7px; height:7px; border-radius:50%; background:var(--tf-ink); }
@media(max-width:380px) { #tide-app .tf-review-content { --task-inset:18px; } }
@media(max-height:480px) {
  #tide-app .tf-import[data-stage="cards"] { padding-block:6px max(6px,env(safe-area-inset-bottom)); }
  #tide-app .tf-import[data-stage="cards"] .tf-import-head { margin-bottom:0; }
  #tide-app .tf-review-content { --review-height:200px; }
  #tide-app .tf-import-card .tf-figure { width:48px; height:50px; margin:0; }
  #tide-app .tf-import-card { padding-block:10px; gap:2px; }
  #tide-app .tf-import-pager { margin-top:2px; }
}
@media(prefers-reduced-motion:reduce) {
  #tide-app .tf-source-choose:active + .tf-picker-stack { transform:none; }
  #tide-app .tf-picker-stack * { transition:none; }
}

#tide-app .tf-inline-error { color:light-dark(#9e3c32,#ffa69a); font-size:13px; line-height:1.5; padding:8px 18px; }
#tide-app .tf-inline-error:empty { display:none; }
#tide-app .tf-review-error { order:1; flex:none; }
#tide-app .tf-import[data-stage=source] .tf-review-error { display:none; }
