/* Markdown converter landing page (/tools/markdown-converter) only. Layers on market-tools.css + browser-tool.css. */
.tp-md .tp-main{max-width:1220px}
.tp-md .tp-hero{display:grid;gap:8px;max-width:820px;margin:0 0 18px}
.tp-md .tp-hero h1{margin:0;font-size:clamp(1.7rem,3.6vw,2.6rem);line-height:1.12;letter-spacing:-.03em}
.tp-md .tp-hero .mt-eyebrow{margin:0}
.tp-md .tp-lede{margin:0;font-size:1.05rem;line-height:1.55;color:var(--muted,#52647b);max-width:68ch}

.tp-md .tp-tool{margin:0 0 12px;scroll-margin-top:90px}
.tp-md .tp-grid{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:16px;margin:0 0 14px}
.tp-md .tp-grid .bt-panel{min-width:0;margin:0}
.tp-md .tp-input{display:flex;flex-direction:column;border-color:#9fb7e6;box-shadow:0 10px 30px rgba(7,27,53,.08)}

/* Format toggle + one download button (pure CSS: the checked radio decides which button shows) */
.tp-md .tp-fmt{border:0;margin:0 0 16px;padding:0 0 16px;border-bottom:1px solid var(--line,#d7e1ee);min-width:0}
.tp-md .tp-fmt legend{padding:0;margin:0 0 8px;font-size:.74rem;font-weight:700;letter-spacing:.06em;text-transform:uppercase;color:var(--muted,#52647b)}
.tp-md .tp-seg{display:flex;flex-wrap:wrap;align-items:center;gap:10px}
.tp-md .tp-seg input[type=radio]{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip:rect(0 0 0 0);border:0;opacity:0}
.tp-md .tp-seg label{display:inline-flex;align-items:center;justify-content:center;min-height:44px;margin:0;padding:8px 16px;border:1px solid var(--line,#d7e1ee);border-radius:10px;background:#fff;color:var(--ink,#071b35);font-size:.95rem;font-weight:700;letter-spacing:0;cursor:pointer}
.tp-md .tp-seg label:hover{border-color:var(--blue,#1f5cf0)}
.tp-md .tp-seg input[type=radio]:checked+label{background:var(--soft,#edf4ff);border-color:var(--blue,#1f5cf0);color:var(--blue-dark,#1548c7);box-shadow:inset 0 0 0 1px var(--blue,#1f5cf0)}
.tp-md .tp-seg input[type=radio]:focus-visible+label{outline:3px solid #1f5cf0;outline-offset:2px}
.tp-md .tp-dl{display:flex;flex-wrap:wrap;align-items:center;gap:8px 14px;flex:1 1 100%;margin-top:2px}
.tp-md .tp-go{min-height:48px}
.tp-md .tp-go:focus-visible{outline:3px solid #0a2a6b;outline-offset:2px}
.tp-md .tp-go-note{margin:0;flex:1 1 220px;font-size:.84rem;line-height:1.45;color:var(--muted,#52647b)}
.tp-md #fmt-pdf:checked~.tp-dl .tp-go-docx,.tp-md #fmt-pdf:checked~.tp-dl .tp-go-html,
.tp-md #fmt-docx:checked~.tp-dl .tp-go-pdf,.tp-md #fmt-docx:checked~.tp-dl .tp-go-html,
.tp-md #fmt-html:checked~.tp-dl .tp-go-pdf,.tp-md #fmt-html:checked~.tp-dl .tp-go-docx{display:none}

.tp-md .tp-input-head{display:flex;align-items:center;justify-content:space-between;gap:10px;margin:0 0 8px}
.tp-md .tp-input-head h2{margin:0}
.tp-md .tp-tag{font-size:.74rem;font-weight:700;letter-spacing:.04em;text-transform:uppercase;color:#1548c7;background:#edf4ff;border-radius:999px;padding:4px 10px;white-space:nowrap}
.tp-md .tp-input label[for=md-in]{font-weight:500;color:var(--muted,#52647b);letter-spacing:0}
.tp-md .tp-input textarea#md-in{flex:1 1 auto;min-height:340px;border-color:#9fb7e6}
.tp-md .tp-input textarea#md-in:focus-visible{outline:3px solid #1f5cf0;outline-offset:1px}

/* Rendered preview */
.tp-md .tp-prev{display:flex;flex-direction:column}
.tp-md .tp-preview{flex:1 1 auto;max-height:620px;overflow:auto;padding:4px 2px;line-height:1.6;color:var(--ink,#071b35);overflow-wrap:anywhere}
.tp-md .tp-preview:focus-visible{outline:2px solid #1f5cf0;outline-offset:2px}
.tp-md .tp-preview h1,.tp-md .tp-preview h2,.tp-md .tp-preview h3,.tp-md .tp-preview h4{margin:1.1em 0 .45em;line-height:1.25}
.tp-md .tp-preview h1{font-size:1.5rem}
.tp-md .tp-preview h2{font-size:1.2rem}
.tp-md .tp-preview h3{font-size:1.02rem}
.tp-md .tp-preview>:first-child{margin-top:0}
.tp-md .tp-preview p,.tp-md .tp-preview ul,.tp-md .tp-preview ol,.tp-md .tp-preview blockquote,.tp-md .tp-preview pre,.tp-md .tp-preview table{margin:0 0 .9em}
.tp-md .tp-preview ul,.tp-md .tp-preview ol{padding-left:1.4em}
.tp-md .tp-preview blockquote{padding:8px 14px;border-left:4px solid #9fb7e6;background:#f5f8fd;color:#34465e}
.tp-md .tp-preview code{font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;font-size:.86em;background:#edf2f9;border-radius:4px;padding:1px 5px}
.tp-md .tp-preview pre{padding:12px 14px;border-radius:10px;background:#0d1b33;color:#e6ecf7;overflow:auto}
.tp-md .tp-preview pre code{background:none;padding:0;color:inherit}
.tp-md .tp-preview table{display:block;max-width:100%;overflow-x:auto;border-collapse:collapse;font-size:.9rem}
.tp-md .tp-preview th,.tp-md .tp-preview td{border:1px solid var(--line,#d7e1ee);padding:6px 10px}
.tp-md .tp-preview th{background:#f3f6fb}
.tp-md .tp-preview img{max-width:100%;height:auto}
.tp-md .tp-preview hr{border:0;border-top:1px solid var(--line,#d7e1ee);margin:1.2em 0}
.tp-md .tp-preview a{color:var(--blue,#1f5cf0)}

/* HTML source + options */
.tp-md .tp-opts{margin:0 0 14px;padding:0 18px}
.tp-md .tp-opts summary{display:flex;align-items:center;min-height:48px;font-weight:700;cursor:pointer}
.tp-md .tp-opts summary:focus-visible{outline:2px solid #1f5cf0;outline-offset:2px}
.tp-md .tp-opts-body{padding:0 0 18px}
.tp-md .tp-opts .bt-check{min-height:40px;margin:0}
.tp-md .tp-lbl{display:block;margin:14px 0 6px;font-size:.82rem;font-weight:600}
.tp-md .tp-select{font:inherit;font-size:.95rem;min-height:44px;padding:8px 12px;border:1px solid var(--line,#d7e1ee);border-radius:9px;background:#fff;color:inherit;max-width:100%}
.tp-md .tp-select:focus-visible{outline:2px solid #1f5cf0;outline-offset:2px}
.tp-md .bt-pre{max-height:320px;white-space:pre-wrap;word-break:break-word}
.tp-md .bt-pre:focus-visible{outline:2px solid #1f5cf0;outline-offset:2px}
.tp-md #md-copy{min-height:44px}

.tp-md .tp-price{margin:0;font-size:.92rem;line-height:1.55;color:var(--muted,#52647b)}
.tp-md .tp-price b{color:var(--ink,#071b35)}
.tp-md .tp-price a{display:inline-flex;align-items:center;min-height:40px;font-weight:700;color:var(--blue,#1f5cf0)}
.tp-md .tp-price a:focus-visible{outline:2px solid #1f5cf0;outline-offset:2px}

/* What you get / syntax */
.tp-md .tp-cards{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}
.tp-md .tp-card{border:1px solid var(--line,#d7e1ee);border-radius:14px;background:#fff;padding:18px 18px 8px}
.tp-md .tp-card h3{margin:0 0 8px;font-size:1.02rem}
.tp-md .tp-card p{margin:0 0 10px;line-height:1.6}
.tp-md .tp-cols{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}
.tp-md .tp-cols h3{margin:0 0 6px}
.tp-md .tp-cols p{margin:0;line-height:1.6}

/* Browser tool: the footer's generic result-expiry note does not apply here. */
.tp-md .wt-foot-note{display:none}

@media (max-width:900px){
  .tp-md .tp-grid,.tp-md .tp-cards,.tp-md .tp-cols{grid-template-columns:minmax(0,1fr)}
  .tp-md .tp-input textarea#md-in{min-height:220px;flex:0 0 auto}
  .tp-md .tp-preview{max-height:420px}
}
@media (max-width:600px){
  .tp-md .tp-hero{margin-bottom:12px}
  .tp-md .tp-lede{font-size:.98rem}
  .tp-md .tp-seg{gap:8px}
  .tp-md .tp-seg label{flex:1 1 0;padding:8px 8px;font-size:.9rem}
  .tp-md .tp-go{width:100%}
  .tp-md .tp-opts{padding:0 14px}
}
@media (prefers-reduced-motion:reduce){
  .tp-md *{scroll-behavior:auto;transition:none!important}
}
.tp-md .tp-preview .al-left{text-align:left}.tp-md .tp-preview .al-center{text-align:center}.tp-md .tp-preview .al-right{text-align:right}
