/* DekAus additions on top of the Sarsa theme (main.css). */

:root {
  /* Noto Sans Thai has Thai glyphs; Roboto (the theme default) does not. */
  --tg-body-font-family: 'Noto Sans Thai', 'Roboto', sans-serif;
  --tg-heading-font-family: 'Noto Sans Thai', 'Roboto', sans-serif;
  --tg-body-line-height: 1.75;
  --tg-heading-line-height: 1.4;
  --dekaus-card-bg: #fff;
  --dekaus-soft-bg: #f6f6f6;
  --dekaus-muted: #6b6b6b;
  --dekaus-error: #c62828;
  --dekaus-radius: 10px;
}
[tg-theme=dark] {
  --dekaus-card-bg: #1b1b1b;
  --dekaus-soft-bg: #161616;
  --dekaus-muted: #a9a9a9;
  --dekaus-error: #ff6b6b;
}

body { font-family: var(--tg-body-font-family); }
h1, h2, h3, h4, h5, h6 { font-family: var(--tg-heading-font-family); }

.dekaus-skip { position: absolute; left: 1rem; top: 1rem; z-index: 1000; background: #fff; padding: .5rem 1rem; }
.dekaus-tagline { font-size: 14px; color: var(--tg-body-color); }
.dekaus-muted { color: var(--dekaus-muted); }
.dekaus-empty { padding: 40px 0; color: var(--dekaus-muted); }
.dekaus-view-all { font-weight: 600; white-space: nowrap; }
.dekaus-error-code { font-size: 96px; font-weight: 700; line-height: 1; color: var(--tg-theme-primary); margin-bottom: 10px; }

/* Image placeholders when an article or business has no picture. */
.dekaus-placeholder {
  display: block; width: 100%; aspect-ratio: 16 / 10;
  background: var(--dekaus-soft-bg) url(../img/logo/dekaus-logo-small-sq.png) center / 30% no-repeat;
  opacity: .9;
}
.dekaus-placeholder--big { aspect-ratio: 16 / 9; }
.latest__post-thumb img, .tgbanner__thumb img { width: 100%; object-fit: cover; }

/*
 * Featured images: one shape everywhere (1200 × 630, the Facebook/LINE share size),
 * instead of the theme's fixed pixel heights, which cropped text off the top and bottom
 * (or the sides) differently at each screen width. A 1200 × 630 image is never cropped;
 * other shapes are cropped to the centre. Guide for editors: Admin → News → Featured image guide.
 */
.latest__post-thumb img,
.tgbanner__post.big-post img,
.tgbanner__post.small-post img {
  height: auto; aspect-ratio: 1200 / 630; object-fit: cover; object-position: center;
}
.dekaus-placeholder, .dekaus-placeholder--big { aspect-ratio: 1200 / 630; }
/* The theme pulls the big home story's caption 50px up over the image, hiding its bottom edge. */
.tgbanner__post.big-post .tgbanner__content { margin-top: 0; }
.blog-details-thumb img { width: 100%; height: auto; }

/* Article bodies (imported WordPress HTML and the admin editor). */
.dekaus-prose { overflow-wrap: anywhere; }
.dekaus-prose img { max-width: 100%; height: auto; border-radius: 6px; }
.dekaus-prose figure { margin: 30px 0; max-width: 100%; }
.dekaus-prose figure.aligncenter, .dekaus-prose .aligncenter { margin-left: auto; margin-right: auto; display: block; text-align: center; }
.dekaus-prose .alignleft { float: left; margin: 0 20px 15px 0; }
.dekaus-prose .alignright { float: right; margin: 0 0 15px 20px; }
.dekaus-prose figcaption { font-size: 14px; color: var(--dekaus-muted); margin-top: 8px; text-align: center; }
.dekaus-prose iframe, .dekaus-prose .dekaus-embed { width: 100%; max-width: 100%; border: 0; }
.dekaus-prose .dekaus-embed { aspect-ratio: 16 / 9; height: auto; }
.dekaus-prose table { width: 100%; margin-bottom: 20px; }
.dekaus-prose td, .dekaus-prose th { border: 1px solid var(--tg-border-1); padding: 8px; }
.dekaus-prose .dekaus-columns { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 24px; margin-bottom: 20px; }
.dekaus-prose .dekaus-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 10px; }
.dekaus-prose::after { content: ""; display: table; clear: both; }
@media (max-width: 575px) { .dekaus-prose .alignleft, .dekaus-prose .alignright { float: none; margin: 0 0 15px; } }

/* Facebook group cards */
.dekaus-groups { display: grid; gap: 14px; }
.dekaus-groups--large { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 24px; }
.dekaus-group-card {
  display: flex; gap: 14px; align-items: flex-start; padding: 16px;
  border: 1px solid var(--tg-border-1); border-radius: var(--dekaus-radius);
  background: var(--dekaus-card-bg); color: inherit; transition: border-color .2s, transform .2s;
}
.dekaus-group-card:hover { border-color: #1877f2; transform: translateY(-2px); color: inherit; }
.dekaus-group-card__icon {
  flex: 0 0 44px; height: 44px; border-radius: 50%; display: grid; place-items: center;
  background: #1877f2; color: #fff; font-size: 18px;
}
.dekaus-group-card__body { display: flex; flex-direction: column; gap: 4px; font-size: 14px; line-height: 1.5; }
.dekaus-group-card__body strong { font-size: 16px; color: var(--tg-heading-color); }
.dekaus-group-card__cta { color: #1877f2; font-weight: 600; margin-top: 4px; }
.dekaus-groups-list li a { display: flex; gap: 10px; align-items: center; padding: 6px 0; }

.dekaus-cta { padding: 20px; border-radius: var(--dekaus-radius); background: var(--dekaus-soft-bg); }
.dekaus-cta p { font-size: 14px; }

/* Directory */
.dekaus-directory-strip { background: var(--dekaus-soft-bg); }
.dekaus-business-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 20px; margin-bottom: 30px; }
.dekaus-business-grid--2 { grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); }
.dekaus-business-card {
  display: flex; gap: 16px; padding: 18px; border: 1px solid var(--tg-border-1);
  border-radius: var(--dekaus-radius); background: var(--dekaus-card-bg); height: 100%;
}
.dekaus-business-card .title { font-size: 18px; margin-bottom: 6px; }
.dekaus-business-card p { font-size: 14px; margin: 8px 0 0; line-height: 1.6; }
.dekaus-business-card .tgbanner__content-meta { font-size: 13px; }
.dekaus-business-card__logo {
  flex: 0 0 72px; height: 72px; border-radius: 8px; overflow: hidden; display: grid; place-items: center;
  background: var(--dekaus-soft-bg); color: var(--tg-theme-primary); font-size: 28px;
}
.dekaus-business-card__logo img { width: 100%; height: 100%; object-fit: cover; }
.dekaus-business-card__logo--lg { flex-basis: 120px; height: 120px; font-size: 44px; }
.dekaus-business-header { display: flex; gap: 24px; align-items: flex-start; }
.dekaus-badge {
  display: inline-block; font-size: 12px; font-weight: 600; padding: 2px 10px; border-radius: 20px;
  background: var(--tg-theme-primary); color: #fff; margin-bottom: 6px;
}
.dekaus-dir-cats li.active > a { color: var(--tg-theme-primary); font-weight: 600; }
.dekaus-contact-list li { display: flex; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--tg-border-1); }
.dekaus-contact-list li:last-child { border-bottom: 0; }
.dekaus-contact-list i { width: 18px; margin-top: 4px; color: var(--tg-theme-primary); }
.dekaus-contact-list small { display: block; color: var(--dekaus-muted); }
.dekaus-contact-list span { overflow-wrap: anywhere; }
.dekaus-more-list li { padding: 6px 0; }

.dekaus-search { display: flex; gap: 10px; }
.dekaus-search input {
  flex: 1; min-width: 0; padding: 12px 18px; border: 1px solid var(--tg-border-1); border-radius: 6px;
  background: var(--dekaus-card-bg); color: var(--tg-heading-color);
}
@media (max-width: 575px) { .dekaus-business-header { flex-direction: column; } .dekaus-search .btn-text { display: none; } }

/* Submit form */
.dekaus-form fieldset { border: 1px solid var(--tg-border-1); border-radius: var(--dekaus-radius); padding: 24px; margin-bottom: 30px; }
.dekaus-form legend { float: none; width: auto; padding: 0 10px; font-size: 18px; font-weight: 600; color: var(--tg-heading-color); }
.dekaus-field { margin-bottom: 18px; }
.dekaus-field label { display: block; font-weight: 500; margin-bottom: 6px; color: var(--tg-heading-color); }
.dekaus-field input:not([type=checkbox]), .dekaus-field select, .dekaus-field textarea {
  width: 100%; padding: 10px 14px; border: 1px solid var(--tg-border-1); border-radius: 6px;
  background: var(--dekaus-card-bg); color: var(--tg-heading-color);
}
.dekaus-field input:focus, .dekaus-field select:focus, .dekaus-field textarea:focus { outline: 2px solid var(--tg-theme-primary); outline-offset: 1px; }
.dekaus-field.has-error input, .dekaus-field.has-error select, .dekaus-field.has-error textarea { border-color: var(--dekaus-error); }
.dekaus-help { font-size: 13px; color: var(--dekaus-muted); margin: 4px 0 0; }
.dekaus-error { font-size: 13px; color: var(--dekaus-error); margin: 4px 0 0; }
.dekaus-required { color: var(--dekaus-error); }
.dekaus-form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 20px; }
.dekaus-form-row--3 { grid-template-columns: 2fr 2fr 1fr; }
@media (max-width: 767px) { .dekaus-form-row, .dekaus-form-row--3 { grid-template-columns: 1fr; } }
.dekaus-check { display: flex; gap: 10px; align-items: flex-start; flex-wrap: wrap; }
.dekaus-check input { margin-top: 6px; }
.dekaus-check label { flex: 1; font-weight: 400; }
.dekaus-check .dekaus-error { flex-basis: 100%; }
.dekaus-hp { position: absolute !important; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.dekaus-alert { padding: 16px 20px; border-radius: 8px; margin-bottom: 24px; }
.dekaus-alert--error { background: rgba(198, 40, 40, .08); border: 1px solid var(--dekaus-error); color: var(--dekaus-error); }
.dekaus-success-icon { font-size: 64px; color: var(--tg-common-color-green); margin-bottom: 20px; }

.pagination__wrap li span { display: block; }
.dekaus-error-page { font-family: 'Noto Sans Thai', sans-serif; }

/* Webboard (หางาน / หาบ้าน) */
.dekaus-wb-board { border: 1px solid var(--tg-border-1); border-radius: var(--dekaus-radius); background: var(--dekaus-card-bg); padding: 24px; height: 100%; display: flex; flex-direction: column; }
.dekaus-wb-board__head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; margin-bottom: 12px; flex-wrap: wrap; }
.dekaus-wb-board__title { font-size: 24px; margin-bottom: 4px; }
.dekaus-wb-board__title i { color: var(--tg-theme-primary); margin-right: 6px; }
.dekaus-wb-board .dekaus-wb-list { flex: 1; }
.dekaus-wb-more { display: inline-block; margin-top: 12px; font-weight: 600; }
.dekaus-wb-list--boxed { border: 1px solid var(--tg-border-1); border-radius: var(--dekaus-radius); background: var(--dekaus-card-bg); padding: 0 20px; }
.dekaus-wb-row { display: flex; gap: 14px; align-items: flex-start; padding: 16px 0; border-bottom: 1px solid var(--tg-border-1); }
.dekaus-wb-row:last-child { border-bottom: 0; }
.dekaus-wb-row__body { min-width: 0; flex: 1; }
.dekaus-wb-row__title { font-size: 17px; margin-bottom: 4px; line-height: 1.45; overflow-wrap: anywhere; }
.dekaus-wb-meta { display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 13px; color: var(--dekaus-muted); }
.dekaus-wb-meta i { margin-right: 4px; }
.dekaus-wb-type { flex: none; display: inline-block; font-size: 12px; font-weight: 600; padding: 2px 10px; border-radius: 20px; white-space: nowrap; }
.dekaus-wb-type--offering { background: var(--tg-theme-primary); color: #fff; }
.dekaus-wb-type--seeking { background: var(--dekaus-soft-bg); color: var(--tg-heading-color); border: 1px solid var(--tg-border-1); }
.dekaus-wb-tabs { display: flex; flex-wrap: wrap; gap: 8px; }
.dekaus-wb-tabs a { padding: 6px 16px; border-radius: 20px; border: 1px solid var(--tg-border-1); font-size: 14px; }
.dekaus-wb-tabs a.active { background: var(--tg-theme-primary); border-color: var(--tg-theme-primary); color: #fff; }
.dekaus-wb-safety { font-size: 14px; padding: 12px 16px; border-radius: var(--dekaus-radius); background: var(--dekaus-soft-bg); }
.dekaus-wb-safety i { color: var(--tg-theme-primary); margin-right: 6px; }
.dekaus-wb-choice { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.dekaus-wb-choice label { display: inline-flex; flex: 0 0 auto; align-items: center; gap: 8px; font-weight: 400; margin: 0; white-space: nowrap; }
.dekaus-label { display: block; font-weight: 600; margin-bottom: 8px; }
@media (max-width: 575px) { .dekaus-wb-row { flex-direction: column; gap: 6px; } }
.dekaus-wb-choice input[type=radio] { flex: none; width: 18px; height: 18px; margin: 0; padding: 0; }

/* Member sign-in and account */
.dekaus-account-link a { font-size: 14px; font-weight: 500; color: var(--tg-heading-color); display: inline-flex; align-items: center; gap: 6px; }
.dekaus-account-link a:hover { color: var(--tg-theme-primary); }
.header__top-right .list-wrap { display: flex; align-items: center; justify-content: flex-end; gap: 20px; }
.dekaus-auth { border: 1px solid var(--tg-border-1); border-radius: var(--dekaus-radius); background: var(--dekaus-card-bg); padding: 32px; }
.dekaus-auth__buttons { display: flex; flex-direction: column; gap: 12px; }
.dekaus-auth__btn {
  display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; min-height: 48px; padding: 10px 16px;
  border-radius: 8px; font-weight: 600; font-size: 16px; border: 1px solid var(--tg-border-1); background: var(--dekaus-card-bg);
  color: var(--tg-heading-color); cursor: pointer; transition: border-color .2s, box-shadow .2s;
}
.dekaus-auth__btn:hover { border-color: var(--tg-heading-color); color: var(--tg-heading-color); }
.dekaus-auth__btn i { font-size: 20px; }
.dekaus-auth__btn--google i { color: #4285f4; }
.dekaus-auth__btn--apple { background: #000; border-color: #000; color: #fff; }
.dekaus-auth__btn--apple:hover { color: #fff; box-shadow: 0 0 0 2px rgba(0,0,0,.2); border-color: #000; }
.dekaus-auth__btn--passkey i { color: var(--tg-theme-primary); }
.dekaus-auth__or { display: flex; align-items: center; gap: 12px; font-size: 13px; color: var(--dekaus-muted); margin: 6px 0; }
.dekaus-auth__or::before, .dekaus-auth__or::after { content: ""; flex: 1; height: 1px; background: var(--tg-border-1); }
.dekaus-auth__terms { font-size: 13px; color: var(--dekaus-muted); margin: 24px 0 0; }
.dekaus-auth__terms a { text-decoration: underline; }
.dekaus-alert--success { background: rgba(46, 125, 50, .08); border: 1px solid #2e7d32; color: #2e7d32; }
.dekaus-panel { border: 1px solid var(--tg-border-1); border-radius: var(--dekaus-radius); background: var(--dekaus-card-bg); padding: 24px; }
.dekaus-panel--danger { border-color: var(--dekaus-error); }
.dekaus-panel__title { font-size: 20px; margin-bottom: 16px; }
.dekaus-panel__subtitle { font-size: 16px; margin: 24px 0 6px; }
.dekaus-my-posts li { padding: 16px 0; border-bottom: 1px solid var(--tg-border-1); }
.dekaus-my-posts li:first-child { padding-top: 0; }
.dekaus-my-posts__head { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center; font-size: 13px; margin-bottom: 4px; }
.dekaus-my-posts__title { font-size: 17px; margin: 0 0 6px; overflow-wrap: anywhere; }
.dekaus-my-posts__actions { display: flex; flex-wrap: wrap; gap: 6px 18px; align-items: center; font-size: 14px; }
.dekaus-my-posts__actions form { display: inline; margin: 0; }
.dekaus-status { display: inline-block; font-size: 12px; font-weight: 600; padding: 2px 10px; border-radius: 20px; background: var(--dekaus-soft-bg); }
.dekaus-status--pending { background: #fff4d6; color: #8a5a00; }
.dekaus-status--published { background: #e3f4e5; color: #1f6b2a; }
.dekaus-status--rejected { background: #fde8e8; color: #a12020; }
.dekaus-link { background: none; border: 0; padding: 0; color: var(--tg-theme-primary); font: inherit; cursor: pointer; text-decoration: underline; }
.dekaus-link--danger { color: var(--dekaus-error); }
.dekaus-connections li { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--tg-border-1); }
.dekaus-connections li > i { font-size: 20px; width: 24px; text-align: center; color: var(--tg-heading-color); }
.dekaus-connections li > div { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.dekaus-connections form { margin: 0; }
.dekaus-passkeys__add { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.dekaus-passkeys__add input { flex: 1 1 10rem; min-width: 0; height: 40px; padding: 0 12px; border: 1px solid var(--tg-border-1); border-radius: 6px; background: transparent; color: inherit; }
.dekaus-btn-outline { background: transparent !important; color: var(--tg-heading-color) !important; border: 1px solid var(--tg-border-1) !important; }
.dekaus-btn-danger { background: var(--dekaus-error) !important; }
.dekaus-field input[readonly] { opacity: .75; }

/* Language switch (EN / TH) */
.dekaus-lang { display: inline-flex; border: 1px solid var(--tg-border-1); border-radius: 20px; overflow: hidden; font-size: 12px; font-weight: 600; line-height: 1; }
.dekaus-lang__item { padding: 6px 10px; color: var(--tg-heading-color); }
.dekaus-lang__item.is-active { background: var(--tg-theme-primary); color: #fff; }
a.dekaus-lang__item:hover { color: var(--tg-theme-primary); }
.dekaus-mobile-extra { display: flex; flex-direction: column; gap: 14px; padding: 20px 25px; border-top: 1px solid var(--tg-border-1); }
.dekaus-mobile-extra a { color: var(--tg-heading-color); font-weight: 500; }
.dekaus-msg-link { position: relative; font-size: 17px !important; }
.dekaus-count { display: inline-flex; align-items: center; justify-content: center; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--tg-theme-primary); color: #fff; font-size: 11px; font-weight: 700; line-height: 1; }
.dekaus-msg-link .dekaus-count { position: absolute; top: -8px; right: -12px; }

/* "Viewing as" bar */
.dekaus-impersonation { position: sticky; top: 0; z-index: 1000; display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; justify-content: center; padding: 8px 16px; background: #b45309; color: #fff; font-size: 14px; }
.dekaus-impersonation form { margin: 0; }
.dekaus-impersonation__btn { background: #fff; color: #7c2d12; border: 0; border-radius: 6px; padding: 4px 12px; font-weight: 600; }

/* Sign-in, register, password tools */
.dekaus-auth__form { margin-top: 4px; }
.dekaus-auth__switch { margin: 20px 0 0; text-align: center; font-size: 15px; }
.dekaus-auth__switch a { font-weight: 600; text-decoration: underline; }
.dekaus-password { position: relative; }
.dekaus-password input { padding-right: 46px !important; }
.dekaus-password__toggle { position: absolute; top: 0; right: 0; height: 100%; width: 44px; border: 0; background: none; color: var(--dekaus-muted); }
.dekaus-password__gen { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; margin-top: 6px; font-size: 14px; }
.dekaus-password__generated code { font-size: 14px; padding: 2px 8px; border-radius: 4px; background: var(--dekaus-soft-bg); color: var(--tg-heading-color); word-break: break-all; }
.dekaus-check { display: flex; align-items: flex-start; gap: 10px; }
.dekaus-check input[type=checkbox] { flex: none; width: 18px; height: 18px; margin-top: 5px; }
.dekaus-check label { font-weight: 400; margin: 0; }
.dekaus-recovery-channels li { display: flex; gap: 10px; align-items: center; padding: 4px 0; }
.dekaus-recovery-channels li.is-off { opacity: .55; }
.dekaus-recovery-channels i { width: 18px; color: var(--tg-theme-primary); }

/* Account */
.dekaus-account-nav { display: flex; flex-wrap: wrap; gap: 8px; }
.dekaus-account-nav a { padding: 6px 14px; border-radius: 20px; border: 1px solid var(--tg-border-1); font-size: 14px; color: var(--tg-heading-color); }
.dekaus-account-nav a:hover { border-color: var(--tg-theme-primary); color: var(--tg-theme-primary); }
.dekaus-account-email { margin: 0; padding: 10px 14px; border: 1px solid var(--tg-border-1); border-radius: 6px; background: var(--dekaus-soft-bg); color: var(--tg-heading-color); overflow-wrap: anywhere; word-break: break-all; line-height: 1.5; }
.dekaus-break { overflow-wrap: anywhere; word-break: break-all; }
.dekaus-label { display: block; font-weight: 500; margin-bottom: 6px; color: var(--tg-heading-color); }
.dekaus-table { width: 100%; font-size: 14px; border-collapse: collapse; }
.dekaus-table th, .dekaus-table td { padding: 8px 10px 8px 0; border-bottom: 1px solid var(--tg-border-1); text-align: left; vertical-align: top; }
.dekaus-table th { font-weight: 600; color: var(--tg-heading-color); white-space: nowrap; }
.dekaus-table code { font-size: 13px; color: var(--dekaus-muted); }
.dekaus-templates li { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 18px; padding: 10px 0; border-bottom: 1px solid var(--tg-border-1); }
.dekaus-templates li > div { flex: 1 1 12rem; min-width: 0; }
.dekaus-templates form { margin: 0; }
.dekaus-line-link { margin-top: 12px; padding: 14px 16px; border-radius: 8px; background: var(--dekaus-soft-bg); font-size: 14px; }
.dekaus-line-link ol { padding-left: 20px; }
.dekaus-line-code { font-size: 16px; font-weight: 700; letter-spacing: .05em; padding: 2px 8px; border-radius: 4px; background: var(--dekaus-card-bg); color: var(--tg-heading-color); }
.dekaus-status--expired { background: var(--dekaus-soft-bg); color: var(--dekaus-muted); }

/* Messages: list on the left, conversation on the right (one at a time on phones) */
.dekaus-inbox { display: grid; grid-template-columns: minmax(0, 340px) minmax(0, 1fr); border: 1px solid var(--tg-border-1); border-radius: var(--dekaus-radius); background: var(--dekaus-card-bg); min-height: 480px; overflow: hidden; }
.dekaus-inbox__list { border-right: 1px solid var(--tg-border-1); max-height: 70vh; overflow-y: auto; }
.dekaus-inbox__item { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-bottom: 1px solid var(--tg-border-1); color: var(--tg-body-color); }
.dekaus-inbox__item:hover, .dekaus-inbox__item.is-active { background: var(--dekaus-soft-bg); color: var(--tg-body-color); }
.dekaus-inbox__item.is-active { box-shadow: inset 3px 0 0 var(--tg-theme-primary); }
.dekaus-inbox__item.is-unread .dekaus-inbox__subject, .dekaus-inbox__item.is-unread strong { font-weight: 700; color: var(--tg-heading-color); }
.dekaus-inbox__item .dekaus-count { background: none; color: var(--tg-theme-primary); min-width: 0; padding: 0; }
.dekaus-inbox__avatar { flex: none; width: 40px; height: 40px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: var(--dekaus-soft-bg); color: var(--tg-heading-color); font-weight: 700; border: 1px solid var(--tg-border-1); }
.dekaus-inbox__avatar.is-team { background: var(--tg-theme-primary); color: #fff; border-color: var(--tg-theme-primary); }
.dekaus-inbox__summary { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; font-size: 14px; line-height: 1.45; }
.dekaus-inbox__top { display: flex; justify-content: space-between; gap: 8px; }
.dekaus-inbox__top strong { font-weight: 600; color: var(--tg-heading-color); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dekaus-inbox__top time { flex: none; font-size: 12px; color: var(--dekaus-muted); }
.dekaus-inbox__subject, .dekaus-inbox__preview { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dekaus-inbox__preview { color: var(--dekaus-muted); font-size: 13px; }
.dekaus-inbox__empty, .dekaus-inbox__placeholder { padding: 48px 24px; text-align: center; color: var(--dekaus-muted); }
.dekaus-inbox__empty i, .dekaus-inbox__placeholder i { font-size: 40px; margin-bottom: 12px; display: block; }
.dekaus-inbox__thread { display: flex; flex-direction: column; min-width: 0; }
.dekaus-inbox__thread-head { display: flex; gap: 12px; align-items: flex-start; padding: 16px 20px; border-bottom: 1px solid var(--tg-border-1); }
.dekaus-inbox__thread-head h2 { font-size: 18px; margin: 0 0 2px; overflow-wrap: anywhere; }
.dekaus-inbox__thread-head p { font-size: 14px; }
.dekaus-inbox__thread-head form { margin: 0; }
.dekaus-inbox__back { font-size: 18px; color: var(--tg-heading-color); padding: 2px 6px 0 0; }
.dekaus-thread { flex: 1; display: flex; flex-direction: column; gap: 12px; padding: 20px; max-height: 55vh; overflow-y: auto; }
.dekaus-thread__msg { max-width: 85%; padding: 10px 14px; border-radius: 12px; background: var(--dekaus-soft-bg); border: 1px solid var(--tg-border-1); }
.dekaus-thread__msg.is-mine { margin-left: auto; background: rgba(233, 30, 99, .08); border-color: rgba(233, 30, 99, .25); }
.dekaus-thread__msg.is-team { border-color: var(--tg-theme-primary); }
.dekaus-thread__meta { display: flex; justify-content: space-between; gap: 12px; font-size: 12px; color: var(--dekaus-muted); margin-bottom: 2px; }
.dekaus-thread__meta strong { color: var(--tg-heading-color); }
.dekaus-thread__body { font-size: 15px; line-height: 1.6; overflow-wrap: anywhere; }
.dekaus-thread__reply { padding: 16px 20px; border-top: 1px solid var(--tg-border-1); display: flex; flex-direction: column; gap: 10px; }
.dekaus-thread__reply textarea, .dekaus-contact-form textarea { width: 100%; padding: 10px 14px; border: 1px solid var(--tg-border-1); border-radius: 6px; background: var(--dekaus-card-bg); color: var(--tg-heading-color); }
.dekaus-inbox .pagination { padding: 12px 16px; }
@media (max-width: 767px) {
  .dekaus-inbox { grid-template-columns: minmax(0, 1fr); }
  .dekaus-inbox__list { border-right: 0; max-height: none; }
  .dekaus-inbox.has-open .dekaus-inbox__list { display: none; }
  .dekaus-inbox:not(.has-open) .dekaus-inbox__thread { display: none; }
  .dekaus-thread { max-height: none; padding: 16px; }
  .dekaus-thread__msg { max-width: 92%; }
}
.dekaus-contact-form label { font-weight: 500; margin-bottom: 6px; display: block; color: var(--tg-heading-color); }

/* Webboard form: templates, mini editor, photo */
.dekaus-template-picker { padding: 16px 20px; margin-bottom: 30px; border: 1px dashed var(--tg-theme-primary); border-radius: var(--dekaus-radius); background: var(--dekaus-soft-bg); }
.dekaus-template-picker label { display: block; font-weight: 600; color: var(--tg-heading-color); margin-bottom: 8px; }
.dekaus-template-picker__row { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 6px; }
.dekaus-template-picker select { flex: 1 1 14rem; min-width: 0; padding: 8px 12px; border: 1px solid var(--tg-border-1); border-radius: 6px; background: var(--dekaus-card-bg); color: var(--tg-heading-color); }
.dekaus-editor { border: 1px solid var(--tg-border-1); border-radius: 6px; background: var(--dekaus-card-bg); }
.dekaus-editor:focus-within { outline: 2px solid var(--tg-theme-primary); outline-offset: 1px; }
.dekaus-editor__toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 2px; padding: 6px; border-bottom: 1px solid var(--tg-border-1); }
.dekaus-editor__toolbar button { width: 36px; height: 34px; border: 0; border-radius: 4px; background: none; color: var(--tg-heading-color); }
.dekaus-editor__toolbar button:hover, .dekaus-editor__toolbar button:focus-visible { background: var(--dekaus-soft-bg); color: var(--tg-theme-primary); }
.dekaus-editor__sep { width: 1px; height: 20px; margin: 0 4px; background: var(--tg-border-1); }
.dekaus-editor__count { margin-left: auto; padding: 0 6px; font-size: 12px; color: var(--dekaus-muted); }
.dekaus-editor__area { min-height: 220px; max-height: 60vh; overflow-y: auto; padding: 12px 14px; color: var(--tg-heading-color); line-height: 1.7; outline: none; overflow-wrap: anywhere; }
.dekaus-editor__area p, .dekaus-editor__area div { margin: 0 0 .6em; }
.dekaus-editor__area ul, .dekaus-editor__area ol, .dekaus-prose ul, .dekaus-prose ol { padding-left: 1.5em; margin: 0 0 .8em; }
.dekaus-editor__area ul, .dekaus-prose ul { list-style: disc; }
.dekaus-editor__area ol, .dekaus-prose ol { list-style: decimal; }
.dekaus-image-preview, .dekaus-image-current { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin: 10px 0; }
.dekaus-image-preview img, .dekaus-image-current img { max-width: 160px; max-height: 120px; border-radius: 6px; object-fit: cover; border: 1px solid var(--tg-border-1); }
.dekaus-wb-image img { max-width: 100%; max-height: 520px; border-radius: var(--dekaus-radius); }
.dekaus-turnstile { margin: 8px 0 20px; }
.dekaus-report-reasons { display: flex; flex-direction: column; gap: 8px; }
.dekaus-report-reasons label { display: flex; align-items: center; gap: 10px; font-weight: 400; margin: 0; }
.dekaus-report-reasons input { width: 18px; height: 18px; margin: 0; flex: none; }
.dekaus-report-post { padding: 10px 14px; border-radius: 6px; background: var(--dekaus-soft-bg); }
