:root {
  font-family: "OPPO Sans", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: #171916;
  background: #f3f4f1;
  font-synthesis: none;
  --topbar-height: 74px;
  --android-status-bar: 0px;
  --android-cutout-top: 0px;
  --android-nav-bar: 0px;
  --app-safe-top: 0px;
  --app-safe-bottom: 0px;
}

/* LUT entry P0: keep the long formal tool name inside the shared two-column card. */
@media (max-width: 720px) {
  .open-tools .feature-card[data-tool-id="ai-color-lut"] strong {
    padding-right: 42px !important;
    white-space: normal !important;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
  }
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
body { margin: 0; min-width: 320px; background: radial-gradient(circle at 10% 0%, #fff 0, #f3f4f1 30%, #eceeea 100%); }
body.splash-active { overflow: hidden; }
button, input, textarea, a { font: inherit; }
button {
  color: inherit; -webkit-user-select: none; user-select: none;
  transition: transform .2s cubic-bezier(.2,.8,.2,1), box-shadow .2s, background-color .2s, opacity .2s;
}
button:active { transform: translateY(2px) scale(.96); }
button:focus-visible, input:focus-visible, textarea:focus-visible {
  outline: 2px solid rgba(44,255,115,.72); outline-offset: 3px;
}

.app { min-height: 100vh; }
.tool-hidden { display: none !important; }

.app-splash {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: grid;
  place-items: center;
  overflow: hidden;
  background:
    radial-gradient(circle at 52% 38%, rgba(44, 255, 115, .16), transparent 34%),
    radial-gradient(circle at 18% 22%, rgba(44, 255, 115, .08), transparent 28%),
    linear-gradient(145deg, #fbfdfb 0%, #f3f7f3 100%);
  transition: opacity 420ms ease, visibility 420ms ease;
}

.app-splash.is-hiding {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.app-splash-skip {
  position: fixed;
  top: calc(18px + var(--app-safe-top, env(safe-area-inset-top, 0px)));
  right: 18px;
  z-index: 2;
  min-width: 76px;
  height: 36px;
  padding: 0 14px;
  border: 1px solid rgba(14, 108, 62, .12);
  border-radius: 999px;
  color: rgba(11, 92, 52, .78);
  background: rgba(255, 255, 255, .72);
  box-shadow: 0 10px 30px rgba(22, 38, 24, .08);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
}

.app-splash-skip:active {
  transform: scale(.96);
}

.app-splash-inner {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
  gap: 12px;
  opacity: 0;
  transform: translateY(8px) scale(.98);
  animation: splashContentIn 620ms cubic-bezier(.2, .8, .2, 1) 90ms forwards;
}

.app-splash-logo {
  width: min(76vw, 520px);
  height: auto;
  filter: drop-shadow(0 24px 40px rgba(44, 255, 115, .22));
  animation: splashLogoPulse 1160ms ease-in-out 260ms infinite alternate;
}

.app-splash-copy {
  display: none;
  justify-items: center;
  gap: 5px;
  color: #101510;
  text-align: center;
  margin-top: -30px;
}

.app-splash-copy strong {
  font-size: 21px;
  font-weight: 700;
  letter-spacing: 0;
}

.app-splash-copy span {
  color: #00a94f;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .12em;
}

.app-splash-copy small {
  color: rgba(16, 21, 16, .58);
  font-size: 13px;
  letter-spacing: 0;
}

.app-splash-orbit {
  position: absolute;
  border-radius: 999px;
  border: 1px solid rgba(44, 255, 115, .18);
  background: rgba(255, 255, 255, .36);
  filter: blur(.2px);
  animation: splashOrbit 1800ms ease-in-out infinite alternate;
}

.app-splash-orbit-one { width: 220px; height: 220px; }
.app-splash-orbit-two { width: 340px; height: 340px; animation-delay: 180ms; opacity: .62; }

@keyframes splashContentIn {
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes splashLogoPulse {
  to {
    transform: translateY(-4px) scale(1.035);
    filter: drop-shadow(0 30px 48px rgba(44, 255, 115, .28));
  }
}

@keyframes splashOrbit {
  to { transform: scale(1.05); opacity: .72; }
}

@media (prefers-reduced-motion: reduce) {
  .app-splash,
  .app-splash-inner,
  .app-splash-logo,
  .app-splash-skip,
  .app-splash-orbit {
    animation: none !important;
    transition: opacity 180ms ease, visibility 180ms ease !important;
  }

  .app-splash-inner {
    opacity: 1;
    transform: none;
  }

  .launch-shell:not(.tool-hidden),
  .app:not(.tool-hidden) {
    animation: reducedPageFade var(--mdl-motion-normal) var(--mdl-ease-out) both !important;
    transform: none !important;
    filter: none !important;
  }

  .feature-card.tap-animating,
  .pending-tools .feature-card,
  .pending-section h2::after {
    animation: none !important;
    transform: none !important;
  }
}

@keyframes reducedPageFade {
  from { opacity: 0; }
  to { opacity: 1; }
}

.launch-shell:not(.tool-hidden), .app:not(.tool-hidden) { animation: pageIn .28s cubic-bezier(.2,.8,.2,1) both; }
@keyframes pageIn {
  from { opacity: 0; transform: translateY(10px) scale(.992); filter: blur(4px); }
  to { opacity: 1; transform: translateY(0) scale(1); filter: blur(0); }
}
.launch-shell {
  min-height: 100vh; padding: calc(18px + var(--android-status-bar)) 34px calc(34px + var(--android-nav-bar));
  display: grid; align-content: center; gap: 22px;
}
.launch-toolbar {
  width: min(960px, 100%); margin: 0 auto; display: flex; justify-content: flex-end; gap: 10px;
}
.launch-toolbar button {
  border: 0; border-radius: 999px; height: 38px; padding: 0 15px; cursor: pointer; font-size: 11px; font-weight: 500;
}
.launch-license-pill { color: #087b38; background: #eaf8ef; }
.settings-btn { color: #151815; background: #fff; box-shadow: 0 8px 22px rgba(25,31,25,.08); }
.launch-hero {
  width: min(960px, 100%); margin: 0 auto; padding: 34px; border-radius: 28px;
  background: linear-gradient(135deg, rgba(255,255,255,.94), rgba(240,255,246,.9));
  box-shadow: 0 24px 70px rgba(23,25,22,.1); border: 1px solid rgba(255,255,255,.8);
}
.launch-mark, .activation-logo {
  width: 58px; height: 58px; display: grid; place-items: center; border-radius: 18px; color: #fff;
  background: linear-gradient(145deg, #2CFF73 0%, #046a38 100%);
  font-size: 28px; font-weight: 700; box-shadow: inset 0 0 0 1px rgba(255,255,255,.28), 0 14px 30px rgba(4,106,56,.22);
}
.launch-hero p { margin: 22px 0 8px; color: #047336; font-size: 12px; font-weight: 700; letter-spacing: .1em; }
.launch-hero h1 { margin: 0; max-width: 620px; font-size: clamp(30px, 5.4vw, 54px); line-height: 1.12; letter-spacing: 0; }
.launch-hero small { display: block; margin-top: 18px; color: #8b9189; font-size: 12px; }
.author-link { border: 0; padding: 0; background: transparent; color: #656c64; cursor: pointer; font-size: 12px; }
.admin-mini-link {
  margin-left: 10px; padding: 5px 8px; border: 0; border-radius: 999px;
  color: #5c625b; background: rgba(20,24,20,.08); font-size: 10px; cursor: pointer;
}
.feature-grid {
  width: min(960px, 100%); margin: 0 auto; display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px;
}
.feature-card {
  min-height: 128px; padding: 17px; border: 1px solid #e3e7df; border-radius: 20px; text-align: left;
  background: rgba(255,255,255,.78); cursor: pointer; display: grid; align-content: space-between;
  box-shadow: 0 10px 28px rgba(28,34,28,.05);
}
.feature-card.available:hover, .settings-btn:hover, .export-btn:hover, .quiet-btn:hover, .back-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 34px rgba(24,30,24,.1);
}
.feature-card span { color: #8c938a; font-size: 10px; font-weight: 500; }
.feature-card strong { font-size: 18px; line-height: 1.25; }
.feature-card small { color: #9ca39a; font-size: 10px; line-height: 1.5; }
.feature-card.available { border-color: #2CFF73; background: linear-gradient(145deg, #2CFF73, #eafff1); color: #101510; }
.feature-card.available span, .feature-card.available small { color: rgba(16,21,16,.7); }
.feature-card.long-entry,
.feature-card.poster-entry,
.feature-card.cover-pro-entry {
  border-color: var(--ds-border);
  background: var(--ds-surface);
}
.feature-card.pending { cursor: not-allowed; }
.topbar {
  min-height: var(--topbar-height);
  padding: var(--android-status-bar) 34px 0; display: flex; align-items: center; justify-content: space-between;
  background: rgba(255,255,255,.88); border-bottom: 1px solid #e4e6e1; backdrop-filter: blur(20px);
  position: sticky; top: 0; z-index: 20;
}
.brand, .top-actions, .section-title, .upload-box, .range-row, .custom-color-row label { display: flex; align-items: center; }
.brand { gap: 10px; }
.brand-mark { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; color: #fff; background: linear-gradient(145deg,#2CFF73,#046a38); font-weight: 700; font-size: 18px; }
.back-btn {
  height: 34px; padding: 0 12px; border: 0; border-radius: 999px; background: #eef2ed;
  color: #485049; cursor: pointer; font-size: 11px; text-decoration: none; display: inline-flex; align-items: center;
}
.brand div { display: grid; gap: 2px; }
.brand strong { font-size: 17px; }
.brand small { color: #989d96; font-size: 11px; }
.top-actions { gap: 10px; }
.top-actions button, .top-actions a { border: 0; border-radius: 12px; height: 42px; padding: 0 18px; cursor: pointer; font-weight: 500; text-decoration: none; display: inline-flex; align-items: center; }
.license-badge { display: flex; align-items: center; gap: 7px; background: #f0f8f3; color: #176836; }
.license-badge span { width: 7px; height: 7px; border-radius: 50%; background: #08d862; box-shadow: 0 0 0 3px #d4f5e1; }
.license-badge b { font-size: 11px; font-weight: 500; }
.license-badge small { color: #73a184; font-size: 9px; }
.quiet-btn { background: #eff1ed; }
.export-btn { background: #111; color: #fff; display: flex; gap: 8px; align-items: center; }
.export-btn svg { width: 19px; fill: none; stroke: currentColor; stroke-width: 1.8; }

.workspace { display: grid; grid-template-columns: minmax(420px, 1fr) 430px; min-height: calc(100vh - var(--topbar-height) - var(--android-status-bar)); }
.preview-panel { min-width: 0; padding: 24px 32px 32px; position: sticky; top: calc(var(--topbar-height) + var(--android-status-bar)); height: calc(100vh - var(--topbar-height) - var(--android-status-bar)); display: flex; flex-direction: column; align-items: center; }
.preview-head { height: 30px; display: flex; justify-content: space-between; color: #777d75; font-size: 12px; }
.preview-head { width: 100%; }
.preview-head > div { display: flex; gap: 8px; align-items: center; }
.preview-guide-label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  max-width: 46%;
  padding: 3px 9px;
  border-radius: 999px;
  color: rgba(23, 25, 22, .58);
  background: rgba(20, 24, 20, .05);
  font-size: 11px;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.preview-guide-label em { font-style: normal; }
.status-dot { width: 7px; height: 7px; background: #08d765; border-radius: 50%; box-shadow: 0 0 0 4px #d9f8e7; }
.canvas-stage {
  flex: 0 0 auto; width: var(--stage-width, 100%); height: var(--stage-height, 640px);
  max-width: 100%; min-height: 0; padding: var(--stage-pad-y, 28px) var(--stage-pad-x, 28px);
  border-radius: 22px; background: #171917;
  background-image: radial-gradient(#31352f 1px, transparent 1px); background-size: 18px 18px;
  margin: auto;
  display: grid; place-items: center; position: relative; overflow: hidden; box-shadow: inset 0 0 0 1px rgba(255,255,255,.08), 0 16px 40px rgba(29,36,29,.12);
}
#coverCanvas {
  display: block; width: var(--canvas-css-width, auto); height: var(--canvas-css-height, auto);
  max-width: 100%; max-height: 100%; box-shadow: 0 18px 50px rgba(0,0,0,.48);
  cursor: grab; touch-action: pan-y;
}
#coverCanvas:active { cursor: grabbing; }
.crop-guide {
  position: absolute; pointer-events: none; display: flex;
  width: var(--canvas-display-width, 0); height: var(--canvas-display-height, 0);
  left: var(--canvas-display-left, 50%); top: var(--canvas-display-top, 50%);
  translate: -50% -50%; z-index: 3;
}
.crop-guide.portrait { flex-direction: column; }
.crop-guide.landscape { flex-direction: row; }
.crop-guide.official34 { flex-direction: column; }
.crop-shade { flex: 1; background: rgba(0,0,0,.22); }
.crop-safe-area { position: relative; flex: 0 0 auto; border: 2px dashed rgba(255,255,255,.92); filter: drop-shadow(0 1px 2px rgba(0,0,0,.55)); }
.crop-guide.portrait .crop-safe-area { width: 100%; height: 75%; }
.crop-guide.landscape .crop-safe-area { width: 75%; height: 100%; }
.crop-guide.official34 .crop-safe-area { width: 100%; height: 100%; }
.crop-safe-area b {
  position: absolute; top: 8px; left: 8px; padding: 4px 7px; border-radius: 5px;
  color: #fff; background: rgba(0,0,0,.62); font-size: clamp(7px, 1vw, 10px); font-weight: 500;
}
.crop-safe-area i {
  position: absolute; top: 8px; right: 8px; padding: 4px 7px; border-radius: 5px;
  color: #fff; background: rgba(0,0,0,.62); font-size: clamp(7px, 1vw, 10px); font-style: normal;
}
.focus-guide {
  position: absolute;
  left: var(--focus-left, 50%);
  top: var(--focus-top, 50%);
  width: var(--focus-width, 0);
  height: var(--focus-height, 0);
  translate: -50% -50%;
  border: 2px dashed rgba(44,255,115,.95);
  border-radius: 10px;
  box-shadow: 0 0 0 4px rgba(44,255,115,.12), 0 0 22px rgba(44,255,115,.42);
  pointer-events: none;
  opacity: 0;
  z-index: 6;
}
.focus-guide.show {
  opacity: 1;
  animation: focusGuidePulse 1.15s ease-in-out infinite;
}
@keyframes focusGuidePulse {
  0%, 100% { opacity: .58; scale: .985; }
  50% { opacity: 1; scale: 1.018; }
}
.canvas-tip { position: absolute; bottom: 14px; color: rgba(255,255,255,.55); background: rgba(0,0,0,.34); padding: 6px 12px; border-radius: 99px; font-size: 11px; pointer-events: none; transition: opacity .3s; }
.crop-safe-area b,
.crop-safe-area i,
.canvas-tip {
  display: none !important;
}

.editor-panel { border-left: 1px solid #e3e5e0; background: rgba(255,255,255,.82); padding: 8px 26px 42px; overflow: auto; }
.editor-section { padding: 24px 0; border-bottom: 1px solid #eceee9; }
.editor-section[hidden] { display: none !important; }
.section-title { gap: 11px; margin-bottom: 17px; }
.section-title > span { width: 28px; height: 28px; border-radius: 9px; background: #e7faee; color: #00a846; display: grid; place-items: center; font-size: 11px; font-weight: 700; }
.section-title div { display: grid; gap: 2px; }
.section-title strong { font-size: 15px; }
.section-title small { color: #9a9f98; font-size: 11px; }

.ratio-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.ratio-card { position: relative; min-height: 72px; display: flex; align-items: center; gap: 10px; text-align: left; border: 1px solid #e3e6e0; background: #fafbf9; border-radius: 13px; padding: 11px; cursor: pointer; }
.ratio-card.active { border-color: #2CFF73; background: #f2fff7; box-shadow: 0 0 0 2px rgba(44,255,115,.09); }
.ratio-card > span:nth-child(2) { display: grid; gap: 3px; }
.ratio-card strong { font-size: 13px; }
.ratio-card small { color: #979c95; font-size: 9px; white-space: nowrap; }
.ratio-card i { position: absolute; top: -7px; right: 8px; font-size: 9px; font-style: normal; color: #008d3c; background: #caffdf; padding: 2px 6px; border-radius: 9px; }
.ratio-card[data-ratio="official34"] { grid-column: 1 / -1; }
.ratio-shape { background: linear-gradient(145deg,#a8b0aa,#656a66); border-radius: 3px; flex: 0 0 auto; }
.ratio-shape.portrait { width: 25px; height: 34px; }
.ratio-shape.landscape { width: 36px; height: 27px; }
.ratio-shape.official { width: 28px; height: 37px; background: linear-gradient(145deg, #2CFF73, #046A38); }

.cover-template-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.cover-template-card {
  position: relative; min-height: 96px; padding: 12px; border: 1px solid #e3e6e0; border-radius: 15px;
  background: #fafbf8; cursor: pointer; text-align: left; display: grid; gap: 8px; overflow: hidden;
}
.cover-template-card::before {
  content: ""; position: absolute; right: 10px; top: 10px; width: 34px; height: 45px; border-radius: 6px;
  background: linear-gradient(160deg, rgba(44,255,115,.88), rgba(15,21,17,.88)); opacity: .9;
}
.cover-template-card > img {
  position: absolute; inset: 0 0 0 auto; width: 48%; height: 100%; object-fit: cover;
  opacity: .16; filter: saturate(.72); pointer-events: none;
}
.cover-template-card strong { position: relative; z-index: 1; font-size: 13px; }
.cover-template-card small { position: relative; z-index: 1; color: #8b9189; font-size: 10px; line-height: 1.45; max-width: 86%; }
.cover-template-card span { position: relative; z-index: 1; width: fit-content; padding: 3px 7px; border-radius: 999px; color: #057738; background: #e7faee; font-size: 9px; font-weight: 700; }
.cover-template-card em { position: relative; z-index: 1; color: #626960; font-style: normal; font-size: 9px; line-height: 1.45; }
.cover-template-card.active { border-color: #2CFF73; background: #f2fff7; box-shadow: 0 0 0 2px rgba(44,255,115,.09); }

.official-input-list { display: grid; gap: 12px; }
.official-input-field { display: grid; gap: 6px; }
.official-input-field label { color: #72786f; font-size: 11px; font-weight: 700; }
.official-input-field small { color: #9da39b; font-size: 10px; line-height: 1.5; }
.official-input-field em { margin-left: 6px; color: #a0a69e; font-style: normal; font-weight: 500; }
.official-input-field .text-input { width: 100%; }
.official-input-field input[type="range"] { width: 100%; accent-color: #2CFF73; }
.official-input-field output { justify-self: end; margin-top: -4px; color: #7b8279; font-size: 10px; font-weight: 700; }

.upload-box { gap: 11px; padding: 12px; border-radius: 13px; background: #f6f7f4; border: 1px dashed #cfd3cc; cursor: pointer; }
.upload-box > span:nth-child(2) { display: grid; gap: 2px; flex: 1; }
.upload-box strong { font-size: 13px; }
.upload-box small { color: #9a9f98; font-size: 10px; }
.upload-icon { width: 38px; height: 38px; border-radius: 10px; display: grid; place-items: center; background: white; box-shadow: 0 3px 10px rgba(0,0,0,.05); }
.upload-icon svg { width: 21px; fill: none; stroke: #3d443e; stroke-width: 1.6; }
.replace-text { font-size: 11px; color: #00ad4d; }
.range-row { gap: 12px; margin-top: 14px; font-size: 11px; color: #777d75; }
.range-row input { flex: 1; accent-color: #08d862; }
.range-row output { width: 34px; text-align: right; color: #232623; }
.atmosphere-range { position: relative; }
.atmosphere-popover {
  position: absolute; z-index: 12; left: 50%; bottom: 35px; width: calc(var(--atmo-width, 138px) + 14px); padding: 7px;
  translate: -50% 10px; opacity: 0; visibility: hidden; pointer-events: none;
  border-radius: 13px; background: rgba(20,23,20,.94); box-shadow: 0 12px 35px rgba(0,0,0,.3);
  transition: opacity .15s, translate .15s, visibility .15s;
}
.atmosphere-popover.show { opacity: 1; visibility: visible; translate: -50% 0; }
.atmosphere-popover::after {
  content: ""; position: absolute; left: 50%; bottom: -6px; translate: -50% 0;
  border: 6px solid transparent; border-top-color: rgba(20,23,20,.94); border-bottom: 0;
}
.atmosphere-popover canvas { display: block; width: var(--atmo-width, 138px); height: var(--atmo-height, 102px); object-fit: contain; border-radius: 8px; background: #333; }
.atmosphere-popover b {
  position: absolute; right: 12px; bottom: 12px; padding: 3px 6px; border-radius: 5px;
  color: #fff; background: rgba(0,0,0,.68); font-size: 9px;
}

.field-label { display: flex; justify-content: space-between; color: #6e746d; font-size: 11px; margin: 13px 0 7px; }
.field-label em { font-style: normal; color: #a3a7a1; }
.text-input { width: 100%; border: 1px solid #dee2db; background: #f9faf8; border-radius: 11px; padding: 11px 13px; outline: 0; font-size: 13px; transition: .2s; }
.text-input:focus { background: #fff; border-color: #11d868; box-shadow: 0 0 0 3px rgba(17,216,104,.1); }
.title-input { resize: vertical; line-height: 1.6; }
.field-help { margin: 6px 2px 0; font-size: 10px; color: #a1a69f; }
.field-warning { margin: 6px 2px 0; font-size: 10px; color: #e1342f; font-weight: 500; }

.recommend-head { display: flex; justify-content: space-between; margin-bottom: 11px; font-size: 11px; color: #727771; }
.recommend-head button { border: 0; background: transparent; color: #00a94a; font-size: 10px; cursor: pointer; }
.color-list { display: grid; grid-template-columns: repeat(5, 1fr); gap: 9px; }
.color-choice { position: relative; aspect-ratio: 1; border: 0; border-radius: 12px; cursor: pointer; box-shadow: inset 0 0 0 1px rgba(0,0,0,.08); }
.color-choice.active::after { content: "✓"; position: absolute; inset: 0; display: grid; place-items: center; color: var(--check-color, #fff); font-size: 18px; font-weight: 700; }
.color-choice small { position: absolute; top: calc(100% + 4px); left: 50%; translate: -50% 0; font-size: 8px; color: #959a93; white-space: nowrap; }
.custom-color-row { margin-top: 28px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(96px, 132px) 38px; gap: 10px; align-items: center; padding: 11px 12px; background: #f7f8f5; border-radius: 12px; }
.custom-color-row label { gap: 10px; cursor: pointer; }
.custom-color-row label > span:nth-child(2) { display: grid; gap: 2px; }
.custom-color-row strong { font-size: 12px; }
.custom-color-row small { font-size: 9px; color: #929790; text-transform: uppercase; }
.custom-swatch { width: 30px; height: 30px; border-radius: 50%; background: #2CFF73; box-shadow: inset 0 0 0 1px rgba(0,0,0,.1); }
.custom-color-row input[type="color"] { width: 34px; height: 34px; padding: 0; border: 0; background: transparent; cursor: pointer; }
.color-value-input { display: grid; gap: 5px; min-width: 0; }
.color-value-input span { color: #8b9189; font-size: 8px; font-weight: 700; }
.color-value-input input {
  width: 100%; height: 30px; border: 1px solid rgba(0,0,0,.08); border-radius: 9px; padding: 0 8px;
  background: rgba(255,255,255,.78); color: #151815; font-size: 10px; font-weight: 700; outline: none;
}
.color-value-input input:focus { border-color: #2CFF73; box-shadow: 0 0 0 3px rgba(44,255,115,.12); }
.color-input-help { margin: 7px 2px 0; color: #8e958d; font-size: 9px; line-height: 1.5; }
.color-input-help.error { color: #e1342f; font-weight: 600; }
.contrast-note { margin-top: 9px; display: flex; align-items: center; gap: 7px; color: #858a83; font-size: 9px; }
.contrast-note svg { width: 14px; fill: none; stroke: #56a574; stroke-width: 1.8; }

.toast { position: fixed; left: 50%; bottom: 28px; translate: -50% 20px; opacity: 0; pointer-events: none; color: white; background: #181b18; border-radius: 99px; padding: 11px 18px; font-size: 12px; transition: .25s; z-index: 50; }
.toast.show { opacity: 1; translate: -50% 0; }

.long-workspace { grid-template-columns: minmax(520px, 1fr) 430px; background: #f4f6f5; }
.long-preview-panel { align-items: stretch; }
.long-canvas-stage {
  width: 100%; height: calc(100vh - var(--topbar-height) - var(--android-status-bar) - 118px);
  min-height: 520px; overflow: auto; display: block; padding: 30px;
  background:
    linear-gradient(135deg, rgba(255,255,255,.08), transparent),
    #202522;
  position: relative;
}
#longCanvas {
  display: block; width: var(--long-canvas-css-width, 360px); height: var(--long-canvas-css-height, 1400px);
  margin: 0 auto; background: #eef9ff; box-shadow: 0 22px 70px rgba(0,0,0,.34);
  cursor: default; touch-action: pan-y;
}
#longCanvas.dragging { cursor: grabbing; }
.long-editor-panel { padding-top: 8px; background: #ffffff; }
.long-float-toolbar {
  position: absolute; z-index: 9; translate: -50% -100%; display: flex; align-items: center; gap: 6px;
  max-width: min(520px, calc(100% - 28px)); padding: 8px; border-radius: 16px;
  background: rgba(255,255,255,.96); box-shadow: 0 18px 55px rgba(0,0,0,.22); backdrop-filter: blur(14px);
}
.long-float-toolbar.hidden { display: none; }
.long-float-toolbar strong {
  max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 0 7px;
  color: #1a1f1b; font-size: 12px;
}
.long-float-toolbar button {
  height: 30px; border: 0; border-radius: 10px; background: #f1f3f1; padding: 0 9px; cursor: pointer;
  color: #252b26; font-size: 11px;
}
.long-float-toolbar button:last-child { color: #c9342d; background: #fff0ef; }
.poster-workspace { grid-template-columns: minmax(430px, 1fr) 440px; }
.poster-mark { background: var(--ds-primary); color: #101510; }
#posterToolApp .topbar {
  gap: 12px;
}
#posterToolApp .brand {
  min-width: 0;
  flex: 1 1 auto;
}
#posterToolApp .brand div {
  min-width: 0;
}
#posterToolApp .brand strong,
#posterToolApp .brand small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
#posterToolApp .top-actions {
  flex: 0 0 auto;
}
.poster-preview-panel { align-items: center; overflow: hidden; }
.poster-canvas-stage {
  width: var(--poster-stage-width, 100%);
  height: var(--poster-stage-height, 640px);
  min-height: 0;
  display: grid;
  place-items: center;
  overflow: hidden;
  padding: 12px;
  background: linear-gradient(180deg, #fff 0%, #f7f8f6 100%);
  position: relative;
}
#posterCanvas {
  display: block;
  width: var(--poster-canvas-css-width, auto);
  height: var(--poster-canvas-css-height, auto);
  max-width: 100%;
  max-height: 100%;
  background: #fff;
  border-radius: 18px;
  box-shadow: 0 16px 34px rgba(18, 24, 21, .12), 0 0 0 1px rgba(228, 232, 225, .9);
}
.poster-ratio-grid { grid-template-columns: 1fr 1fr; }
.ratio-shape.poster { width: 25px; height: 34px; }
.ratio-shape.feed { width: 26px; height: 32px; }
.ratio-shape.square { width: 30px; height: 30px; }
.ratio-shape.story { width: 21px; height: 36px; }
.poster-headline-input { min-height: 96px; resize: vertical; line-height: 1.55; font-weight: 700; }
#posterToolApp:not(.poster-free-mode) .poster-copy-section label[for="posterBodyInput"],
#posterToolApp:not(.poster-free-mode) .poster-copy-section #posterBodyInput,
#posterToolApp:not(.poster-free-mode) .poster-copy-section label[for="posterTagInput"],
#posterToolApp:not(.poster-free-mode) .poster-copy-section #posterTagInput,
#posterToolApp:not(.poster-free-mode) .poster-copy-section .field-help {
  display: none;
}
#posterToolApp:not(.poster-free-mode) .poster-copy-section {
  padding-bottom: 18px;
}
.poster-control-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.poster-control-grid label { display: grid; gap: 7px; color: #737a72; font-size: 10px; }
.poster-mode-switch {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 12px;
  padding: 4px;
  border: 1px solid #e3e7e1;
  border-radius: 14px;
  background: #f6f8f5;
}
.poster-mode-switch button,
.poster-edit-toolbar button,
.poster-element-grid button,
.poster-variant-grid button {
  min-height: 38px;
  border: 1px solid #e0e5de;
  border-radius: 12px;
  background: #fff;
  color: #333a33;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}
.poster-mode-switch button.active,
.poster-variant-grid button.active {
  border-color: #14d86b;
  background: #101510;
  color: #fff;
}
.poster-variant-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(74px, 1fr));
  gap: 9px;
}
.poster-variant-card {
  display: grid;
  gap: 5px;
  padding: 6px;
  min-height: 104px !important;
}
.poster-variant-card small {
  color: inherit;
  font-size: 10px;
  line-height: 1;
}
.poster-thumb {
  display: block;
  aspect-ratio: 3 / 4;
  border-radius: 10px;
  padding: 8px;
  background: var(--thumb-bg);
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.08);
}
.poster-thumb-card {
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 4px;
  width: 100%;
  height: 100%;
  border-radius: 8px;
  background: var(--thumb-card);
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.07);
}
.poster-thumb-card i,
.poster-thumb-card em {
  display: block;
  width: 36%;
  height: 4px;
  border-radius: 999px;
  background: var(--thumb-accent);
}
.poster-thumb-card em {
  width: 48%;
  height: 6px;
  margin-top: 5px;
}
.poster-thumb-card b {
  max-width: 90%;
  overflow: hidden;
  color: var(--thumb-ink);
  font-size: 8px;
  line-height: 1.1;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.poster-edit-hint {
  position: absolute;
  z-index: 8;
  display: none;
  pointer-events: none;
  border: 2px solid #ff3f5f;
  border-radius: 10px;
  background: rgba(255,63,95,.08);
  box-shadow: 0 0 0 4px rgba(255,63,95,.12);
}
.poster-edit-hint.show { display: block; }
.poster-edit-hint span {
  position: absolute;
  left: 10px;
  top: -8px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #ff3f5f;
  box-shadow: 0 0 0 3px #fff;
}
.poster-edit-hint strong {
  position: absolute;
  left: 0;
  top: -36px;
  min-width: 112px;
  padding: 6px 9px;
  border-radius: 999px;
  background: #101510;
  color: #fff;
  font-size: 11px;
  line-height: 1;
  white-space: nowrap;
}
.poster-edit-toolbar,
.poster-element-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.poster-app:not(.poster-free-mode) .poster-edit-only { display: none; }
.poster-app.poster-free-mode #posterVariantSection { display: none; }
.poster-app:not(.poster-free-mode) .poster-advanced-section { display: none; }
.poster-app.poster-free-mode .poster-advanced-section { display: block; }
.canvas-container {
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 18px 50px rgba(0,0,0,.46);
}
.template-list { display: grid; gap: 10px; }
.template-card {
  border: 1px solid #e0e5e0; border-radius: 13px; background: #fafbf9; padding: 13px;
  text-align: left; cursor: pointer; display: grid; gap: 5px;
}
.template-card strong { font-size: 13px; }
.template-card small { color: #929991; font-size: 10px; line-height: 1.45; }
.template-card.active { border-color: #10d867; background: #f1fff6; box-shadow: 0 0 0 2px rgba(16,216,103,.1); }
.long-template-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.long-layout-card {
  min-height: 86px; border: 1px solid #dfe4df; border-radius: 14px; background: #fbfcfb; padding: 12px;
  text-align: left; cursor: pointer; display: grid; gap: 5px; align-content: center;
}
.long-layout-card strong { color: #171d19; font-size: 13px; }
.long-layout-card small { color: #838b84; font-size: 10px; line-height: 1.45; }
.long-layout-card.active { border-color: #101510; background: #f2f5f2; box-shadow: inset 0 0 0 1px #101510; }
.long-theme-palette { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.long-theme-palette button {
  display: inline-flex; align-items: center; gap: 6px; min-height: 32px; border: 1px solid #dde3de;
  border-radius: 999px; background: #fff; padding: 0 10px; cursor: pointer; font-size: 11px; color: #3d453f;
}
.long-theme-palette button::before {
  content: ""; width: 14px; height: 14px; border-radius: 50%; background: var(--swatch); box-shadow: inset 0 0 0 1px rgba(0,0,0,.12);
}
.long-theme-palette button.active { border-color: #111510; background: #f4f6f4; color: #111510; }
.select-input {
  width: 100%; height: 42px; border: 1px solid #dfe4dc; border-radius: 12px; background: #f9faf8;
  padding: 0 12px; outline: 0; font-size: 12px;
}
.custom-size-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 10px; }
.custom-size-grid label {
  display: grid; gap: 6px; color: #737a72; font-size: 10px;
}
.custom-size-grid input {
  width: 100%; height: 38px; border: 1px solid #dfe4dc; border-radius: 11px; background: #f9faf8;
  padding: 0 10px; outline: 0;
}
.custom-size-grid .select-input { height: 38px; border-radius: 11px; padding: 0 10px; }
.module-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.module-grid button {
  min-height: 70px; border: 1px solid #dfe5df; border-radius: 12px; background: #fbfcfb; padding: 11px;
  text-align: left; cursor: pointer; display: grid; gap: 4px; align-content: center;
}
.module-grid button:hover { border-color: #101510; background: #f4f7f3; }
.module-grid strong { font-size: 13px; color: #171b17; }
.module-grid small { font-size: 10px; color: #8a9289; }
.preset-strip, .deco-list { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.preset-strip button, .deco-list button {
  min-height: 34px; border: 1px solid #dfe5df; border-radius: 999px; background: #fff; padding: 0 12px;
  cursor: pointer; color: #394139; font-size: 11px;
}
.preset-strip button:hover, .deco-list button:hover { border-color: #10d867; color: #08783a; background: #f1fff6; }
.long-editor-panel .text-input:disabled { color: #9aa19a; background: #f3f5f2; }
.template-actions, .layer-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; margin-top: 12px; }
.template-actions button, .layer-actions button {
  min-height: 38px; border: 0; border-radius: 11px; background: #eef2ed; cursor: pointer; font-size: 12px;
}
.template-actions { grid-template-columns: 1fr 1fr 1fr; }
.template-actions button:last-child { background: #101510; color: #fff; }
.template-actions button:disabled { opacity: .45; cursor: not-allowed; }
.layer-actions { grid-template-columns: 1fr 1fr 70px; }
.layer-actions button:last-child { color: #c22f29; background: #fff0ef; }

#posterToolApp .template-actions button,
#posterToolApp .poster-mode-switch button,
#posterToolApp .poster-edit-toolbar button,
#posterToolApp .poster-element-grid button {
  border: 1px solid #ffe0e7;
  background: linear-gradient(180deg, #fff 0%, #fff5f7 100%);
  color: #323735;
  box-shadow: 0 8px 20px rgba(255, 72, 101, .08);
}
#posterToolApp .template-actions button:hover,
#posterToolApp .poster-mode-switch button:hover,
#posterToolApp .poster-edit-toolbar button:hover,
#posterToolApp .poster-element-grid button:hover {
  border-color: #ff8da1;
  background: #fff7f9;
}
#posterToolApp #posterAiDraftBtn,
#posterToolApp #posterRandomBtn {
  border: 0;
  background: linear-gradient(135deg, #ff4b69 0%, #ff6c84 100%);
  color: #fff;
  box-shadow: 0 14px 30px rgba(255, 75, 105, .24);
}
#posterToolApp #posterCopyTaskBtn,
#posterToolApp #posterNextVariantBtn,
#posterToolApp #posterPaletteBtn,
#posterToolApp #posterFontBtn,
#posterToolApp #posterStyleBtn {
  background: #f4f6f3;
  border-color: #e4e9e1;
  color: #222724;
  box-shadow: none;
}
#posterToolApp .poster-mode-switch {
  border-color: #e4ebe3;
  background: #fff7f9;
}
#posterToolApp .poster-mode-switch button.active {
  border-color: #ff4b69;
  background: #fff;
  color: #ff4b69;
  box-shadow: inset 0 0 0 1px #ff4b69, 0 10px 24px rgba(255, 75, 105, .12);
}
#posterToolApp .poster-variant-grid button.active {
  border-color: #ff4b69;
  background: #fff5f7;
  color: #111510;
  box-shadow: inset 0 0 0 1px #ff4b69, 0 12px 26px rgba(255, 75, 105, .12);
}
.selected-layer-name {
  margin: 0 0 4px; min-height: 22px; color: #59615a; background: #f6f8f5; border-radius: 9px;
  padding: 6px 9px; font-size: 11px;
}
.long-layer-list { display: grid; gap: 7px; margin: 9px 0 12px; }
.long-layer-list button {
  min-height: 38px; border: 1px solid #e2e7e2; border-radius: 11px; background: #fbfcfb; padding: 7px 9px;
  display: grid; grid-template-columns: 24px 1fr auto; align-items: center; gap: 8px; text-align: left; cursor: pointer;
}
.long-layer-list span {
  width: 22px; height: 22px; display: grid; place-items: center; border-radius: 8px; background: #eef2ed;
  color: #687169; font-size: 10px; font-weight: 700;
}
.long-layer-list strong { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; color: #1b211d; }
.long-layer-list small { color: #8a9289; font-size: 10px; }
.long-layer-list button.active { border-color: #101510; background: #f3f6f3; }
.long-layer-list button.active span { background: #101510; color: #fff; }
.cover-pro-workspace { grid-template-columns: minmax(520px, 1fr) 430px; background: #eef0ef; }
.cover-pro-mark { width: 42px; background: #111; color: #2cff73; font-size: 13px; letter-spacing: 0; }
.cover-pro-preview-panel { align-items: stretch; }
.cover-pro-stage {
  flex: 1;
  min-height: 0;
  padding: 28px;
  border-radius: 22px;
  background: #202221;
  background-image: radial-gradient(rgba(255,255,255,.12) 1px, transparent 1px);
  background-size: 20px 20px;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.08), 0 16px 40px rgba(29,36,29,.12);
  display: grid;
  place-items: center;
  position: relative;
  overflow: hidden;
}
#coverProCanvas {
  display: block;
  width: var(--cover-pro-canvas-css-width, auto);
  height: var(--cover-pro-canvas-css-height, auto);
  max-width: 100%;
  max-height: 100%;
  background: #1e293b;
  cursor: grab;
  touch-action: none;
  box-shadow: 0 18px 54px rgba(0,0,0,.46);
}
#coverProCanvas:active { cursor: grabbing; }
.cover-pro-editor-panel { background: #fff; }
.cover-pro-segment {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 12px;
}
.cover-pro-segment button,
.cover-pro-ratio-grid button {
  min-height: 40px;
  border: 1px solid #e1e5dd;
  border-radius: 12px;
  background: #fff;
  color: #373d37;
  cursor: pointer;
  font-size: 12px;
}
.cover-pro-segment button.active,
.cover-pro-ratio-grid button.active {
  border-color: #111510;
  background: #111510;
  color: #fff;
}
.cover-pro-swatch-grid {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 14px;
}
.cover-pro-swatch-grid.text { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.cover-pro-swatch-grid button {
  min-height: 34px;
  border: 2px solid transparent;
  border-radius: 999px;
  background: var(--swatch);
  cursor: pointer;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.12);
}
.cover-pro-swatch-grid button span {
  display: block;
  overflow: hidden;
  width: 1px;
  height: 1px;
  clip-path: inset(50%);
}
.cover-pro-swatch-grid button.active {
  border-color: #fff;
  box-shadow: 0 0 0 2px #111510, inset 0 0 0 1px rgba(0,0,0,.12);
}
.cover-pro-ratio-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.cover-pro-ratio-grid button {
  min-height: 74px;
  display: grid;
  align-content: center;
  gap: 5px;
  padding: 10px;
  text-align: left;
}
.cover-pro-ratio-grid strong { font-size: 13px; }
.cover-pro-ratio-grid small { color: inherit; opacity: .68; font-size: 10px; }
.block-list { display: grid; gap: 8px; }
.block-chip {
  border: 1px solid #e0e5e0; border-radius: 12px; background: #fafbf9; padding: 10px 12px;
  text-align: left; cursor: pointer; display: grid; gap: 4px;
}
.block-chip strong { font-size: 12px; }
.block-chip small { color: #8f968d; font-size: 10px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.block-chip.active { border-color: #08d862; background: #f0fff6; box-shadow: 0 0 0 2px rgba(8,216,98,.09); }
.progress-overlay {
  position: fixed; inset: 0; z-index: 130; display: grid; place-items: center; padding: 24px;
  background: rgba(13,16,13,.48); backdrop-filter: blur(12px);
}
.progress-overlay.hidden { display: none; }
.progress-card {
  width: min(360px, 100%); padding: 28px; border-radius: 22px; background: rgba(255,255,255,.96);
  box-shadow: 0 24px 80px rgba(0,0,0,.28); text-align: center;
}
.progress-spinner {
  width: 42px; height: 42px; margin: 0 auto 16px; border-radius: 50%;
  border: 4px solid #e5f6ec; border-top-color: var(--ds-primary); animation: progressSpin .8s linear infinite;
}
.progress-card strong { display: block; font-size: 17px; }
.progress-card p { margin: 8px 0 18px; color: #788078; font-size: 12px; }
.progress-track { height: 8px; border-radius: 99px; overflow: hidden; background: #edf1ec; }
.progress-track span { display: block; width: 4%; height: 100%; border-radius: inherit; background: var(--ds-primary); transition: width .2s ease; }
@keyframes progressSpin { to { rotate: 360deg; } }

.activation-gate { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: max(16px, env(safe-area-inset-top, 0px)) 16px max(16px, env(safe-area-inset-bottom, 0px)); background: rgba(13,16,13,.84); backdrop-filter: blur(18px); overflow: hidden; }
.activation-gate.hidden { display: none; }
.activation-card { position: relative; box-sizing: border-box; width: min(430px, calc(100vw - 32px)); max-width: 100%; max-height: calc(100dvh - 32px - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px)); overflow: auto; overflow-x: hidden; -webkit-overflow-scrolling: touch; padding: clamp(24px, 7vw, 38px); border-radius: 26px; background: #fff; box-shadow: 0 28px 90px rgba(0,0,0,.38); }
.activation-admin-icon { position: absolute; top: 18px; right: 18px; width: 36px; height: 36px; border: 1px solid #e4e8e2; border-radius: 50%; color: #4e554e; background: #fff; cursor: pointer; font-size: 16px; line-height: 1; }
.activation-logo { width: 48px; height: 48px; border-radius: 15px; font-size: 22px; }
.activation-kicker { margin: 24px 0 7px; color: #00a84a; font-size: 9px; font-weight: 700; letter-spacing: .16em; }
.activation-card h1 { margin: 0; font-size: clamp(24px, 7vw, 36px); line-height: 1.18; }
.activation-desc { margin: 11px 0 25px; color: #818780; font-size: 12px; line-height: 1.7; }
.activation-card > label { display: block; margin-bottom: 8px; color: #5e645d; font-size: 11px; }
.license-input-wrap { height: 50px; display: flex; border: 1px solid #dce1da; background: #f8faf7; border-radius: 13px; overflow: hidden; }
.license-input-wrap:focus-within { border-color: #09d963; box-shadow: 0 0 0 3px rgba(9,217,99,.1); }
.license-input-wrap input { min-width: 0; flex: 1; border: 0; outline: 0; background: transparent; padding: 0 14px; letter-spacing: .08em; text-transform: uppercase; }
.license-input-wrap button { border: 0; background: transparent; padding: 0 14px; color: #00a94a; cursor: pointer; font-size: 11px; }
.license-error { min-height: 18px; margin: 6px 2px 0; color: #d83c32; font-size: 10px; }
.license-error.hint { color: #7d857c; }
.activate-btn { width: 100%; height: 50px; border: 0; border-radius: 13px; color: #fff; background: #101310; font-weight: 500; cursor: pointer; }
.demo-license { margin-top: 19px; padding: 12px 13px; display: flex; align-items: center; justify-content: space-between; gap: 12px; border-radius: 11px; background: #f0faf4; font-size: 10px; color: #6a766d; }
.demo-license span { min-width: 0; }
.demo-license button { border: 0; background: transparent; color: #008c3c; font-weight: 700; letter-spacing: .05em; cursor: pointer; }
.contact-developer { margin: 10px 0 0; color: #858b83; font-size: 10px; line-height: 1.6; }
.contact-developer button { width: 100%; min-height: 38px; border: 0; border-radius: 10px; color: #087b38; background: #eefbf3; cursor: pointer; font-size: 11px; }
.activation-foot { margin: 15px 0 0; color: #a2a6a0; font-size: 9px; text-align: center; }
.license-dialog, .settings-dialog, .save-diagnostic-dialog { width: min(430px, calc(100% - 30px)); padding: 0; border: 0; border-radius: 22px; box-shadow: 0 30px 80px rgba(0,0,0,.3); }
.license-dialog::backdrop, .settings-dialog::backdrop, .save-diagnostic-dialog::backdrop { background: rgba(10,12,10,.6); backdrop-filter: blur(8px); }
.license-detail, .settings-detail { position: relative; padding: 31px; }
.save-diagnostic-dialog > div { position: relative; padding: 28px; }
.save-diagnostic-dialog h2 { margin: 0 0 10px; font-size: 18px; }
.save-diagnostic-dialog p { margin: 0 0 14px; color: #747b72; font-size: 12px; line-height: 1.7; }
.save-diagnostic-dialog pre {
  max-height: 230px; overflow: auto; margin: 0 0 14px; padding: 12px; border-radius: 12px;
  color: #263029; background: #f4f7f3; border: 1px solid #e1e7df; font-size: 11px; line-height: 1.6; white-space: pre-wrap; word-break: break-word;
}
.save-diagnostic-dialog .primary-action { width: 100%; min-height: 42px; border: 0; border-radius: 12px; color: #041009; background: var(--ds-primary); font-weight: 700; cursor: pointer; }
.dialog-close { position: absolute; top: 14px; right: 14px; width: 32px; height: 32px; border: 0; border-radius: 50%; background: #f0f2ef; cursor: pointer; font-size: 20px; color: #747a73; }
.license-ok { display: inline-block; padding: 5px 9px; border-radius: 99px; color: #008d3d; background: #dcf9e8; font-size: 9px; }
.license-detail h2, .settings-detail h2 { margin: 12px 0 20px; }
.license-detail dl, .settings-detail dl { margin: 0; border-top: 1px solid #e9ece7; }
.license-detail dl div, .settings-detail dl div { display: flex; justify-content: space-between; gap: 12px; padding: 13px 0; border-bottom: 1px solid #e9ece7; font-size: 11px; }
.license-detail dt, .settings-detail dt { color: #929790; }
.license-detail dd, .settings-detail dd { margin: 0; font-weight: 500; text-align: right; word-break: break-all; }
.license-detail p { margin: 16px 0 0; color: #8b908a; font-size: 10px; line-height: 1.6; }
.settings-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; margin: 18px 0; }
.settings-actions button {
  min-height: 38px; border: 0; border-radius: 10px; background: #eef2ed; cursor: pointer; font-size: 11px;
}
.settings-actions button:last-child { color: #b83a32; background: #fff0ef; }
.license-renewal-actions { grid-template-columns: 1fr; margin-bottom: 8px; }
.license-renewal-actions button {
  min-height: 48px;
  font-size: 13px;
  font-weight: 700;
}

.license-renewal-actions button:first-child {
  color: #b83a32;
  background: #fff0ef;
}

.license-renewal-actions button:last-child {
  color: #5f675f;
  background: #f1f4f1;
}
.renewal-status {
  min-height: 34px;
  margin: 0;
  padding: 10px 12px;
  border-radius: 12px;
  color: #6f786f;
  background: #f5f7f5;
  font-size: 12px;
  line-height: 1.55;
}
.renewal-status:empty {
  display: none;
}
.renewal-status[data-state="pending"] {
  color: #946300;
  background: #fff7d8;
}
.renewal-status[data-state="success"] {
  color: #087b38;
  background: #e8fbed;
}
.renewal-status[data-state="error"] {
  color: #b83a32;
  background: #fff0ef;
}
.feedback-box { display: grid; gap: 8px; margin-bottom: 12px; color: #6d746d; font-size: 11px; }
.feedback-box textarea,
.feedback-box input { width: 100%; min-width: 0; box-sizing: border-box; border: 1px solid #dfe4dc; border-radius: 11px; background: #f9faf8; padding: 10px; outline: 0; line-height: 1.6; }
.feedback-box textarea { resize: vertical; }
.split-upload { margin-bottom: 9px; }

@media (max-width: 900px) {
  :root { --topbar-height: 62px; }
  .launch-shell { padding: calc(10px + var(--android-status-bar)) 16px calc(24px + var(--android-nav-bar)); align-content: start; gap: 14px; }
  .launch-toolbar { justify-content: space-between; }
  .launch-hero { padding: 24px; border-radius: 24px; }
  .launch-mark { width: 50px; height: 50px; border-radius: 15px; font-size: 24px; }
  .feature-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .feature-card { min-height: 112px; padding: 14px; border-radius: 17px; }
  .feature-card strong { font-size: 16px; }
  .topbar { padding: var(--android-status-bar) 16px 0; }
  .brand small, .quiet-btn { display: none; }
  .back-btn { display: inline-flex; align-items: center; }
  .license-badge b { display: none; }
  .license-badge { padding: 0 10px !important; }
  .license-badge small { font-size: 8px; }
  .export-btn { padding: 0 13px !important; height: 38px !important; }
  .workspace { display: block; }
  .preview-panel { position: relative; top: 0; height: auto; padding: 14px 14px 18px; }
  .preview-head { height: 30px; }
  .canvas-stage { border-radius: 16px; }
  .canvas-stage {
    min-height: 0;
    padding: var(--stage-pad-y, 18px) var(--stage-pad-x, 18px);
  }
  #coverCanvas {
    touch-action: pan-y;
  }
  .canvas-tip { bottom: 8px; font-size: 9px; }
  .editor-panel { border-left: 0; border-top: 1px solid #e3e5e0; padding: 2px 18px calc(32px + var(--android-nav-bar)); }
  .long-canvas-stage { height: min(68vh, 620px); min-height: 420px; padding: 18px; }
  .long-template-grid { grid-template-columns: 1fr 1fr; gap: 9px; }
  .long-layout-card { min-height: 78px; padding: 10px; }
  .long-theme-palette { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 4px; }
  .long-theme-palette button { white-space: nowrap; }
  .long-float-toolbar { max-width: calc(100% - 24px); overflow-x: auto; border-radius: 14px; }
  .long-float-toolbar strong { max-width: 96px; flex: 0 0 auto; }
  .long-float-toolbar button { flex: 0 0 auto; }
  .template-actions { grid-template-columns: 1fr; }
  .poster-workspace { display: block; }
  .poster-preview-panel {
    height: clamp(430px, 48vh, 560px);
    padding: 10px 12px 12px;
  }
  .poster-canvas-stage {
    height: var(--poster-stage-height, 320px);
    max-width: 100%;
    padding: 11px;
    border-radius: 18px;
  }
  #posterToolApp .canvas-tip { display: none; }
  .poster-variant-grid {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding: 2px 2px 8px;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
  }
  .poster-variant-card {
    flex: 0 0 86px;
    min-height: 126px !important;
    scroll-snap-align: start;
  }
  .cover-pro-workspace { display: block; }
  .cover-pro-stage { height: min(60vh, 540px); min-height: 260px; padding: 18px; }
  .cover-pro-ratio-grid { grid-template-columns: 1fr 1fr; }
  .poster-control-grid { grid-template-columns: 1fr; }
  .template-actions, .layer-actions { grid-template-columns: 1fr; }
  .activation-card { padding: 28px 23px; }
}

@media (max-width: 390px) {
  .ratio-grid { grid-template-columns: 1fr; }
  .poster-ratio-grid { grid-template-columns: 1fr; }
}

/* Unified Lightfield Design System */
:root {
  --ds-primary: #2CFF73;
  --ds-primary-rgb: 44, 255, 115;
  --ds-bg: #F6F7F8;
  --ds-surface: #FFFFFF;
  --ds-text: #171916;
  --ds-muted: rgba(23, 25, 22, .7);
  --ds-subtle: rgba(23, 25, 22, .56);
  --ds-border: #ECEDEF;
  --ds-danger: #D83C32;
  --ds-warning: #A97910;
  --ds-radius-card: 12px;
  --ds-space-1: 4px;
  --ds-space-2: 8px;
  --ds-space-3: 12px;
  --ds-space-4: 16px;
  --ds-space-5: 24px;
  --ds-space-6: 32px;
  --ds-space-7: 48px;
  --ds-transition: 200ms cubic-bezier(.2, .8, .2, 1);
}

body {
  color: var(--ds-text);
  background: radial-gradient(circle at 50% -10%, rgba(var(--ds-primary-rgb), .12), transparent 320px), var(--ds-bg);
}

button, a, input, textarea, select {
  transition: transform var(--ds-transition), box-shadow var(--ds-transition), border-color var(--ds-transition), background-color var(--ds-transition), opacity var(--ds-transition);
}

h1 { font-size: 22px; font-weight: 600; line-height: 1.35; }
h2 { font-size: 18px; font-weight: 600; line-height: 1.35; }
h3, .section-title strong, .brand strong { font-size: 16px; font-weight: 500; line-height: 1.35; }
body, input, textarea, select, button { font-size: 14px; font-weight: 400; }
small, .field-help, .license-detail p { font-size: 12px; font-weight: 400; }

.launch-shell {
  min-height: 100vh;
  padding: calc(var(--ds-space-4) + var(--android-status-bar)) var(--ds-space-4) calc(var(--ds-space-5) + var(--android-nav-bar));
  align-content: start;
  gap: var(--ds-space-5);
}

.launch-appbar, .topbar {
  min-height: 64px;
  padding: var(--android-status-bar) var(--ds-space-4) 0;
  background: rgba(255, 255, 255, .92);
  border-bottom: 1px solid var(--ds-border);
  backdrop-filter: blur(18px);
}

.launch-content {
  width: min(1180px, 100%);
  margin: 0 auto;
  display: grid;
  gap: var(--ds-space-5);
}

.site-record-footer {
  justify-self: center;
  width: fit-content;
  max-width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: -4px;
  margin-bottom: calc(2px + var(--android-nav-bar));
  padding: 8px 13px;
  border: 1px solid rgba(44, 255, 115, .20);
  border-radius: 999px;
  color: rgba(23, 25, 22, .56);
  font-size: 12px;
  line-height: 1.5;
  background:
    radial-gradient(circle at 18% 50%, rgba(44, 255, 115, .13), transparent 68px),
    rgba(255, 255, 255, .72);
  box-shadow: 0 12px 30px rgba(20, 28, 20, .045);
  backdrop-filter: blur(14px);
}

.site-record-footer span {
  color: rgba(0, 140, 69, .74);
  font-weight: 700;
}

.site-record-footer a {
  color: inherit;
  text-decoration: none;
  white-space: nowrap;
}

.site-record-footer a:hover {
  color: #008c45;
}

.android-download-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  padding: 16px;
  border: 1px solid rgba(44, 255, 115, .24);
  border-radius: 18px;
  background: linear-gradient(110deg, rgba(236, 255, 244, .92), rgba(255, 255, 255, .96));
}

.android-download-icon {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: 14px;
  color: #007f3e;
  background: rgba(44, 255, 115, .14);
}

.android-download-card h2,
.android-download-card p { margin: 0; }
.android-download-card h2 { font-size: 16px; }
.android-download-card p { margin-top: 4px; color: rgba(23, 25, 22, .62); font-size: 12px; }
.android-download-card > a {
  padding: 10px 15px;
  border-radius: 12px;
  color: #07130b;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
  background: #2cff73;
  transition: transform 180ms ease, box-shadow 180ms ease;
}
.android-download-card > a:hover { transform: translateY(-2px); box-shadow: 0 8px 18px rgba(0, 150, 65, .14); }
.android-download-card > a:active { transform: scale(.97); }
body.android-app .android-download-card { display: none; }

.activation-app-download {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  width: 100%;
  margin-top: 10px;
  padding: 11px 14px;
  border: 1px solid rgba(0, 145, 67, .16);
  border-radius: 14px;
  color: #007f3e;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
  background: rgba(239, 255, 245, .84);
}
body.android-app .activation-app-download { display: none; }

@media (max-width: 560px) {
  .android-download-card { grid-template-columns: auto minmax(0, 1fr); }
  .android-download-card > a { grid-column: 1 / -1; text-align: center; }
}

.launch-summary {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--ds-space-3);
}

.profile-card, .expiry-card, .feature-card, .ratio-card, .template-card, .block-chip, .upload-box, .activation-card {
  border-radius: var(--ds-radius-card);
  background: var(--ds-surface);
  border: 1px solid var(--ds-border);
  box-shadow: none;
}

.profile-card, .expiry-card {
  padding: var(--ds-space-4);
}

.profile-card span, .expiry-card span, .feature-card small, .section-title small, .brand small, .field-help {
  color: var(--ds-muted);
  opacity: .7;
}

.tool-section {
  display: grid;
  gap: var(--ds-space-3);
}

.tool-section h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
}

.feature-grid {
  width: 100%;
  margin: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--ds-space-3);
}

.feature-card {
  min-height: 112px;
  padding: var(--ds-space-4);
  border-radius: var(--ds-radius-card);
  background: var(--ds-surface);
  border: 1px solid var(--ds-border);
  color: var(--ds-text);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  align-content: start;
  column-gap: var(--ds-space-3);
  row-gap: var(--ds-space-2);
  box-shadow: none;
}

.feature-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, .08);
}

.feature-card.featured {
  border-color: var(--ds-primary);
  box-shadow: 0 0 0 3px rgba(var(--ds-primary-rgb), .16), 0 0 24px rgba(var(--ds-primary-rgb), .25);
}

.feature-card.recommended {
  border-color: rgba(var(--ds-primary-rgb), .55);
}

.feature-card.disabled, .feature-card.pending {
  opacity: .6;
  cursor: not-allowed;
  filter: grayscale(1);
}

.feature-card.disabled:hover, .feature-card.pending:hover {
  transform: none;
  box-shadow: none;
}

.feature-card strong {
  min-width: 0;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.35;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.feature-card small {
  grid-column: 2 / 4;
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  font-size: 12px;
  line-height: 1.45;
}

.feature-card .tool-icon {
  width: auto;
  height: auto;
  border-radius: 0;
  display: grid;
  place-items: center;
  color: inherit;
  background: transparent;
  font-size: 0;
}

.feature-card .tool-icon svg {
  width: 58%;
  height: 58%;
}

.feature-card.available, .feature-card.long-entry, .feature-card.poster-entry, .feature-card.cover-pro-entry {
  background: var(--ds-surface);
  border-color: var(--ds-border);
}

.feature-card.available.featured {
  border-color: var(--ds-primary);
}

.feature-card.available span, .feature-card.available small {
  color: var(--ds-muted);
}

.top-actions button, .top-actions a, .launch-license-pill, .launch-icon-btn, .export-btn, .activate-btn {
  border-radius: var(--ds-radius-card);
}

.export-btn, .activate-btn {
  background: var(--ds-primary);
  color: #101510;
}

.brand-mark, .launch-mini-mark, .activation-logo {
  background: var(--ds-primary);
  color: #101510;
  box-shadow: 0 0 18px rgba(var(--ds-primary-rgb), .25);
}

.ratio-card.active, .template-card.active, .block-chip.active, .license-input-wrap:focus-within, .text-input:focus, input:focus, textarea:focus, select:focus {
  border-color: var(--ds-primary);
  box-shadow: 0 0 0 3px rgba(var(--ds-primary-rgb), .16);
}

.status-dot, .license-badge span, .progress-track span {
  background: var(--ds-primary);
}

.poster-mark, .cover-pro-mark, .feature-card.poster-entry .tool-icon, .feature-card.long-entry .tool-icon, .feature-card.cover-pro-entry .tool-icon {
  background: rgba(var(--ds-primary-rgb), .12);
  color: var(--ds-text);
}

@media (min-width: 720px) {
  .launch-shell { padding-left: var(--ds-space-5); padding-right: var(--ds-space-5); }
  .launch-summary { grid-template-columns: 1fr 1fr; }
  .feature-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (min-width: 1080px) {
  .feature-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* Product polish pass: restore the finished mobile app feel while keeping shared tokens. */
body {
  background:
    radial-gradient(circle at 18% 8%, rgba(var(--ds-primary-rgb), .16), transparent 260px),
    radial-gradient(circle at 86% 38%, rgba(255, 255, 255, .92), transparent 280px),
    linear-gradient(180deg, #fbfcfa 0%, #eef1ec 100%);
}

.launch-shell {
  display: block;
  padding: calc(18px + var(--android-status-bar)) 16px calc(34px + var(--android-nav-bar));
}

.launch-appbar {
  width: min(960px, 100%);
  min-height: 56px;
  margin: 0 auto 18px;
  padding: 0;
  border: 0;
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.launch-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.launch-brand strong {
  max-width: 52vw;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 18px;
  font-weight: 700;
}

.launch-mini-mark {
  width: 32px;
  height: 32px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
  background: var(--ds-primary);
  color: #101510;
  font-size: 20px;
  font-weight: 700;
  box-shadow: 0 10px 24px rgba(var(--ds-primary-rgb), .28);
}

.launch-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
}

.launch-license-pill {
  min-height: 46px;
  padding: 0 18px;
  border: 0;
  border-radius: 999px;
  background: rgba(var(--ds-primary-rgb), .14);
  color: #047336;
  font-weight: 700;
  white-space: nowrap;
  box-shadow: inset 0 0 0 1px rgba(var(--ds-primary-rgb), .06);
}

.launch-icon-btn {
  position: relative;
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: rgba(255, 255, 255, .86);
  color: #1d211d;
  box-shadow: 0 12px 28px rgba(20, 24, 20, .08);
}

.launch-icon-btn svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
}

.launch-content {
  width: min(960px, 100%);
  gap: 26px;
}

.launch-hero {
  min-height: 252px;
  padding: 32px 30px;
  border-radius: 32px;
  display: grid;
  align-content: center;
  background:
    radial-gradient(circle at 18% 16%, rgba(var(--ds-primary-rgb), .16), transparent 190px),
    linear-gradient(135deg, rgba(255, 255, 255, .96), rgba(239, 250, 244, .94));
  border: 1px solid rgba(255, 255, 255, .86);
  box-shadow: 0 28px 80px rgba(21, 29, 22, .11);
}

.launch-mark {
  width: 72px;
  height: 72px;
  border-radius: 24px;
  margin-bottom: 30px;
  background: linear-gradient(145deg, var(--ds-primary), #046a38);
  color: #fff;
  font-size: 34px;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.22), 0 18px 38px rgba(4,106,56,.24);
}

.launch-hero p {
  margin: 0 0 12px;
  color: #047336;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: .08em;
}

.launch-hero h1 {
  max-width: 720px;
  margin: 0;
  color: #151815;
  font-size: clamp(34px, 7vw, 50px);
  line-height: 1.15;
  font-weight: 700;
  letter-spacing: 0;
}

.launch-hero small {
  margin-top: 28px;
  display: flex;
  align-items: center;
  gap: 12px;
  color: rgba(23, 25, 22, .62);
}

.author-link {
  font-size: 14px;
  color: rgba(23, 25, 22, .72);
}

.admin-mini-link {
  min-height: 36px;
  padding: 0 16px;
  border-radius: 999px;
  background: rgba(20, 24, 20, .08);
  color: rgba(23, 25, 22, .78);
  font-size: 13px;
}

.launch-summary {
  display: none;
}

.tool-section {
  gap: 14px;
}

.tool-section h2 {
  margin: 0 2px;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 0;
}

.feature-grid {
  gap: 16px;
}

.open-tools,
.pending-tools {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.feature-card {
  min-height: 176px;
  padding: 24px 22px;
  border-radius: 28px;
  display: grid;
  grid-template-columns: 1fr;
  grid-template-rows: auto 1fr auto;
  gap: 0;
  border-color: rgba(230, 233, 228, .9);
  background: rgba(255, 255, 255, .86);
  box-shadow: 0 14px 40px rgba(19, 25, 19, .055);
}

.feature-card .tool-icon {
  width: auto;
  height: auto;
  margin: 0 0 26px;
  display: block;
  place-items: unset;
  background: transparent;
  color: rgba(23, 25, 22, .42);
  font-size: 14px;
  font-weight: 500;
}

.feature-card strong {
  font-size: 22px;
  font-weight: 700;
  line-height: 1.2;
}

.feature-card small {
  grid-column: auto;
  align-self: end;
  margin-top: 20px;
  color: rgba(23, 25, 22, .56);
  font-size: 13px;
  line-height: 1.45;
}

.feature-card i,
.feature-card em {
  display: none;
}

.feature-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 44px rgba(19, 25, 19, .1);
}

.feature-card.featured {
  background:
    radial-gradient(circle at 15% 12%, rgba(var(--ds-primary-rgb), .48), transparent 120px),
    linear-gradient(135deg, rgba(var(--ds-primary-rgb), .68), rgba(235, 255, 243, .92));
  border-color: rgba(var(--ds-primary-rgb), .95);
  box-shadow: 0 0 0 1px rgba(var(--ds-primary-rgb), .2), 0 20px 54px rgba(var(--ds-primary-rgb), .2);
}

.feature-card.recommended {
  border-color: rgba(var(--ds-primary-rgb), .36);
  background:
    radial-gradient(circle at 88% 16%, rgba(var(--ds-primary-rgb), .12), transparent 130px),
    rgba(255, 255, 255, .88);
}

.feature-card.disabled,
.feature-card.pending {
  opacity: .82;
  filter: none;
  cursor: not-allowed;
}

.pending-section {
  margin-top: 4px;
}

.pending-section h2 {
  font-size: 20px;
}

.pending-tools .feature-card {
  min-height: 152px;
}

.topbar {
  min-height: 72px;
  padding: var(--android-status-bar) 18px 0;
  gap: 14px;
}

.brand {
  min-width: 0;
  gap: 12px;
  flex: 1 1 auto;
}

.brand div {
  min-width: 0;
}

.brand strong {
  display: block;
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 20px;
  font-weight: 700;
}

.brand small {
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.brand-mark {
  width: 52px;
  height: 52px;
  border-radius: 18px;
  flex: 0 0 auto;
  background: var(--ds-primary);
  color: #101510;
  font-size: 26px;
}

.back-btn,
.quiet-btn,
.license-badge,
.export-btn {
  border-radius: 18px;
}

.top-actions {
  flex: 0 0 auto;
  gap: 10px;
}

.top-actions button,
.top-actions a {
  min-width: 72px;
  height: 52px;
  padding: 0 16px;
  justify-content: center;
  white-space: nowrap;
  line-height: 1.05;
}

.license-badge {
  min-width: 116px;
  padding: 0 12px !important;
}

.license-badge b {
  display: none;
}

.license-badge small {
  color: #047336;
  font-size: 13px;
  line-height: 1.05;
  white-space: normal;
}

.export-btn {
  min-width: 128px;
  background: var(--ds-primary);
  color: #101510;
  font-weight: 700;
}

.preview-panel {
  background: rgba(255, 255, 255, .52);
}

.editor-panel {
  background: rgba(255, 255, 255, .92);
}

@media (max-width: 900px) {
  :root { --topbar-height: 72px; }
  .launch-shell {
    padding-left: 18px;
    padding-right: 18px;
  }
  .launch-brand strong {
    max-width: 42vw;
  }
  .launch-license-pill {
    min-height: 48px;
    padding: 0 18px;
  }
  .launch-icon-btn {
    width: 48px;
    height: 48px;
  }
  .launch-hero {
    min-height: 248px;
    padding: 30px 28px;
    border-radius: 30px;
  }
  .launch-mark {
    width: 64px;
    height: 64px;
    border-radius: 22px;
    margin-bottom: 26px;
  }
  .feature-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .feature-card {
    min-height: 168px;
    padding: 22px 20px;
    border-radius: 26px;
  }
  .topbar {
    min-height: 72px;
    padding-left: 18px;
    padding-right: 18px;
  }
  .brand {
    gap: 10px;
  }
  .back-btn {
    width: 54px;
    min-width: 54px;
    height: 54px;
    padding: 0;
    justify-content: center;
    white-space: normal;
    line-height: 1.05;
  }
  .brand-mark {
    width: 54px;
    height: 54px;
  }
  .brand strong {
    max-width: 116px;
    font-size: 20px;
    white-space: normal;
    line-height: 1.05;
  }
  .brand small {
    display: none;
  }
  .top-actions {
    gap: 10px;
  }
  .top-actions button,
  .top-actions a {
    min-width: 78px;
    height: 54px;
    padding: 0 13px !important;
    font-size: 14px;
    font-weight: 700;
  }
  .quiet-btn {
    background: rgba(20, 24, 20, .08);
  }
  .license-badge {
    min-width: 86px;
  }
  .export-btn {
    min-width: 124px;
  }
  .export-btn svg {
    width: 18px;
    flex: 0 0 auto;
  }
  .workspace {
    display: block;
  }
  .preview-panel {
    padding: 24px 18px 28px;
  }
  .editor-panel {
    padding: 18px 20px calc(42px + var(--android-nav-bar));
  }
}

/* Final activation polish: keep helper copy readable on all surfaces. */
.activation-kicker,
body.android-app .activation-kicker {
  font-size: clamp(12px, 3.1vw, 14px) !important;
  font-weight: 900 !important;
  letter-spacing: .12em !important;
}

.demo-license,
body.android-app .demo-license {
  justify-content: space-between !important;
  align-items: center !important;
  text-align: left !important;
  gap: 14px !important;
}

.demo-license span,
body.android-app .demo-license span {
  color: #566056 !important;
  font-size: 12px !important;
  font-weight: 800 !important;
  flex: 0 0 auto !important;
}

.demo-license button,
body.android-app .demo-license button {
  color: #087b38 !important;
  font-size: 13px !important;
  font-weight: 900 !important;
  text-align: right !important;
  flex: 1 1 auto !important;
}

@media (max-width: 520px) {
  .launch-appbar {
    gap: 12px;
  }
  .launch-brand strong {
    display: none;
  }
  .launch-license-pill {
    max-width: 58vw;
  }
  .open-tools,
  .pending-tools {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }
  .feature-card {
    min-height: 154px;
    padding: 18px 16px;
    border-radius: 24px;
  }
  .feature-card strong {
    font-size: 19px;
  }
  .feature-card small {
    font-size: 12px;
  }
  .topbar {
    padding-left: 10px;
    padding-right: 10px;
    gap: 8px;
  }
  .brand {
    gap: 8px;
  }
  .back-btn {
    width: 44px;
    min-width: 44px;
    height: 44px;
    border-radius: 16px;
    font-size: 13px;
  }
  .brand-mark {
    width: 44px;
    height: 44px;
    border-radius: 16px;
    font-size: 22px;
  }
  .brand strong {
    max-width: 72px;
    font-size: 18px;
  }
  .top-actions {
    gap: 8px;
  }
  .top-actions button,
  .top-actions a {
    min-width: 56px;
    height: 44px;
    padding: 0 8px !important;
    border-radius: 16px;
    font-size: 13px;
  }
  .license-badge {
    min-width: 62px;
  }
  .license-badge span {
    width: 7px;
    height: 7px;
  }
  .license-badge small {
    font-size: 12px;
  }
  .export-btn {
    min-width: 96px;
  }
}

/* Stable home card contract: long tool names never resize a grid track or misalign the action baseline. */
.open-tools .feature-card {
  min-width: 0;
}

.open-tools .feature-card strong {
  min-width: 0;
  min-height: 2.4em;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  overflow-wrap: anywhere;
}

.open-tools .feature-card small {
  min-width: 0;
  min-height: 2.9em;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

/* Header P0 rhythm and measured landing offset. */
.launch-content {
  gap: 32px;
}

.launch-hero {
  min-height: 0;
}

#toolSection {
  scroll-margin-top: calc(var(--launch-nav-offset, 0px) + 12px);
}

@media (max-width: 900px) {
  .launch-content {
    gap: 24px;
  }
}

@media (max-width: 520px) {
  .launch-content {
    gap: 22px;
  }
}

/* Browser workstation style inspired by the OPPO-like tool center references. */
@media (min-width: 901px) {
  body {
    background:
      radial-gradient(circle at 24% 0%, rgba(var(--ds-primary-rgb), .10), transparent 360px),
      radial-gradient(circle at 88% 12%, rgba(205, 234, 255, .32), transparent 340px),
      #f8faf9;
  }

  .launch-shell {
    padding: 0 56px 56px;
  }

  .launch-appbar {
    width: calc(100% + 112px);
    max-width: none;
    margin: 0 -56px 44px;
    min-height: 82px;
    padding: 0 56px;
    background: rgba(255,255,255,.82);
    border-bottom: 1px solid rgba(236,237,239,.86);
    backdrop-filter: blur(22px);
  }

  .launch-brand strong {
    max-width: none;
    font-size: 20px;
  }

  .launch-nav {
    display: flex;
    align-items: center;
    gap: 38px;
    margin-left: 42px;
  }

  .launch-nav a {
    position: relative;
    color: rgba(23,25,22,.82);
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
    line-height: 82px;
  }

  .launch-nav a.active {
    color: #009b46;
  }

  .launch-nav a.active::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: 0;
    width: 22px;
    height: 2px;
    border-radius: 99px;
    translate: -50% 0;
    background: var(--ds-primary);
  }

  .launch-search {
    width: min(330px, 26vw);
    height: 44px;
    margin-left: auto;
    padding: 0 14px;
    border-radius: 999px;
    border: 1px solid var(--ds-border);
    background: rgba(255,255,255,.86);
    display: flex;
    align-items: center;
    gap: 10px;
    color: rgba(23,25,22,.38);
  }

  .launch-search svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
  }

  .launch-search input {
    min-width: 0;
    flex: 1;
    border: 0;
    outline: 0;
    background: transparent;
    font-size: 14px;
  }

  .launch-search kbd {
    min-width: 32px;
    height: 22px;
    padding: 0 7px;
    border-radius: 8px;
    display: grid;
    place-items: center;
    background: #f1f3f2;
    color: rgba(23,25,22,.34);
    font-size: 12px;
    font-family: inherit;
  }

  .launch-actions {
    margin-left: 18px;
  }

  .launch-icon-btn {
    box-shadow: none;
    border: 1px solid transparent;
  }

  .launch-content {
    width: min(1280px, 100%);
    gap: 46px;
  }

  .launch-hero {
    min-height: 168px;
    padding: 0;
    border: 0;
    box-shadow: none;
    background: transparent;
  }

  .launch-mark {
    display: none;
  }

  .launch-hero p {
    margin-bottom: 10px;
    color: rgba(23,25,22,.74);
    letter-spacing: 0;
    font-size: 15px;
  }

  .launch-hero h1 {
    max-width: 720px;
    font-size: 30px;
    line-height: 1.25;
  }

  .launch-hero small {
    margin-top: 18px;
  }

  .tool-section {
    gap: 22px;
  }

  .tool-section h2 {
    position: relative;
    padding-left: 12px;
    font-size: 24px;
  }

  .tool-section h2::before {
    content: "";
    position: absolute;
    left: 0;
    top: 6px;
    width: 4px;
    height: 20px;
    border-radius: 99px;
    background: var(--ds-primary);
  }

  .tool-section h2::after {
    content: "高效的营销创作工具，助力内容快速产出";
    display: block;
    margin-top: 10px;
    color: rgba(23,25,22,.56);
    font-size: 14px;
    font-weight: 400;
  }

  .pending-section h2::after {
    content: "更多能力正在路上，敬请期待";
  }

  .open-tools,
  .pending-tools,
  .feature-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px;
  }

  .feature-card {
    min-height: 238px;
    padding: 30px;
    border-radius: 16px;
    background: rgba(255,255,255,.86);
    border: 1px solid rgba(236,237,239,.95);
    box-shadow: 0 18px 50px rgba(20,24,20,.055);
  }

  .feature-card .tool-icon {
    width: 58px;
    height: 58px;
    margin: 0 0 30px;
    border-radius: 18px;
    display: grid;
    place-items: center;
    background: rgba(var(--ds-primary-rgb), .13);
    color: #009b46;
    font-size: 24px;
  }

  .feature-card .tool-icon svg {
    width: 29px;
    height: 29px;
  }

  .feature-card strong {
    font-size: 24px;
  }

  .feature-card small {
    margin-top: 14px;
    font-size: 15px;
  }

  .feature-card i {
    display: block;
    margin-top: 24px;
    color: #009b46;
    font-style: normal;
    font-weight: 700;
    font-size: 14px;
  }

  .feature-card i::before {
    content: "立即使用 ";
  }

  .feature-card.featured {
    background:
      radial-gradient(circle at 20% 10%, rgba(var(--ds-primary-rgb), .18), transparent 170px),
      rgba(255,255,255,.9);
    border-color: rgba(var(--ds-primary-rgb), .45);
    box-shadow: 0 0 0 1px rgba(var(--ds-primary-rgb), .12), 0 22px 54px rgba(20,24,20,.07);
  }

  .feature-card.featured::after {
    content: "推荐";
    position: absolute;
    top: 22px;
    right: 22px;
    padding: 7px 11px;
    border-radius: 999px;
    background: #009b46;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
  }

  .feature-card {
    position: relative;
  }

  .pending-tools .feature-card {
    min-height: 176px;
  }

  .pending-tools .feature-card .tool-icon {
    color: #899099;
    background: #f1f3f5;
  }

  .feature-card em {
    display: block;
    position: absolute;
    top: 24px;
    right: 24px;
    padding: 6px 10px;
    border-radius: 999px;
    background: #f1f3f2;
    color: rgba(23,25,22,.56);
    font-style: normal;
    font-size: 12px;
  }
}

.topbar {
  overflow: hidden;
}

@media (max-width: 900px) {
  .launch-nav,
  .launch-search {
    display: none;
  }
  .export-btn {
    height: 44px !important;
  }
}

@media (min-width: 521px) and (max-width: 900px) {
  .export-btn {
    height: 54px !important;
  }
}

@media (min-width: 901px) {
  .launch-hero {
    width: 100%;
  }
}

@media (max-width: 520px) {
  #toolApp .topbar .brand {
    flex: 0 0 auto;
  }

  #toolApp .topbar .brand div {
    display: none;
  }

  #toolApp .top-actions {
    margin-left: auto;
  }
}

/* Mobile APP home: compact guide-focused entry, separated from desktop workstation. */
@media (max-width: 520px) {
  body {
    background:
      radial-gradient(circle at 12% 0%, rgba(var(--ds-primary-rgb), .18), transparent 260px),
      linear-gradient(180deg, #fbfcfa 0%, #eef2ee 100%);
  }

  .launch-shell {
    padding: calc(8px + var(--android-status-bar)) 16px calc(28px + var(--android-nav-bar));
  }

  .launch-appbar {
    min-height: 48px;
    margin: 0 auto 14px;
    padding: 0;
    gap: 10px;
  }

  .launch-brand {
    flex: 0 0 auto;
  }

  .launch-mini-mark {
    width: 44px;
    height: 44px;
    border-radius: 15px;
    font-size: 23px;
    color: #fff;
    background: linear-gradient(145deg, var(--ds-primary), #046a38);
    box-shadow: 0 12px 26px rgba(4, 106, 56, .18);
  }

  .launch-actions {
    flex: 1 1 auto;
    justify-content: flex-end;
    gap: 10px;
    min-width: 0;
  }

  .launch-license-pill {
    min-height: 44px;
    max-width: none;
    flex: 1 1 auto;
    justify-content: center;
    padding: 0 14px;
    font-size: 14px;
    border-radius: 999px;
    background: rgba(var(--ds-primary-rgb), .14);
    box-shadow: inset 0 0 0 1px rgba(var(--ds-primary-rgb), .08);
  }

  .launch-icon-btn {
    width: 44px;
    height: 44px;
    flex: 0 0 auto;
    border-radius: 18px;
    background: rgba(255,255,255,.9);
    box-shadow: 0 10px 26px rgba(20,24,20,.08);
  }

  .launch-content {
    width: 100%;
    display: grid;
    gap: 24px;
  }

  .launch-hero {
    min-height: 184px;
    padding: 24px 22px;
    border-radius: 28px;
    display: grid;
    align-content: center;
    background:
      radial-gradient(circle at 0% 0%, rgba(var(--ds-primary-rgb), .12), transparent 170px),
      rgba(255,255,255,.82);
    border: 1px solid rgba(255,255,255,.86);
    box-shadow: 0 22px 60px rgba(21, 29, 22, .09);
  }

  .launch-mark {
    display: none;
  }

  .launch-hero p {
    margin: 0 0 10px;
    color: #047336;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: .06em;
  }

  .launch-hero h1 {
    max-width: 310px;
    font-size: 30px;
    line-height: 1.18;
    font-weight: 700;
    letter-spacing: 0;
  }

  .launch-hero small {
    margin-top: 24px;
    display: flex;
    align-items: center;
    gap: 10px;
  }

  .author-link {
    font-size: 13px;
  }

  .admin-mini-link {
    min-height: 34px;
    padding: 0 14px;
    font-size: 12px;
  }

  .tool-section {
    gap: 14px;
  }

  .tool-section h2 {
    margin: 0;
    font-size: 20px;
    line-height: 1.25;
    font-weight: 700;
  }

  .open-tools,
  .pending-tools {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
  }

  .feature-card {
    min-height: 164px;
    padding: 18px;
    border-radius: 22px;
    background: rgba(255,255,255,.82);
    border: 1px solid rgba(236,237,239,.92);
    box-shadow: 0 12px 34px rgba(20,24,20,.055);
    display: grid;
    grid-template-rows: auto 1fr auto;
  }

  .feature-card.featured {
    background:
      radial-gradient(circle at 24% 10%, rgba(var(--ds-primary-rgb), .34), transparent 118px),
      rgba(255,255,255,.84);
    border-color: rgba(var(--ds-primary-rgb), .72);
    box-shadow: 0 0 0 1px rgba(var(--ds-primary-rgb), .16), 0 18px 44px rgba(var(--ds-primary-rgb), .12);
  }

  .feature-card.recommended {
    border-color: rgba(var(--ds-primary-rgb), .32);
  }

  .feature-card .tool-icon {
    width: 42px;
    height: 42px;
    margin: 0 0 18px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    color: #009b46;
    background: rgba(var(--ds-primary-rgb), .12);
  }

  .feature-card .tool-icon svg {
    width: 22px;
    height: 22px;
  }

  .feature-card strong {
    min-width: 0;
    font-size: 18px;
    line-height: 1.25;
    font-weight: 700;
    white-space: normal;
    overflow: visible;
  }

  .feature-card small {
    margin-top: 14px;
    color: rgba(23,25,22,.54);
    font-size: 12px;
    line-height: 1.45;
    -webkit-line-clamp: 2;
  }

  .feature-card i,
  .feature-card em {
    display: none !important;
  }

  .feature-card.disabled,
  .feature-card.pending {
    opacity: .82;
    filter: none;
  }

  .pending-section {
    margin-top: 2px;
  }

  .pending-section h2 {
    font-size: 19px;
  }
}

/* Mobile cover tool: compact production layout, no repeated license badge. */
@media (max-width: 520px) {
  #toolApp {
    background:
      radial-gradient(circle at 8% 0%, rgba(var(--ds-primary-rgb), .12), transparent 220px),
      #fbfcfa;
  }

  #toolApp .topbar {
    min-height: 58px;
    padding-left: 12px;
    padding-right: 12px;
    align-items: center;
    gap: 8px;
    background: rgba(255,255,255,.94);
    border-bottom-color: rgba(228,230,225,.78);
    overflow: visible;
  }

  #toolApp .brand {
    min-width: 0;
    flex: 1 1 auto;
    gap: 8px;
  }

  #toolApp .back-btn {
    width: 42px;
    min-width: 42px;
    height: 42px;
    border-radius: 16px;
    padding: 0;
    color: #2b302b;
    background: rgba(20,24,20,.07);
    font-size: 12px;
    font-weight: 600;
  }

  #toolApp .brand-mark {
    display: none;
  }

  #toolApp .brand div {
    display: block;
    min-width: 0;
  }

  #toolApp .brand strong {
    max-width: none;
    color: #171917;
    font-size: 18px;
    line-height: 1.05;
    font-weight: 700;
    white-space: normal;
  }

  #toolApp .brand small,
  #toolApp .license-badge {
    display: none !important;
  }

  #toolApp .top-actions {
    flex: 0 0 auto;
    gap: 8px;
    margin-left: 0;
  }

  #toolApp .top-actions button,
  #toolApp .top-actions a {
    min-width: 54px;
    height: 42px !important;
    padding: 0 12px !important;
    border-radius: 16px;
    font-size: 13px;
    line-height: 1;
    font-weight: 700;
  }

  #toolApp .quiet-btn {
    background: rgba(20,24,20,.07);
    color: #2b302b;
  }

  #toolApp .export-btn {
    min-width: 94px;
    gap: 6px;
    background: var(--ds-primary);
    color: #101510;
    box-shadow: 0 10px 26px rgba(var(--ds-primary-rgb), .20);
  }

  #toolApp .export-btn svg {
    width: 16px;
  }

  #toolApp .workspace {
    display: block;
    min-height: auto;
  }

  #toolApp .preview-panel {
    padding: 10px 12px 18px;
    background: rgba(255,255,255,.42);
    transition: padding .22s cubic-bezier(.2,.8,.2,1), background-color .22s cubic-bezier(.2,.8,.2,1);
  }

  #toolApp .preview-head {
    height: 24px;
    margin-bottom: 6px;
    font-size: 11px;
  }

  #toolApp .preview-head > div {
    gap: 7px;
  }

  #toolApp .status-dot {
    width: 7px;
    height: 7px;
    box-shadow: 0 0 0 4px rgba(var(--ds-primary-rgb), .20);
  }

  #toolApp #sizeLabel {
    color: rgba(23,25,22,.52);
    font-size: 11px;
  }

  #toolApp .canvas-stage {
    border-radius: 20px;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.08), 0 14px 34px rgba(29,36,29,.10);
  }

  #toolApp .canvas-tip {
    bottom: 10px;
    max-width: calc(100% - 36px);
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(13,16,13,.66);
    color: rgba(255,255,255,.78);
    font-size: 10px;
    line-height: 1.2;
  }

  #toolApp .crop-safe-area b,
  #toolApp .crop-safe-area i {
    font-size: 8px;
    padding: 4px 6px;
  }

  #toolApp .editor-panel {
    padding: 16px 16px calc(34px + var(--android-nav-bar));
  }
}

@media (max-width: 720px) {
  #toolApp .workspace,
  body.android-app #toolApp .workspace,
  #posterToolApp .workspace,
  body.android-app #posterToolApp .workspace {
    display: grid !important;
    grid-template-columns: 1fr !important;
    grid-template-rows: 35% 65% !important;
    height: calc(100dvh - var(--topbar-height) - var(--app-safe-top, 0px)) !important;
    min-height: 0 !important;
    overflow: hidden !important;
  }

  #toolApp .preview-panel,
  body.android-app #toolApp .preview-panel,
  #posterToolApp .preview-panel,
  body.android-app #posterToolApp .preview-panel {
    position: relative !important;
    top: auto !important;
    height: auto !important;
    min-height: 0 !important;
    padding: 8px 12px 10px !important;
    overflow: hidden !important;
    background: rgba(255,255,255,.78);
  }

  #toolApp .editor-panel,
  body.android-app #toolApp .editor-panel,
  #posterToolApp .editor-panel,
  body.android-app #posterToolApp .editor-panel {
    height: auto !important;
    min-height: 0 !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
    border-left: 0 !important;
    border-top: 1px solid rgba(227,229,224,.9) !important;
    padding: 12px 16px calc(32px + var(--app-safe-bottom, 0px)) !important;
  }

  #toolApp .preview-head,
  #posterToolApp .preview-head {
    min-height: 22px !important;
    margin-bottom: 4px !important;
  }

  #toolApp .canvas-stage,
  #posterToolApp .poster-canvas-stage {
    margin: 0 auto !important;
    border-radius: 16px !important;
  }
  #posterToolApp .poster-canvas-stage {
    padding: 10px !important;
    background: #f7f8f6 !important;
    background-image: none !important;
  }
}

.asset-entry {
  border-color: #2CFF73;
  background: linear-gradient(145deg, #eefdf4, #ffffff);
}

.asset-shell {
  min-height: calc(100vh - var(--topbar-height));
  padding: 28px 34px calc(44px + var(--android-nav-bar));
  background: #f8faf9;
}

.asset-hero {
  width: min(1180px, 100%);
  margin: 0 auto 18px;
  padding: 28px;
  border: 1px solid #ecefed;
  border-radius: 12px;
  background: #fff;
  display: grid;
  grid-template-columns: 1fr minmax(280px, 420px);
  gap: 20px;
  align-items: end;
  box-shadow: 0 10px 28px rgba(16, 21, 16, .05);
}

.asset-hero p, .asset-detail-head p, .asset-item-card p, .asset-link-dialog p {
  margin: 0 0 6px;
  color: #0a9d47;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .14em;
}

.asset-hero h1 {
  margin: 0;
  font-size: 34px;
  letter-spacing: 0;
}

.asset-hero span, .asset-detail-head span, .asset-item-card span, .asset-item-card small {
  color: #7f877f;
  font-size: 12px;
  line-height: 1.6;
}

.asset-search {
  height: 46px;
  padding: 0 14px;
  border: 1px solid #dde3dd;
  border-radius: 12px;
  display: flex;
  gap: 10px;
  align-items: center;
  background: #fafcfb;
}

.asset-search svg {
  width: 18px;
  fill: none;
  stroke: #7b827b;
  stroke-width: 1.8;
}

.asset-search input {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
}

.asset-layout {
  width: min(1180px, 100%);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 230px 1fr;
  gap: 18px;
  align-items: start;
}

.asset-filter-panel, .asset-main-panel, .asset-detail {
  border: 1px solid #ecefed;
  border-radius: 12px;
  background: #fff;
}

.asset-filter-panel {
  position: sticky;
  top: calc(var(--topbar-height) + 18px);
  padding: 16px;
  display: grid;
  gap: 14px;
}

.asset-filter-panel label {
  display: grid;
  gap: 7px;
  color: #687068;
  font-size: 11px;
}

.asset-filter-panel select {
  height: 42px;
  border: 1px solid #dde3dd;
  border-radius: 10px;
  background: #fafcfb;
  padding: 0 10px;
}

.asset-main-panel {
  padding: 16px;
}

.asset-product-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.asset-product-card {
  min-height: 260px;
  padding: 16px;
  border: 1px solid #edf0ed;
  border-radius: 12px;
  background: #fff;
  display: grid;
  gap: 14px;
  text-align: left;
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(16, 21, 16, .05);
}

.asset-product-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 34px rgba(16, 21, 16, .09);
}

.asset-product-art, .asset-detail-art {
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: linear-gradient(135deg, #effcf4, #eef5ff);
  color: #101510;
  font-size: 46px;
  font-weight: 700;
  overflow: hidden;
}

.asset-product-art {
  aspect-ratio: 4 / 3;
}

.asset-product-art img, .asset-detail-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.asset-product-meta {
  display: grid;
  gap: 4px;
}

.asset-product-meta small {
  color: #0a9d47;
  font-size: 11px;
}

.asset-product-meta strong {
  font-size: 19px;
  line-height: 1.3;
}

.asset-product-meta em {
  width: fit-content;
  padding: 5px 8px;
  border-radius: 999px;
  background: #eff3ef;
  color: #5e665e;
  font-size: 11px;
  font-style: normal;
}

.asset-product-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.asset-product-foot b, .asset-detail-stats span {
  color: #5f675f;
  font-size: 12px;
}

.asset-product-foot i, .asset-detail-stats i, .asset-item-card em {
  padding: 5px 8px;
  border-radius: 999px;
  background: #eafbf0;
  color: #0a873e;
  font-size: 10px;
  font-style: normal;
}

.asset-product-foot i.incomplete, .asset-product-foot i.archived, .asset-detail-stats i.incomplete, .asset-detail-stats i.archived {
  background: #f1f2f1;
  color: #737b73;
}

.asset-updated {
  color: #99a099;
  font-size: 11px;
}

.asset-empty {
  padding: 34px;
  text-align: center;
  color: #909890;
  font-size: 13px;
}

.asset-detail {
  width: min(1180px, 100%);
  margin: 0 auto;
  padding: 18px;
}

.asset-detail-back {
  border: 0;
  border-radius: 10px;
  background: #eef2ef;
  padding: 10px 12px;
  cursor: pointer;
}

.asset-detail-head {
  margin-top: 14px;
  display: grid;
  grid-template-columns: 150px 1fr auto;
  gap: 18px;
  align-items: center;
}

.asset-detail-art {
  width: 150px;
  height: 112px;
}

.asset-detail-head h2 {
  margin: 0;
  font-size: 28px;
}

.asset-detail-stats {
  min-width: 120px;
  display: grid;
  justify-items: end;
  gap: 4px;
}

.asset-detail-stats strong {
  font-size: 34px;
}

.asset-tabs {
  margin: 20px 0 14px;
  display: flex;
  gap: 8px;
  overflow-x: auto;
}

.asset-tabs button {
  flex: 0 0 auto;
  border: 1px solid #e2e7e2;
  border-radius: 999px;
  background: #fff;
  padding: 9px 13px;
  cursor: pointer;
}

.asset-tabs button.active {
  border-color: #2CFF73;
  background: #eafbf0;
  color: #087f3b;
}

.asset-list {
  display: grid;
  gap: 12px;
}

.asset-item-card {
  padding: 16px;
  border: 1px solid #edf0ed;
  border-radius: 12px;
  display: grid;
  grid-template-columns: 92px 1fr minmax(140px, auto) auto;
  gap: 16px;
  align-items: center;
  background: #fff;
}

.asset-preview-thumb {
  width: 92px;
  height: 72px;
  border: 0;
  border-radius: 14px;
  display: grid;
  place-items: center;
  overflow: hidden;
  color: #0b7e3c;
  background: linear-gradient(145deg, #eafff1, #eef6ff);
  cursor: pointer;
  font-weight: 800;
}

.asset-preview-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.asset-preview-thumb span {
  width: 42px;
  height: 42px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: #101510;
  background: rgba(var(--ds-primary-rgb), .62);
  font-size: 18px;
}

.asset-item-card h3 {
  margin: 0 0 5px;
  font-size: 18px;
}

.asset-tags {
  margin-top: 10px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.asset-tags b {
  padding: 4px 7px;
  border-radius: 999px;
  background: #f2f5f2;
  color: #656c65;
  font-size: 10px;
}

.asset-link-summary {
  display: grid;
  gap: 6px;
  justify-items: start;
}

.asset-link-summary b {
  width: fit-content;
  padding: 5px 9px;
  border-radius: 999px;
  color: #087f3b;
  background: rgba(var(--ds-primary-rgb), .13);
  font-size: 11px;
}

.asset-link-summary b.external {
  color: #8a5b00;
  background: #fff3d2;
}

.asset-link-summary b.mixed {
  color: #2f66a5;
  background: #e9f4ff;
}

.asset-link-summary span.expired {
  color: #b34b31;
}

.asset-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.asset-actions button, .asset-link-list button {
  border: 0;
  border-radius: 10px;
  background: #101510;
  color: #fff;
  padding: 10px 12px;
  cursor: pointer;
  font-size: 12px;
}

.asset-actions button:nth-child(n+2), .asset-link-list button:nth-child(n+3) {
  background: #edf2ee;
  color: #283028;
}

.asset-link-dialog {
  width: min(560px, calc(100% - 28px));
  border: 0;
  border-radius: 16px;
  padding: 0;
}

.asset-link-dialog::backdrop {
  background: rgba(10, 14, 10, .38);
}

.asset-link-dialog > div {
  position: relative;
  padding: 22px;
}

.asset-link-dialog h2 {
  margin: 0 0 14px;
}

.asset-link-list {
  display: grid;
  gap: 10px;
}

.asset-link-list article {
  padding: 12px;
  border: 1px solid #edf0ed;
  border-radius: 12px;
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 8px;
  align-items: center;
}

.asset-link-list article div {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.asset-link-list span, .asset-link-list small {
  color: #747c74;
  font-size: 11px;
  overflow-wrap: anywhere;
}

.asset-external-dialog span {
  display: block;
  margin-bottom: 14px;
  color: #747c74;
  overflow-wrap: anywhere;
}

.asset-password-card {
  display: grid;
  gap: 6px;
  margin: 14px 0;
  padding: 14px;
  border-radius: 12px;
  border: 1px solid rgba(var(--ds-primary-rgb), .32);
  background: rgba(var(--ds-primary-rgb), .1);
}

.asset-password-card small {
  color: #047336;
  font-size: 12px;
}

.asset-password-card strong {
  font-size: 22px;
  letter-spacing: .08em;
}

.asset-preview-body {
  display: grid;
  gap: 16px;
}

.asset-preview-visual {
  min-height: 220px;
  border-radius: 18px;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: linear-gradient(145deg, #eafff1, #eef6ff);
}

.asset-preview-visual img {
  width: 100%;
  height: 100%;
  max-height: 320px;
  object-fit: cover;
}

.asset-preview-visual video {
  width: 100%;
  height: 100%;
  max-height: 68vh;
  border-radius: 16px;
  background: #111;
  object-fit: contain;
}

.asset-zspace-preview {
  height: min(72vh, 720px);
  min-height: 520px;
  border-radius: 20px;
  overflow: hidden;
  background: #f5f8f5;
  border: 1px solid var(--ds-border);
}

.asset-zspace-preview iframe {
  width: 100%;
  height: 100%;
  border: 0;
  background: #fff;
}

.asset-video-mark {
  min-width: 78px;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #087f3b;
  background: rgba(var(--oppo-primary-rgb), .16);
  font-size: 12px;
  font-weight: 800;
}

.asset-preview-visual.empty span {
  width: 78px;
  height: 78px;
  border-radius: 24px;
  display: grid;
  place-items: center;
  color: #101510;
  background: var(--ds-primary);
  font-size: 28px;
  font-weight: 800;
}

.asset-preview-info {
  display: grid;
  gap: 10px;
}

.asset-preview-info strong {
  font-size: 15px;
}

.asset-preview-info p {
  margin: 0;
  color: #737b73;
  font-size: 13px;
  line-height: 1.7;
}

.asset-preview-info dl {
  margin: 0;
  display: grid;
  gap: 8px;
}

.asset-preview-info dl div {
  display: grid;
  grid-template-columns: 86px 1fr;
  gap: 10px;
  color: #535b53;
  font-size: 12px;
}

.asset-preview-info dt {
  color: #8c948c;
}

.asset-preview-info dd {
  margin: 0;
  overflow-wrap: anywhere;
}

.asset-preview-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.asset-preview-actions button {
  border: 0;
  border-radius: 12px;
  background: #101510;
  color: #fff;
  padding: 11px 14px;
  cursor: pointer;
  font-weight: 700;
}

.asset-preview-actions button:nth-child(n+2) {
  color: #087f3b;
  background: rgba(var(--ds-primary-rgb), .14);
}

.asset-external-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  margin-top: 18px;
}

.asset-external-actions button {
  min-height: 42px;
}

@media (max-width: 900px) {
  .asset-shell {
    padding: 16px 12px calc(28px + var(--android-nav-bar));
  }

  .asset-hero {
    grid-template-columns: 1fr;
    padding: 20px;
  }

  .asset-hero h1 {
    font-size: 27px;
  }

  .asset-layout {
    grid-template-columns: 1fr;
  }

  .asset-filter-panel {
    position: static;
    grid-template-columns: 1fr;
  }

  .asset-product-grid {
    grid-template-columns: 1fr;
  }

  .asset-detail-head {
    grid-template-columns: 92px 1fr;
  }

  .asset-detail-art {
    width: 92px;
    height: 92px;
    font-size: 32px;
  }

  .asset-detail-stats {
    grid-column: 1 / -1;
    justify-items: start;
  }

  .asset-item-card {
    grid-template-columns: 1fr;
  }

  .asset-preview-thumb {
    width: 100%;
    height: 112px;
  }

  .asset-actions {
    justify-content: stretch;
  }

  .asset-actions button,
  .asset-preview-actions button {
    flex: 1;
    min-height: 44px;
  }

  .asset-link-list article {
    grid-template-columns: 1fr;
  }
}

/* Commercial UI consolidation: final cross-platform contract. */
.launch-shell {
  padding-top: var(--ds-space-4);
}

body.android-app .launch-shell {
  padding-top: 0;
}

.launch-appbar {
  box-sizing: border-box;
  position: sticky;
  top: 0;
}

body.android-app .launch-appbar {
  min-height: calc(56px + var(--android-status-bar));
  padding-top: var(--android-status-bar);
  align-items: center;
}

.launch-hero {
  border-radius: var(--oppo-r-panel);
}

.feature-card,
.feature-card.available,
.feature-card.long-entry,
.feature-card.poster-entry,
.feature-card.cover-pro-entry,
.asset-entry {
  border-radius: var(--ds-radius-card);
  background: var(--ds-surface);
  border-color: var(--ds-border);
  box-shadow: none;
}

.feature-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, .08);
}

.feature-card.featured {
  border-color: var(--ds-primary);
  background:
    radial-gradient(circle at 18% 12%, rgba(var(--ds-primary-rgb), .14), transparent 150px),
    var(--ds-surface);
  box-shadow: 0 0 0 1px rgba(var(--ds-primary-rgb), .14), 0 0 28px rgba(var(--ds-primary-rgb), .22);
}

.feature-card.recommended {
  border-color: rgba(var(--ds-primary-rgb), .38);
}

.feature-card.pending,
.feature-card.disabled {
  opacity: .6;
  filter: grayscale(1);
}

.feature-card.pending:hover,
.feature-card.disabled:hover {
  transform: none;
  box-shadow: none;
}

.feature-card .tool-icon,
.pending-tools .feature-card .tool-icon,
.feature-card.poster-entry .tool-icon,
.feature-card.long-entry .tool-icon,
.feature-card.cover-pro-entry .tool-icon {
  background: transparent;
  color: inherit;
}

.feature-card strong,
.tool-section h2,
.launch-hero h1,
.brand strong {
  letter-spacing: 0;
}

@media (max-width: 719px) {
  .open-tools,
  .pending-tools,
  .feature-grid {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 720px) and (max-width: 1079px) {
  .open-tools,
  .pending-tools,
  .feature-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1080px) {
  .open-tools,
  .pending-tools,
  .feature-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 520px) {
  .launch-shell {
    padding: 8px var(--ds-space-4) calc(var(--ds-space-5) + var(--android-nav-bar));
  }

  body.android-app .launch-shell {
    padding-top: 0;
  }

  .launch-appbar {
    min-height: 52px;
    margin-bottom: var(--ds-space-3);
  }

  body.android-app .launch-appbar {
    min-height: calc(52px + var(--android-status-bar));
  }

  .launch-license-pill,
  .launch-icon-btn {
    height: 40px;
    min-height: 40px;
  }

  .launch-mini-mark {
    width: 40px;
    height: 40px;
    border-radius: var(--ds-radius-card);
  }

  .launch-hero {
    min-height: 168px;
    padding: var(--ds-space-5);
    border-radius: var(--oppo-r-panel);
  }

  .launch-hero h1 {
    max-width: 100%;
    font-size: 24px;
    line-height: 1.28;
    font-weight: 700;
  }

  .tool-section h2 {
    font-size: 18px;
  }

  .feature-card {
    min-height: 132px;
    padding: var(--ds-space-4);
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    grid-template-rows: auto auto;
    column-gap: var(--ds-space-3);
    row-gap: var(--ds-space-2);
  }

  .feature-card .tool-icon {
    width: 44px;
    height: 44px;
    margin: 0;
  }

  .feature-card strong {
    align-self: center;
    font-size: 16px;
    line-height: 1.35;
  }

  .feature-card small {
    grid-column: 2 / 3;
    margin-top: 0;
    font-size: 12px;
  }

  #toolApp .topbar,
  #longToolApp .topbar,
  #posterToolApp .topbar,
  #coverProToolApp .topbar,
  #assetToolApp .topbar {
    min-height: 56px;
    padding-top: 0;
  }

  body.android-app #toolApp .topbar,
  body.android-app #longToolApp .topbar,
  body.android-app #posterToolApp .topbar,
  body.android-app #coverProToolApp .topbar,
  body.android-app #assetToolApp .topbar {
    min-height: calc(56px + var(--android-status-bar));
    padding-top: var(--android-status-bar);
  }
}

@media (max-width: 520px) {
  .feature-grid,
  .open-tools,
  .pending-tools {
    gap: 16px;
  }

  .feature-card {
    min-height: 124px;
    padding: 14px;
  }

  .feature-card strong {
    font-size: 18px;
    line-height: 1.28;
  }

  .feature-card small {
    font-size: 13px;
    line-height: 1.45;
  }
}

/* Android WebView system bars: final override.
   top = status bar + display cutout safe inset, bottom = gesture/navigation bar. */
body.android-app {
  min-height: 100dvh;
}

body.android-app .launch-shell {
  min-height: 100dvh;
  padding-top: 3px !important;
  padding-bottom: var(--app-safe-bottom) !important;
}

body.android-app .launch-appbar {
  min-height: 56px !important;
  padding-top: var(--app-safe-top, env(safe-area-inset-top, 0px)) !important;
  margin-top: 0 !important;
  position: sticky !important;
  top: 0 !important;
}

body.android-app .activation-gate {
  padding-top: calc(var(--app-safe-top) + 12px);
  padding-bottom: calc(var(--app-safe-bottom) + 12px);
}

body.android-app .activation-card {
  max-height: calc(100dvh - var(--app-safe-top) - var(--app-safe-bottom) - 24px);
}

body.android-app .topbar {
  min-height: var(--topbar-height);
}

body.android-app .workspace {
  min-height: calc(100dvh - var(--topbar-height) - var(--app-safe-top));
}

body.android-app .preview-panel {
  top: calc(var(--topbar-height) + var(--app-safe-top));
  height: calc(100dvh - var(--topbar-height) - var(--app-safe-top));
}

body.android-app .editor-panel,
body.android-app .long-editor-panel,
body.android-app .poster-editor-panel,
body.android-app .cover-pro-editor-panel,
body.android-app .asset-panel {
  padding-bottom: max(24px, var(--app-safe-bottom));
}

@media (max-width: 520px) {
  body.android-app .launch-shell {
    padding-top: 3px !important;
    padding-bottom: var(--app-safe-bottom) !important;
  }

  body.android-app #toolApp .topbar,
  body.android-app #longToolApp .topbar,
  body.android-app #posterToolApp .topbar,
  body.android-app #coverProToolApp .topbar,
  body.android-app #assetToolApp .topbar {
    min-height: 56px !important;
  }
}

/* Safe-area contract: every APP/Web surface follows the same status-bar rule.
   Do not add fixed status-bar heights here; Android injects --app-safe-* and
   iOS/browser uses env(safe-area-inset-*). */
html {
  box-sizing: border-box;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

body {
  padding-top: env(safe-area-inset-top);
  padding-bottom: env(safe-area-inset-bottom);
}

body.android-app {
  padding-top: env(safe-area-inset-top) !important;
  padding-bottom: env(safe-area-inset-bottom) !important;
}

.launch-shell {
  padding-top: 8px !important;
  padding-bottom: calc(28px + env(safe-area-inset-bottom)) !important;
}

body.android-app .launch-shell {
  padding-top: 8px !important;
  padding-bottom: calc(28px + env(safe-area-inset-bottom)) !important;
}

/* Android mobile home P0: tool descriptions remain legible in the 390px dual-column grid. */
@media (max-width: 520px) {
  body.android-app #openToolGrid.feature-grid .feature-card small {
    font-size: 13px !important;
  }
}

.launch-hero {
  margin-top: 8px !important;
}

body.android-app .launch-hero {
  margin-top: 8px !important;
}

body.android-app .launch-appbar {
  padding-top: var(--app-safe-top, env(safe-area-inset-top, 0px)) !important;
}

/* Topbar safe-area padding is owned by the base .topbar rule via --android-status-bar. */

.workspace,
body.android-app .workspace,
.long-workspace,
.poster-workspace,
.cover-pro-workspace {
  min-height: calc(100dvh - var(--topbar-height) - var(--app-safe-top, 0px)) !important;
}

.preview-panel,
body.android-app .preview-panel {
  top: calc(var(--topbar-height) + var(--app-safe-top, 0px)) !important;
  height: calc(100dvh - var(--topbar-height) - var(--app-safe-top, 0px)) !important;
}

body.android-app .preview-panel {
  top: calc(var(--topbar-height) + var(--app-safe-top, 0px)) !important;
  height: calc(100dvh - var(--topbar-height) - var(--app-safe-top, 0px)) !important;
}

@media (max-width: 720px) {
  body.android-app .top-actions button,
  body.android-app .top-actions a,
  body.android-app #toolApp .top-actions button,
  body.android-app #posterToolApp .top-actions button,
  body.android-app #longToolApp .top-actions button,
  body.android-app #coverProToolApp .top-actions button,
  body.android-app #assetToolApp .top-actions button {
    height: auto !important;
    min-height: 42px;
    line-height: 1.15;
    white-space: normal;
    text-align: center;
  }

  body.android-app .preview-head {
    height: auto;
    min-height: 30px;
    flex-wrap: wrap;
    gap: 6px 12px;
    line-height: 1.25;
  }
}

.long-canvas-stage,
.canvas-stage,
.long-editor-panel,
.poster-editor-panel,
.cover-pro-editor-panel,
.editor-panel {
  box-sizing: border-box;
}

.long-canvas-stage,
#longCanvas {
  touch-action: none;
  -webkit-user-select: none;
  user-select: none;
}

.long-canvas-stage.is-dragging,
.long-canvas-stage.is-dragging #longCanvas {
  cursor: grabbing;
}

@media (max-width: 720px) {
  .preview-panel,
  body.android-app .preview-panel {
    top: auto !important;
    height: auto !important;
  }

  #posterToolApp .poster-workspace,
  body.android-app #posterToolApp .poster-workspace {
    display: block !important;
    height: auto !important;
    min-height: 0 !important;
    overflow: visible !important;
    grid-template-rows: none !important;
  }

  #posterToolApp .poster-preview-panel,
  body.android-app #posterToolApp .poster-preview-panel {
    position: relative !important;
    top: auto !important;
    z-index: 1 !important;
    height: clamp(360px, 44vh, 480px) !important;
    min-height: 0 !important;
    overflow: hidden !important;
    background: #fff !important;
  }

  #posterToolApp .poster-canvas-stage,
  body.android-app #posterToolApp .poster-canvas-stage {
    height: var(--poster-stage-height, 330px) !important;
    max-width: 100% !important;
    overflow: hidden !important;
    padding: 10px !important;
    background: #f7f8f6 !important;
    background-image: none !important;
  }

  #posterToolApp .poster-editor-panel,
  body.android-app #posterToolApp .poster-editor-panel {
    position: relative !important;
    z-index: 2 !important;
    height: auto !important;
    min-height: 0 !important;
    overflow: visible !important;
    background: #fff !important;
    opacity: 1 !important;
  }

  #posterToolApp .poster-edit-hint strong {
    top: -30px;
    font-size: 10px;
  }

  #posterToolApp .topbar,
  body.android-app #posterToolApp .topbar {
    min-height: 70px !important;
    padding: var(--android-status-bar) 12px 0 !important;
    gap: 8px !important;
  }

  #posterToolApp .brand,
  body.android-app #posterToolApp .brand {
    gap: 8px !important;
    min-width: 0 !important;
  }

  #posterToolApp .poster-mark,
  body.android-app #posterToolApp .poster-mark {
    width: 46px !important;
    height: 46px !important;
    border-radius: 14px !important;
    font-size: 24px !important;
    flex: 0 0 46px !important;
  }

  #posterToolApp .brand strong,
  body.android-app #posterToolApp .brand strong {
    display: block !important;
    max-width: 120px !important;
    font-size: 16px !important;
    line-height: 1.15 !important;
    white-space: nowrap !important;
  }

  #posterToolApp .brand small,
  body.android-app #posterToolApp .brand small {
    display: none !important;
  }

  #posterToolApp .top-actions,
  body.android-app #posterToolApp .top-actions {
    gap: 6px !important;
  }

  #posterToolApp .top-actions button,
  body.android-app #posterToolApp .top-actions button {
    min-height: 42px !important;
    height: 42px !important;
    padding: 0 12px !important;
    border-radius: 14px !important;
    font-size: 13px !important;
    line-height: 1 !important;
    white-space: nowrap !important;
  }

  #posterToolApp .export-btn,
  body.android-app #posterToolApp .export-btn {
    padding: 0 14px !important;
    gap: 6px !important;
  }

  #posterToolApp .export-btn [data-lf-icon],
  body.android-app #posterToolApp .export-btn [data-lf-icon] {
    width: 18px !important;
    height: 18px !important;
  }
}

/* Workbench homepage extensions */
.workbench-row {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 16px;
  margin: 18px 0 22px;
}

/* Official sample watermark editor */
.sample-watermark-app {
  min-height: 100dvh;
  background: #000;
  color: #f7f7f4;
}

.sample-watermark-shell {
  min-height: 100dvh;
  padding: calc(14px + var(--app-safe-top, 0px)) 0 calc(92px + var(--app-safe-bottom, 0px));
  display: grid;
  grid-template-rows: minmax(260px, 1fr) auto;
  background: #000;
}

.sample-preview-area {
  min-height: 0;
  display: grid;
  grid-template-rows: minmax(220px, 1fr) 26px;
  gap: 8px;
  padding: 0 22px;
}

.sample-preview-frame {
  position: relative;
  min-height: 260px;
  display: grid;
  place-items: center;
  overflow: hidden;
  touch-action: none;
}

.sample-preview-frame.is-dragging {
  cursor: grabbing;
}

#sampleWatermarkCanvas {
  display: block;
  max-width: 100%;
  max-height: 100%;
  background: #111;
  box-shadow: 0 18px 70px rgba(0,0,0,.72);
  cursor: grab;
  touch-action: none;
  -webkit-user-select: none;
  user-select: none;
}

.sample-empty-state {
  position: absolute;
  inset: 24px 0;
  width: min(520px, calc(100% - 24px));
  margin: auto;
  min-height: 260px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 28px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 12px;
  color: rgba(255,255,255,.76);
  background:
    radial-gradient(circle at 50% 20%, rgba(255,255,255,.1), transparent 32%),
    linear-gradient(180deg, rgba(255,255,255,.08), rgba(255,255,255,.025));
  cursor: pointer;
}

.sample-empty-state[hidden] {
  display: none !important;
}

.sample-empty-state span {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #101010;
  background: #f1f1ef;
  font-size: 13px;
  font-weight: 800;
}

.sample-empty-state strong {
  font-size: 20px;
  letter-spacing: 0;
}

.sample-empty-state small {
  max-width: 260px;
  color: rgba(255,255,255,.42);
  font-size: 12px;
  line-height: 1.6;
  text-align: center;
}

.sample-preview-meta {
  display: flex;
  justify-content: center;
  gap: 16px;
  color: rgba(255,255,255,.38);
  font-size: 12px;
}

.sample-control-area {
  padding: 16px 22px 10px;
  display: grid;
  gap: 18px;
}

.sample-template-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.sample-template-row label {
  display: grid;
  gap: 7px;
  color: rgba(255,255,255,.34);
  font-size: 12px;
}

.sample-template-row select,
.sample-template-row input {
  width: 100%;
  height: 42px;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 14px;
  padding: 0 12px;
  color: rgba(255,255,255,.86);
  background: #171717;
  outline: none;
}

.sample-batch-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.sample-upload-btn {
  height: 42px;
  padding: 0 16px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  color: #101010;
  background: #f2f2f0;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.sample-batch-row span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: rgba(255,255,255,.38);
  font-size: 12px;
}

.sample-slider-row {
  display: grid;
  gap: 12px;
}

.sample-slider-row div,
.sample-position-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: rgba(255,255,255,.34);
  font-size: 15px;
}

.sample-slider-row strong,
.sample-position-head strong {
  color: rgba(255,255,255,.86);
  font-weight: 600;
}

.sample-slider-row input[type="range"] {
  width: 100%;
  height: 38px;
  appearance: none;
  background: transparent;
}

.sample-slider-row input[type="range"]::-webkit-slider-runnable-track {
  height: 12px;
  border-radius: 999px;
  background: linear-gradient(90deg, #fff 0%, #fff 52%, #444 52%, #444 100%);
}

.sample-slider-row input[type="range"]::-webkit-slider-thumb {
  appearance: none;
  width: 34px;
  height: 34px;
  margin-top: -11px;
  border: 0;
  border-radius: 50%;
  background: #f4f4f2;
  box-shadow: 0 2px 10px rgba(0,0,0,.45);
}

.sample-anchor-strip {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 132px;
  gap: 12px;
  overflow-x: auto;
  padding: 2px 0 6px;
  scrollbar-width: none;
}

.sample-anchor-strip::-webkit-scrollbar {
  display: none;
}

.sample-anchor-strip button {
  height: 92px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 9px;
  position: relative;
  color: rgba(255,255,255,.48);
  background: #171717;
  cursor: pointer;
}

.sample-anchor-strip button.active {
  border-color: #fff;
  box-shadow: inset 0 0 0 2px #fff;
}

.sample-anchor-strip button i {
  position: absolute;
  inset: 15px;
  border-radius: 4px;
  background-image: radial-gradient(circle, rgba(255,255,255,.14) 1.4px, transparent 1.6px);
  background-size: 28px 24px;
}

.sample-anchor-strip button i::before,
.sample-anchor-strip button i::after {
  content: "";
  position: absolute;
  width: 32px;
  height: 6px;
  border-radius: 999px;
  background: rgba(255,255,255,.58);
}

.sample-anchor-strip button i::after {
  width: 44px;
  transform: translateY(12px);
}

.sample-anchor-strip [data-anchor$="left"] i::before,
.sample-anchor-strip [data-anchor$="left"] i::after { left: 6px; }
.sample-anchor-strip [data-anchor$="center"] i::before,
.sample-anchor-strip [data-anchor$="center"] i::after { left: 50%; transform: translateX(-50%); }
.sample-anchor-strip [data-anchor$="center"] i::after { transform: translate(-50%, 12px); }
.sample-anchor-strip [data-anchor$="right"] i::before,
.sample-anchor-strip [data-anchor$="right"] i::after { right: 6px; }
.sample-anchor-strip [data-anchor^="top"] i::before { top: 8px; }
.sample-anchor-strip [data-anchor^="top"] i::after { top: 8px; }
.sample-anchor-strip [data-anchor^="middle"] i::before { top: 38%; }
.sample-anchor-strip [data-anchor^="middle"] i::after { top: 38%; }
.sample-anchor-strip [data-anchor^="bottom"] i::before { bottom: 20px; }
.sample-anchor-strip [data-anchor^="bottom"] i::after { bottom: 20px; }

.sample-anchor-strip button span {
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 7px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 11px;
}

.sample-segment {
  width: 184px;
  height: 58px;
  margin: 0 auto;
  padding: 5px;
  border-radius: 999px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  background: #151515;
}

.sample-segment button {
  border: 0;
  border-radius: 999px;
  color: rgba(255,255,255,.7);
  background: transparent;
  font-size: 18px;
  font-weight: 700;
  cursor: pointer;
}

.sample-segment button.active {
  color: #111;
  background: #f3f3f1;
}

.sample-tab-panel.hidden {
  display: none;
}

.sample-bottom-actions {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 30;
  height: calc(76px + var(--app-safe-bottom, 0px));
  padding: 0 26px var(--app-safe-bottom, 0px);
  display: grid;
  grid-template-columns: 1fr 72px 1fr;
  align-items: center;
  background: linear-gradient(180deg, rgba(0,0,0,0), #000 28%);
}

.sample-bottom-actions button {
  border: 0;
  background: transparent;
  cursor: pointer;
}

.sample-cancel-btn,
.sample-apply-btn {
  color: #ff8a3d;
  font-size: 22px;
  font-weight: 700;
}

.sample-cancel-btn {
  justify-self: start;
}

.sample-apply-btn {
  justify-self: end;
}

.sample-reset-btn {
  justify-self: center;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  color: rgba(255,255,255,.32);
  font-size: 38px;
  line-height: 1;
}

.feature-card.official-watermark-entry {
  border-color: #1b1b1b;
  color: #f6f6f2;
  background: linear-gradient(145deg, #171717, #030303);
}

.feature-card.official-watermark-entry small,
.feature-card.official-watermark-entry span {
  color: rgba(255,255,255,.62);
}

@media (min-width: 900px) {
  .sample-watermark-shell {
    width: min(520px, 100%);
    margin: 0 auto;
    border-left: 1px solid rgba(255,255,255,.08);
    border-right: 1px solid rgba(255,255,255,.08);
  }
}

@media (max-width: 720px) {
  .sample-watermark-shell {
    grid-template-rows: minmax(300px, 48vh) auto;
    padding-bottom: calc(88px + var(--app-safe-bottom, 0px));
  }

  .sample-preview-area {
    padding: 0 14px;
  }

  .sample-control-area {
    padding: 12px 18px 8px;
    gap: 14px;
  }

  .sample-template-row {
    grid-template-columns: 1fr;
  }

  .sample-anchor-strip {
    grid-auto-columns: 118px;
  }
}

/* Keep the official watermark layout section inside the editor panel. */
#sampleWatermarkToolApp .editor-panel,
#sampleWatermarkToolApp .editor-section,
#sampleWatermarkToolApp .sample-tab-panel,
#sampleWatermarkToolApp .sample-position-head {
  min-width: 0;
  max-width: 100%;
}

#sampleWatermarkToolApp .editor-panel,
#sampleWatermarkToolApp .editor-section {
  overflow-x: hidden;
}

#sampleWatermarkToolApp .sample-slider-row {
  width: 100%;
  min-width: 0;
  padding: 14px 16px 16px;
  border: 1px solid #e5ebe3;
  border-radius: 14px;
  background: #f8faf7;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.9);
}

#sampleWatermarkToolApp .sample-slider-row input[type="range"] {
  display: block;
  max-width: 100%;
  --sample-range-progress: 40%;
  height: 28px;
  margin: 4px 0 0;
  appearance: none;
  background: transparent;
  cursor: pointer;
}

#sampleWatermarkToolApp .sample-slider-row input[type="range"]::-webkit-slider-runnable-track {
  height: 8px;
  border-radius: 999px;
  background: linear-gradient(
    90deg,
    #2CFF73 0,
    #2CFF73 var(--sample-range-progress),
    #dfe7de var(--sample-range-progress),
    #dfe7de 100%
  );
  box-shadow: inset 0 1px 2px rgba(16,21,16,.08);
}

#sampleWatermarkToolApp .sample-slider-row input[type="range"]::-webkit-slider-thumb {
  appearance: none;
  width: 24px;
  height: 24px;
  margin-top: -8px;
  border: 4px solid #fff;
  border-radius: 50%;
  background: #111510;
  box-shadow: 0 6px 16px rgba(16,21,16,.18);
}

#sampleWatermarkToolApp .sample-slider-row input[type="range"]:active::-webkit-slider-thumb {
  transform: scale(1.08);
  box-shadow: 0 8px 22px rgba(16,21,16,.22);
}

#sampleWatermarkToolApp .sample-slider-row input[type="range"]::-moz-range-track {
  height: 8px;
  border-radius: 999px;
  background: #dfe7de;
}

#sampleWatermarkToolApp .sample-slider-row input[type="range"]::-moz-range-progress {
  height: 8px;
  border-radius: 999px;
  background: #2CFF73;
}

#sampleWatermarkToolApp .sample-slider-row input[type="range"]::-moz-range-thumb {
  width: 18px;
  height: 18px;
  border: 4px solid #fff;
  border-radius: 50%;
  background: #111510;
  box-shadow: 0 6px 16px rgba(16,21,16,.18);
}

#sampleWatermarkToolApp .sample-slider-row div {
  font-size: 13px;
}

#sampleWatermarkToolApp .sample-slider-row strong {
  min-width: 48px;
  text-align: right;
  color: #101510;
  font-size: 18px;
}

#sampleWatermarkToolApp .sample-anchor-strip {
  width: 100%;
  max-width: 100%;
  min-width: 0;
  display: flex;
  grid-auto-flow: unset;
  grid-auto-columns: unset;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x proximity;
  -webkit-overflow-scrolling: touch;
}

#sampleWatermarkToolApp .sample-anchor-strip button {
  flex: 0 0 104px;
  height: 78px;
  border-radius: 12px;
  scroll-snap-align: start;
}

#sampleWatermarkToolApp .sample-anchor-strip button.active {
  border-color: #101510;
  box-shadow: inset 0 0 0 2px #101510, 0 8px 20px rgba(16,21,16,.08);
}

#sampleWatermarkToolApp .sample-anchor-strip button i {
  inset: 11px 12px 18px;
}

#sampleWatermarkToolApp .sample-anchor-strip button span {
  bottom: 5px;
  font-size: 10px;
}

@media (max-width: 720px) {
  #sampleWatermarkToolApp .sample-anchor-strip {
    padding-right: 14px;
  }

  #sampleWatermarkToolApp .sample-anchor-strip button {
    flex-basis: 96px;
  }
}

/* Final guard: keep tool entry cards stable across WebView/font scaling. */
.feature-grid,
.feature-card {
  min-width: 0;
}

.feature-card {
  overflow: hidden;
  align-content: start;
}

.feature-card .tool-icon {
  flex: 0 0 auto;
}

.feature-card strong,
.feature-card small {
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
}

.feature-card strong {
  white-space: nowrap;
}

.feature-card small {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

/* Homepage bugfix pass 2026-07-03: browser comments. */
@media (max-width: 520px) {
  .launch-hero {
    min-height: 142px !important;
    padding: 18px !important;
  }

  .launch-hero h1 {
    max-width: 238px !important;
    font-size: 20px !important;
    line-height: 1.28 !important;
  }

  .feature-card {
    min-height: 99px !important;
    padding: 12px !important;
    grid-template-columns: 42px minmax(0, 1fr) !important;
    column-gap: 12px !important;
    row-gap: 5px !important;
  }

  .feature-card strong {
    font-size: 15px !important;
    line-height: 1.24 !important;
  }

  .feature-card small {
    font-size: 10px !important;
    line-height: 1.35 !important;
  }
}

.feature-card .tool-icon,
.pending-tools .feature-card .tool-icon,
.feature-card.poster-entry .tool-icon,
.feature-card.long-entry .tool-icon,
.feature-card.cover-pro-entry .tool-icon,
.feature-card.official-watermark-entry .tool-icon,
.feature-card.asset-entry .tool-icon {
  width: 42px !important;
  height: 42px !important;
  min-width: 42px !important;
  min-height: 42px !important;
  margin: 0 !important;
}

.feature-card .tool-icon .lf-icon-tile {
  width: 42px !important;
  height: 42px !important;
  min-width: 42px !important;
  min-height: 42px !important;
}

.feature-card .tool-icon svg,
.feature-card .tool-icon .lf-icon-tile svg {
  width: 21px !important;
  height: 21px !important;
}

.developer-summary {
  margin: 0 0 16px;
  color: rgba(16, 21, 16, .66);
  font-size: 13px;
  line-height: 1.7;
}

.developer-identity,
.developer-role {
  margin: 0;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.5;
}

.developer-identity {
  color: #047336;
}

.developer-role {
  margin-top: 2px;
  color: rgba(16, 21, 16, .72);
}

.developer-dialog .developer-summary {
  margin-top: 10px;
}

.settings-detail dd.developer-contact {
  display: flex;
  min-width: 0;
  justify-content: flex-end;
  flex-wrap: wrap;
  text-align: right;
  word-break: normal;
}

.developer-contact__prefix {
  color: #101510;
}

.developer-contact__name {
  color: #008c45;
  font-weight: 750;
  white-space: nowrap;
}

.message-list {
  display: grid;
  gap: 10px;
  margin: 16px 0;
}

.message-list article {
  padding: 14px;
  border: 1px solid rgba(46, 255, 115, .22);
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(46, 255, 115, .08), rgba(255,255,255,.92));
}

.message-list article span {
  display: block;
  margin-bottom: 7px;
  color: #008c45;
  font-size: 11px;
  font-weight: 700;
}

.message-list article strong {
  display: block;
  color: #101510;
  font-size: 14px;
  line-height: 1.45;
}

.message-list article small {
  display: block;
  margin-top: 7px;
  color: rgba(16, 21, 16, .56);
  font-size: 12px;
  line-height: 1.55;
}

.message-badge {
  position: absolute;
  top: -5px;
  right: -5px;
  min-width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  padding: 0 5px;
  color: #fff;
  background: #f04438;
  box-shadow: 0 0 0 2px #fff;
  font-size: 10px;
  font-style: normal;
  font-weight: 800;
}

.message-badge[hidden] {
  display: none !important;
}

.message-list .message-card {
  cursor: pointer;
  border-color: rgba(220, 226, 220, .94);
  background: #fff;
}

.message-list .message-empty {
  min-height: 96px;
  display: grid;
  place-items: center;
  border-color: rgba(220, 226, 220, .94);
  background: #f7faf7;
  text-align: center;
}

.message-list .message-card.unread {
  border-color: rgba(46, 255, 115, .40);
  background: linear-gradient(135deg, rgba(46, 255, 115, .12), rgba(255,255,255,.96));
}

.message-list .message-card.warning { border-left: 4px solid #f79009; }
.message-list .message-card.success { border-left: 4px solid #12b76a; }
.message-list .message-card.danger { border-left: 4px solid #f04438; }

.message-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 10px;
}

.message-card-foot em {
  color: rgba(16, 21, 16, .46);
  font-size: 11px;
  font-style: normal;
}

.message-card-foot button {
  min-height: 30px;
  border: 0;
  border-radius: 999px;
  padding: 0 11px;
  background: #101510;
  color: #fff;
  font-size: 11px;
  font-weight: 800;
}

.pending-section {
  position: relative;
}

.pending-section h2 {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.pending-section h2::after {
  content: "灵感排队中";
  display: inline-flex;
  align-items: center;
  height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  color: #008c45;
  font-size: 11px;
  font-weight: 700;
  background: linear-gradient(90deg, rgba(46,255,115,.1), rgba(255,255,255,.9), rgba(46,255,115,.16));
  background-size: 220% 100%;
  animation: pendingLightSweep 2.8s ease-in-out infinite;
}

.quick-start-panel,
.hot-template-panel,
.recent-work-section {
  border: 1px solid rgba(229, 235, 229, .95);
  border-radius: 18px;
  background: rgba(255,255,255,.82);
  box-shadow: 0 16px 40px rgba(24, 32, 24, .05);
  padding: 18px;
}

.workbench-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.workbench-head h2 {
  margin: 0;
  font-size: 18px;
  line-height: 1.25;
}

.workbench-head button {
  border: 0;
  background: transparent;
  color: #6c736c;
  cursor: pointer;
  font-size: 13px;
}

.quick-steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.quick-steps button {
  min-height: 108px;
  display: grid;
  align-content: center;
  text-align: left;
  gap: 7px;
  padding: 14px;
  border-radius: 14px;
  background: linear-gradient(145deg, #fff, #f8fbf8);
  border: 1px solid #edf0ed;
  color: inherit;
  cursor: pointer;
  transition: transform 180ms ease, border-color 180ms ease;
}

.quick-steps button:hover {
  transform: translateY(-2px);
  border-color: rgba(44, 255, 115, .55);
}

.quick-steps button:active {
  transform: scale(.98);
}

.quick-steps strong {
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  color: #05a34a;
  background: #e8fff0;
  font-size: 13px;
}

.quick-steps b {
  font-size: 14px;
}

.quick-steps span {
  color: #8a918a;
  font-size: 12px;
  line-height: 1.45;
}

.mobile-tutorial-entry {
  display: none;
}

.tutorial-dialog {
  width: min(760px, calc(100% - 32px));
  max-height: min(820px, calc(100dvh - 32px));
  overflow: hidden;
  border-radius: 24px;
}

.tutorial-detail {
  position: relative;
  max-height: min(820px, calc(100dvh - 32px));
  overflow: auto;
  padding: 28px;
  background: #f8faf8;
}

.tutorial-kicker {
  margin: 0 0 8px;
  color: #048d43;
  font-size: 12px;
  font-weight: 600;
}

.tutorial-header {
  padding: 18px 20px;
  border: 1px solid rgba(44, 255, 115, .28);
  border-radius: 20px;
  background: linear-gradient(145deg, #e7fff0 0%, #fff 60%, #f1fff6 100%);
}

.tutorial-header h2 {
  margin: 0;
  font-size: 24px;
  line-height: 1.25;
}

.tutorial-header p:last-child {
  margin: 9px 0 0;
  color: #687168;
  font-size: 13px;
  line-height: 1.6;
}

.tutorial-overview-head,
.tutorial-guide-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 22px 0 12px;
}

.tutorial-overview-head h3,
.tutorial-guide-head h3 {
  margin: 0;
  font-size: 17px;
}

.tutorial-progress-label {
  color: #778077;
  font-size: 12px;
}

.tutorial-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.tutorial-list button {
  min-height: 112px;
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 16px;
  border: 1px solid #e5ebe7;
  border-radius: 18px;
  background: #fff;
  text-align: left;
  color: #161c17;
  cursor: pointer;
  transition: transform 180ms ease, border-color 180ms ease;
}

.tutorial-list button:hover {
  transform: translateY(-2px);
  border-color: rgba(44, 255, 115, .62);
}

.tutorial-list button > span:first-child,
.tutorial-step-number {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: #e6ffef;
  color: #007f3a;
  font-weight: 600;
}

.tutorial-list strong,
.tutorial-list small {
  display: block;
}

.tutorial-list small {
  margin-top: 5px;
  color: #798279;
  font-size: 12px;
  line-height: 1.45;
}

.tutorial-list em {
  color: #059b49;
  font-size: 12px;
  font-style: normal;
  white-space: nowrap;
}

.tutorial-back {
  border: 0;
  padding: 0;
  background: transparent;
  color: #078c44;
  font-size: 13px;
  cursor: pointer;
}

.tutorial-principle {
  margin: 14px 0 20px;
  padding: 15px 17px;
  border: 1px solid #c4efd4;
  border-radius: 16px;
  background: #e9fff1;
  color: #114a2a;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.55;
}

.tutorial-steps {
  display: grid;
  gap: 10px;
}

.tutorial-step {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  gap: 13px;
  padding: 15px;
  border: 1px solid #e5ebe7;
  border-radius: 17px;
  background: #fff;
}

.tutorial-step h4 {
  margin: 1px 0 5px;
  font-size: 14px;
}

.tutorial-step p,
.tutorial-tips li {
  margin: 0;
  color: #707970;
  font-size: 12px;
  line-height: 1.6;
}

.tutorial-tips {
  margin: 12px 0 20px;
  padding: 16px 18px 16px 34px;
  border: 1px solid #e5ebe7;
  border-radius: 17px;
  background: #fff;
}

.tutorial-tips li + li {
  margin-top: 7px;
}

.tutorial-actions {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
}

.tutorial-actions button {
  min-height: 48px;
  padding: 0 18px;
  border-radius: 16px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

.tutorial-enter-tool {
  border: 0;
  background: #2cff73;
  color: #07371d;
}

.tutorial-complete {
  border: 1px solid #dfe6e1;
  background: #fff;
  color: #536056;
}

.template-strip,
.recent-work-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
}

.template-strip article {
  min-height: 116px;
  display: grid;
  align-content: end;
  padding: 12px;
  border-radius: 14px;
  color: #fff;
  font-weight: 700;
  line-height: 1.35;
  background: linear-gradient(145deg, #0f1b16, #2cff73);
  box-shadow: inset 0 -40px 40px rgba(0,0,0,.2);
}

.template-strip article:nth-child(2) { background: linear-gradient(145deg, #58a6ff, #dff3ff); color: #10304c; }
.template-strip article:nth-child(3) { background: linear-gradient(145deg, #ff4d4f, #ffd7d7); }
.template-strip article:nth-child(4) { background: linear-gradient(145deg, #ffb020, #fff3cb); color: #49310a; }
.template-strip article:nth-child(5) { background: linear-gradient(145deg, #2cff73, #d9ffe6); color: #063d21; }

.recent-work-section {
  margin: 0 0 22px;
}

.recent-work-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.recent-work-grid article,
.recent-work-grid button {
  min-height: 84px;
  border: 1px solid #e8ece8;
  border-radius: 14px;
  background: #fff;
  padding: 12px;
  text-align: left;
}

.recent-work-grid article {
  display: grid;
  grid-template-columns: 54px 1fr;
  column-gap: 10px;
  align-items: center;
}

.recent-work-grid span {
  grid-row: span 2;
  width: 54px;
  height: 54px;
  border-radius: 10px;
  background: linear-gradient(145deg, #d9fff0, #2cff73);
}

.recent-work-grid strong {
  font-size: 13px;
  line-height: 1.35;
}

.recent-work-grid small {
  color: #959c95;
}

.recent-work-grid button {
  display: grid;
  place-items: center;
  color: #7b837b;
  cursor: pointer;
  border-style: dashed;
  font-size: 28px;
}

.recent-work-grid button small {
  display: block;
  margin-top: -12px;
  font-size: 12px;
}

@media (max-width: 980px) {
  .workbench-row,
  .quick-steps {
    grid-template-columns: 1fr;
  }

  .template-strip,
  .recent-work-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Android/mobile type scale guardrail.
   Keeps every APP page readable without allowing system/browser text inflation
   to break cards, headers, toolbars, dialogs, and bottom navigation. */
html,
body {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

/* OPPO Light Field Icon System overrides.
   Feature cards now use .lf-icon-tile from design/icon-map.js; page-local icon
   backgrounds are intentionally neutralized here to avoid double icon bases. */
.feature-card .tool-icon,
.pending-tools .feature-card .tool-icon,
.feature-card.poster-entry .tool-icon,
.feature-card.long-entry .tool-icon,
.feature-card.cover-pro-entry .tool-icon {
  width: auto !important;
  height: auto !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  color: inherit !important;
  font-size: 0 !important;
  display: grid !important;
  place-items: center !important;
}

.feature-card .tool-icon .lf-icon-tile {
  width: var(--lf-icon-tile-md);
  height: var(--lf-icon-tile-md);
}

.feature-card.featured .tool-icon .lf-icon-tile {
  width: var(--lf-icon-tile-lg);
  height: var(--lf-icon-tile-lg);
}

/* Final activation layout guard: license screen must never overflow narrow phones. */
.activation-gate,
body.android-app .activation-gate {
  box-sizing: border-box !important;
  width: 100vw !important;
  max-width: 100vw !important;
  overflow-x: hidden !important;
  overflow-y: auto !important;
  justify-items: center !important;
  align-items: center !important;
  padding-left: 12px !important;
  padding-right: 12px !important;
}

body.android-app .activation-gate {
  padding-top: calc(var(--app-safe-top, 0px) + 12px) !important;
  padding-bottom: calc(var(--app-safe-bottom, 0px) + 12px) !important;
}

.activation-card,
body.android-app .activation-card {
  box-sizing: border-box !important;
  width: min(390px, calc(100vw - 24px)) !important;
  max-width: calc(100vw - 24px) !important;
  min-width: 0 !important;
  overflow-x: hidden !important;
  padding: clamp(22px, 5.2vw, 32px) !important;
}

.activation-card *,
body.android-app .activation-card * {
  box-sizing: border-box !important;
  max-width: 100% !important;
}

.activation-card h1,
body.android-app .activation-card h1 {
  overflow-wrap: anywhere !important;
  font-size: clamp(22px, 6vw, 28px) !important;
}

.activation-desc,
body.android-app .activation-desc {
  overflow-wrap: anywhere !important;
  font-size: clamp(10px, 3vw, 12px) !important;
}

.license-input-wrap,
body.android-app .license-input-wrap {
  width: 100% !important;
  min-width: 0 !important;
}

.license-input-wrap input,
body.android-app .license-input-wrap input {
  min-width: 0 !important;
  width: 0 !important;
  flex: 1 1 auto !important;
  font-size: clamp(13px, 3.7vw, 16px) !important;
  letter-spacing: .035em !important;
}

.license-input-wrap button,
body.android-app .license-input-wrap button {
  flex: 0 0 auto !important;
  padding: 0 12px !important;
}

.demo-license,
body.android-app .demo-license {
  flex-wrap: wrap !important;
  align-items: flex-start !important;
}

.demo-license button,
.contact-developer button,
body.android-app .demo-license button,
body.android-app .contact-developer button {
  white-space: normal !important;
  overflow-wrap: anywhere !important;
  text-align: left !important;
}

.demo-license,
body.android-app .demo-license {
  flex-wrap: nowrap !important;
  justify-content: space-between !important;
  align-items: center !important;
  text-align: left !important;
}

.demo-license button,
body.android-app .demo-license button {
  text-align: right !important;
}

@media (max-width: 720px) {
  body,
  input,
  textarea,
  select,
  button {
    font-size: 13px;
  }

  .launch-brand strong {
    max-width: 112px;
    font-size: 17px !important;
    line-height: 1.12 !important;
  }

  .launch-license-pill {
    font-size: 12px !important;
    line-height: 1.15 !important;
  }

  .launch-icon-btn {
    font-size: 13px !important;
  }

  .launch-hero {
    min-height: 158px !important;
    padding: 20px !important;
  }

  .launch-hero p {
    font-size: 12px !important;
    line-height: 1.25 !important;
  }

  .launch-hero h1 {
    max-width: 250px !important;
    font-size: 25px !important;
    line-height: 1.22 !important;
  }

  .launch-hero small,
  .author-link {
    font-size: 12px !important;
  }

  .tool-section h2,
  .pending-section h2,
  .workbench-head h2,
  .section-title strong {
    font-size: 17px !important;
    line-height: 1.25 !important;
  }

  .feature-card {
    min-height: 132px !important;
    padding: 14px !important;
  }

  .feature-card strong {
    font-size: 15px !important;
    line-height: 1.28 !important;
  }

  .feature-card small {
    font-size: 11px !important;
    line-height: 1.42 !important;
  }

  .feature-card .tool-icon {
    width: 40px !important;
    height: 40px !important;
  }

  .topbar .brand strong,
  #toolApp .brand strong,
  #longToolApp .brand strong,
  #posterToolApp .brand strong,
  #coverProToolApp .brand strong,
  #assetToolApp .brand strong {
    font-size: 15px !important;
    line-height: 1.2 !important;
  }

  .topbar .brand small,
  .preview-head,
  #sizeLabel,
  .field-label,
  .field-help,
  .field-warning {
    font-size: 10px !important;
  }

  .top-actions button,
  .top-actions a,
  .back-btn,
  .quiet-btn,
  .export-btn {
    font-size: 12px !important;
  }

  .editor-section {
    padding-top: 20px;
    padding-bottom: 20px;
  }

  .text-input,
  .poster-control-grid label,
  .official-input-field label,
  .upload-box strong,
  .ratio-card strong,
  .cover-template-card strong,
  .template-card strong,
  .long-layout-card strong,
  .module-grid strong,
  .asset-item-card strong,
  .asset-detail-head strong {
    font-size: 12px !important;
  }

  .upload-box small,
  .ratio-card small,
  .cover-template-card small,
  .template-card small,
  .long-layout-card small,
  .module-grid small,
  .asset-item-card p,
  .asset-detail-head p {
    font-size: 10px !important;
  }

  .activation-card h1 {
    font-size: 25px !important;
    line-height: 1.2 !important;
  }

  .activation-desc {
    font-size: 11px !important;
    line-height: 1.65 !important;
  }

  .license-input-wrap input {
    font-size: 16px !important;
  }

  .workbench-row,
  .recent-work-section {
    display: none;
  }

  .mobile-tutorial-entry {
    width: 100%;
    min-height: 82px;
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr) 20px;
    align-items: center;
    gap: 12px;
    margin: 16px 0 22px;
    padding: 14px 16px;
    border: 1px solid rgba(44, 255, 115, .35);
    border-radius: 18px;
    background: linear-gradient(135deg, #f1fff6, #fff);
    color: #161c17;
    text-align: left;
  }

  .mobile-tutorial-mark {
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border-radius: 15px;
    background: #ddffea;
    color: #00813b;
    font-size: 13px;
    font-weight: 600;
  }

  .mobile-tutorial-entry strong,
  .mobile-tutorial-entry small {
    display: block;
  }

  .mobile-tutorial-entry strong {
    font-size: 15px;
  }

  .mobile-tutorial-entry small {
    margin-top: 4px;
    color: #788078;
    font-size: 11px;
    line-height: 1.4;
  }

  .mobile-tutorial-entry b {
    color: #0b9d4d;
    font-size: 24px;
    font-weight: 400;
  }

  .tutorial-dialog {
    width: 100%;
    max-width: none;
    max-height: calc(100dvh - var(--app-safe-top, 0px) - 10px);
    margin: auto 0 0;
    border-radius: 24px 24px 0 0;
  }

  .tutorial-detail {
    max-height: calc(100dvh - var(--app-safe-top, 0px) - 10px);
    padding: 24px 16px calc(24px + var(--app-safe-bottom, 0px));
  }

  .tutorial-header h2 {
    font-size: 21px;
  }

  .tutorial-list {
    grid-template-columns: 1fr;
  }

  .tutorial-list button {
    min-height: 94px;
  }

  .tutorial-actions {
    grid-template-columns: 1fr;
  }

  #posterToolApp .brand strong,
  body.android-app #posterToolApp .brand strong {
    max-width: 120px !important;
    font-size: 16px !important;
    line-height: 1.15 !important;
    white-space: nowrap !important;
  }

  #posterToolApp .top-actions button,
  body.android-app #posterToolApp .top-actions button {
    font-size: 13px !important;
    white-space: nowrap !important;
  }

}

@media (max-width: 720px) {
  #posterToolApp .poster-workspace,
  body.android-app #posterToolApp .poster-workspace {
    display: grid !important;
    grid-template-columns: 1fr !important;
    grid-template-rows: clamp(330px, 50dvh, 460px) minmax(0, 1fr) !important;
    height: calc(100dvh - var(--topbar-height) - var(--app-safe-top, 0px)) !important;
    min-height: 0 !important;
    overflow: hidden !important;
  }

  #posterToolApp .poster-preview-panel,
  body.android-app #posterToolApp .poster-preview-panel {
    position: relative !important;
    top: auto !important;
    z-index: 1 !important;
    height: auto !important;
    min-height: 0 !important;
    overflow: hidden !important;
    padding: 10px 12px 12px !important;
    background: #fff !important;
  }

  #posterToolApp .poster-canvas-stage,
  body.android-app #posterToolApp .poster-canvas-stage {
    height: var(--poster-stage-height, 330px) !important;
    max-width: 100% !important;
    overflow: hidden !important;
    padding: 10px !important;
    background: #f7f8f6 !important;
    background-image: none !important;
  }

  #posterToolApp .poster-editor-panel,
  body.android-app #posterToolApp .poster-editor-panel {
    position: relative !important;
    z-index: 2 !important;
    height: auto !important;
    min-height: 0 !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
    background: #fff !important;
    opacity: 1 !important;
    border-top: 1px solid rgba(227,229,224,.95) !important;
    padding: 12px 16px calc(32px + var(--app-safe-bottom, 0px)) !important;
  }
}

/* Official watermark tool aligned with the main Marketing Book UI. */
.sample-watermark-app {
  min-height: 100vh;
  color: #171916;
  background: #f3f4f1;
}

.sample-watermark-mark {
  color: #101510;
  background: var(--ds-primary);
}

.sample-watermark-workspace {
  grid-template-columns: minmax(420px, 1fr) 430px;
  background: #f4f6f5;
}

.sample-watermark-preview-panel {
  align-items: center;
}

.sample-preview-frame {
  position: relative;
  width: 100%;
  flex: 1;
  min-height: 0;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid #e4e8e2;
  border-radius: 8px;
  background:
    linear-gradient(45deg, #edf0eb 25%, transparent 25%),
    linear-gradient(-45deg, #edf0eb 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, #edf0eb 75%),
    linear-gradient(-45deg, transparent 75%, #edf0eb 75%);
  background-color: #f8faf7;
  background-size: 28px 28px;
  background-position: 0 0, 0 14px, 14px -14px, -14px 0;
  touch-action: none;
}

#sampleWatermarkCanvas {
  display: block;
  max-width: 100%;
  max-height: 100%;
  border-radius: 6px;
  background: #fff;
  box-shadow: 0 20px 70px rgba(16, 21, 16, .16);
  cursor: grab;
  touch-action: none;
  -webkit-user-select: none;
  user-select: none;
}

.sample-preview-frame.is-dragging,
.sample-preview-frame.is-dragging #sampleWatermarkCanvas {
  cursor: grabbing;
}

.sample-empty-state {
  position: absolute;
  inset: auto;
  width: min(430px, calc(100% - 34px));
  min-height: 210px;
  padding: 28px;
  border: 1px solid #e1e6df;
  border-radius: 8px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 11px;
  color: #687268;
  text-align: center;
  background: rgba(255,255,255,.9);
  box-shadow: 0 18px 50px rgba(16, 21, 16, .08);
  cursor: pointer;
}

.sample-empty-state .upload-icon {
  width: 50px;
  height: 50px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  color: #101510;
  background: var(--ds-primary);
}

.sample-empty-state strong {
  color: #111510;
  font-size: 21px;
  letter-spacing: 0;
}

.sample-empty-state small {
  max-width: 280px;
  color: #7b847b;
  font-size: 12px;
  line-height: 1.65;
}

.sample-control-area {
  padding-top: 8px;
  background: #fff;
  color: #171916;
}

.sample-template-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
}

.sample-template-row label {
  display: grid;
  gap: 7px;
  color: #737a72;
  font-size: 10px;
}

.sample-template-row select,
.sample-template-row input {
  width: 100%;
  height: 42px;
  border: 1px solid #dfe5dc;
  border-radius: 8px;
  padding: 0 12px;
  color: #171916;
  background: #fff;
  outline: none;
}

.sample-segment {
  width: 184px;
  height: 54px;
  margin: 0 auto 18px;
  padding: 5px;
  border-radius: 999px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  background: #eef1ed;
}

.sample-segment button {
  border: 0;
  border-radius: 999px;
  color: #7a827a;
  background: transparent;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
}

.sample-segment button.active {
  color: #111510;
  background: #fff;
  box-shadow: 0 6px 16px rgba(20, 25, 20, .1);
}

.sample-slider-row {
  display: grid;
  gap: 12px;
  margin-bottom: 20px;
}

.sample-slider-row div,
.sample-position-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: #777f77;
  font-size: 14px;
}

.sample-slider-row strong,
.sample-position-head strong {
  color: #1a1f1a;
  font-weight: 700;
}

.sample-slider-row input[type="range"] {
  width: 100%;
  height: 38px;
  appearance: none;
  background: transparent;
}

.sample-slider-row input[type="range"]::-webkit-slider-runnable-track {
  height: 12px;
  border-radius: 999px;
  background: linear-gradient(90deg, #111510 0%, #111510 52%, #d7ddd5 52%, #d7ddd5 100%);
}

.sample-slider-row input[type="range"]::-webkit-slider-thumb {
  appearance: none;
  width: 34px;
  height: 34px;
  margin-top: -11px;
  border: 0;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 3px 14px rgba(16, 21, 16, .22);
}

.sample-tab-panel.hidden {
  display: none;
}

.sample-position-head {
  margin: 4px 0 12px;
}

.sample-anchor-strip {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 128px;
  gap: 12px;
  overflow-x: auto;
  padding: 2px 2px 8px;
  scrollbar-width: none;
}

.sample-anchor-strip::-webkit-scrollbar {
  display: none;
}

.sample-anchor-strip button {
  height: 92px;
  border: 1px solid #e1e6df;
  border-radius: 8px;
  position: relative;
  color: #7a827a;
  background: #f7f9f6;
  cursor: pointer;
}

.sample-anchor-strip button.active {
  border-color: #111510;
  box-shadow: inset 0 0 0 2px #111510;
  background: #fff;
}

.sample-anchor-strip button i {
  position: absolute;
  inset: 15px;
  border-radius: 4px;
  background-image: radial-gradient(circle, rgba(17,21,16,.16) 1.4px, transparent 1.6px);
  background-size: 28px 24px;
}

.sample-anchor-strip button i::before,
.sample-anchor-strip button i::after {
  content: "";
  position: absolute;
  width: 32px;
  height: 6px;
  border-radius: 999px;
  background: rgba(17,21,16,.5);
}

.sample-anchor-strip button i::after {
  width: 44px;
  transform: translateY(12px);
}

.sample-anchor-strip [data-anchor$="left"] i::before,
.sample-anchor-strip [data-anchor$="left"] i::after { left: 6px; }
.sample-anchor-strip [data-anchor$="center"] i::before,
.sample-anchor-strip [data-anchor$="center"] i::after { left: 50%; transform: translateX(-50%); }
.sample-anchor-strip [data-anchor$="center"] i::after { transform: translate(-50%, 12px); }
.sample-anchor-strip [data-anchor$="right"] i::before,
.sample-anchor-strip [data-anchor$="right"] i::after { right: 6px; }
.sample-anchor-strip [data-anchor^="top"] i::before { top: 8px; }
.sample-anchor-strip [data-anchor^="top"] i::after { top: 8px; }
.sample-anchor-strip [data-anchor^="middle"] i::before { top: 38%; }
.sample-anchor-strip [data-anchor^="middle"] i::after { top: 38%; }
.sample-anchor-strip [data-anchor^="bottom"] i::before { bottom: 20px; }
.sample-anchor-strip [data-anchor^="bottom"] i::after { bottom: 20px; }

.sample-anchor-strip button span {
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 7px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 11px;
}

.feature-card.official-watermark-entry {
  border-color: var(--ds-border);
  color: #101510;
  background: var(--ds-surface);
}

.feature-card.official-watermark-entry small,
.feature-card.official-watermark-entry span {
  color: rgba(16,21,16,.7);
}

@media (max-width: 720px) {
  .sample-watermark-workspace {
    display: block;
  }

  #sampleWatermarkToolApp .brand strong {
    font-size: 15px !important;
    line-height: 1.2 !important;
  }

  .sample-watermark-preview-panel {
    min-height: 430px;
    padding: 16px;
  }

  .sample-preview-frame {
    min-height: 360px;
  }

  .sample-control-area {
    padding-top: 0;
  }

  .sample-anchor-strip {
    grid-auto-columns: 118px;
  }
}

/* Homepage card correction: keep entry cards compact and visually centered. */
@media (max-width: 720px) {
  .open-tools {
    gap: 12px !important;
  }

  .open-tools .feature-card {
    min-height: 92px !important;
    padding: 8px 10px !important;
    grid-template-columns: 40px minmax(0, 1fr) !important;
    grid-template-rows: auto auto !important;
    column-gap: 10px !important;
    row-gap: 2px !important;
    align-items: center !important;
    align-content: center !important;
  }

  .open-tools .feature-card .tool-icon,
  .open-tools .feature-card.poster-entry .tool-icon,
  .open-tools .feature-card.long-entry .tool-icon,
  .open-tools .feature-card.cover-pro-entry .tool-icon,
  .open-tools .feature-card.official-watermark-entry .tool-icon,
  .open-tools .feature-card.asset-entry .tool-icon {
    grid-row: 1 / 3 !important;
    align-self: center !important;
    justify-self: center !important;
    width: 40px !important;
    height: 40px !important;
    min-width: 40px !important;
    min-height: 40px !important;
  }

  .open-tools .feature-card .tool-icon .lf-icon-tile {
    width: 40px !important;
    height: 40px !important;
    min-width: 40px !important;
    min-height: 40px !important;
  }

  .open-tools .feature-card .tool-icon svg,
  .open-tools .feature-card .tool-icon .lf-icon-tile svg {
    width: 20px !important;
    height: 20px !important;
  }

  .open-tools .feature-card strong {
    align-self: end !important;
    font-size: 14px !important;
    line-height: 1.22 !important;
    white-space: nowrap !important;
  }

  .open-tools .feature-card small {
    align-self: start !important;
    font-size: 10px !important;
    line-height: 1.25 !important;
    word-break: keep-all !important;
    overflow-wrap: normal !important;
  }

  .open-tools .feature-card.official-watermark-entry small {
    display: block !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
  }
}

/* Cover editor polish pass: compact mobile tool chrome and clearer edit controls. */
@media (max-width: 720px) {
  #toolApp {
    --cover-topbar-mobile: 54px;
  }

  #toolApp .topbar {
    min-height: var(--cover-topbar-mobile) !important;
    padding: var(--app-safe-top, var(--android-status-bar, 0px)) 12px 0 !important;
    gap: 8px !important;
    background: rgba(255,255,255,.96) !important;
    box-shadow: 0 8px 26px rgba(16,21,16,.05);
  }

  #toolApp .back-btn,
  #toolApp .quiet-btn,
  #toolApp .export-btn {
    height: 38px !important;
    min-height: 38px !important;
    border-radius: 14px !important;
    font-size: 12px !important;
  }

  #toolApp .back-btn {
    width: 44px !important;
    min-width: 44px !important;
  }

  #toolApp .quiet-btn {
    min-width: 54px !important;
    padding: 0 12px !important;
  }

  #toolApp .export-btn {
    min-width: 104px !important;
    padding: 0 14px !important;
  }

  #toolApp .workspace,
  body.android-app #toolApp .workspace {
    grid-template-rows: 35% 65% !important;
    height: calc(100dvh - var(--cover-topbar-mobile) - var(--app-safe-top, 0px)) !important;
  }

  #toolApp .preview-panel,
  body.android-app #toolApp .preview-panel {
    padding: 8px 12px 12px !important;
    background:
      radial-gradient(circle at 50% 18%, rgba(var(--ds-primary-rgb), .08), transparent 170px),
      linear-gradient(180deg, rgba(255,255,255,.92), rgba(247,250,247,.78)) !important;
    border-bottom: 1px solid rgba(227,229,224,.82);
  }

  #toolApp .preview-head {
    display: grid !important;
    grid-template-columns: minmax(72px, 1fr) auto minmax(92px, 1fr) !important;
    align-items: center !important;
    gap: 8px !important;
    height: 26px !important;
    min-height: 26px !important;
    margin: 0 0 6px !important;
    color: rgba(23,25,22,.56) !important;
  }

  #toolApp .preview-status {
    justify-self: start;
    display: inline-flex !important;
    align-items: center;
    gap: 7px;
    white-space: nowrap;
  }

  #toolApp .preview-guide-label {
    justify-self: center;
    max-width: 150px !important;
    height: 24px;
    padding: 0 10px !important;
    background: rgba(20,24,20,.055) !important;
    color: rgba(23,25,22,.60) !important;
    font-size: 10px !important;
  }

  #toolApp #sizeLabel {
    justify-self: end;
    max-width: 118px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    text-align: right;
    font-size: 10px !important;
  }

  #toolApp .editor-panel {
    padding-top: 14px !important;
  }
}

.upload-box {
  position: relative;
  overflow: hidden;
  border-style: solid;
  background:
    linear-gradient(135deg, rgba(255,255,255,.96), rgba(245,250,246,.92));
  box-shadow: 0 10px 28px rgba(16,21,16,.045);
}

.upload-box:hover {
  border-color: rgba(var(--ds-primary-rgb), .44);
  box-shadow: 0 14px 34px rgba(16,21,16,.07);
}

.upload-icon {
  background: linear-gradient(145deg, #ffffff, #f0fff5) !important;
  color: #0a9346;
}

.replace-text {
  min-width: 42px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(var(--ds-primary-rgb), .10);
  color: #008c45 !important;
  font-weight: 700;
}

.upload-progress {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 7px;
  height: 3px;
  border-radius: 999px;
  overflow: hidden;
  background: rgba(16,21,16,.06);
  opacity: 0;
}

.upload-progress i {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #2CFF73, #00a850);
  transition: width .28s ease;
}

.upload-box[data-upload-state="reading"],
.upload-box[data-upload-state="done"] {
  padding-bottom: 17px;
  border-color: rgba(var(--ds-primary-rgb), .45);
}

.upload-box[data-upload-state="reading"] .upload-progress,
.upload-box[data-upload-state="done"] .upload-progress {
  opacity: 1;
}

.upload-box[data-upload-state="reading"] .upload-progress i {
  animation: coverUploadPulse 1.2s ease-in-out infinite;
}

.upload-box[data-upload-state="error"] {
  border-color: rgba(225,52,47,.32);
  background: linear-gradient(135deg, #fff, #fff5f4);
}

@keyframes coverUploadPulse {
  0%, 100% { filter: brightness(1); }
  50% { filter: brightness(1.18); }
}

.custom-color-row {
  border: 1px solid rgba(227,230,224,.92);
  background:
    radial-gradient(circle at 9% 50%, rgba(var(--ds-primary-rgb), .12), transparent 88px),
    rgba(255,255,255,.78) !important;
  box-shadow: 0 12px 28px rgba(16,21,16,.045);
}

.custom-color-summary {
  min-width: 0;
}

.custom-swatch {
  width: 34px !important;
  height: 34px !important;
  box-shadow:
    inset 0 0 0 1px rgba(0,0,0,.10),
    0 8px 20px rgba(var(--ds-primary-rgb), .18) !important;
}

.color-value-input {
  padding: 6px 8px;
  border-radius: 12px;
  background: rgba(255,255,255,.72);
  border: 1px solid rgba(16,21,16,.06);
}

.color-value-input span {
  letter-spacing: .04em;
  color: rgba(16,21,16,.46) !important;
}

.color-value-input input {
  height: 28px !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  font-size: 11px !important;
  box-shadow: none !important;
}

.custom-color-row input[type="color"] {
  width: 34px !important;
  height: 34px !important;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 0 0 1px rgba(16,21,16,.12);
}

.field-label em {
  max-width: 112px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Homepage tool cards: keep IconTile placement consistent across tool types. */
@media (min-width: 721px) {
  .open-tools .feature-card,
  .pending-tools .feature-card {
    display: grid !important;
    grid-template-columns: 58px minmax(0, 1fr) auto !important;
    grid-template-rows: auto auto auto !important;
    align-items: center !important;
    align-content: center !important;
    column-gap: 18px !important;
    row-gap: 6px !important;
    min-height: 150px !important;
    padding: 22px 24px !important;
  }

  .open-tools .feature-card .tool-icon,
  .pending-tools .feature-card .tool-icon,
  .open-tools .feature-card.poster-entry .tool-icon,
  .open-tools .feature-card.long-entry .tool-icon,
  .open-tools .feature-card.cover-pro-entry .tool-icon,
  .open-tools .feature-card.official-watermark-entry .tool-icon,
  .open-tools .feature-card.asset-entry .tool-icon {
    grid-column: 1 !important;
    grid-row: 1 / 4 !important;
    align-self: center !important;
    justify-self: start !important;
    width: 58px !important;
    height: 58px !important;
    min-width: 58px !important;
    min-height: 58px !important;
    margin: 0 !important;
    transform: none !important;
  }

  .open-tools .feature-card .tool-icon .lf-icon-tile,
  .pending-tools .feature-card .tool-icon .lf-icon-tile {
    width: 58px !important;
    height: 58px !important;
    min-width: 58px !important;
    min-height: 58px !important;
  }

  .open-tools .feature-card .tool-icon svg,
  .open-tools .feature-card .tool-icon .lf-icon-tile svg,
  .pending-tools .feature-card .tool-icon svg,
  .pending-tools .feature-card .tool-icon .lf-icon-tile svg {
    width: 26px !important;
    height: 26px !important;
  }

  .open-tools .feature-card strong,
  .pending-tools .feature-card strong {
    grid-column: 2 !important;
    grid-row: 1 !important;
    align-self: end !important;
    min-width: 0 !important;
  }

  .open-tools .feature-card small,
  .pending-tools .feature-card small {
    grid-column: 2 !important;
    grid-row: 2 !important;
    align-self: start !important;
    min-width: 0 !important;
    max-width: 100% !important;
  }

  .open-tools .feature-card i,
  .open-tools .feature-card em,
  .pending-tools .feature-card i,
  .pending-tools .feature-card em {
    grid-column: 3 !important;
    grid-row: 1 / 4 !important;
    align-self: center !important;
    justify-self: end !important;
    margin: 0 !important;
  }
}

/* Activation gate final layout override: left prompt, right action. */
.demo-license,
body.android-app .demo-license {
  flex-wrap: nowrap !important;
  justify-content: space-between !important;
  align-items: center !important;
  text-align: left !important;
}

.demo-license span,
body.android-app .demo-license span {
  flex: 0 0 auto !important;
  color: #566056 !important;
  font-weight: 800 !important;
}

.demo-license button,
body.android-app .demo-license button {
  flex: 1 1 auto !important;
  text-align: right !important;
  color: #087b38 !important;
  font-weight: 900 !important;
}

/* Homepage tool cards: restrained OPPO light-field motion. */
.open-tools .feature-card {
  --tool-soft-rgb: 32,185,93;
  --tool-shadow-rgb: 16,21,16;
  position: relative;
  overflow: hidden;
  border-color: rgba(var(--tool-soft-rgb), .18) !important;
  background:
    radial-gradient(circle at 18% 10%, rgba(var(--tool-soft-rgb), .085), transparent 108px),
    linear-gradient(145deg, rgba(255,255,255,.995), rgba(249,251,249,.97)) !important;
  box-shadow:
    inset 0 0 0 1px rgba(255,255,255,.72),
    0 14px 32px rgba(16,21,16,.065) !important;
  transition:
    transform .28s cubic-bezier(.2,.8,.2,1),
    border-color .28s ease,
    background .28s ease,
    box-shadow .28s ease;
}

.open-tools .feature-card::before {
  content: "";
  position: absolute;
  inset: -40% -26%;
  background:
    linear-gradient(112deg, transparent 35%, rgba(255,255,255,.68) 48%, transparent 62%),
    radial-gradient(circle at 72% 22%, rgba(var(--tool-soft-rgb), .12), transparent 138px);
  opacity: 0;
  transform: translateX(-34%) rotate(8deg);
  transition: opacity .28s ease, transform .54s cubic-bezier(.2,.8,.2,1);
  pointer-events: none;
}

.open-tools .feature-card > * {
  position: relative;
  z-index: 1;
}

.open-tools .feature-card.cover-pro-entry {
  --tool-soft-rgb: 68,105,168;
}

.open-tools .feature-card.official-watermark-entry {
  --tool-soft-rgb: 32,132,116;
}

.open-tools .feature-card.asset-entry {
  --tool-soft-rgb: 48,128,142;
}

.open-tools .feature-card.poster-entry {
  --tool-soft-rgb: 176,82,102;
}

.open-tools .feature-card.long-entry {
  --tool-soft-rgb: 108,91,156;
}

@media (hover: hover) and (pointer: fine) {
  .open-tools .feature-card:hover {
    transform: translateY(-6px) scale(1.012) !important;
    border-color: rgba(var(--tool-soft-rgb), .31) !important;
    background:
      radial-gradient(circle at 16% 12%, rgba(var(--tool-soft-rgb), .14), transparent 132px),
      linear-gradient(145deg, rgba(255,255,255,1), rgba(247,250,247,.98)) !important;
    box-shadow:
      inset 0 0 0 1px rgba(255,255,255,.78),
      0 24px 54px rgba(var(--tool-soft-rgb), .115),
      0 12px 26px rgba(16,21,16,.10) !important;
  }

  .open-tools .feature-card:hover::before {
    opacity: 1;
    transform: translateX(30%) rotate(8deg);
  }

  .open-tools .feature-card:hover .tool-icon .lf-icon-tile {
    transform: rotate(-4deg) scale(1.08);
  }
}

/* Homepage mobile layout refinement: compact hero, aligned actions, visible tool badges. */
.feature-card .tool-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  min-width: 42px;
  height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(var(--tool-soft-rgb, 32,185,93), .24);
  background: rgba(255, 255, 255, .82);
  color: rgba(16, 21, 16, .72);
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
  box-shadow: 0 8px 20px rgba(16,21,16,.07);
  backdrop-filter: blur(10px);
}

.feature-card.featured .tool-badge {
  background: rgba(var(--ds-primary-rgb), .16);
  border-color: rgba(var(--ds-primary-rgb), .34);
  color: #087b38;
}

.feature-card.disabled .tool-badge,
.feature-card.pending .tool-badge {
  color: rgba(16,21,16,.56);
  border-color: rgba(16,21,16,.10);
  background: rgba(255,255,255,.74);
}

.feature-card.featured::after {
  content: none !important;
  display: none !important;
}

@media (max-width: 720px) {
  .launch-appbar {
    align-items: center !important;
    gap: 10px !important;
  }

  .launch-actions {
    height: 46px !important;
    align-items: stretch !important;
    gap: 8px !important;
  }

  .launch-license-pill,
  .launch-icon-btn {
    height: 46px !important;
    min-height: 46px !important;
    border-radius: 16px !important;
  }

  .launch-license-pill {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 0 15px !important;
    font-size: 14px !important;
  }

  .launch-icon-btn {
    width: 46px !important;
    min-width: 46px !important;
    box-shadow: 0 12px 28px rgba(20,24,20,.08) !important;
  }

  .launch-hero {
    min-height: 212px !important;
    padding: 24px !important;
    border-radius: 28px !important;
    align-content: center !important;
  }

  .launch-mark {
    width: 58px !important;
    height: 58px !important;
    margin-bottom: 22px !important;
    border-radius: 18px !important;
    font-size: 28px !important;
  }

  .launch-hero p {
    margin-bottom: 10px !important;
    font-size: 15px !important;
    font-weight: 800 !important;
  }

  .launch-hero h1 {
    max-width: 420px !important;
    font-size: clamp(28px, 7.4vw, 38px) !important;
    line-height: 1.14 !important;
  }

  .launch-hero small {
    margin-top: 20px !important;
  }

  .open-tools .feature-card {
    padding-top: 18px !important;
  }

  .open-tools .feature-card strong {
    padding-right: 46px !important;
  }

  .feature-card .tool-badge {
    top: 10px;
    right: 10px;
    height: 22px;
    min-width: 40px;
    padding: 0 9px;
    font-size: 10px;
  }
}

/* Official watermark final control polish. */
#sampleWatermarkToolApp .sample-slider-row {
  width: 100% !important;
  min-width: 0 !important;
  padding: 14px 16px 16px !important;
  border: 1px solid #e5ebe3 !important;
  border-radius: 14px !important;
  background: #f8faf7 !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.9) !important;
}

#sampleWatermarkToolApp .sample-slider-row div {
  color: #6f786f !important;
  font-size: 13px !important;
}

#sampleWatermarkToolApp .sample-slider-row strong {
  min-width: 48px !important;
  color: #101510 !important;
  font-size: 18px !important;
  text-align: right !important;
}

#sampleWatermarkToolApp .sample-slider-row input[type="range"] {
  --sample-range-progress: 40%;
  display: block !important;
  width: 100% !important;
  max-width: 100% !important;
  height: 28px !important;
  margin: 4px 0 0 !important;
  appearance: none !important;
  background: transparent !important;
  cursor: pointer !important;
}

#sampleWatermarkToolApp .sample-slider-row input[type="range"]::-webkit-slider-runnable-track {
  height: 8px !important;
  border-radius: 999px !important;
  background: linear-gradient(90deg, #2CFF73 0, #2CFF73 var(--sample-range-progress), #dfe7de var(--sample-range-progress), #dfe7de 100%) !important;
  box-shadow: inset 0 1px 2px rgba(16,21,16,.08) !important;
}

#sampleWatermarkToolApp .sample-slider-row input[type="range"]::-webkit-slider-thumb {
  appearance: none !important;
  width: 24px !important;
  height: 24px !important;
  margin-top: -8px !important;
  border: 4px solid #fff !important;
  border-radius: 50% !important;
  background: #111510 !important;
  box-shadow: 0 6px 16px rgba(16,21,16,.18) !important;
}

#sampleWatermarkToolApp .sample-slider-row input[type="range"]:active::-webkit-slider-thumb {
  transform: scale(1.08) !important;
}

#sampleWatermarkToolApp .sample-anchor-strip {
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  display: flex !important;
  grid-auto-flow: unset !important;
  grid-auto-columns: unset !important;
  overflow-x: auto !important;
  overflow-y: hidden !important;
  scroll-snap-type: x proximity !important;
  -webkit-overflow-scrolling: touch !important;
}

#sampleWatermarkToolApp .sample-anchor-strip button {
  flex: 0 0 104px !important;
  height: 78px !important;
  border-radius: 12px !important;
  scroll-snap-align: start !important;
}

#sampleWatermarkToolApp .sample-anchor-strip button.active {
  border-color: #101510 !important;
  box-shadow: inset 0 0 0 2px #101510, 0 8px 20px rgba(16,21,16,.08) !important;
}

#sampleWatermarkToolApp .sample-anchor-strip button i {
  inset: 11px 12px 18px !important;
}

#sampleWatermarkToolApp .sample-anchor-strip button span {
  bottom: 5px !important;
  font-size: 10px !important;
}

@media (max-width: 720px) {
  #sampleWatermarkToolApp .sample-anchor-strip button {
    flex-basis: 96px !important;
  }
}

/* Final mobile activation guard: keep the license card inside narrow WebViews. */
@media (max-width: 720px) {
  .activation-gate,
  body.android-app .activation-gate {
    width: 100vw !important;
    max-width: 100vw !important;
    min-width: 0 !important;
    justify-items: stretch !important;
    align-items: center !important;
    padding-left: 14px !important;
    padding-right: 14px !important;
    overflow-x: hidden !important;
  }

  .activation-card,
  body.android-app .activation-card {
    width: calc(100vw - 44px) !important;
    max-width: calc(100vw - 44px) !important;
    min-width: 0 !important;
    margin: 0 auto !important;
    padding: 24px 20px !important;
    place-self: center !important;
    transform: none !important;
  }

  .activate-btn,
  body.android-app .activate-btn,
  .contact-developer button,
  body.android-app .contact-developer button {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
  }

  .license-input-wrap,
  body.android-app .license-input-wrap {
    height: auto !important;
    min-height: 48px !important;
    align-items: center !important;
  }

  .license-input-wrap input,
  body.android-app .license-input-wrap input {
    min-width: 0 !important;
    font-size: 13px !important;
    letter-spacing: .015em !important;
  }

  .demo-license,
  body.android-app .demo-license {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 8px !important;
  }

  .demo-license button,
  body.android-app .demo-license button {
    width: 100% !important;
    text-align: left !important;
  }
}

@media (max-width: 380px) {
  .activation-card,
  body.android-app .activation-card {
    width: calc(100vw - 36px) !important;
    max-width: calc(100vw - 36px) !important;
    padding: 22px 18px !important;
  }

  .activation-card h1,
  body.android-app .activation-card h1 {
    font-size: 22px !important;
  }
}
.price-tag-app {
  min-height: 100dvh;
  background: #f7faf8;
}

.price-tag-runtime {
  height: var(--tool-v2-content-block-size, calc(100dvh - var(--tool-v2-shell-block-size)));
  min-height: 560px;
  background: #f7faf8;
}

.price-tag-runtime iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background: #f7faf8;
}

.summer-benefits-poster-app {
  min-height: 100dvh;
  background: #f3f4f1;
}

.summer-benefits-poster-runtime {
  height: var(--tool-v2-content-block-size, calc(100dvh - var(--tool-v2-shell-block-size)));
  min-height: 0;
  overflow: hidden;
  background: #f3f4f1;
}

.summer-benefits-poster-runtime iframe {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
  background: #f3f4f1;
}

@media (max-width: 719px) {
  .price-tag-runtime {
    height: var(--tool-v2-content-block-size, calc(100dvh - var(--tool-v2-shell-block-size)));
    min-height: 0;
  }

  .summer-benefits-poster-runtime {
    height: var(--tool-v2-content-block-size, calc(100dvh - var(--tool-v2-shell-block-size)));
    min-height: 0;
  }
}

body.android-app .summer-benefits-poster-runtime {
  height: var(--tool-v2-content-block-size, calc(100dvh - var(--tool-v2-shell-block-size)));
  padding-bottom: var(--app-safe-bottom, 0px);
}

/* Unified developer signature entry: shared by Web and Android WebView. */
.developer-signature {
  width: fit-content;
  max-width: 100%;
  min-width: 0;
  margin: 22px 0 0;
  padding: 13px 18px;
  position: relative;
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(var(--ds-primary-rgb), .22);
  border-radius: 999px;
  background: rgba(255, 255, 255, .82);
  box-shadow: 0 10px 28px rgba(16, 21, 16, .07);
  color: #101510;
  font: inherit;
  text-align: left;
  cursor: pointer;
  overflow-wrap: anywhere;
  will-change: transform;
  animation: developer-signature-enter 220ms cubic-bezier(.2, .8, .2, 1) 60ms both;
  transition: transform 200ms cubic-bezier(.2, .8, .2, 1);
}

.developer-signature::before {
  content: "";
  position: absolute;
  inset: 1px;
  border-radius: inherit;
  pointer-events: none;
  background: linear-gradient(108deg, transparent 12%, rgba(46,255,115,.08) 34%, rgba(255,255,255,.78) 50%, rgba(46,255,115,.12) 66%, transparent 88%);
  background-size: 220% 100%;
  animation: pendingLightSweep 2.8s ease-in-out infinite;
}

.developer-signature__name {
  position: relative;
  z-index: 1;
  min-width: 0;
  font-size: 15px;
  font-weight: 750;
  line-height: 1.3;
  letter-spacing: .01em;
}

.developer-signature__status {
  display: none;
}

@keyframes pendingLightSweep {
  0%, 100% { background-position: 0% 50%; opacity: .82; }
  50% { background-position: 100% 50%; opacity: 1; }
}

.developer-signature:focus-visible {
  outline: 3px solid rgba(var(--ds-primary-rgb), .34);
  outline-offset: 3px;
  border-color: rgba(var(--ds-primary-rgb), .46);
}

@media (hover: hover) and (pointer: fine) {
  .developer-signature:hover {
    transform: translateY(-2px);
  }

}

.developer-signature:active {
  transform: scale(.97);
  transition-duration: 100ms;
}

@keyframes developer-signature-enter {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 720px) {
  .developer-signature,
  body.android-app .developer-signature {
    width: fit-content;
    max-width: 100%;
    margin-top: 18px;
    padding: 12px 16px;
    border-radius: 999px;
  }

  .developer-signature__name {
    font-size: 14px;
  }

}

@media (prefers-reduced-motion: reduce) {
  .developer-signature,
  .developer-signature::before {
    animation: none;
    transition: none;
  }
}

/* Header P0: one searchable, keyboard-accessible home navigation on Web and Android. */
:root {
  --launch-brand-min-inline: 184px;
  --launch-action-size: 44px;
  --launch-search-overlay-max: 340px;
}

.launch-brand {
  color: inherit;
  text-decoration: none;
  min-inline-size: var(--launch-brand-min-inline);
}

.launch-brand:focus-visible,
.launch-nav a:focus-visible,
.tool-search-option:focus-visible {
  outline: 3px solid rgba(var(--ds-primary-rgb), .34);
  outline-offset: 3px;
}

.launch-brand-mark-slot {
  inline-size: 36px;
  block-size: 36px;
  flex: 0 0 36px;
  display: grid;
  place-items: center;
}

.launch-brand .launch-mini-mark {
  grid-area: 1 / 1;
  inline-size: 100%;
  block-size: 100%;
  object-fit: contain;
  background: transparent;
  box-shadow: none;
}

.launch-brand[data-logo-state="failed"] .launch-brand-mark-slot { display: none; }
.launch-brand-copy { min-inline-size: 0; }
.launch-brand-copy [data-app-short-name] { display: none; }
.launch-brand strong { max-width: none; overflow: visible; text-overflow: clip; }

.launch-search-toggle,
.launch-search-close {
  inline-size: var(--launch-action-size);
  min-inline-size: var(--launch-action-size);
  block-size: var(--launch-action-size);
}

.launch-search-overlay {
  position: absolute;
  z-index: 60;
  inset-block-start: calc(100% + 8px);
  inset-inline-end: 0;
  inline-size: min(var(--launch-search-overlay-max), calc(100vw - 32px));
  display: flex;
  gap: 8px;
  padding: 8px;
  border: 1px solid #ECEDEF;
  border-radius: 16px;
  background: #fff;
  box-shadow: 0 18px 42px rgba(15, 31, 20, .16);
}

.launch-search-overlay[hidden] { display: none; }
.launch-search-field { position: relative; flex: 1 1 auto; }
.launch-search-field input { inline-size: 100%; }

.tool-search-results {
  position: absolute;
  z-index: 60;
  top: calc(100% + 10px);
  right: 0;
  width: min(430px, calc(100vw - 32px));
  max-height: min(420px, 60vh);
  overflow: auto;
  padding: 8px;
  border: 1px solid rgba(21, 32, 24, .1);
  border-radius: 16px;
  background: rgba(255, 255, 255, .98);
  box-shadow: 0 18px 42px rgba(15, 31, 20, .16);
}

.launch-license-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  overflow: hidden;
  max-inline-size: 320px;
  transition: max-inline-size 260ms cubic-bezier(.2, .8, .2, 1), padding 260ms cubic-bezier(.2, .8, .2, 1), background-color 180ms ease;
}

.launch-license-pill [data-launch-license-icon] { flex: 0 0 18px; }
.launch-license-pill [data-launch-license-label] {
  opacity: 1;
  transform: translateX(0);
  transition: opacity 180ms ease, transform 260ms cubic-bezier(.2, .8, .2, 1);
}
.launch-license-pill[data-license-expanded="false"][data-license-state="active"] {
  inline-size: auto;
  min-inline-size: 0;
  max-inline-size: 128px;
  padding-inline: 12px;
  justify-content: center;
}
.launch-license-pill[data-license-expanded="false"][data-license-state="active"] [data-launch-license-label] {
  inline-size: auto;
  opacity: .86;
  overflow: visible;
  transform: translateX(-1px);
}

.tool-search-option {
  width: 100%;
  padding: 11px 12px;
  border: 0;
  border-radius: 11px;
  background: transparent;
  color: #172017;
  text-align: left;
  cursor: pointer;
}

.tool-search-option strong,
.tool-search-option small {
  display: block;
}

.tool-search-option strong {
  font-size: 14px;
}

.tool-search-option small {
  margin-top: 3px;
  color: rgba(23, 32, 23, .56);
  font-size: 12px;
  line-height: 1.35;
}

.tool-search-option:hover,
.tool-search-option.is-active {
  background: rgba(var(--ds-primary-rgb), .13);
}

.tool-search-empty {
  margin: 0;
  padding: 14px 12px;
  color: rgba(23, 32, 23, .58);
  font-size: 13px;
}

@media (max-width: 900px) {
  .launch-appbar {
    flex-wrap: wrap;
    justify-content: flex-start;
  }

  .launch-brand {
    order: 0;
  }

  .launch-actions {
    order: 1;
    margin-left: auto;
  }

  .launch-nav {
    display: flex;
    order: 2;
    flex: 1 0 100%;
    gap: 0;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .launch-nav::-webkit-scrollbar {
    display: none;
  }

  .launch-nav a {
    flex: 1 0 auto;
    min-height: 40px;
    padding: 10px 12px;
    color: rgba(23, 25, 22, .82);
    font-size: 14px;
    font-weight: 650;
    line-height: 20px;
    text-align: center;
    text-decoration: none;
    white-space: nowrap;
  }

  .launch-nav a.active {
    color: #009b46;
  }

  .launch-search-overlay {
    inset-inline-end: 0;
    inline-size: min(var(--launch-search-overlay-max), calc(100vw - 24px));
  }
}

@media (max-width: 768px) {
  .launch-brand { min-inline-size: 144px; }
  .launch-brand-copy > [data-app-name] { display: none !important; }
  .launch-brand-copy > [data-app-short-name] { display: block !important; font-size: 14px; font-weight: 700; white-space: nowrap; }
  .launch-search-overlay {
    position: fixed;
    inset-block-start: calc(var(--safe-area-top, env(safe-area-inset-top, 0px)) + 58px);
    inset-inline: auto 12px;
    inline-size: min(340px, calc(100vw - 24px));
    padding: 8px;
    border-radius: 16px;
  }
}

@media (max-width: 340px) {
  .launch-brand { min-inline-size: 36px; }
  .launch-brand-copy { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .launch-license-pill,
  .launch-license-pill [data-launch-license-label] { transition: none; }
}

@media (max-width: 520px) {
  .launch-appbar {
    gap: 8px;
  }

  .launch-nav a {
    flex-basis: 25%;
    padding-inline: 6px;
    font-size: 12px;
  }

  .launch-search-overlay {
    height: 44px;
    padding-inline: 13px;
  }

  .launch-search kbd {
    display: none;
  }

  .tool-search-results {
    right: 0;
    left: auto;
    width: 100%;
  }
}

/* Android homepage P0: native marker prevents download-card flash before bridge insets apply. */
html.android-native-splash-authority .android-download-card,
body.android-app .android-download-card,
html.android-native-splash-authority .activation-app-download,
body.android-app .activation-app-download {
  display: none !important;
}

@media (max-width: 420px) {
  body.android-app .launch-appbar {
    column-gap: 8px;
  }

  body.android-app .launch-actions {
    flex: 1 1 auto;
    min-width: 0;
    gap: 8px;
  }

  body.android-app .launch-license-pill {
    display: inline-flex;
    min-width: 0;
    max-width: none;
    flex: 1 1 0;
    justify-content: center;
    padding-inline: 10px;
    overflow: hidden;
    font-size: 12px;
    line-height: 1;
    text-overflow: ellipsis;
  }

  body.android-app .launch-icon-btn {
    width: 44px;
    height: 44px;
    flex: 0 0 44px;
  }

  body.android-app .open-tools,
  body.android-app .pending-tools {
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }

  body.android-app .feature-card {
    min-height: 144px !important;
    padding: 16px !important;
    border-radius: 20px;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: auto 1fr auto !important;
    row-gap: 0 !important;
  }

  body.android-app .feature-card .tool-icon,
  body.android-app .open-tools .feature-card .tool-icon,
  body.android-app .pending-tools .feature-card .tool-icon {
    grid-column: 1 !important;
    grid-row: 1 !important;
    align-self: start !important;
    justify-self: start !important;
    width: 40px !important;
    height: 40px !important;
    min-width: 40px !important;
    min-height: 40px !important;
    margin: 0 0 12px !important;
  }

  body.android-app .feature-card strong,
  body.android-app .open-tools .feature-card strong,
  body.android-app .pending-tools .feature-card strong {
    grid-column: 1 !important;
    grid-row: 2 !important;
    align-self: start !important;
    font-size: 18px !important;
    line-height: 1.3 !important;
    white-space: normal !important;
  }

  body.android-app .feature-card small,
  body.android-app .open-tools .feature-card small,
  body.android-app .pending-tools .feature-card small {
    grid-column: 1 !important;
    grid-row: 3 !important;
    align-self: end !important;
    margin-top: 8px !important;
    font-size: 13px !important;
    line-height: 1.45 !important;
    white-space: normal !important;
    word-break: break-word !important;
    overflow-wrap: anywhere !important;
  }
}
