/* Marketplace (ttc-market.js) */
.ta-layout.tmk-layout{max-width:1560px}
.tmk-main{flex-basis:520px!important}
.tmk-wrap{display:grid;grid-template-columns:300px minmax(0,1fr);gap:20px;align-items:start}
.tmk-side{position:sticky;top:84px;display:flex;flex-direction:column;gap:10px;background:#111D22;border:1px solid #1E2F36;border-radius:16px;padding:16px 12px;max-height:calc(100vh - 100px);overflow:auto}
.tmk-side-head{display:flex;flex-direction:column;gap:10px;padding:0 4px}
#ttc-feed-app .tmk-title{margin:0;font:700 26px 'Space Grotesk',Inter,sans-serif;color:#E8F1F3}
.tmk-search{display:flex;align-items:center;gap:8px;height:42px;padding:0 14px;border-radius:21px;background:#0E191D;border:1px solid #23363D;color:#8FA6AD}
.tmk-search .tf-ic{width:18px;height:18px;flex-shrink:0}
#ttc-feed-app .tmk-search input{flex:1;min-width:0;border:0;background:none;color:#E8F1F3;font:15px Inter,sans-serif;outline:none;height:100%;padding:0;margin:0}
.tmk-navs{display:flex;flex-direction:column;gap:2px}
#ttc-feed-app .tmk-nav{display:flex;align-items:center;gap:12px;padding:8px;border-radius:10px;color:#E8F1F3!important;font-weight:600;font-size:15px;text-decoration:none}
.tmk-nav:hover{background:#15242A}
#ttc-feed-app .tmk-nav[aria-current=page]{background:#3FD2E81a;color:#7FE3F2!important}
.tmk-nav-ic{width:36px;height:36px;border-radius:50%;background:#15242A;display:flex;align-items:center;justify-content:center;font-size:18px;flex-shrink:0}
.tmk-nav-ic .tf-ic{width:18px;height:18px}
.tmk-nav[aria-current=page] .tmk-nav-ic{background:#3FD2E8;color:#062026}
.tmk-create{justify-content:center;margin:4px 4px 0}
#ttc-feed-app .tmk-side-h{margin:10px 8px 0;font:700 16px Inter,sans-serif;color:#E8F1F3;border-top:1px solid #1E2F36;padding-top:12px}
.tmk-body{min-width:0;display:flex;flex-direction:column;gap:14px}
.tmk-phone-top{display:none}
.tmk-wrap.focus{grid-template-columns:minmax(0,1fr);max-width:1240px}
.tmk-wrap.focus .tmk-side,.tmk-wrap.focus .tmk-phone-top{display:none!important}
.tmk-wrap.focus .tmk-chat{max-width:760px;width:100%;margin:0 auto}

/* Grid */
.tmk-section{display:flex;flex-direction:column;gap:12px}
.tmk-section-head{display:flex;align-items:center;justify-content:space-between;gap:10px}
#ttc-feed-app .tmk-section-head h2{margin:0;font:700 20px 'Space Grotesk',Inter,sans-serif;color:#E8F1F3}
.tmk-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(200px,1fr));gap:18px 14px}
#ttc-feed-app .tmk-card{display:flex;flex-direction:column;gap:2px;color:#E8F1F3!important;text-decoration:none;min-width:0}
.tmk-card-pic{position:relative;aspect-ratio:1;border-radius:12px;overflow:hidden;background:#15242A;margin-bottom:6px}
.tmk-card-pic img{width:100%;height:100%;object-fit:cover;display:block;transition:transform .25s}
.tmk-card:hover .tmk-card-pic img{transform:scale(1.03)}
.tmk-noimg{width:100%;height:100%;display:flex;align-items:center;justify-content:center;font-size:56px;background:linear-gradient(135deg,#15242A,#0E191D)}
.tmk-noimg.big{font-size:120px;aspect-ratio:4/3}
.tmk-noimg.sm{width:48px;height:48px;font-size:22px;border-radius:10px;flex-shrink:0}
.tmk-price{font:700 17px Inter,sans-serif}
.tmk-card-title{font-size:15px;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical}
.tmk-card-area{font-size:13px;color:#8FA6AD;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.tmk-state{position:absolute;left:8px;top:8px;font-size:12px;font-weight:700;border-radius:8px;padding:3px 8px;background:#F2B26B;color:#1A0E02}
.tmk-state.s-sold{background:#F28B82;color:#2A0806}
.tmk-state.inline{position:static;margin-left:10px;vertical-align:middle}
.tmk-saved-dot{position:absolute;right:8px;top:8px;width:30px;height:30px;border-radius:50%;background:#0B1418cc;color:#3FD2E8;display:flex;align-items:center;justify-content:center}
.tmk-saved-dot .tf-ic{width:16px;height:16px;fill:currentColor}
.tmk-more{grid-column:1/-1;justify-self:center}
.tmk-empty{grid-column:1/-1;display:flex;flex-direction:column;align-items:center;gap:6px;padding:48px 16px;text-align:center;background:#111D22;border:1px solid #1E2F36;border-radius:16px}
.tmk-empty>span{font-size:40px}
.tmk-empty small{color:#8FA6AD;max-width:380px}
.tmk-empty .ta-btn{margin-top:8px}

/* One listing */
.tmk-item{display:grid;grid-template-columns:minmax(0,1.35fr) minmax(320px,1fr);gap:20px;align-items:start}
.tmk-gallery{display:flex;flex-direction:column;gap:10px;position:sticky;top:84px}
.tmk-gallery-main{position:relative;background:#050A0D;border-radius:16px;overflow:hidden;display:flex;align-items:center;justify-content:center;aspect-ratio:4/3}
.tmk-gallery-main img{width:100%;height:100%;object-fit:contain}
#ttc-feed-app .tmk-arrow{position:absolute;top:50%;transform:translateY(-50%);width:44px;height:44px;border-radius:50%;border:0;background:#0B1418cc;color:#E8F1F3;display:flex;align-items:center;justify-content:center;cursor:pointer}
.tmk-arrow.prev{left:10px}.tmk-arrow.next{right:10px}
.tmk-arrow.next svg{transform:rotate(180deg)}
.tmk-thumbs{display:flex;gap:8px;overflow-x:auto}
.tmk-thumbs:empty{display:none}
#ttc-feed-app .tmk-thumb{flex:0 0 72px;height:72px;border-radius:10px;overflow:hidden;border:2px solid transparent;padding:0;background:#15242A;cursor:pointer}
.tmk-thumb[aria-pressed=true]{border-color:#3FD2E8!important}
.tmk-thumb img{width:100%;height:100%;object-fit:cover}
.tmk-info{display:flex;flex-direction:column;gap:12px;min-width:0}
#ttc-feed-app .tmk-item-title{margin:0;font:700 28px/1.2 'Space Grotesk',Inter,sans-serif;color:#E8F1F3;overflow-wrap:anywhere}
.tmk-item-price{font:700 22px Inter,sans-serif;color:#E8F1F3}
.tmk-actions{display:flex;gap:8px;flex-wrap:wrap}
.tmk-actions .ta-btn{flex:1 1 auto;justify-content:center}
.tmk-actions .ta-btn[aria-pressed=true]{background:#3FD2E81f;border-color:#3FD2E855;color:#7FE3F2!important}
.tmk-actions .ta-btn[aria-pressed=true] .tf-ic{fill:currentColor}
#ttc-feed-app .ta-btn.tmk-danger{color:#F28B82!important}
.tmk-seller-tools{display:flex;flex-direction:column;gap:10px}
.tmk-states{display:grid;grid-template-columns:repeat(3,1fr);gap:4px;background:#0E191D;border-radius:12px;padding:4px}
#ttc-feed-app .tmk-states button{height:38px;border:0;border-radius:9px;background:none;color:#8FA6AD;font:600 14px Inter,sans-serif;cursor:pointer}
#ttc-feed-app .tmk-states button[aria-pressed=true]{background:#1E2F36;color:#E8F1F3}
.tmk-details,.tmk-sellercard{background:#111D22;border:1px solid #1E2F36;border-radius:16px;padding:14px 16px}
#ttc-feed-app .tmk-details h2,#ttc-feed-app .tmk-sellercard h2,#ttc-feed-app .tmk-ask h2{margin:0 0 8px;font:700 16px Inter,sans-serif;color:#E8F1F3;display:flex;align-items:center;gap:8px}
.tmk-ask h2 .tf-ic{width:18px;height:18px;color:#3FD2E8}
.tmk-details dl{display:grid;grid-template-columns:auto 1fr;gap:6px 16px;margin:0;font-size:14px}
.tmk-details dt{color:#8FA6AD}
.tmk-details dd{margin:0}
.tmk-details dd a{color:#3FD2E8!important}
.tmk-desc{white-space:pre-wrap;margin:12px 0 0;font-size:15px;line-height:1.5;color:#C9D8DC;overflow-wrap:anywhere}
#ttc-feed-app .tmk-seller{display:flex;align-items:center;gap:12px;color:#E8F1F3!important;text-decoration:none}
.tmk-seller>span{display:flex;flex-direction:column}
.tmk-seller small{color:#8FA6AD;font-size:12px}
.tmk-ask{padding:14px 16px!important;display:flex;flex-direction:column;gap:10px}
.tmk-ask .ta-btn{align-self:flex-end}
.tmk-quick{display:flex;gap:6px;flex-wrap:wrap}
#ttc-feed-app .tmk-quick button{border:1px solid #23363D;background:#0E191D;color:#C9D8DC;border-radius:16px;padding:6px 12px;font:500 13px Inter,sans-serif;cursor:pointer}
.tmk-quick button:hover{border-color:#3FD2E8;color:#E8F1F3}
#ttc-feed-app .tmk-ask textarea,#ttc-feed-app .tmk-form textarea,#ttc-feed-app .tmk-dlg textarea,#ttc-feed-app .tmk-compose textarea{width:100%;box-sizing:border-box;border-radius:12px;border:1px solid #23363D;background:#0E191D;color:#E8F1F3;font:15px/1.4 Inter,sans-serif;padding:10px 12px;margin:0;resize:vertical}

/* Create and edit */
.tmk-editor{display:grid;grid-template-columns:minmax(0,1fr) 280px;gap:20px;align-items:start}
.tmk-form{padding:18px!important;display:flex;flex-direction:column;gap:14px}
#ttc-feed-app .tmk-form h2{margin:0;font:700 22px 'Space Grotesk',Inter,sans-serif}
#ttc-feed-app .tmk-form input:not([type=file]),#ttc-feed-app .tmk-form select{width:100%;box-sizing:border-box;height:46px;border-radius:12px;border:1px solid #23363D;background:#0E191D;color:#E8F1F3;font:15px Inter,sans-serif;padding:0 12px;margin:0;color-scheme:dark}
.tmk-form-row{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.tmk-small{font-size:12px!important;margin:0}
.tmk-upload{display:flex;gap:10px;flex-wrap:wrap}
.tmk-up{position:relative;width:110px;height:110px;border-radius:12px;overflow:hidden;background:#15242A}
.tmk-up img{width:100%;height:100%;object-fit:cover}
.tmk-up.add{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;border:2px dashed #23363D;background:none;cursor:pointer;color:#8FA6AD;font-size:12px;text-align:center;padding:6px;box-sizing:border-box}
.tmk-up.add:hover{border-color:#3FD2E8;color:#E8F1F3}
.tmk-up.add .tf-ic{width:26px;height:26px;color:#3FD2E8}
.tmk-file{position:absolute;inset:0;opacity:0;cursor:pointer}
#ttc-feed-app .tmk-up-x{position:absolute;right:4px;top:4px;width:26px;height:26px;border-radius:50%;border:0;background:#0B1418cc;color:#E8F1F3;display:flex;align-items:center;justify-content:center;padding:0;cursor:pointer}
.tmk-up-x .tf-ic{width:14px;height:14px}
#ttc-feed-app .tmk-up-edit{position:absolute;left:4px;bottom:4px;border:0;border-radius:8px;background:#0B1418cc;color:#E8F1F3;font:600 12px Inter,sans-serif;padding:4px 8px;cursor:pointer}
#ttc-feed-app .tmk-clear{align-self:center;border:0;background:none;color:#F28B82;font:600 13px Inter,sans-serif;cursor:pointer}
.tmk-preview{position:sticky;top:84px;background:#111D22;border:1px solid #1E2F36;border-radius:16px;padding:14px}
.tmk-label{font-size:12px;font-weight:700;color:#8FA6AD;text-transform:uppercase;letter-spacing:.06em;margin-bottom:10px}

/* Inbox and chat */
.tmk-inbox{padding:6px!important;display:flex;flex-direction:column}
#ttc-feed-app .tmk-thread{display:flex;align-items:center;gap:12px;padding:10px;border-radius:12px;color:#E8F1F3!important;text-decoration:none}
.tmk-thread:hover{background:#15242A}
.tmk-thread>span:nth-child(2){flex:1;min-width:0;display:flex;flex-direction:column}
.tmk-thread small{color:#8FA6AD;font-size:13px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.tmk-tag{font-size:11px;font-weight:700;border-radius:6px;padding:2px 8px;background:#3FD2E824;color:#3FD2E8}
.tmk-tag.sell{background:#6FDCA024;color:#6FDCA0}
.tmk-inbox .tmk-empty{border:0}
.tmk-chat{display:flex;flex-direction:column;height:calc(100vh - 130px);min-height:420px;overflow:hidden}
.tmk-chat-head{display:flex;align-items:center;gap:8px;padding:10px 12px;border-bottom:1px solid #1E2F36}
#ttc-feed-app .tmk-thread-item{flex:1;min-width:0;display:flex;align-items:center;gap:10px;color:#E8F1F3!important;text-decoration:none}
.tmk-thread-item img{width:48px;height:48px;border-radius:10px;object-fit:cover;flex-shrink:0}
.tmk-thread-item>span{display:flex;flex-direction:column;min-width:0}
.tmk-thread-item strong{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.tmk-thread-item small{color:#8FA6AD;font-size:12px}
.tmk-log{flex:1;overflow:auto;padding:14px;display:flex;flex-direction:column;gap:8px}
.tmk-msg{display:flex;align-items:flex-end;gap:8px;max-width:78%}
.tmk-msg.out{align-self:flex-end;flex-direction:row-reverse}
.tmk-msg>div{display:flex;flex-direction:column}
.tmk-msg p{margin:0;padding:9px 13px;border-radius:18px;background:#1E2F36;color:#E8F1F3;font-size:15px;white-space:pre-wrap;overflow-wrap:anywhere}
.tmk-msg.out p{background:#3FD2E8;color:#062026}
.tmk-msg small{font-size:11px;color:#6F878E;padding:2px 6px}
.tmk-msg.out small{text-align:right}
.tmk-chat>.tmk-quick{padding:0 12px 8px}
.tmk-quick[hidden]{display:none}
.tmk-compose{display:flex;gap:8px;align-items:flex-end;padding:10px 12px;border-top:1px solid #1E2F36}
#ttc-feed-app .tmk-compose textarea{resize:none;border-radius:20px;min-height:42px}
.tmk-chat>.tf-notice{margin:0 12px}

@media(max-width:1199px){
  .tmk-wrap{grid-template-columns:250px minmax(0,1fr)}
  .tmk-item{grid-template-columns:minmax(0,1fr)}
  .tmk-gallery{position:static}
  .tmk-editor{grid-template-columns:minmax(0,1fr)}
  .tmk-preview{position:static;max-width:280px}
}
@media(max-width:899px){
  .tmk-wrap{grid-template-columns:minmax(0,1fr)}
  .tmk-side{display:none}
  .tmk-phone-top{display:flex;flex-direction:column;gap:10px}
  .tmk-chips{display:flex;gap:8px;overflow-x:auto;scrollbar-width:none;margin:0 -12px;padding:0 12px}
  .tmk-chips::-webkit-scrollbar{display:none}
  #ttc-feed-app .tmk-chip{flex-shrink:0;height:36px;padding:0 14px;border-radius:18px;background:#15242A;color:#E8F1F3!important;font:600 14px Inter,sans-serif;display:inline-flex;align-items:center;text-decoration:none;white-space:nowrap}
  #ttc-feed-app .tmk-chip[aria-current=page]{background:#3FD2E8;color:#062026!important}
}
@media(max-width:759px){
  .tmk-main{padding:12px 12px 0!important}
  .tmk-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:14px 10px}
  .tmk-price{font-size:16px}
  .tmk-card-title{font-size:14px}
  .tmk-item{gap:14px}
  .tmk-gallery-main{border-radius:0;margin:0 -12px;aspect-ratio:1}
  .tmk-thumbs{padding:0 2px}
  #ttc-feed-app .tmk-item-title{font-size:24px}
  .tmk-form{padding:14px!important}
  .tmk-up{width:calc(50% - 5px);height:auto;aspect-ratio:1}
  .tmk-preview{display:none}
  .tmk-chat{height:calc(100dvh - 210px);min-height:360px}
  .tmk-msg{max-width:88%}
}
