/* Image editing: narrow PC settings rail, two equal-width work areas; dark UI. */
.tn-image-workspace{--tn-image-line:#8c8c8c;--tn-image-surface:#353535;--tn-image-field:#262626;--tn-image-accent:#b7d7d4;max-width:var(--tn-max,1280px);min-width:0;margin-inline:auto;color:var(--tn-text,#f0f0f0)}
.tn-image-workspace *{box-sizing:border-box}
.tn-image-workspace__header{margin:0 0 13px}
.tn-image-workspace__header h1{font-size:clamp(1.4rem,2.2vw,1.9rem);line-height:1.32;margin:0 0 5px}
.tn-image-workspace__header p{font-size:.85rem;color:var(--tn-muted,#d1d1d1);margin:0}
.tn-image-workspace__grid{display:grid;grid-template-columns:minmax(235px,290px) minmax(0,1fr);gap:16px;height:clamp(590px,calc(100svh - 270px),840px);min-height:0}
.tn-image-workspace__main{display:grid;grid-template-rows:minmax(0,1fr) minmax(0,1fr);gap:16px;min-width:0;min-height:0}
.tn-image-panel{display:flex;flex-direction:column;min-width:0;min-height:0;background:var(--tn-image-surface);border:1px solid var(--tn-image-line);padding:clamp(12px,1.4vw,18px)}
.tn-image-panel>h2{font-size:1rem;line-height:1.4;margin:0 0 12px;padding-bottom:8px;border-bottom:1px solid var(--tn-image-line);flex:none}
.tn-image-panel__body{flex:1 1 auto;min-height:0;min-width:0;overflow:auto;display:flex;flex-direction:column;gap:12px;overscroll-behavior:contain;scrollbar-width:thin}
.tn-image-panel--settings .tn-image-panel__body{padding-right:4px}
.tn-image-panel__body>div,.tn-image-panel__body>fieldset{min-width:0}
.tn-image-workspace :is(input:not([type=radio]):not([type=checkbox]):not([type=range]):not([type=color]),select,textarea){display:block;min-width:0;max-width:100%;width:100%;min-height:40px;border:1px solid var(--tn-image-line);background:var(--tn-image-field);border-radius:0;color:var(--tn-text,#f0f0f0);padding:8px 9px;font:inherit}
.tn-image-workspace input[type=file]{font-size:.79rem}
.tn-image-workspace input[type=color]{min-height:40px;min-width:46px;background:var(--tn-image-field);border:1px solid var(--tn-image-line);cursor:pointer}
.tn-image-workspace input[type=range]{width:100%;max-width:100%;accent-color:var(--tn-image-accent)}
.tn-image-workspace :is(input[type=radio],input[type=checkbox]){flex:none;accent-color:var(--tn-image-accent);width:16px;height:16px;margin:2px 0 0}
.tn-image-workspace :is(input,select,textarea,button,a):focus-visible{outline:3px solid var(--tn-image-accent);outline-offset:2px}
.tn-image-workspace :is(button,.btn){display:inline-flex;align-items:center;justify-content:center;min-height:39px;border:1px solid var(--tn-image-line);border-radius:0;background:var(--tn-image-field);color:var(--tn-text,#f0f0f0);font:inherit;font-size:.84rem;padding:8px 12px;text-decoration:none;cursor:pointer}
.tn-image-workspace :is(button,.btn):disabled{opacity:.5;cursor:not-allowed}
.tn-image-workspace :is(.btn-primary,.btn-success,button[data-tn-image-primary]){background:var(--tn-image-accent);color:#202b2b;border-color:var(--tn-image-accent);font-weight:700}
.tn-image-workspace .form-label{display:block;font-weight:650;font-size:.84rem;line-height:1.4;margin:0 0 6px}
.tn-image-workspace fieldset{border:0;padding:0;margin:0}
.tn-image-workspace legend{font-size:.88rem;font-weight:700;padding:0;margin:0 0 8px}
.tn-image-workspace .form-check{display:flex;align-items:flex-start;gap:7px;margin:0 0 7px;min-width:0}
.tn-image-workspace .form-check-label{font-size:.79rem;line-height:1.45;overflow-wrap:anywhere;cursor:pointer;min-width:0}
.tn-image-workspace .d-flex{display:flex;gap:8px;align-items:center}
.tn-image-workspace .flex-wrap{flex-wrap:wrap}
.tn-image-workspace .vstack{display:flex;flex-direction:column;gap:12px}
.tn-image-workspace .gap-2{gap:8px}.tn-image-workspace .gap-3{gap:12px}.tn-image-workspace .gap-4{gap:16px}
.tn-image-workspace .row{display:flex;flex-wrap:wrap;gap:10px;min-width:0}
.tn-image-workspace .row>[class*=col-]{flex:1 1 100%;min-width:0}
.tn-image-workspace .row>.col-6{flex:1 1 calc(50% - 10px);max-width:calc(50% - 5px)}
.tn-image-workspace .row>.col-4{flex:1 1 calc(33.333% - 10px);max-width:calc(33.333% - 7px)}
.tn-image-workspace .card{background:transparent;border:0;min-width:0}.tn-image-workspace .card-body{min-width:0}
.tn-image-workspace .form-text,.tn-image-workspace .small,.tn-image-workspace .text-muted{font-size:.76rem;color:var(--tn-muted,#d1d1d1);line-height:1.5}
.tn-image-workspace .fw-semibold{font-weight:650}
.tn-image-workspace .d-none{display:none!important}
.tn-image-workspace .border{border:1px solid var(--tn-image-line)}
.tn-image-workspace .rounded{border-radius:0}
.tn-image-workspace .p-3{padding:12px}
.tn-image-workspace .mt-1,.tn-image-workspace .mt-2{margin-top:8px}
.tn-image-workspace .mt-3{margin-top:12px}
.tn-image-workspace .mb-1{margin-bottom:5px}
.tn-image-workspace .text-center{text-align:center}
.tn-image-workspace .text-danger{color:#ffd0c8}
.tn-image-workspace #wmDropzone,.tn-image-workspace [data-tn-image-dropzone]{border:2px dashed #a0a0a0;background:#292929;min-height:86px;padding:14px;display:grid;align-content:center;gap:6px;text-align:center;cursor:pointer}
.tn-image-workspace #wmDropzone:is(:hover,:focus-visible),.tn-image-workspace [data-tn-image-dropzone]:is(:hover,:focus-visible){border-color:var(--tn-image-accent)}
.tn-image-workspace #wmThumbs{display:grid;grid-template-columns:repeat(auto-fill,minmax(100px,1fr));gap:9px}
.tn-image-workspace #wmThumbs>[class*=col-]{max-width:none;min-width:0}
.tn-image-workspace #wmThumbs img{display:block;max-width:100%;height:auto}
.tn-image-workspace .text-truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.tn-image-workspace .w-100{width:100%}
.tn-image-workspace #image_resize_result_list{display:flex;flex-direction:column;gap:8px}
.tn-image-workspace #image_resize_result_list>.card{padding:9px 10px;border:1px solid var(--tn-image-line);background:#303030}
.tn-image-workspace .justify-content-between{justify-content:space-between}
.tn-image-workspace .progress{height:18px;background:#222;border:1px solid var(--tn-image-line);width:100%;overflow:hidden}
.tn-image-workspace .progress-bar{height:100%;background:var(--tn-image-accent);color:#202b2b;text-align:center;white-space:nowrap;font-size:.72rem}
.tn-image-workspace .alert{border:1px solid #65878d;background:#2d3b3f;padding:10px;font-size:.78rem;line-height:1.5}
.tn-image-workspace .tn-image-actions{display:flex;align-items:center;flex-wrap:wrap;gap:8px}
.tn-image-workspace .tn-image-actions button{flex:1 1 130px}
.tn-image-workspace .tn-image-original-preview{display:flex;gap:12px;align-items:center;margin-top:8px;min-width:0}
.tn-image-workspace .tn-image-original-preview img{max-width:150px;max-height:110px;object-fit:contain;border:1px solid #777}
.tn-image-workspace .tn-image-original-preview figcaption{font-size:.78rem;min-width:0;overflow-wrap:anywhere}
.tn-image-workspace__quicknav{display:none}
.tn-image-secondary{display:grid;gap:14px;margin-top:22px}
.tn-image-secondary .tn-text-page-share,.tn-image-secondary .tn-text-share__buttons{display:flex;flex-wrap:wrap;gap:8px;align-items:center}
.tn-image-secondary .tn-text-page-share :is(button,a),.tn-image-secondary .tn-text-share__buttons button{font:inherit;font-size:.81rem;text-decoration:none;padding:7px 9px;min-height:34px;border:1px solid var(--tn-line,#989898);background:#272727;color:var(--tn-text,#f0f0f0)}
.tn-image-secondary .container.descriptions{width:100%;margin:0;padding:14px 0 0;border-top:1px solid var(--tn-line,#989898);line-height:1.65;font-size:.86rem;max-width:100%}
.tn-image-secondary .container.descriptions h2{font-size:1.08rem;margin:8px 0}.tn-image-secondary .container.descriptions h3{font-size:.98rem;margin:9px 0}
.tn-image-secondary .container.descriptions :is(ul,ol){padding-left:22px;margin:8px 0 14px}
.tn-image-secondary .container.descriptions :is(p,li){overflow-wrap:anywhere}
.tn-image-secondary .container.descriptions img{max-width:100%;height:auto}
.tn-image-secondary .container .row{display:flex;flex-wrap:wrap;gap:12px}
.tn-image-secondary .container .row>[class*=col-]{min-width:0;flex:1 1 min(100%,250px)}
.tn-image-secondary .image-list{min-width:0}
.tn-image-secondary .tn-image-ad :is(.bg-light,.AdsenseArea-placeholder){background:#343434!important;color:#eee!important;border:1px solid #777}
.tn-tool-related{border-top:1px solid var(--tn-line,#989898);padding-top:20px;margin-top:8px}
.tn-tool-related__grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:10px}
.tn-tool-related__item{display:flex;align-items:center;gap:10px;min-height:66px;padding:10px;border:1px solid var(--tn-line,#989898);background:#363636;color:var(--tn-text,#f0f0f0);font-size:.82rem;text-decoration:none}
@media (min-width:901px) and (max-height:665px){.tn-image-workspace__grid{height:auto;min-height:555px}.tn-image-workspace__main{min-height:555px}}
@media(max-width:900px){
 .tn-image-workspace{padding-right:50px}
 .tn-image-workspace__grid{display:flex;flex-direction:column;height:auto;gap:13px}
 .tn-image-workspace__main{display:flex;flex-direction:column;gap:13px}
 .tn-image-panel--settings{max-height:clamp(220px,40svh,360px)}
 .tn-image-panel--upload{min-height:200px}
 .tn-image-panel--download{min-height:220px}
 .tn-image-panel__body{overflow:visible}
 .tn-image-panel--settings .tn-image-panel__body{overflow-y:auto;overscroll-behavior:contain}
 .tn-image-workspace__quicknav{position:fixed;right:max(3px,env(safe-area-inset-right));top:32%;display:flex;flex-direction:column;z-index:60;background:#242424;border:1px solid var(--tn-image-line);width:46px}
 .tn-image-workspace__quicknav a{display:grid;place-items:center;text-align:center;min-height:56px;padding:7px 2px;border-bottom:1px solid #666;color:#f0f0f0;text-decoration:none;overflow-wrap:anywhere;font-size:.66rem}
 .tn-image-workspace__quicknav a:last-child{border:0}
}
@media(max-width:480px){.tn-image-workspace{padding-right:43px}.tn-image-workspace__quicknav{width:40px}.tn-image-workspace #wmThumbs{grid-template-columns:repeat(2,minmax(0,1fr))}}

/* Watermark examples: one compact panel per tab, scrollable image cards. */
.tn-image-secondary .tn-wm-examples{min-width:0;max-width:100%;overflow:hidden}
.tn-wm-examples__intro{font-size:.85rem;color:var(--tn-muted,#d1d1d1)}
.tn-wm-examples__tabs{display:flex;align-items:stretch;gap:6px;min-width:0;overflow-x:auto;overscroll-behavior-x:contain;scrollbar-width:thin;scroll-snap-type:x proximity;padding:2px 1px 10px;margin:12px 0 0}
.tn-wm-examples__tab{flex:0 0 auto;scroll-snap-align:start;min-height:43px;padding:9px 13px;border:1px solid #8c8c8c;border-radius:0;background:#2b2b2b;color:#f0f0f0;font:inherit;font-size:.82rem;font-weight:650;white-space:nowrap;cursor:pointer}
.tn-wm-examples__tab[aria-selected="true"]{background:#b7d7d4;border-color:#b7d7d4;color:#172728}
.tn-wm-examples__tab:focus-visible,.tn-wm-examples__scroll:focus-visible,.tn-wm-examples__card:focus-visible{outline:3px solid #b7d7d4;outline-offset:2px}
.tn-image-secondary .tn-wm-examples__panel{min-width:0;border:1px solid #858585;background:#303030;padding:clamp(10px,1.5vw,16px);margin-top:7px}
.tn-image-secondary .tn-wm-examples__panel[hidden]{display:none!important}
.tn-wm-examples__panel-header{display:flex;align-items:flex-start;justify-content:space-between;gap:12px;margin-bottom:10px}
.tn-image-secondary .tn-wm-examples__panel-header h3{margin:0 0 3px;font-size:1rem}
.tn-image-secondary .tn-wm-examples__panel-header p{margin:0;font-size:.76rem;color:#d1d1d1}
.tn-wm-examples__count{flex:none;align-self:center;font-size:.75rem;color:#d1d1d1}
.tn-wm-examples__gallery{display:grid;grid-template-columns:35px minmax(0,1fr) 35px;gap:9px;align-items:stretch;min-width:0}
.tn-wm-examples__track{display:flex;gap:12px;min-width:0;overflow-x:auto;overscroll-behavior-inline:contain;scroll-snap-type:x mandatory;scroll-padding-inline:2px;scrollbar-width:thin;padding:3px 2px 12px}
.tn-wm-examples__card{flex:0 0 218px;max-width:70vw;min-width:0;display:flex;flex-direction:column;scroll-snap-align:start;border:1px solid #777;background:#252525;color:#f0f0f0;text-decoration:none}
.tn-wm-examples__card:hover{border-color:#b7d7d4}
.tn-image-secondary .tn-wm-examples .tn-wm-examples__card img{display:block;width:100%;height:137px;max-width:100%;object-fit:contain;background:#1c1c1c}
.tn-wm-examples__card span{display:block;padding:8px;font-size:.78rem;line-height:1.4;min-height:34px;overflow-wrap:anywhere}
.tn-wm-examples__scroll{width:35px;min-width:35px;min-height:48px;padding:0 3px;border:1px solid #777;border-radius:0;background:#242424;color:#eee;font-size:1.7rem;cursor:pointer}
.tn-wm-examples__scroll:hover:not(:disabled){background:#3d3d3d}
.tn-wm-examples__scroll:disabled{opacity:.24;cursor:default}
.tn-wm-examples__details{margin-top:12px;border-top:1px solid #777;padding-top:10px;font-size:.84rem}
.tn-wm-examples__details summary{cursor:pointer;font-weight:650;min-height:35px}
.tn-wm-examples__details>div{padding:8px 0 0;line-height:1.6}
.tn-image-secondary .tn-wm-examples__details h4{font-size:.9rem;margin:9px 0 4px}
.tn-image-secondary .tn-wm-examples__details p{margin:0 0 7px}
@media(max-width:600px){
 .tn-wm-examples__gallery{grid-template-columns:28px minmax(0,1fr) 28px;gap:5px}
 .tn-wm-examples__scroll{min-width:28px;width:28px;font-size:1.3rem}
 .tn-wm-examples__card{flex-basis:164px}
 .tn-image-secondary .tn-wm-examples .tn-wm-examples__card img{height:106px}
 .tn-wm-examples__tab{padding:9px 10px;font-size:.78rem}
}


/* Breadcrumbs: same one-line, unnumbered presentation as the other dark tool pages. */
.tn-tool-breadcrumbs{max-width:100%;overflow-x:auto;overscroll-behavior-x:contain;margin:0 0 12px;color:var(--tn-muted,#d1d1d1);font-size:.84rem;scrollbar-width:thin}
.tn-tool-breadcrumbs ol{display:flex;flex-wrap:nowrap;align-items:center;gap:8px;width:max-content;min-width:0;list-style:none;margin:0;padding:0;white-space:nowrap}
.tn-tool-breadcrumbs li{display:inline-flex;align-items:center;flex:none;list-style:none;margin:0;padding:0}
.tn-tool-breadcrumbs li+li::before{content:"/";margin-right:8px;color:#b9b9b9}
.tn-tool-breadcrumbs a{color:inherit;text-decoration:underline;text-underline-offset:2px}
.tn-tool-breadcrumbs [aria-current="page"]{color:var(--tn-text,#f0f0f0)}

/* Watermark only: page scroll instead of independent settings/upload/output scroll. */
.tn-image-workspace[data-image-kind="watermark"] .tn-image-workspace__grid{height:auto;min-height:0;align-items:start}
.tn-image-workspace[data-image-kind="watermark"] .tn-image-workspace__main{grid-template-rows:auto auto;min-height:0;align-content:start}
.tn-image-workspace[data-image-kind="watermark"] .tn-image-panel{height:auto;max-height:none;min-height:0;overflow:visible}
.tn-image-workspace[data-image-kind="watermark"] .tn-image-panel__body{height:auto;max-height:none;min-height:0;overflow:visible;overscroll-behavior:auto}
.tn-image-workspace[data-image-kind="watermark"] .tn-image-panel--settings{max-height:none}
.tn-image-workspace[data-image-kind="watermark"] .tn-image-panel--settings .tn-image-panel__body{overflow:visible}
@media(max-width:900px){
  .tn-image-workspace[data-image-kind="watermark"] .tn-image-panel--settings{max-height:none}
}

/* Render the explanatory page navigation once, as a compact wrapping row. */
.tn-image-secondary .descriptions-nav{min-width:0;margin:6px 0 10px}
.tn-image-secondary .descriptions-nav ul{display:flex;flex-wrap:wrap;align-items:center;gap:8px;list-style:none;padding:0;margin:0}
.tn-image-secondary .descriptions-nav li{list-style:none;margin:0;padding:0}
.tn-image-secondary .descriptions-nav a{display:inline-flex;align-items:center;min-height:36px;padding:6px 10px;border:1px solid var(--tn-line,#989898);background:#292929;color:var(--tn-text,#f0f0f0);text-decoration:none;font-size:.8rem}
.tn-image-secondary .descriptions-nav a:hover,.tn-image-secondary .descriptions-nav a:focus-visible{border-color:#b7d7d4}
.tn-image-secondary .descriptions-nav a.active{border-color:#b7d7d4;background:#394c4b}
