/* ==========================================================================
   RentKrub design system — ใช้ร่วมทุกหน้า โหลดผ่าน include/brand_head
   สีแบรนด์ (--rk-scarlet, --rk-ember, --rk-carbon ...) มาจาก config/brand.php
   กติกาการใช้อยู่ที่ docs/BRAND.md
   ========================================================================== */

:root {
    --rk-canvas: #FBFAF8;
    --rk-stone: #F3F0EB;
    --rk-stone-deep: #EAE5DD;
    --rk-line: #E7E1D8;
    --rk-line-strong: #CFC7BB;
    --rk-ink: #171719;
    --rk-text: #34322F;
    --rk-muted: #6B665F;
    --rk-subtle: #726C64; /* 5.19:1 บนขาว, 4.57:1 บน stone (QC 29/09/2026 เดิม #8C867E = 3.6:1) */
    --rk-success: #1F7A53;
    --rk-amber: #F3C969;

    --rk-radius-xs: 8px;
    --rk-radius-sm: 10px;
    --rk-radius: 14px;
    --rk-radius-lg: 20px;
    --rk-radius-xl: 28px;

    --rk-shadow-xs: 0 1px 2px rgba(23, 23, 25, .05);
    --rk-shadow-sm: 0 1px 2px rgba(23, 23, 25, .04), 0 4px 14px rgba(23, 23, 25, .05);
    --rk-shadow: 0 2px 6px rgba(23, 23, 25, .04), 0 14px 34px rgba(23, 23, 25, .08);
    --rk-shadow-lg: 0 4px 12px rgba(23, 23, 25, .05), 0 26px 60px rgba(23, 23, 25, .12);
    --rk-ring: 0 0 0 4px rgba(23, 23, 25, .08);

    --rk-font: "IBM Plex Sans Thai", "Noto Sans Thai", "Leelawadee UI", Tahoma, system-ui, sans-serif;
    --rk-ease: cubic-bezier(.2, .7, .2, 1);
    --rk-header-h: 76px;

    /* Type scale (QC 29/09/2026): ใช้ token เหล่านี้เท่านั้น ห้ามใส่ค่า rem ตรง ๆ กติกาใน docs/BRAND.md */
    --rk-fs-xs: .75rem;       /* 12px ป้ายเล็ก ตัวนับ */
    --rk-fs-sm: .875rem;      /* 14px ข้อความรอง คำอธิบาย */
    --rk-fs-base: 1rem;       /* 16px เนื้อความ ปุ่ม ช่องกรอก */
    --rk-fs-md: 1.125rem;     /* 18px หัวข้อย่อย lead */
    --rk-fs-lg: 1.25rem;      /* 20px ราคาในการ์ด หัวข้อการ์ด */
    --rk-fs-xl: 1.5rem;       /* 24px หัวข้อส่วน ตัวเลขสถิติ */
    --rk-fs-2xl: 2rem;        /* 32px ราคาในหน้าประกาศ */
    --rk-fs-3xl: 2.5rem;      /* 40px ตัวเลขคะแนนรวม */
    --rk-fs-title: clamp(1.5rem, 2.4vw, 2rem);          /* h1 ของหน้าทั่วไป */
    --rk-fs-title-lg: clamp(1.75rem, 3vw, 2.5rem);      /* h1 หน้าประกาศ / บทความ */
    --rk-fs-display: clamp(2.2rem, 4vw, 3.75rem);       /* hero หน้าแรก */
    --rk-fs-display-sm: clamp(1.75rem, 8.2vw, 2.3rem);  /* hero บนจอ < 576px */

    /* ค่ากลางของ Bootstrap: primary เดิมเป็นน้ำเงิน เปลี่ยนเป็น Carbon ให้เข้ากับแบรนด์ */
    --bs-body-font-family: var(--rk-font);
    --bs-body-font-size: var(--rk-fs-base);
    --bs-body-line-height: 1.65;
    --bs-body-color: var(--rk-text);
    --bs-body-bg: var(--rk-canvas);
    --bs-border-color: var(--rk-line);
    --bs-border-radius: var(--rk-radius-sm);
    --bs-border-radius-sm: var(--rk-radius-xs);
    --bs-border-radius-lg: var(--rk-radius);
    --bs-link-color: var(--rk-scarlet-ui);
    --bs-link-hover-color: var(--rk-scarlet-ui-hover);
    --bs-primary: #171719;
    --bs-primary-rgb: 23, 23, 25;
    --bs-dark-rgb: 23, 23, 25;
    --bs-secondary-rgb: 107, 102, 95;
    --bs-light-rgb: 243, 240, 235;
    --bs-danger-rgb: 209, 31, 25;
    --bs-success-rgb: 31, 122, 83;
    --bs-warning-rgb: 243, 201, 105;
    --bs-info-rgb: 63, 111, 143;
}

/* ---------- พื้นฐาน ---------- */

html {
    scroll-padding-top: calc(var(--rk-header-h) + 16px);
}

body {
    font-family: var(--rk-font);
    background: var(--rk-canvas);
    color: var(--rk-text);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
    color: var(--rk-ink);
    font-weight: 600;
    line-height: 1.3;
}

a {
    text-decoration: none;
    transition: color .18s var(--rk-ease);
}

::selection {
    background: rgba(240, 43, 36, .14);
}

:focus-visible {
    outline: 2px solid var(--rk-ink);
    outline-offset: 2px;
}

hr {
    border-color: var(--rk-line);
    opacity: 1;
}

.text-muted {
    color: var(--rk-muted) !important;
}

.shadow {
    box-shadow: var(--rk-shadow) !important;
}

.shadow-2,
.shadow-sm {
    box-shadow: var(--rk-shadow-sm) !important;
}

.wrapper {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.rk-main {
    flex: 1;
}

.rk-num {
    font-variant-numeric: tabular-nums;
}

/* Bootstrap 5.2 ยังไม่มี fw-medium */
.fw-medium {
    font-weight: 500 !important;
}

/* ---------- คลาสแบรนด์ (ชื่อเดิมของโปรเจกต์) ---------- */

/* ตัวอักษรเน้นบนพื้นเข้ม ห้ามใช้บนพื้นขาวเพราะ ember อ่านยาก */
.text-primarycus {
    color: var(--rk-ember);
}

/* ตัวอักษรและลิงก์เน้นบนพื้นขาว */
.text-secondarycus {
    color: var(--rk-scarlet-ui);
}

.bg-primarycus {
    background-color: var(--rk-scarlet-ui);
}

.bg-carbon {
    background-color: var(--rk-carbon) !important;
}

.bg-stone {
    background-color: var(--rk-stone) !important;
}

/* ---------- ปุ่ม ---------- */

.btn {
    --bs-btn-font-weight: 500;
    --bs-btn-padding-x: 1.125rem;
    --bs-btn-padding-y: .625rem;
    --bs-btn-font-size: var(--rk-fs-base);
    --bs-btn-border-radius: 12px;
    --bs-btn-focus-box-shadow: var(--rk-ring);
    /* ปุ่มสูงเท่ากันทุกหน้า (QC 29/09/2026): ปกติ 48, ใหญ่ 52, เล็ก 40 */
    min-height: 48px;
    transition: color .18s var(--rk-ease), background-color .18s var(--rk-ease), border-color .18s var(--rk-ease), box-shadow .18s var(--rk-ease), transform .18s var(--rk-ease);
}

.btn-lg {
    --bs-btn-padding-x: 1.5rem;
    --bs-btn-padding-y: .7rem;
    --bs-btn-font-size: var(--rk-fs-md);
    --bs-btn-border-radius: 14px;
    min-height: 52px;
}

.btn-sm {
    --bs-btn-padding-x: .75rem;
    --bs-btn-padding-y: .375rem;
    --bs-btn-font-size: var(--rk-fs-sm);
    --bs-btn-border-radius: 10px;
    min-height: 40px;
}

.btn-primarycus {
    --bs-btn-color: var(--rk-white);
    --bs-btn-bg: var(--rk-scarlet-ui);
    --bs-btn-border-color: var(--rk-scarlet-ui);
    --bs-btn-hover-color: var(--rk-white);
    --bs-btn-hover-bg: var(--rk-scarlet-ui-hover);
    --bs-btn-hover-border-color: var(--rk-scarlet-ui-hover);
    --bs-btn-active-color: var(--rk-white);
    --bs-btn-active-bg: var(--rk-scarlet-ui-hover);
    --bs-btn-active-border-color: var(--rk-scarlet-ui-hover);
    --bs-btn-disabled-color: var(--rk-white);
    --bs-btn-disabled-bg: var(--rk-scarlet-ui);
    --bs-btn-disabled-border-color: var(--rk-scarlet-ui);
    --bs-btn-focus-box-shadow: 0 0 0 4px rgba(209, 31, 25, .2);
}

.btn-primarycus:hover {
    box-shadow: 0 10px 24px rgba(209, 31, 25, .22);
}

.btn-primary,
.btn-dark {
    --bs-btn-color: #fff;
    --bs-btn-bg: var(--rk-ink);
    --bs-btn-border-color: var(--rk-ink);
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: #000;
    --bs-btn-hover-border-color: #000;
    --bs-btn-active-color: #fff;
    --bs-btn-active-bg: #000;
    --bs-btn-active-border-color: #000;
    --bs-btn-disabled-color: #fff;
    --bs-btn-disabled-bg: var(--rk-ink);
    --bs-btn-disabled-border-color: var(--rk-ink);
}

.btn-light,
.btn-outline-dark,
.btn-outline-secondary,
.btn-outline-primary {
    --bs-btn-color: var(--rk-ink);
    --bs-btn-bg: #fff;
    --bs-btn-border-color: var(--rk-line-strong);
    --bs-btn-hover-color: var(--rk-ink);
    --bs-btn-hover-bg: var(--rk-stone);
    --bs-btn-hover-border-color: var(--rk-ink);
    --bs-btn-active-color: var(--rk-ink);
    --bs-btn-active-bg: var(--rk-stone-deep);
    --bs-btn-active-border-color: var(--rk-ink);
    --bs-btn-disabled-color: var(--rk-subtle);
    --bs-btn-disabled-bg: #fff;
    --bs-btn-disabled-border-color: var(--rk-line);
}

.btn-secondary {
    --bs-btn-color: var(--rk-ink);
    --bs-btn-bg: var(--rk-stone-deep);
    --bs-btn-border-color: var(--rk-stone-deep);
    --bs-btn-hover-color: var(--rk-ink);
    --bs-btn-hover-bg: #DDD6CC;
    --bs-btn-hover-border-color: #DDD6CC;
    --bs-btn-active-color: var(--rk-ink);
    --bs-btn-active-bg: #D3CBBF;
    --bs-btn-active-border-color: #D3CBBF;
}

.btn-danger {
    --bs-btn-color: #fff;
    --bs-btn-bg: var(--rk-scarlet-ui);
    --bs-btn-border-color: var(--rk-scarlet-ui);
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: var(--rk-scarlet-ui-hover);
    --bs-btn-hover-border-color: var(--rk-scarlet-ui-hover);
    --bs-btn-active-color: #fff;
    --bs-btn-active-bg: var(--rk-scarlet-ui-hover);
    --bs-btn-active-border-color: var(--rk-scarlet-ui-hover);
}

.btn-outline-danger {
    --bs-btn-color: var(--rk-scarlet-ui);
    --bs-btn-border-color: rgba(209, 31, 25, .45);
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: var(--rk-scarlet-ui);
    --bs-btn-hover-border-color: var(--rk-scarlet-ui);
    --bs-btn-active-color: #fff;
    --bs-btn-active-bg: var(--rk-scarlet-ui-hover);
    --bs-btn-active-border-color: var(--rk-scarlet-ui-hover);
}

.btn-warning {
    --bs-btn-color: var(--rk-ink);
    --bs-btn-bg: var(--rk-amber);
    --bs-btn-border-color: var(--rk-amber);
    --bs-btn-hover-color: var(--rk-ink);
    --bs-btn-hover-bg: #ECB947;
    --bs-btn-hover-border-color: #ECB947;
    --bs-btn-active-color: var(--rk-ink);
    --bs-btn-active-bg: #E3AC33;
    --bs-btn-active-border-color: #E3AC33;
}

.btn-success {
    --bs-btn-color: #fff;
    --bs-btn-bg: var(--rk-success);
    --bs-btn-border-color: var(--rk-success);
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: #186444;
    --bs-btn-hover-border-color: #186444;
    --bs-btn-active-bg: #145538;
    --bs-btn-active-border-color: #145538;
}

.btn-info {
    --bs-btn-color: #fff;
    --bs-btn-bg: #3F6F8F;
    --bs-btn-border-color: #3F6F8F;
    --bs-btn-hover-color: #fff;
    --bs-btn-hover-bg: #335C77;
    --bs-btn-hover-border-color: #335C77;
    --bs-btn-active-bg: #2B4E65;
    --bs-btn-active-border-color: #2B4E65;
}

.btn-link {
    --bs-btn-color: var(--rk-ink);
    --bs-btn-hover-color: var(--rk-scarlet-ui);
    --bs-btn-active-color: var(--rk-scarlet-ui);
    text-decoration: none;
}

.rk-btn-pill {
    --bs-btn-border-radius: 999px;
}

.rk-btn-icon {
    --bs-btn-padding-x: 0;
    --bs-btn-padding-y: 0;
    width: 44px;
    height: 44px;
    min-height: 44px;
    display: inline-grid;
    place-items: center;
}

.link-primary {
    color: var(--rk-ink) !important;
}

/* ---------- ฟอร์ม ---------- */

.form-control,
.form-select {
    min-height: 48px;
    padding: .7rem 1rem;
    font-size: var(--rk-fs-base);
    color: var(--rk-ink);
    background-color: #fff;
    border: 1px solid var(--rk-line-strong);
    border-radius: 12px;
    transition: border-color .18s var(--rk-ease), box-shadow .18s var(--rk-ease);
}

.form-select {
    padding-right: 2.75rem;
    background-position: right 1rem center;
}

.form-control-sm,
.form-select-sm {
    min-height: 38px;
    padding: .4rem .75rem;
    font-size: var(--rk-fs-sm);
    border-radius: 10px;
}

textarea.form-control {
    min-height: 120px;
}

.form-control::placeholder {
    color: var(--rk-subtle);
}

.form-control:hover,
.form-select:hover {
    border-color: #B8AFA2;
}

.form-control:focus,
.form-select:focus {
    color: var(--rk-ink);
    border-color: var(--rk-ink);
    box-shadow: var(--rk-ring);
}

.form-control:disabled,
.form-select:disabled,
.form-control[readonly] {
    background-color: var(--rk-stone);
}

.form-control.is-invalid,
.form-select.is-invalid,
.was-validated .form-control:invalid {
    border-color: var(--rk-scarlet-ui);
}

.form-control.is-invalid:focus,
.form-select.is-invalid:focus {
    box-shadow: 0 0 0 4px rgba(209, 31, 25, .12);
}

.invalid-feedback {
    color: var(--rk-scarlet-ui);
}

.form-label,
.col-form-label {
    font-weight: 500;
    color: var(--rk-ink);
    font-size: var(--rk-fs-base);
    margin-bottom: .45rem;
}

.form-text {
    color: var(--rk-muted);
}

.form-check-input {
    width: 1.2em;
    height: 1.2em;
    margin-top: .2em;
    border: 1.5px solid var(--rk-line-strong);
}

.form-check-input[type=checkbox] {
    border-radius: 6px;
}

.form-check-input:checked {
    background-color: var(--rk-ink);
    border-color: var(--rk-ink);
}

.form-check-input:focus {
    border-color: var(--rk-ink);
    box-shadow: var(--rk-ring);
}

.form-switch .form-check-input {
    width: 2.4em;
    border-radius: 2em;
}

.input-group-text {
    color: var(--rk-muted);
    background: var(--rk-stone);
    border-color: var(--rk-line-strong);
    border-radius: 12px;
}

/* select2 ให้หน้าตาเหมือนช่องกรอกอื่น */
.select2-container {
    width: 100% !important;
}

.select2-container .select2-selection--single {
    display: flex;
    align-items: center;
    height: 48px;
    border: 1px solid var(--rk-line-strong);
    border-radius: 12px;
    background: #fff;
    transition: border-color .18s var(--rk-ease), box-shadow .18s var(--rk-ease);
}

.select2-container--default .select2-selection--single .select2-selection__rendered {
    width: 100%;
    padding-left: 1rem;
    padding-right: 2.5rem;
    line-height: 46px;
    color: var(--rk-ink);
}

.select2-container--default .select2-selection--single .select2-selection__placeholder {
    color: var(--rk-subtle);
}

.select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 46px;
    right: 12px;
}

.select2-container--default.select2-container--focus .select2-selection--single,
.select2-container--default.select2-container--open .select2-selection--single {
    border-color: var(--rk-ink);
    box-shadow: var(--rk-ring);
}

/* select2 แบบเลือกได้หลายค่า (เช่น หมวดหมู่ข่าว) สูงเท่าช่องอื่น */
.select2-container .select2-selection--multiple {
    min-height: 48px;
    padding: 5px 10px;
    border: 1px solid var(--rk-line-strong);
    border-radius: 12px;
    background: #fff;
}

.select2-container--default.select2-container--focus .select2-selection--multiple {
    border-color: var(--rk-ink);
    box-shadow: var(--rk-ring);
}

.select2-container--default .select2-selection--multiple .select2-selection__choice {
    margin-top: 4px;
    padding: 2px 10px 2px 26px;
    color: var(--rk-ink);
    background: var(--rk-stone);
    border: 0;
    border-radius: 999px;
}

.select2-container--default .select2-selection--multiple .select2-selection__choice__remove {
    top: 50%;
    left: 6px;
    height: auto;
    padding: 0 4px;
    color: var(--rk-muted);
    border: 0;
    transform: translateY(-50%);
}

.select2-container--default .select2-selection--multiple .select2-selection__choice__remove:hover {
    color: var(--rk-scarlet-ui);
    background: transparent;
}

.select2-container .select2-search--inline .select2-search__field {
    height: 30px;
    margin-top: 4px;
    font-family: inherit;
}

.select2-dropdown {
    border: 1px solid var(--rk-line);
    border-radius: 14px !important;
    box-shadow: var(--rk-shadow-lg);
    overflow: hidden;
}

.select2-container--open .select2-dropdown--below {
    margin-top: 6px;
}

.select2-container--open .select2-dropdown--above {
    margin-top: -6px;
}

.select2-search--dropdown {
    padding: 10px;
}

.select2-container--default .select2-search--dropdown .select2-search__field {
    padding: 8px 12px;
    border: 1px solid var(--rk-line-strong);
    border-radius: 10px;
    outline: none;
}

.select2-results__option {
    padding: 9px 14px;
}

.select2-container--default .select2-results__option--highlighted.select2-results__option--selectable {
    background: var(--rk-stone);
    color: var(--rk-ink);
}

.select2-container--default .select2-results__option--selected {
    background: #fff;
    font-weight: 600;
}

.select2-container--default .select2-results__group {
    padding: 10px 14px 4px;
    font-size: var(--rk-fs-sm);
    font-weight: 600;
    color: var(--rk-muted);
}

/* ---------- การ์ด ---------- */

.card {
    --bs-card-border-color: var(--rk-line);
    --bs-card-border-radius: 16px;
    --bs-card-inner-border-radius: 15px;
    --bs-card-cap-bg: #fff;
    --bs-card-cap-padding-y: 1rem;
    --bs-card-cap-padding-x: 1.35rem;
    --bs-card-spacer-y: 1.25rem;
    --bs-card-spacer-x: 1.35rem;
    box-shadow: var(--rk-shadow-xs);
}

.card-header {
    font-weight: 600;
    color: var(--rk-ink);
}

.card-title {
    color: var(--rk-ink);
}

.img-thumbnail {
    border-color: var(--rk-line);
    border-radius: 12px;
}

/* ---------- แท็บ: เส้นใต้แบบเรียบ ---------- */

.nav-tabs {
    --bs-nav-tabs-border-width: 0;
    --bs-nav-link-padding-x: 0;
    --bs-nav-link-padding-y: .85rem;
    gap: 28px;
    border-bottom: 1px solid var(--rk-line);
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
}

.nav-tabs::-webkit-scrollbar {
    display: none;
}

.nav-tabs .nav-link {
    position: relative;
    margin: 0;
    color: var(--rk-muted);
    font-weight: 500;
    white-space: nowrap;
    background: none !important;
    border: 0 !important;
}

.nav-tabs .nav-link:hover {
    color: var(--rk-ink);
}

.nav-tabs .nav-link.active,
.nav-tabs .nav-item.show .nav-link {
    color: var(--rk-ink) !important;
}

.nav-tabs .nav-link.active::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 2px;
    border-radius: 2px;
    background: var(--rk-scarlet);
}

/* แท็บแบบปุ่มแคปซูล ใช้คู่กับ .nav */
.rk-segmented {
    display: inline-flex;
    gap: 4px;
    padding: 4px;
    background: var(--rk-stone);
    border: 0;
    border-radius: 999px;
}

.rk-segmented .nav-link,
.rk-segmented > button {
    padding: .55rem 1.1rem;
    border: 0;
    border-radius: 999px;
    color: var(--rk-muted);
    font-weight: 500;
    background: transparent;
}

.rk-segmented .nav-link:hover,
.rk-segmented > button:hover {
    color: var(--rk-ink);
}

.rk-segmented .nav-link.active,
.rk-segmented > button.active {
    color: var(--rk-ink) !important;
    background: #fff !important;
    box-shadow: var(--rk-shadow-xs);
}

.rk-segmented .nav-link.active::after {
    display: none;
}

/* ตัวเลือกแบบแคปซูลที่ใช้ radio จริง (ลูกศรซ้าย/ขวาเลื่อนตัวเลือกได้เอง) ต่างจาก .rk-choice ที่เป็นการ์ด
   markup: <div class="rk-pillset" role="radiogroup"><label><input type="radio"><span>ข้อความ</span></label>…</div> */
.rk-pillset {
    display: grid;
    grid-auto-columns: minmax(0, 1fr);
    grid-auto-flow: column;
    gap: 4px;
    padding: 4px;
    background: var(--rk-stone);
    border-radius: 999px;
}

.rk-pillset label {
    position: relative;
    margin: 0;
}

.rk-pillset input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.rk-pillset span {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 40px;
    color: var(--rk-muted);
    border-radius: 999px;
    font-size: var(--rk-fs-sm);
    font-weight: 500;
    cursor: pointer;
    transition: background-color .2s var(--rk-ease), color .2s var(--rk-ease), box-shadow .2s var(--rk-ease);
}

.rk-pillset span:hover {
    color: var(--rk-ink);
}

.rk-pillset input:checked + span {
    color: var(--rk-ink);
    background: #fff;
    box-shadow: var(--rk-shadow-xs);
    font-weight: 600;
}

.rk-pillset input:focus-visible + span {
    box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--rk-ink);
}

.nav-pills {
    --bs-nav-pills-border-radius: 999px;
    --bs-nav-pills-link-active-bg: var(--rk-ink);
}

.nav-pills .nav-link {
    color: var(--rk-muted);
}

/* ---------- badge / alert ---------- */

.badge {
    --bs-badge-font-weight: 600;
    --bs-badge-padding-x: .7em;
    --bs-badge-padding-y: .38em;
    --bs-badge-border-radius: 999px;
    letter-spacing: .01em;
}

.text-bg-primary,
.text-bg-dark {
    color: #fff !important;
    background-color: var(--rk-ink) !important;
}

.text-bg-danger {
    color: #fff !important;
    background-color: var(--rk-scarlet-ui) !important;
}

.text-bg-warning {
    color: #6B4C0B !important;
    background-color: #FBE9BD !important;
}

.text-bg-success {
    color: #fff !important;
    background-color: var(--rk-success) !important;
}

.text-bg-secondary {
    color: var(--rk-ink) !important;
    background-color: var(--rk-stone-deep) !important;
}

.text-bg-info {
    color: #fff !important;
    background-color: #3F6F8F !important;
}

.alert {
    --bs-alert-border-radius: 14px;
    --bs-alert-padding-x: 1.1rem;
    --bs-alert-padding-y: .95rem;
}

.alert-warning {
    --bs-alert-color: #6B4C0B;
    --bs-alert-bg: #FFF7E6;
    --bs-alert-border-color: #F3DEAE;
}

.alert-danger {
    --bs-alert-color: #8F1A15;
    --bs-alert-bg: #FDF1F0;
    --bs-alert-border-color: #F4C9C6;
}

.alert-success {
    --bs-alert-color: #145538;
    --bs-alert-bg: #EEF7F2;
    --bs-alert-border-color: #C8E4D5;
}

.alert-info,
.alert-primary {
    --bs-alert-color: var(--rk-ink);
    --bs-alert-bg: var(--rk-stone);
    --bs-alert-border-color: var(--rk-line);
}

/* ---------- modal / dropdown / pagination / table ---------- */

.modal {
    --bs-modal-border-radius: 22px;
    --bs-modal-inner-border-radius: 21px;
    --bs-modal-border-width: 0;
    --bs-modal-header-padding: 1.4rem 1.6rem .4rem;
    --bs-modal-header-border-width: 0;
    --bs-modal-footer-border-width: 0;
    --bs-modal-padding: 1.6rem;
    --bs-modal-box-shadow: var(--rk-shadow-lg);
}

.modal-content {
    box-shadow: var(--rk-shadow-lg);
}

.modal-title {
    font-size: var(--rk-fs-lg);
    font-weight: 600;
    color: var(--rk-ink);
}

.modal-backdrop {
    --bs-backdrop-bg: #171719;
    --bs-backdrop-opacity: .45;
}

.dropdown-menu {
    --bs-dropdown-border-color: var(--rk-line);
    --bs-dropdown-border-radius: 14px;
    --bs-dropdown-padding-x: .375rem;
    --bs-dropdown-padding-y: .375rem;
    --bs-dropdown-item-padding-x: .85rem;
    --bs-dropdown-item-padding-y: .55rem;
    --bs-dropdown-item-border-radius: 10px;
    --bs-dropdown-link-color: var(--rk-text);
    --bs-dropdown-link-hover-color: var(--rk-ink);
    --bs-dropdown-link-hover-bg: var(--rk-stone);
    --bs-dropdown-link-active-color: var(--rk-ink);
    --bs-dropdown-link-active-bg: var(--rk-stone-deep);
    --bs-dropdown-divider-bg: var(--rk-line);
    --bs-dropdown-box-shadow: var(--rk-shadow-lg);
    box-shadow: var(--rk-shadow-lg);
}

.dropdown-item {
    border-radius: 10px;
}

.pagination {
    --bs-pagination-color: var(--rk-ink);
    --bs-pagination-border-color: transparent;
    --bs-pagination-border-radius: 10px;
    --bs-pagination-hover-color: var(--rk-ink);
    --bs-pagination-hover-bg: var(--rk-stone);
    --bs-pagination-hover-border-color: transparent;
    --bs-pagination-focus-box-shadow: var(--rk-ring);
    --bs-pagination-active-bg: var(--rk-ink);
    --bs-pagination-active-border-color: var(--rk-ink);
    --bs-pagination-disabled-color: var(--rk-subtle);
    --bs-pagination-disabled-bg: transparent;
    --bs-pagination-disabled-border-color: transparent;
    gap: 4px;
}

.page-link {
    min-width: 40px;
    text-align: center;
    border-radius: 10px !important;
}

.table {
    --bs-table-color: var(--rk-text);
    --bs-table-border-color: var(--rk-line);
    --bs-table-striped-bg: rgba(243, 240, 235, .55);
    --bs-table-hover-bg: var(--rk-stone);
    vertical-align: middle;
}

.table > thead > tr > th,
.table th {
    font-size: var(--rk-fs-sm);
    font-weight: 600;
    color: var(--rk-muted);
    border-bottom-color: var(--rk-line-strong);
}

.progress {
    --bs-progress-bg: var(--rk-stone-deep);
    --bs-progress-bar-bg: var(--rk-ember);
    --bs-progress-border-radius: 999px;
}

.list-group {
    --bs-list-group-border-color: var(--rk-line);
    --bs-list-group-active-bg: var(--rk-ink);
    --bs-list-group-active-border-color: var(--rk-ink);
}

.btn-close:focus {
    box-shadow: var(--rk-ring);
}

/* SweetAlert2 ให้เข้าชุด */
.swal2-popup {
    border-radius: 22px !important;
    font-family: var(--rk-font) !important;
}

.swal2-title {
    color: var(--rk-ink) !important;
    font-weight: 600 !important;
}

.swal2-styled.swal2-confirm {
    background: var(--rk-ink) !important;
    border-radius: 12px !important;
}

.swal2-styled.swal2-cancel {
    border-radius: 12px !important;
}

/* ---------- Header ---------- */

.rk-header {
    position: sticky;
    top: 0;
    z-index: 1030;
    background: rgba(251, 250, 248, .9);
    -webkit-backdrop-filter: saturate(180%) blur(14px);
    backdrop-filter: saturate(180%) blur(14px);
    border-bottom: 1px solid var(--rk-line);
}

.rk-header__inner {
    display: flex;
    align-items: center;
    gap: 20px;
    height: var(--rk-header-h);
}

.rk-header__brand {
    flex: none;
}

.rk-header__brand img {
    display: block;
    width: 164px;
    height: auto;
}

.rk-nav {
    display: flex;
    align-items: center;
    gap: 2px;
}

.rk-nav__link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 44px;
    padding: 8px 14px;
    border: 0;
    border-radius: 999px;
    color: var(--rk-ink);
    background: transparent;
    font-size: var(--rk-fs-base);
    font-weight: 500;
    line-height: 1.4;
    transition: background-color .18s var(--rk-ease), color .18s var(--rk-ease);
}

.rk-nav__link:hover,
.rk-nav__link.is-active,
.show > .rk-nav__link {
    color: var(--rk-ink);
    background: var(--rk-stone);
}

.rk-nav__link.dropdown-toggle::after {
    border: 0;
    content: "\f107";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    font-size: var(--rk-fs-xs);
    margin-left: 2px;
    vertical-align: 0;
}

.rk-header__actions {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: auto;
}

.rk-avatar {
    display: inline-grid;
    place-items: center;
    width: 34px;
    height: 34px;
    flex: none;
    border-radius: 50%;
    color: #fff;
    background: var(--rk-ink);
    font-size: var(--rk-fs-sm);
    font-weight: 600;
}

.rk-burger {
    display: inline-grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border: 1px solid var(--rk-line);
    border-radius: 12px;
    color: var(--rk-ink);
    background: #fff;
}

.rk-offcanvas {
    --bs-offcanvas-width: min(88vw, 380px);
    background: var(--rk-canvas);
}

.rk-offcanvas .offcanvas-header {
    border-bottom: 1px solid var(--rk-line);
}

.rk-mnav__label {
    margin: 22px 0 6px;
    font-size: var(--rk-fs-sm);
    font-weight: 600;
    color: var(--rk-subtle);
}

.rk-mnav a,
.rk-mnav button {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    padding: 13px 2px;
    border: 0;
    border-bottom: 1px solid var(--rk-line);
    color: var(--rk-ink);
    background: none;
    font-weight: 500;
    text-align: left;
}

.rk-mnav i {
    width: 20px;
    color: var(--rk-muted);
    text-align: center;
}

@media (max-width: 991.98px) {
    :root {
        --rk-header-h: 64px;
    }

    .rk-header__brand img {
        width: 160px;
    }
}

/* ---------- เนื้อหา ---------- */

.rk-page {
    padding-top: clamp(24px, 4vw, 44px);
    padding-bottom: clamp(48px, 6vw, 80px);
}

.rk-surface {
    padding: clamp(20px, 3vw, 40px);
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: var(--rk-radius-lg);
    box-shadow: var(--rk-shadow-xs);
}

.rk-section {
    padding-top: clamp(48px, 7vw, 88px);
    padding-bottom: clamp(48px, 7vw, 88px);
}

.rk-section--tight {
    padding-top: clamp(32px, 4vw, 48px);
    padding-bottom: clamp(32px, 4vw, 48px);
}

.rk-section--white {
    background: #fff;
    border-top: 1px solid var(--rk-line);
    border-bottom: 1px solid var(--rk-line);
}

.rk-section--stone {
    background: var(--rk-stone);
}

.rk-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: var(--rk-fs-sm);
    font-weight: 600;
    letter-spacing: .02em;
    color: var(--rk-scarlet-ui);
}

.rk-eyebrow::before {
    content: "";
    width: 20px;
    height: 2px;
    border-radius: 2px;
    background: currentColor;
}

.rk-section-head {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px 24px;
    margin-bottom: clamp(20px, 3vw, 32px);
}

.rk-section-title {
    margin: 8px 0 0;
    font-size: var(--rk-fs-title);
    font-weight: 600;
}

.rk-section-lead {
    max-width: 640px;
    margin: 10px 0 0;
    color: var(--rk-muted);
}

.rk-link-arrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--rk-ink);
    font-weight: 500;
}

.rk-link-arrow:hover {
    color: var(--rk-scarlet-ui);
}

.rk-link-arrow i {
    font-size: .8em;
    transition: transform .2s var(--rk-ease);
}

.rk-link-arrow:hover i {
    transform: translateX(3px);
}

.rk-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    color: var(--rk-text);
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: 999px;
    font-size: var(--rk-fs-sm);
    transition: border-color .18s var(--rk-ease), color .18s var(--rk-ease);
}

.rk-chip:hover {
    color: var(--rk-ink);
    border-color: var(--rk-ink);
}

.rk-count {
    display: inline-block;
    min-width: 26px;
    padding: 1px 8px;
    border-radius: 999px;
    color: var(--rk-muted);
    background: var(--rk-stone);
    font-size: var(--rk-fs-sm);
    font-weight: 500;
    text-align: center;
    font-variant-numeric: tabular-nums;
}

.rk-empty {
    padding: 56px 16px;
    color: var(--rk-muted);
    text-align: center;
}

.rk-empty i {
    display: block;
    margin-bottom: 14px;
    font-size: var(--rk-fs-2xl);
    color: var(--rk-line-strong);
}

.rk-empty h3,
.rk-empty .rk-empty__title {
    margin-bottom: 6px;
    font-size: var(--rk-fs-md);
    color: var(--rk-ink);
}

/* ---------- Hero หน้าแรก (พื้น Carbon + แสง scarlet/ember) ---------- */

.rk-hero {
    position: relative;
    isolation: isolate;
    margin: 12px 12px 0;
    padding: clamp(44px, 5vw, 76px) 0 clamp(36px, 4.5vw, 56px);
    overflow: hidden;
    color: #fff;
    background: var(--rk-carbon);
    border-radius: 32px;
}

.rk-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    border-radius: inherit;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08), inset 0 0 0 1px rgba(255, 255, 255, .04);
    pointer-events: none;
}

.rk-hero__bg {
    position: absolute;
    inset: 0;
    z-index: -2;
    overflow: hidden;
    pointer-events: none;
}

.rk-hero__glow {
    position: absolute;
    aspect-ratio: 1;
    border-radius: 50%;
    animation: rk-drift 20s ease-in-out infinite alternate;
}

.rk-hero__glow--1 {
    top: -34%;
    right: -14%;
    width: min(72vw, 940px);
    background: radial-gradient(closest-side, rgba(240, 43, 36, .52), rgba(240, 43, 36, .16) 48%, rgba(240, 43, 36, 0));
}

.rk-hero__glow--2 {
    bottom: -52%;
    left: 10%;
    width: min(62vw, 780px);
    background: radial-gradient(closest-side, rgba(255, 100, 45, .38), rgba(255, 100, 45, 0));
    animation-duration: 26s;
    animation-direction: alternate-reverse;
}

.rk-hero__glow--3 {
    top: -24%;
    left: -16%;
    width: min(48vw, 600px);
    background: radial-gradient(closest-side, rgba(243, 201, 105, .14), rgba(243, 201, 105, 0));
    animation-duration: 32s;
}

.rk-hero__lines {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255, 255, 255, .05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, .05) 1px, transparent 1px);
    background-size: 64px 64px;
    -webkit-mask-image: radial-gradient(ellipse 70% 62% at 72% 18%, #000 10%, transparent 72%);
    mask-image: radial-gradient(ellipse 70% 62% at 72% 18%, #000 10%, transparent 72%);
}

.rk-hero__grain {
    position: absolute;
    inset: 0;
    opacity: .1;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
    mix-blend-mode: overlay;
}

.rk-hero > .container {
    position: relative;
}

.rk-hero__layout {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr);
    align-items: center;
    gap: 48px;
}

.rk-hero__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 7px 16px 7px 12px;
    color: rgba(255, 255, 255, .84);
    background: rgba(255, 255, 255, .06);
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 999px;
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    font-size: var(--rk-fs-sm);
    font-weight: 500;
}

.rk-hero__eyebrow i {
    width: 8px;
    height: 8px;
    background: var(--rk-ember);
    border-radius: 50%;
    box-shadow: 0 0 0 4px rgba(255, 100, 45, .18), 0 0 14px rgba(255, 100, 45, .8);
    animation: rk-live 2.2s ease-in-out infinite;
}

.rk-hero__title {
    margin: 24px 0 20px;
    color: #fff;
    font-size: var(--rk-fs-display);
    font-weight: 600;
    line-height: 1.16;
    letter-spacing: -.02em;
}

.rk-hero__line {
    display: block;
    color: rgba(255, 255, 255, .94);
}

/* คำที่หมุนเปลี่ยน: กล่องสูงเท่าหนึ่งบรรทัด คำซ้อนกันแบบ absolute แล้ว JS ปรับความกว้างตามคำปัจจุบัน */
.rk-rotator {
    position: relative;
    display: inline-block;
    height: 1.16em;
    vertical-align: bottom;
    white-space: nowrap;
    transition: width .65s var(--rk-ease);
}

.rk-rotator__word {
    display: inline-block;
    /* เผื่อพื้นที่ให้สระ/วรรณยุกต์บน-ล่าง ไม่ให้ background-clip ตัดหาย */
    margin: -.2em -.06em;
    padding: .2em .06em;
    color: transparent;
    background: linear-gradient(100deg, #FFC4A3 0%, #FF7A45 30%, #FF642D 50%, #F02B24 86%);
    -webkit-background-clip: text;
    background-clip: text;
    white-space: nowrap;
}

.rk-rotator:not(.is-ready) .rk-rotator__word:not(.is-active) {
    display: none;
}

.rk-rotator.is-ready .rk-rotator__word {
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0;
    filter: blur(12px);
    transform: translateY(.5em);
    transition: opacity .55s var(--rk-ease), transform .75s var(--rk-ease), filter .55s var(--rk-ease);
}

.rk-rotator.is-ready .rk-rotator__word.is-active {
    opacity: 1;
    filter: blur(0);
    transform: none;
    transition-delay: .1s;
}

.rk-rotator.is-ready .rk-rotator__word.is-leaving {
    opacity: 0;
    filter: blur(12px);
    transform: translateY(-.5em);
    transition-delay: 0s;
}

.rk-hero__lead {
    max-width: 560px;
    margin: 0;
    color: rgba(255, 255, 255, .68);
    font-size: var(--rk-fs-md);
    line-height: 1.75;
}

.rk-hero__maplink {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    margin-top: 22px;
    padding: 8px 16px 8px 8px;
    color: #fff;
    background: rgba(255, 255, 255, .06);
    border: 1px solid rgba(255, 255, 255, .14);
    border-radius: 999px;
    font-size: var(--rk-fs-sm);
}

.rk-hero__maplink b {
    margin-right: 4px;
    color: var(--rk-ember);
}

.rk-hero__maplink:hover {
    color: #fff;
    border-color: rgba(255, 255, 255, .3);
}

/* ที่พักยอดนิยม + ป้ายลอยด้านขวา */
.rk-hero__showcase {
    position: relative;
    width: 100%;
    max-width: 540px;
    height: 450px;
    margin-left: auto;
}

.rk-showcase__main {
    position: absolute;
    top: 0;
    right: 0;
    width: 86%;
    height: 392px;
    overflow: hidden;
    color: #fff;
    background: #222;
    border-radius: 28px;
    box-shadow: 0 34px 80px rgba(0, 0, 0, .5), 0 0 0 1px rgba(255, 255, 255, .08);
}

.rk-showcase__main img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 1.2s var(--rk-ease);
}

.rk-showcase__main::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(23, 23, 25, .15) 0%, rgba(23, 23, 25, 0) 30%, rgba(23, 23, 25, 0) 50%, rgba(23, 23, 25, .88) 100%);
}

.rk-showcase__main:hover {
    color: #fff;
}

.rk-showcase__main:hover img {
    transform: scale(1.05);
}

.rk-showcase__badge,
.rk-showcase__price,
.rk-showcase__info {
    position: absolute;
    z-index: 1;
}

.rk-showcase__badge {
    top: 18px;
    right: 18px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: rgba(23, 23, 25, .5);
    border: 1px solid rgba(255, 255, 255, .16);
    border-radius: 999px;
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    font-size: var(--rk-fs-sm);
    font-weight: 600;
}

.rk-showcase__badge i {
    color: var(--rk-ember);
}

.rk-showcase__info {
    right: 22px;
    bottom: 64px;
    left: 22px;
    display: grid;
    gap: 2px;
}

.rk-showcase__info b {
    font-size: var(--rk-fs-lg);
    font-weight: 600;
    line-height: 1.35;
}

.rk-showcase__info span {
    color: rgba(255, 255, 255, .72);
    font-size: var(--rk-fs-sm);
}

.rk-showcase__price {
    bottom: 20px;
    left: 22px;
    padding: 6px 14px;
    color: var(--rk-ink);
    background: #fff;
    border-radius: 999px;
    font-size: var(--rk-fs-sm);
}

.rk-showcase__price b {
    font-size: var(--rk-fs-base);
}

.rk-showcase__mini,
.rk-showcase__radar,
.rk-showcase__review {
    position: absolute;
    z-index: 2;
    display: flex;
    align-items: center;
    box-shadow: 0 18px 44px rgba(0, 0, 0, .38);
}

.rk-showcase__mini {
    top: 40%;
    left: 0;
    gap: 12px;
    width: 250px;
    padding: 10px 14px 10px 10px;
    color: var(--rk-ink);
    background: rgba(255, 255, 255, .97);
    border-radius: 18px;
}

.rk-showcase__mini:hover {
    color: var(--rk-ink);
}

.rk-showcase__mini img {
    flex: none;
    width: 56px;
    height: 56px;
    object-fit: cover;
    border-radius: 12px;
}

.rk-showcase__mini > span {
    min-width: 0;
}

.rk-showcase__mini b {
    display: block;
    overflow: hidden;
    font-size: var(--rk-fs-sm);
    line-height: 1.35;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rk-showcase__mini small {
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-showcase__radar {
    right: 32px;
    bottom: 0;
    gap: 12px;
    padding: 12px 20px 12px 12px;
    color: #fff;
    background: rgba(23, 23, 25, .74);
    border: 1px solid rgba(255, 255, 255, .14);
    border-radius: 18px;
    -webkit-backdrop-filter: blur(14px) saturate(140%);
    backdrop-filter: blur(14px) saturate(140%);
}

.rk-showcase__radar:hover {
    color: #fff;
    border-color: rgba(255, 255, 255, .32);
}

.rk-showcase__radar b {
    display: block;
    font-size: var(--rk-fs-sm);
}

.rk-showcase__radar small {
    color: rgba(255, 255, 255, .66);
    font-size: var(--rk-fs-sm);
}

.rk-showcase__review {
    top: 46px;
    left: 0;
    gap: 10px;
    padding: 10px 16px;
    color: var(--rk-ink);
    background: rgba(255, 255, 255, .97);
    border-radius: 999px;
    font-size: var(--rk-fs-sm);
}

.rk-showcase__review b {
    font-size: var(--rk-fs-base);
}

.rk-showcase__stars {
    color: #F5A524;
    font-size: var(--rk-fs-sm);
    letter-spacing: 1px;
}

/* เรดาร์: จุดกลาง + วงคลื่นกระจาย */
.rk-radar {
    position: relative;
    flex: none;
    width: 46px;
    height: 46px;
    background: radial-gradient(circle, rgba(240, 43, 36, .38), rgba(240, 43, 36, .08) 70%);
    border-radius: 50%;
}

.rk-radar::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 10px;
    height: 10px;
    margin: -5px 0 0 -5px;
    background: var(--rk-scarlet);
    border-radius: 50%;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, .92);
}

.rk-radar i {
    position: absolute;
    inset: 0;
    border: 1.5px solid rgba(255, 122, 69, .85);
    border-radius: 50%;
    opacity: 0;
    animation: rk-radar 2.7s var(--rk-ease) infinite;
}

.rk-radar i:nth-child(2) {
    animation-delay: .9s;
}

.rk-radar i:nth-child(3) {
    animation-delay: 1.8s;
}

.rk-radar--sm {
    width: 32px;
    height: 32px;
}

.rk-radar--sm::after {
    width: 8px;
    height: 8px;
    margin: -4px 0 0 -4px;
    box-shadow: 0 0 0 2px rgba(255, 255, 255, .92);
}

.rk-float {
    animation: rk-float 7s ease-in-out infinite;
}

.rk-float--slow {
    animation-duration: 9s;
    animation-delay: -3s;
}

.rk-float--late {
    animation-delay: -5s;
}

.rk-hero__stats {
    display: flex;
    flex-wrap: wrap;
    gap: 14px 0;
    margin: 30px 0 0;
    padding: 0;
    list-style: none;
}

.rk-hero__stats li {
    padding: 0 28px;
    color: rgba(255, 255, 255, .6);
    border-left: 1px solid rgba(255, 255, 255, .12);
    font-size: var(--rk-fs-sm);
}

.rk-hero__stats li:first-child {
    padding-left: 0;
    border-left: 0;
}

.rk-hero__stats strong {
    display: block;
    color: #fff;
    font-size: var(--rk-fs-xl);
    font-weight: 600;
    line-height: 1.25;
    font-variant-numeric: tabular-nums;
}

@keyframes rk-drift {
    0% {
        transform: translate3d(0, 0, 0) scale(1);
    }

    50% {
        transform: translate3d(-4%, 6%, 0) scale(1.08);
    }

    100% {
        transform: translate3d(5%, -3%, 0) scale(.96);
    }
}

@keyframes rk-live {
    50% {
        box-shadow: 0 0 0 7px rgba(255, 100, 45, 0), 0 0 18px rgba(255, 100, 45, .9);
    }
}

@keyframes rk-radar {
    0% {
        opacity: 1;
        transform: scale(.25);
    }

    100% {
        opacity: 0;
        transform: scale(1.3);
    }
}

@keyframes rk-float {
    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

@media (max-width: 1199.98px) {
    .rk-hero__showcase {
        height: 430px;
    }

    .rk-showcase__main {
        width: 88%;
        height: 372px;
    }

    .rk-showcase__mini {
        width: 220px;
    }
}

@media (max-width: 991.98px) {
    .rk-hero__layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .rk-hero__showcase {
        display: none;
    }
}

@media (max-width: 575.98px) {
    .rk-hero {
        margin: 8px 8px 0;
        border-radius: 24px;
    }

    /* ขนาดที่คำยาวสุด + "ที่ใช่" ยังอยู่บรรทัดเดียวบนจอ 360px หัวข้อจึงคงเป็น 2 บรรทัดทุกคำ */
    .rk-hero__title {
        margin-top: 20px;
        font-size: var(--rk-fs-display-sm);
    }

    .rk-hero__stats li {
        flex: 1 1 50%;
        padding: 0 0 0 16px;
    }

    .rk-hero__stats li:nth-child(odd) {
        padding-left: 0;
        border-left: 0;
    }
}

/* ---------- กล่องค้นหา ---------- */

.rk-search {
    margin-top: clamp(28px, 4vw, 44px);
    padding: 10px;
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: 26px;
    box-shadow: var(--rk-shadow-lg);
}

.rk-search__tabs {
    display: flex;
    flex-wrap: nowrap; /* คลาส .nav ของ Bootstrap ตั้ง wrap ไว้ ทำให้แท็บบนมือถือแตกเป็น 3 แถว (QC M04) */
    gap: 6px;
    padding: 4px;
    overflow-x: auto;
    scrollbar-width: none;
}

.rk-search__tabs::-webkit-scrollbar {
    display: none;
}

.rk-search__tab {
    flex: 1 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 18px;
    border: 0;
    border-radius: 16px;
    color: var(--rk-muted);
    background: transparent;
    font-weight: 500;
    white-space: nowrap;
    transition: background-color .2s var(--rk-ease), color .2s var(--rk-ease);
}

.rk-search__tab i {
    font-size: var(--rk-fs-base);
}

.rk-search__tab:hover {
    color: var(--rk-ink);
    background: var(--rk-canvas);
}

.rk-search__tab.active {
    color: #fff;
    background: var(--rk-ink);
}

.rk-search__pane {
    padding: 14px 12px 12px;
}

.rk-searchbar {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 250px) auto;
    align-items: start;
    gap: 10px;
}

.rk-searchbar--3 {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 230px) auto;
}

.rk-searchbar .btn {
    min-width: 140px;
}

/* ช่องที่พิมพ์เพื่อค้นหา แสดงแว่นขยายแทนลูกศร dropdown */
.rk-field-search {
    position: relative;
}

.rk-field-search::before {
    content: "\f002";
    position: absolute;
    top: 24px;
    left: 1rem;
    z-index: 2;
    transform: translateY(-50%);
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    font-size: var(--rk-fs-sm);
    color: var(--rk-subtle);
    pointer-events: none;
}

.rk-field-search .select2-selection__rendered {
    padding-left: 2.6rem !important;
}

.rk-field-search .select2-selection__arrow {
    display: none;
}

@media (max-width: 991.98px) {
    .rk-searchbar,
    .rk-searchbar--3 {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    }

    .rk-searchbar > :first-child {
        grid-column: 1 / -1;
    }

    .rk-searchbar .btn {
        width: 100%;
    }
}

@media (max-width: 575.98px) {
    .rk-searchbar,
    .rk-searchbar--3 {
        grid-template-columns: minmax(0, 1fr);
    }

    /* จอเล็ก: แท็บเป็นแถวเลื่อนแนวนอน (QC M04) ไม่ให้แท็บที่ 5 ลอยเดี่ยว */
    .rk-search__tab {
        flex: 0 0 auto;
        padding: 10px 14px;
    }

    /* จอเล็ก: ซ่อนแบนเนอร์แผนที่ใน hero เพราะซ้ำกับแท็บ แผนที่ และดันช่องค้นหาพ้นจอแรก (QC M05) */
    .rk-hero__maplink {
        display: none;
    }

    .rk-hero {
        padding-top: 32px;
        padding-bottom: 28px;
    }

    .rk-hero__lead {
        font-size: var(--rk-fs-sm);
    }
}

/* กล่องค้นหาบนพื้นเข้มของ hero: ขอบไล่สี ember → scarlet */
.rk-hero .rk-search {
    position: relative;
    margin-top: clamp(32px, 4vw, 52px);
    border-color: transparent;
    box-shadow: 0 30px 80px rgba(0, 0, 0, .45);
}

.rk-hero .rk-search::before {
    content: "";
    position: absolute;
    inset: -1px;
    z-index: -1;
    padding: 1px;
    background: linear-gradient(120deg, rgba(255, 122, 69, .9), rgba(255, 255, 255, .12) 32%, rgba(255, 255, 255, .12) 68%, rgba(240, 43, 36, .9));
    border-radius: 27px;
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
}

.rk-search__new {
    padding: 2px 7px;
    color: #fff;
    background: var(--rk-scarlet-ui);
    border-radius: 999px;
    font-size: var(--rk-fs-xs);
    font-weight: 700;
    line-height: 1.35;
    letter-spacing: .02em;
}

.rk-searchbar--map {
    grid-template-columns: minmax(0, 1fr) auto auto;
}

.rk-pillset--radius {
    align-self: stretch;
    align-items: center;
    border-radius: 14px;
}

.rk-pillset--radius span {
    height: 40px;
    padding: 0 12px;
    border-radius: 10px;
    font-size: var(--rk-fs-sm);
    white-space: nowrap;
}

.rk-search__near {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 12px 4px 0;
    color: var(--rk-ink);
    font-size: var(--rk-fs-sm);
    font-weight: 600;
}

.rk-search__near i {
    color: var(--rk-scarlet-ui);
}

.rk-search__near:hover {
    color: var(--rk-ink);
    text-decoration: underline;
    text-underline-offset: 4px;
}

@media (max-width: 991.98px) {
    .rk-searchbar--map {
        grid-template-columns: minmax(0, 1fr) auto;
    }
}

@media (max-width: 575.98px) {
    .rk-searchbar--map {
        grid-template-columns: minmax(0, 1fr);
    }

    .rk-search__tab:last-child:nth-child(odd) {
        grid-column: 1 / -1;
    }
}

/* ---------- สารบัญทำเล (สถานี / มหาวิทยาลัย / จังหวัด / ทำเล) ---------- */

.rk-dir-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 34px 32px;
    margin-top: 28px;
}

.rk-dir-grid--2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (max-width: 991.98px) {
    .rk-dir-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 575.98px) {
    .rk-dir-grid,
    .rk-dir-grid--2 {
        grid-template-columns: minmax(0, 1fr);
    }
}

.rk-dir-group__title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 8px;
    font-size: var(--rk-fs-base);
    font-weight: 600;
}

.rk-line-dot {
    width: 10px;
    height: 10px;
    flex: none;
    border-radius: 50%;
    background: var(--dot, var(--rk-ink));
    box-shadow: 0 0 0 3px rgba(23, 23, 25, .05);
}

.rk-dir-group a.text-station,
.rk-dir-list a,
#stationList a,
#provinceList a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 8px 0;
    color: var(--rk-text);
    border-bottom: 1px solid var(--rk-line);
    font-size: var(--rk-fs-base);
}

.rk-dir-group a.text-station.d-none {
    display: none !important;
}

.rk-dir-group a.text-station:hover,
.rk-dir-list a:hover,
#stationList a:hover,
#provinceList a:hover {
    color: var(--rk-scarlet-ui);
}

#stationList,
#provinceList {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 24px;
    margin: 0;
    padding: 0;
    list-style: none;
}

#stationList .text-muted,
#provinceList .text-muted {
    font-size: var(--rk-fs-sm);
}

.rk-dir-more {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 12px;
    color: var(--rk-ink);
    font-weight: 500;
    font-size: var(--rk-fs-sm);
}

.rk-dir-more:hover {
    color: var(--rk-scarlet-ui);
}

/* ---------- การ์ดประกาศ ---------- */

.rk-listing-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}

@media (max-width: 991.98px) {
    .rk-listing-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 18px;
    }
}

@media (max-width: 575.98px) {
    .rk-listing-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

.rk-listing {
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
    color: var(--rk-text);
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: 18px;
    transition: transform .28s var(--rk-ease), box-shadow .28s var(--rk-ease), border-color .28s var(--rk-ease);
}

.rk-listing:hover {
    color: var(--rk-text);
    border-color: transparent;
    box-shadow: var(--rk-shadow);
    transform: translateY(-3px);
}

.rk-listing__media {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: var(--rk-stone);
}

.rk-listing__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .7s var(--rk-ease);
}

.rk-listing:hover .rk-listing__media img {
    transform: scale(1.04);
}

.rk-listing__tags {
    position: absolute;
    top: 12px;
    left: 12px;
    right: 12px;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.rk-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 10px;
    border-radius: 999px;
    color: var(--rk-ink);
    background: rgba(255, 255, 255, .94);
    box-shadow: var(--rk-shadow-xs);
    font-size: var(--rk-fs-xs);
    font-weight: 600;
    line-height: 1.2;
}

.rk-tag i {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--tier, var(--rk-ember));
}

.rk-tag--promo {
    color: #fff;
    background: var(--rk-scarlet-ui);
}

.rk-listing__body {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 6px;
    padding: 16px 18px 18px;
}

.rk-listing__title {
    display: -webkit-box;
    margin: 0;
    overflow: hidden;
    color: var(--rk-ink);
    font-size: var(--rk-fs-base);
    font-weight: 600;
    line-height: 1.45;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.rk-listing__loc {
    display: flex;
    gap: 8px;
    margin: 0;
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-listing__loc i {
    margin-top: .32em;
    font-size: var(--rk-fs-sm);
    color: var(--rk-subtle);
}

.rk-listing__loc span {
    display: -webkit-box;
    overflow: hidden;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
}

.rk-listing__price {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 2px 12px;
    margin-top: 4px;
    padding: 8px 10px;
    background: var(--rk-scarlet-tint);
    border-radius: 10px;
}

.rk-listing__price b {
    color: var(--rk-scarlet-ui); /* ราคาเด่นสีแดงแบรนด์ (เจ้าของ 29/09/2026) 5.36:1 บนขาว */
    font-size: var(--rk-fs-xl);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.rk-listing__price small {
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-listing__foot {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    margin-top: auto;
    padding-top: 12px;
    border-top: 1px solid var(--rk-line);
    color: var(--rk-subtle);
    font-size: var(--rk-fs-sm);
}

.rk-listing__promo {
    margin: 6px 0 14px;
    padding: 9px 12px;
    border-radius: 12px;
    color: #6B4C0B;
    background: #FFF7E6;
    font-size: var(--rk-fs-sm);
    line-height: 1.5;
}

.rk-listing__promo b {
    color: #6B4C0B;
}

/* ---------- การ์ดข่าว ---------- */

.rk-post-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 28px;
}

@media (max-width: 991.98px) {
    .rk-post-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 575.98px) {
    .rk-post-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

.rk-post {
    display: flex;
    flex-direction: column;
    height: 100%;
    color: var(--rk-text);
}

.rk-post:hover {
    color: var(--rk-text);
}

.rk-post__media {
    aspect-ratio: 16 / 10;
    overflow: hidden;
    border-radius: 18px;
    background: var(--rk-stone);
}

.rk-post__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .7s var(--rk-ease);
}

.rk-post:hover .rk-post__media img {
    transform: scale(1.04);
}

.rk-post__meta {
    margin: 16px 0 6px;
    color: var(--rk-subtle);
    font-size: var(--rk-fs-sm);
}

.rk-post__title {
    display: -webkit-box;
    margin: 0 0 6px;
    overflow: hidden;
    color: var(--rk-ink);
    font-size: var(--rk-fs-md);
    font-weight: 600;
    line-height: 1.45;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    transition: color .18s var(--rk-ease);
}

.rk-post:hover .rk-post__title {
    color: var(--rk-scarlet-ui);
}

.rk-post__excerpt {
    display: -webkit-box;
    margin: 0;
    overflow: hidden;
    color: var(--rk-muted);
    font-size: var(--rk-fs-base);
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.rk-post--feature {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr);
    align-items: center;
    gap: 44px;
}

.rk-post--feature .rk-post__media {
    border-radius: 24px;
}

.rk-post--feature .rk-post__title {
    font-size: var(--rk-fs-title);
    line-height: 1.35;
    -webkit-line-clamp: 3;
}

.rk-post--feature .rk-post__excerpt {
    font-size: var(--rk-fs-base);
    -webkit-line-clamp: 3;
}

@media (max-width: 767.98px) {
    .rk-post--feature {
        grid-template-columns: minmax(0, 1fr);
        gap: 0;
    }
}

/* ---------- หน้าข่าวสารและบทความ ---------- */

.rk-blog-head {
    max-width: 720px;
    margin-bottom: 36px;
}

.rk-blog-grid {
    margin-top: clamp(40px, 5vw, 64px);
    row-gap: 44px;
}

.rk-pager {
    display: flex;
    justify-content: center;
    margin-top: 48px;
}

.rk-article__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 18px;
}

.rk-article__title {
    margin: 0 0 20px;
    font-size: var(--rk-fs-title-lg);
    line-height: 1.3;
}

.rk-article__meta {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 28px;
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
    line-height: 1.5;
}

.rk-article__avatar {
    display: grid;
    place-items: center;
    flex: none;
    width: 44px;
    height: 44px;
    color: var(--rk-muted);
    background: var(--rk-stone);
    border-radius: 50%;
}

.rk-article__cover {
    margin: 0 0 36px;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    background: var(--rk-stone);
    border-radius: 24px;
}

.rk-article__cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.rk-article__body {
    font-size: var(--rk-fs-base);
    line-height: 1.9;
}

.rk-article__body > :first-child {
    margin-top: 0;
}

.rk-article__body h2,
.rk-article__body h3,
.rk-article__body h4 {
    margin: 1.7em 0 .6em;
    line-height: 1.4;
}

.rk-article__body p {
    margin-bottom: 1.1em;
}

.rk-article__body img {
    max-width: 100%;
    height: auto;
    border-radius: 16px;
}

.rk-article__body a {
    color: var(--rk-scarlet-ui);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.rk-article__body blockquote {
    margin: 1.6em 0;
    padding: 4px 0 4px 22px;
    color: var(--rk-ink);
    border-left: 3px solid var(--rk-scarlet);
    font-size: var(--rk-fs-md);
}

.rk-article__body ul,
.rk-article__body ol {
    padding-left: 1.3em;
}

.rk-article__body table {
    width: 100%;
    margin: 1.4em 0;
    border-collapse: collapse;
    font-size: var(--rk-fs-base);
}

.rk-article__body th,
.rk-article__body td {
    padding: 8px 12px;
    border: 1px solid var(--rk-line);
}

.rk-share {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-top: 44px;
    padding-top: 24px;
    border-top: 1px solid var(--rk-line);
}

.rk-share__label {
    margin-right: 6px;
    color: var(--rk-muted);
    font-weight: 500;
}

.rk-share .btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: 1px solid var(--rk-line);
}

.rk-share .fa-facebook {
    color: #0866FF;
}

.rk-share .fa-line {
    color: #06C755;
}

.rk-aside-title {
    margin-bottom: 18px;
    font-size: var(--rk-fs-md);
}

.rk-pop-list {
    display: grid;
    gap: 18px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.rk-pop-list a {
    display: grid;
    grid-template-columns: 92px minmax(0, 1fr);
    align-items: center;
    gap: 14px;
    color: var(--rk-text);
}

.rk-pop-list img {
    width: 92px;
    height: 70px;
    object-fit: cover;
    background: var(--rk-stone);
    border-radius: 12px;
}

.rk-pop-list b {
    display: -webkit-box;
    margin-bottom: 4px;
    overflow: hidden;
    color: var(--rk-ink);
    font-size: var(--rk-fs-base);
    font-weight: 600;
    line-height: 1.45;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    transition: color .18s var(--rk-ease);
}

.rk-pop-list a:hover b {
    color: var(--rk-scarlet-ui);
}

.rk-pop-list small {
    color: var(--rk-subtle);
}

.rk-article__more {
    margin-top: clamp(56px, 7vw, 88px);
    padding-top: clamp(40px, 5vw, 56px);
    border-top: 1px solid var(--rk-line);
}

/* ---------- แถบชวนลงประกาศ ---------- */

.rk-cta {
    position: relative;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: clamp(28px, 5vw, 56px);
    overflow: hidden;
    color: #B5B5B5;
    background: var(--rk-carbon);
    border-radius: var(--rk-radius-xl);
}

.rk-cta::after {
    content: "";
    position: absolute;
    right: -120px;
    bottom: -160px;
    width: 420px;
    aspect-ratio: 1;
    border-radius: 50%;
    background: radial-gradient(closest-side, rgba(240, 43, 36, .35), rgba(240, 43, 36, 0));
    pointer-events: none;
}

.rk-cta > * {
    position: relative;
    z-index: 1;
}

.rk-cta h2 {
    margin: 0 0 8px;
    color: #fff;
    font-size: var(--rk-fs-title);
}

.rk-cta p {
    max-width: 560px;
    margin: 0;
}

/* ---------- Footer ---------- */

.rk-footer {
    padding: clamp(48px, 6vw, 72px) 0 28px;
    color: #B5B5B5;
    background: var(--rk-carbon);
}

.rk-footer a {
    color: #B5B5B5;
}

.rk-footer a:hover {
    color: #fff;
}

.rk-footer__brand img {
    display: block;
    width: 176px;
    height: auto;
}

.rk-footer__about {
    max-width: 380px;
    margin: 18px 0 0;
    font-size: var(--rk-fs-base);
    line-height: 1.8;
}

.rk-footer__title {
    margin-bottom: 16px;
    color: #fff;
    font-size: var(--rk-fs-base);
    font-weight: 600;
}

.rk-footer__list {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 11px;
    margin: 0;
    padding: 0;
    list-style: none;
    font-size: var(--rk-fs-base);
}

.rk-footer__list li {
    display: flex;
    gap: 12px;
}

.rk-footer__list span {
    min-width: 0;
    overflow-wrap: anywhere;
}

.rk-footer__list i {
    width: 16px;
    margin-top: .38em;
    color: var(--rk-ember);
    font-size: var(--rk-fs-sm);
    text-align: center;
}

.rk-footer__bottom {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 8px 24px;
    margin-top: clamp(36px, 5vw, 56px);
    padding-top: 22px;
    border-top: 1px solid rgba(255, 255, 255, .1);
    font-size: var(--rk-fs-sm);
}

/* ---------- หน้ารายละเอียดประกาศ ---------- */

.rk-crumbs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
    color: var(--rk-subtle);
    font-size: var(--rk-fs-sm);
}

.rk-crumbs a {
    color: var(--rk-muted);
}

.rk-crumbs a:hover {
    color: var(--rk-ink);
}

.rk-detail-title {
    margin: 0 0 8px;
    font-size: var(--rk-fs-title-lg);
    line-height: 1.25;
}

.rk-detail-loc {
    display: flex;
    gap: 8px;
    margin: 0;
    color: var(--rk-muted);
}

.rk-detail-loc i {
    margin-top: .35em;
    font-size: var(--rk-fs-sm);
    color: var(--rk-subtle);
}

.rk-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 16px;
}

.rk-badge-soft {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 12px;
    border-radius: 999px;
    color: var(--rk-ink);
    background: var(--rk-stone);
    font-size: var(--rk-fs-sm);
    font-weight: 500;
}

.rk-badge-soft--success {
    color: #145538;
    background: #EEF7F2;
}

.rk-badge-soft--promo {
    color: var(--rk-scarlet-ui);
    background: #FDF1F0;
}

.rk-gallery {
    position: relative;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    gap: 8px;
    height: clamp(300px, 42vw, 520px);
    margin-top: 28px;
    overflow: hidden;
    border-radius: 22px;
}

.rk-gallery__item {
    position: relative;
    display: block;
    overflow: hidden;
    background: var(--rk-stone);
}

.rk-gallery__item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .7s var(--rk-ease), filter .3s var(--rk-ease);
}

.rk-gallery__item:hover img {
    transform: scale(1.03);
    filter: brightness(.94);
}

.rk-gallery__item--main {
    grid-row: span 2;
}

.rk-gallery--4 .rk-gallery__item:nth-child(4) {
    grid-column: span 2;
}

.rk-gallery--3,
.rk-gallery--2 {
    grid-template-columns: 2fr 1fr;
}

.rk-gallery--2 .rk-gallery__item:nth-child(2) {
    grid-row: span 2;
}

.rk-gallery--1 {
    grid-template-columns: minmax(0, 1fr);
}

.rk-gallery__all {
    position: absolute;
    right: 16px;
    bottom: 16px;
    z-index: 3;
    box-shadow: var(--rk-shadow);
}

@media (max-width: 767.98px) {
    .rk-gallery,
    .rk-gallery--3,
    .rk-gallery--4 {
        grid-template-columns: 1fr 1fr;
        grid-template-rows: 2fr 1fr;
        height: 380px;
        border-radius: 18px;
    }

    .rk-gallery .rk-gallery__item--main {
        grid-column: 1 / -1;
        grid-row: auto;
    }

    .rk-gallery .rk-gallery__item:nth-child(4) {
        grid-column: auto;
    }

    .rk-gallery .rk-gallery__item:nth-child(n+4) {
        display: none;
    }

    .rk-gallery--2 {
        grid-template-columns: minmax(0, 1fr);
    }

    .rk-gallery--2 .rk-gallery__item:nth-child(2) {
        grid-row: auto;
    }

    .rk-gallery--1 {
        grid-template-rows: 1fr;
        height: 280px;
    }
}

.rk-block {
    padding: 32px 0;
    border-bottom: 1px solid var(--rk-line);
}

.rk-block:first-child {
    padding-top: 8px;
}

.rk-block:last-child {
    border-bottom: 0;
}

.rk-block__title {
    margin: 0 0 18px;
    font-size: var(--rk-fs-lg);
}

.rk-prose {
    color: var(--rk-text);
    line-height: 1.8;
}

.rk-prose p:last-child {
    margin-bottom: 0;
}

.rk-pre {
    margin: 0;
    white-space: pre-line;
    font-family: inherit;
}

.rk-promo {
    padding: 18px 20px;
    margin-bottom: 8px;
    border: 1px solid #F3DEAE;
    border-radius: 18px;
    background: #FFF7E6;
}

.rk-promo__head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 12px;
    color: #6B4C0B;
    font-weight: 600;
}

.rk-promo__body {
    margin-top: 6px;
    color: #6B4C0B;
}

.rk-specs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 36px;
    margin: 0;
}

.rk-specs > div {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 14px 0;
    border-bottom: 1px dashed var(--rk-line-strong);
}

.rk-specs dt {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--rk-muted);
    font-weight: 400;
}

.rk-specs dt i {
    width: 18px;
    color: var(--rk-subtle);
    text-align: center;
}

.rk-specs dd {
    margin: 0;
    color: var(--rk-ink);
    font-weight: 500;
    text-align: right;
}

.rk-specs dd small {
    display: block;
    color: var(--rk-muted);
    font-weight: 400;
}

@media (max-width: 575.98px) {
    .rk-specs {
        grid-template-columns: minmax(0, 1fr);
    }
}

.rk-amenities {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px 24px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.rk-amenities li {
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--rk-text);
}

.rk-amenities i {
    display: inline-grid;
    place-items: center;
    width: 38px;
    height: 38px;
    flex: none;
    border-radius: 11px;
    color: var(--rk-ink);
    background: var(--rk-stone);
    font-size: var(--rk-fs-base);
}

@media (max-width: 767.98px) {
    .rk-amenities {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

.rk-price-card {
    padding: 24px;
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: 22px;
    box-shadow: var(--rk-shadow);
}

.rk-sticky {
    position: sticky;
    top: calc(var(--rk-header-h) + 20px);
}

.rk-price-card__label {
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-price-card__price {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 4px 8px;
    margin-top: 2px;
}

.rk-price-card__price b {
    color: var(--rk-scarlet-ui);
    font-size: var(--rk-fs-2xl);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    line-height: 1.3;
}

.rk-price-card__price span {
    color: var(--rk-muted);
}

.rk-price-card__verified {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 16px 0 18px;
    padding: 10px 12px;
    border-radius: 12px;
    color: #145538;
    background: #EEF7F2;
    font-size: var(--rk-fs-sm);
}

.rk-price-card__note {
    margin: 14px 0 0;
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
    text-align: center;
}

.rk-map {
    position: relative;
    z-index: 0;
    height: 380px;
    overflow: hidden;
    border: 1px solid var(--rk-line);
    border-radius: 18px;
    background: var(--rk-stone);
}

.rk-nearby-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px 36px;
    margin-top: 28px;
}

@media (max-width: 767.98px) {
    .rk-nearby-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

.rk-nearby__title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 6px;
    font-size: var(--rk-fs-base);
}

.rk-nearby__title i {
    color: var(--rk-subtle);
}

.rk-nearby-item {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid var(--rk-line);
}

.rk-nearby-item a {
    color: var(--rk-ink);
    font-weight: 500;
}

.rk-nearby-item a:hover {
    color: var(--rk-scarlet-ui);
}

.rk-nearby-item small {
    display: block;
    color: var(--rk-muted);
}

.rk-toggle {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 12px;
    color: var(--rk-ink);
    font-weight: 500;
    font-size: var(--rk-fs-sm);
    cursor: pointer;
}

.rk-toggle:hover {
    color: var(--rk-scarlet-ui);
}

.rk-review-summary {
    display: grid;
    grid-template-columns: 200px minmax(0, 1fr);
    align-items: center;
    gap: 32px;
    padding: 24px 28px;
    border-radius: 20px;
    background: var(--rk-stone);
}

.rk-score {
    color: var(--rk-ink);
    font-size: var(--rk-fs-3xl);
    font-weight: 700;
    line-height: 1;
    font-variant-numeric: tabular-nums;
}

.rk-bars > div {
    display: grid;
    grid-template-columns: 110px minmax(0, 1fr) 36px;
    align-items: center;
    gap: 12px;
    margin: 7px 0;
    font-size: var(--rk-fs-sm);
}

.rk-bars .progress {
    height: 8px;
}

.rk-bars span:last-child {
    color: var(--rk-ink);
    font-weight: 500;
    text-align: right;
    font-variant-numeric: tabular-nums;
}

.rk-review {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 260px;
    gap: 28px;
    padding: 26px 0;
    border-bottom: 1px solid var(--rk-line);
}

.rk-review__who {
    display: flex;
    align-items: center;
    gap: 12px;
}

.rk-review__avatar {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    flex: none;
    border-radius: 50%;
    color: var(--rk-subtle);
    background: var(--rk-stone);
}

.rk-review__msg {
    margin-top: 14px;
    white-space: pre-line;
    color: var(--rk-text);
}

.rk-review__pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    border-radius: 999px;
    color: var(--rk-ink);
    background: #FFF1E9;
    font-weight: 700;
}

.rk-review__pill i {
    color: var(--rk-ember);
}

@media (max-width: 767.98px) {
    .rk-review-summary,
    .rk-review {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* ---------- หน้าผลค้นหา ---------- */

.rk-results-head {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px 24px;
    margin-bottom: 20px;
}

.rk-related {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 8px 16px;
    padding: 12px 0;
    border-top: 1px solid var(--rk-line);
}

.rk-related__label {
    flex: 0 0 120px;
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
    font-weight: 500;
}

.rk-related__chips {
    display: flex;
    flex: 1;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.rk-related__chips .rk-chip {
    padding: 4px 10px;
    font-size: var(--rk-fs-sm);
}

.rk-related__chips .rk-chip.d-none {
    display: none !important;
}

@media (max-width: 575.98px) {
    .rk-related__label {
        flex-basis: 100%;
    }

    /* จอมือถือ: chip แต่ละกลุ่มเป็นแถวเดียวเลื่อนแนวนอน ผลค้นหาจะไม่ถูกดันลงไปไกล */
    .rk-related__chips {
        flex-wrap: nowrap;
        margin-right: -16px;
        padding: 2px 16px 4px 0;
        overflow-x: auto;
        scrollbar-width: none;
        -webkit-overflow-scrolling: touch;
    }

    .rk-related__chips::-webkit-scrollbar {
        display: none;
    }

    .rk-related__chips .rk-chip {
        flex: none;
        white-space: nowrap;
    }

    .rk-related .rk-related__chips .rk-chip.d-none {
        display: inline-flex !important;
    }

    .rk-related__chips .rk-toggle {
        display: none !important;
    }
}

.rk-listing-grid--2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (max-width: 575.98px) {
    .rk-listing-grid--2 {
        grid-template-columns: minmax(0, 1fr);
    }
}

.rk-filter {
    padding: 22px;
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: 20px;
}

.rk-filter__title {
    font-size: var(--rk-fs-md);
}

.rk-filter__head {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
}

.rk-filter__head .rk-filter__title {
    margin-right: auto;
}

.rk-filter-backdrop,
.rk-filter-fab {
    display: none;
}

/* จอเล็ก: ตัวกรองเป็น bottom sheet เปิดด้วยปุ่มลอย (สถานะอยู่ที่ body.rk-filters-open) */
@media (max-width: 991.98px) {
    .rk-filter--sheet {
        position: fixed;
        top: auto;
        right: 0;
        bottom: 0;
        left: 0;
        z-index: 1045;
        max-height: 88vh;
        max-height: 88dvh;
        padding: 0 20px;
        overflow-y: auto;
        overscroll-behavior: contain;
        border: 0;
        border-radius: 22px 22px 0 0;
        box-shadow: 0 -12px 40px rgba(23, 23, 25, .18);
        transform: translateY(100%);
        visibility: hidden;
        transition: transform .32s cubic-bezier(.2, .8, .2, 1), visibility 0s linear .32s;
    }

    .rk-filters-open .rk-filter--sheet {
        transform: none;
        visibility: visible;
        transition: transform .32s cubic-bezier(.2, .8, .2, 1);
    }

    .rk-filter--sheet .rk-filter__head {
        position: sticky;
        top: 0;
        z-index: 2;
        margin: 0 -20px 16px;
        padding: 18px 20px 14px;
        background: #fff;
        border-bottom: 1px solid var(--rk-line);
    }

    .rk-filter__foot {
        position: sticky;
        bottom: 0;
        z-index: 2;
        margin: 0 -20px;
        padding: 14px 20px calc(14px + env(safe-area-inset-bottom));
        background: #fff;
        border-top: 1px solid var(--rk-line);
    }

    .rk-filter-backdrop {
        position: fixed;
        inset: 0;
        z-index: 1044;
        display: block;
        background: rgba(23, 23, 25, .5);
        opacity: 0;
        visibility: hidden;
        transition: opacity .25s ease, visibility 0s linear .25s;
    }

    .rk-filters-open .rk-filter-backdrop {
        opacity: 1;
        visibility: visible;
        transition: opacity .25s ease;
    }

    body.rk-filters-open {
        overflow: hidden;
    }

    .rk-filter-fab {
        position: fixed;
        bottom: calc(18px + env(safe-area-inset-bottom));
        left: 50%;
        z-index: 1030;
        display: inline-flex;
        align-items: center;
        gap: 10px;
        padding: 13px 24px;
        color: #fff;
        background: var(--rk-carbon);
        border: 0;
        border-radius: 999px;
        box-shadow: 0 10px 30px rgba(23, 23, 25, .3);
        font-weight: 600;
        transform: translateX(-50%);
    }

    .rk-filter-fab.is-hidden {
        opacity: 0;
        pointer-events: none;
        transform: translate(-50%, 12px);
        transition: opacity .2s var(--rk-ease), transform .2s var(--rk-ease);
    }

    .rk-filter-fab:hover {
        background: #000;
    }

    .rk-filter-fab:focus-visible {
        outline: 0;
        box-shadow: 0 0 0 3px #fff, 0 0 0 6px var(--rk-carbon);
    }

    .rk-filter-fab__count {
        display: inline-grid;
        place-items: center;
        min-width: 22px;
        height: 22px;
        padding: 0 6px;
        color: var(--rk-carbon);
        background: #fff;
        border-radius: 999px;
        font-size: var(--rk-fs-sm);
        line-height: 1;
    }

    /* เว้นที่ท้ายหน้าให้ปุ่มลอยไม่บังเนื้อหาชิ้นสุดท้าย */
    #content_near {
        padding-bottom: 88px;
    }
}

.rk-filter__section {
    padding: 18px 0;
    border-top: 1px solid var(--rk-line);
}

.rk-filter__label {
    margin-bottom: 10px;
    color: var(--rk-ink);
    font-weight: 600;
}

.rk-filter__check,
.rk-check-list .form-check {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    padding: 7px 0;
    cursor: pointer;
}

.rk-filter__check .form-check-input,
.rk-check-list .form-check-input {
    float: none;
    flex: none;
    margin: 0;
}

.rk-filter__check .form-check-label,
.rk-check-list .form-check-label {
    flex: 1;
    color: var(--rk-text);
}

.rk-check-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.rk-price-chart {
    display: block;
    width: calc(100% - 24px);
    height: 72px;
    margin: 8px 12px 0;
}

.rk-slider {
    margin: 0 12px 18px;
}

.rk-slider.noUi-target {
    height: 4px;
    border: 0;
    border-radius: 4px;
    background: var(--rk-stone-deep);
    box-shadow: none;
}

.rk-slider .noUi-connect {
    background: var(--rk-ink);
}

.rk-slider .noUi-handle {
    top: -10px !important;
    right: -12px !important;
    width: 24px !important;
    height: 24px !important;
    border: 1px solid var(--rk-line-strong);
    border-radius: 50%;
    background: #fff;
    box-shadow: var(--rk-shadow-sm);
    cursor: grab;
}

.rk-slider .noUi-handle::before,
.rk-slider .noUi-handle::after {
    display: none;
}

.rk-price-inputs {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: end;
    gap: 10px;
}

.rk-price-inputs label span {
    display: block;
    margin-bottom: 4px;
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-price-inputs .form-control {
    min-height: 42px;
    background: var(--rk-canvas);
    font-variant-numeric: tabular-nums;
}

.rk-price-inputs__dash {
    padding-bottom: 10px;
    color: var(--rk-subtle);
}

/* ลูกศร accordion สีหมึกแทนสีน้ำเงินของ Bootstrap ใช้กับทุก accordion */
.accordion {
    --bs-accordion-btn-icon: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23171719'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
    --bs-accordion-btn-active-icon: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23171719'%3e%3cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3e%3c/svg%3e");
    --bs-accordion-btn-icon-width: 1rem;
}

.rk-accordion {
    --bs-accordion-border-color: var(--rk-line);
    --bs-accordion-border-radius: 14px;
    --bs-accordion-inner-border-radius: 13px;
    --bs-accordion-btn-focus-box-shadow: var(--rk-ring);
    --bs-accordion-active-bg: var(--rk-stone);
    --bs-accordion-active-color: var(--rk-ink);
    --bs-accordion-btn-padding-y: .8rem;
}

/* ---------- หน้า "ค้นหาจาก" (สถานี สถานศึกษา จังหวัด ทำเล รายวัน) ---------- */

.rk-browse-head {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px 40px;
    margin-bottom: 24px;
}

.rk-browse-search {
    flex: 0 1 380px;
}

.rk-field-search > .form-control {
    padding-left: 2.6rem;
}

.rk-browse-tabs {
    flex-wrap: nowrap;
    max-width: 100%;
    margin-bottom: 8px;
    overflow-x: auto;
    scrollbar-width: none;
}

.rk-browse-tabs::-webkit-scrollbar {
    display: none;
}

.rk-browse-tabs .nav-link {
    flex: none;
    white-space: nowrap;
}

.rk-browse-results {
    transition: opacity .2s var(--rk-ease);
}

.rk-browse-results.is-loading {
    opacity: .45;
    pointer-events: none;
}

.rk-browse-group {
    padding: 28px 0 8px;
}

.rk-browse-group + .rk-browse-group {
    border-top: 1px solid var(--rk-line);
}

.rk-browse-group__title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
    font-size: var(--rk-fs-md);
}

.rk-place-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 12px;
}

.rk-place {
    display: flex;
    flex-direction: column;
    padding: 14px 16px 16px;
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: 16px;
    transition: border-color .2s var(--rk-ease), box-shadow .2s var(--rk-ease);
}

.rk-place:hover {
    border-color: var(--rk-line-strong);
    box-shadow: var(--rk-shadow-sm);
}

.rk-place__name {
    margin-bottom: 12px;
    color: var(--rk-ink);
    font-weight: 600;
    line-height: 1.45;
}

.rk-place__sub {
    display: block;
    color: var(--rk-subtle);
    font-size: var(--rk-fs-sm);
    font-weight: 400;
}

.rk-place__links {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: auto;
}

.rk-place__links a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    padding: 7px 10px;
    color: var(--rk-text);
    background: var(--rk-stone);
    border: 1px solid transparent;
    border-radius: 10px;
    font-size: var(--rk-fs-sm);
    transition: background-color .18s var(--rk-ease), color .18s var(--rk-ease);
}

.rk-place__links a:hover {
    color: #fff;
    background: var(--rk-ink);
}

.rk-place__links b {
    font-weight: 600;
    font-variant-numeric: tabular-nums;
}

.rk-place__links a.is-empty {
    color: var(--rk-subtle);
    background: transparent;
    border-color: var(--rk-line);
}

.rk-place__links a.is-empty:hover {
    color: var(--rk-ink);
    background: transparent;
    border-color: var(--rk-ink);
}

/* จอมือถือ: การ์ดทำเลเป็นแถวกะทัดรัด ชื่อซ้าย ปุ่มรายเดือน/รายวันขวา */
@media (max-width: 575.98px) {
    .rk-browse-search {
        flex-basis: 100%;
    }

    .rk-place-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 8px;
    }

    .rk-place {
        flex-direction: row;
        align-items: center;
        gap: 12px;
        padding: 10px 10px 10px 14px;
        border-radius: 14px;
    }

    .rk-place__name {
        flex: 1;
        min-width: 0;
        margin: 0;
    }

    .rk-place__links {
        display: flex;
        flex: none;
        gap: 6px;
    }

    .rk-place__links a {
        gap: 8px;
        padding: 6px 9px;
        font-size: var(--rk-fs-sm);
    }
}

/* ---------- โหมดค้นหาบนแผนที่ (Leaflet) ---------- */

.leaflet-container {
    font-family: var(--rk-font);
}

/* ช่องค้นหาสถานที่ ใช้ร่วมกับฟอร์มลงประกาศ/แก้ไขประกาศ */
.rk-mapsearch__search {
    display: flex;
    gap: 8px;
}

.rk-mapsearch__results {
    margin-top: -8px;
    overflow: hidden;
    border: 1px solid var(--rk-line);
    border-radius: 12px;
}

.rk-mapsearch__results button {
    display: block;
    width: 100%;
    padding: 10px 12px;
    color: var(--rk-text);
    background: #fff;
    border: 0;
    border-bottom: 1px solid var(--rk-line);
    font-size: var(--rk-fs-sm);
    line-height: 1.5;
    text-align: left;
}

.rk-mapsearch__results button b {
    display: block;
    color: var(--rk-ink);
    font-weight: 600;
}

.rk-mapsearch__results button span {
    display: block;
    overflow: hidden;
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rk-mapsearch__results li:last-child button {
    border-bottom: 0;
}

.rk-mapsearch__results button:hover,
.rk-mapsearch__results button:focus-visible {
    background: var(--rk-stone);
}

.rk-mapsearch__note {
    padding: 10px 12px;
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

/* โครงหน้า: ซ้ายตัวเลือก + รายการผล (เลื่อนตามหน้า) ขวาแผนที่ติดจอ */
.rk-mapmode {
    display: grid;
    grid-template-columns: minmax(360px, 440px) minmax(0, 1fr);
    grid-template-rows: auto 1fr;
    grid-template-areas:
        "controls stage"
        "results stage";
    background: #fff;
}

.rk-mapmode__controls {
    display: grid;
    grid-area: controls;
    align-content: start;
    gap: 14px;
    padding: 28px 28px 22px;
    border-right: 1px solid var(--rk-line);
}

.rk-mapmode__controls .rk-crumbs {
    margin-bottom: 0;
}

.rk-mapmode__title {
    margin: 0;
    font-size: var(--rk-fs-title);
    line-height: 1.2;
    letter-spacing: -.01em;
}

.rk-mapmode__lead {
    margin: -6px 0 4px;
    color: var(--rk-muted);
    font-size: var(--rk-fs-base);
    line-height: 1.6;
}

.rk-mapmode__locate {
    display: inline-flex;
    align-items: center;
    justify-self: start;
    gap: 8px;
    padding: 2px 0;
    color: var(--rk-ink);
    background: none;
    border: 0;
    font-size: var(--rk-fs-sm);
    font-weight: 600;
}

.rk-mapmode__locate i {
    color: var(--rk-scarlet-ui);
}

.rk-mapmode__locate:hover {
    text-decoration: underline;
    text-underline-offset: 4px;
}

.rk-mapmode__locate:disabled {
    opacity: .6;
}

.rk-mapmode__locate.is-busy i {
    animation: rk-spin 1s linear infinite;
}

.rk-mapmode__field {
    min-width: 0;
    margin: 4px 0 0;
    padding: 0;
    border: 0;
}

.rk-mapmode__field legend {
    margin-bottom: 8px;
    color: var(--rk-ink);
    font-size: var(--rk-fs-sm);
    font-weight: 600;
}

.rk-radius__opt {
    position: relative;
    margin: 0;
}

.rk-radius__opt input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.rk-mapmode__stage {
    position: sticky;
    top: var(--rk-header-h);
    grid-area: stage;
    align-self: start;
    height: calc(100vh - var(--rk-header-h));
    height: calc(100dvh - var(--rk-header-h));
    min-height: 520px;
    background: var(--rk-stone);
}

.rk-mapmode__map {
    position: absolute;
    inset: 0;
    z-index: 0;
}

/* ลดความสดของแผนที่พื้นหลัง ให้หมุดและวงรัศมีเด่นขึ้น */
.rk-mapmode__map .leaflet-tile-pane {
    filter: saturate(.55) contrast(1.03);
}

/* แถบเลือกรัศมีลอยเหนือแผนที่ */
.rk-radius {
    position: absolute;
    top: 18px;
    left: 50%;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 5px;
    background: rgba(255, 255, 255, .92);
    -webkit-backdrop-filter: blur(14px) saturate(160%);
    backdrop-filter: blur(14px) saturate(160%);
    border: 1px solid rgba(23, 23, 25, .08);
    border-radius: 999px;
    box-shadow: var(--rk-shadow);
    transform: translateX(-50%);
}

.rk-radius__label {
    padding: 0 8px 0 12px;
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
    font-weight: 600;
    white-space: nowrap;
}

.rk-radius__opt span {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 3px;
    min-width: 62px;
    height: 38px;
    padding: 0 12px;
    color: var(--rk-text);
    border-radius: 999px;
    font-size: var(--rk-fs-base);
    font-weight: 600;
    line-height: 38px;
    white-space: nowrap;
    cursor: pointer;
    transition: background-color .2s var(--rk-ease), color .2s var(--rk-ease), box-shadow .2s var(--rk-ease);
}

.rk-radius__opt small {
    font-size: var(--rk-fs-xs);
    font-weight: 500;
    opacity: .72;
}

.rk-radius__opt span:hover {
    background: var(--rk-stone);
}

.rk-radius__opt input:checked + span {
    color: #fff;
    background: var(--rk-ink);
    box-shadow: 0 6px 16px rgba(23, 23, 25, .24);
}

/* อยู่หลัง :checked เพื่อให้วงโฟกัสแสดงทับเงาของตัวที่เลือก */
.rk-radius__opt input:focus-visible + span {
    box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--rk-scarlet-ui);
}

.rk-mapmode__hint {
    position: absolute;
    bottom: 18px;
    left: 18px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    color: #fff;
    background: rgba(23, 23, 25, .82);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    border-radius: 999px;
    font-size: var(--rk-fs-sm);
    pointer-events: none;
    transition: opacity .4s var(--rk-ease), transform .4s var(--rk-ease);
}

.rk-mapmode__hint.is-hidden {
    opacity: 0;
    transform: translateY(8px);
}

.rk-mapmode__results {
    grid-area: results;
    min-width: 0;
    padding: 0 28px 48px;
    border-right: 1px solid var(--rk-line);
}

.rk-mapmode__summary {
    position: sticky;
    top: var(--rk-header-h);
    z-index: 3;
    display: grid;
    gap: 2px;
    margin: 0 -28px 16px;
    padding: 14px 28px;
    background: rgba(255, 255, 255, .95);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border-top: 1px solid var(--rk-line);
    border-bottom: 1px solid var(--rk-line);
}

.rk-mapmode__summary b {
    color: var(--rk-ink);
    font-size: var(--rk-fs-base);
}

.rk-mapmode__count {
    color: var(--rk-scarlet-ui);
}

.rk-mapmode__place {
    display: flex;
    align-items: baseline;
    gap: 6px;
    min-width: 0;
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-mapmode__place i {
    color: var(--rk-scarlet-ui);
    font-size: var(--rk-fs-sm);
}

.rk-mapmode__place span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rk-mapmode__list {
    display: grid;
    gap: 12px;
    transition: opacity .2s var(--rk-ease);
}

.rk-mapmode__list.is-loading {
    opacity: .5;
    pointer-events: none;
}

.rk-mapitem {
    display: grid;
    grid-template-columns: 136px minmax(0, 1fr);
    gap: 16px;
    padding: 10px;
    color: var(--rk-text);
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: var(--rk-radius);
    transition: border-color .2s var(--rk-ease), box-shadow .2s var(--rk-ease);
}

.rk-mapitem:hover,
.rk-mapitem:focus-visible,
.rk-mapitem.is-hot {
    color: var(--rk-text);
    border-color: var(--rk-line-strong);
    box-shadow: var(--rk-shadow);
}

.rk-mapitem.is-hot {
    border-color: var(--rk-ink);
}

.rk-mapitem__media {
    position: relative;
    height: 116px;
    overflow: hidden;
    background: var(--rk-stone);
    border-radius: 10px;
}

.rk-mapitem__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .6s var(--rk-ease);
}

.rk-mapitem:hover .rk-mapitem__media img {
    transform: scale(1.05);
}

.rk-mapitem__dist {
    position: absolute;
    bottom: 8px;
    left: 8px;
    padding: 3px 8px;
    color: #fff;
    background: rgba(23, 23, 25, .78);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
    border-radius: 999px;
    font-size: var(--rk-fs-xs);
    font-weight: 600;
    line-height: 1.3;
}

.rk-mapitem__body {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
    padding: 2px 4px 2px 0;
}

.rk-mapitem__tier {
    align-self: flex-start;
    padding: 3px 8px;
    background: var(--rk-stone);
    box-shadow: none;
    font-size: var(--rk-fs-xs);
}

.rk-mapitem__title {
    display: -webkit-box;
    margin: 0;
    overflow: hidden;
    color: var(--rk-ink);
    font-size: var(--rk-fs-base);
    font-weight: 600;
    line-height: 1.4;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.rk-mapitem__area {
    display: flex;
    align-items: baseline;
    gap: 6px;
    min-width: 0;
    margin: 0;
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-mapitem__area i {
    color: var(--rk-subtle);
    font-size: var(--rk-fs-xs);
}

.rk-mapitem__area span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rk-mapitem__price {
    display: flex;
    flex-wrap: wrap;
    gap: 0 14px;
    margin-top: auto;
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-mapitem__price b {
    color: var(--rk-ink);
    font-size: var(--rk-fs-base);
}

.rk-mapitem--skeleton {
    pointer-events: none;
}

.rk-mapitem--skeleton .rk-mapitem__media,
.rk-mapitem--skeleton .rk-mapitem__body {
    background: linear-gradient(90deg, var(--rk-stone) 0%, #F8F6F2 50%, var(--rk-stone) 100%);
    background-size: 200% 100%;
    border-radius: 10px;
    animation: rk-shimmer 1.3s linear infinite;
}

.rk-mapitem--skeleton .rk-mapitem__body {
    height: 116px;
}

.rk-mapmode__empty {
    display: grid;
    justify-items: center;
    gap: 8px;
    padding: 44px 20px;
    color: var(--rk-muted);
    background: var(--rk-canvas);
    border: 1px dashed var(--rk-line-strong);
    border-radius: var(--rk-radius-lg);
    text-align: center;
}

.rk-mapmode__empty i {
    margin-bottom: 4px;
    color: var(--rk-line-strong);
    font-size: var(--rk-fs-2xl);
}

.rk-mapmode__empty b {
    color: var(--rk-ink);
    font-size: var(--rk-fs-base);
}

.rk-mapmode__empty p {
    max-width: 320px;
    margin: 0 0 8px;
    font-size: var(--rk-fs-sm);
}

.rk-mapmode__empty-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
}

/* หมุดบนแผนที่ (ตัว .rk-pin-wrap / .rk-map-halo ถูก Leaflet ใช้ transform วางตำแหน่ง ห้ามใส่ transform ที่ตัวมันเอง) */
.rk-pin-wrap,
.rk-map-halo {
    background: none;
    border: 0;
}

.rk-price-pin {
    display: inline-block;
    padding: 5px 10px;
    color: var(--rk-ink);
    background: #fff;
    border-radius: 999px;
    box-shadow: 0 2px 10px rgba(23, 23, 25, .18), 0 0 0 1px rgba(23, 23, 25, .08);
    font-size: var(--rk-fs-sm);
    font-weight: 600;
    line-height: 1.3;
    white-space: nowrap;
    transform: translate(-50%, -50%);
    transition: transform .15s var(--rk-ease), background-color .15s var(--rk-ease), color .15s var(--rk-ease);
}

.rk-pin-wrap:hover .rk-price-pin,
.rk-pin-wrap.is-active .rk-price-pin,
.rk-pin-wrap:focus-visible .rk-price-pin {
    color: #fff;
    background: var(--rk-ink);
    transform: translate(-50%, -50%) scale(1.08);
}

.rk-map-halo span {
    display: block;
    width: 100%;
    height: 100%;
    background: rgba(240, 43, 36, .28);
    border-radius: 50%;
    animation: rk-halo 2.4s var(--rk-ease) infinite;
}

.rk-radius-tag {
    display: inline-block;
    padding: 3px 9px;
    color: #fff;
    background: var(--rk-scarlet-ui);
    border-radius: 999px;
    box-shadow: 0 4px 12px rgba(209, 31, 25, .3);
    font-size: var(--rk-fs-xs);
    font-weight: 700;
    line-height: 1.3;
    white-space: nowrap;
    transform: translate(-50%, -50%);
}

.leaflet-popup-content-wrapper {
    border-radius: 14px;
    box-shadow: var(--rk-shadow);
}

.leaflet-popup-content {
    margin: 10px;
}

.rk-map-card {
    display: flex;
    gap: 10px;
    width: 260px;
    color: var(--rk-text) !important;
    font-size: var(--rk-fs-sm);
    line-height: 1.45;
}

.rk-map-card img {
    flex: none;
    width: 76px;
    height: 76px;
    object-fit: cover;
    border-radius: 10px;
}

.rk-map-card b {
    display: block;
    margin-bottom: 4px;
    color: var(--rk-ink);
    font-size: var(--rk-fs-sm);
}

.rk-map-card__price {
    display: grid;
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-map-card__price b {
    display: inline;
    margin: 0;
    font-size: var(--rk-fs-sm);
}

.rk-map-card__meta {
    display: block;
    margin-top: 2px;
    color: var(--rk-subtle);
    font-size: var(--rk-fs-xs);
}

@keyframes rk-halo {
    0% {
        opacity: .9;
        transform: scale(.5);
    }

    100% {
        opacity: 0;
        transform: scale(3.4);
    }
}

@keyframes rk-shimmer {
    from {
        background-position: 200% 0;
    }

    to {
        background-position: -200% 0;
    }
}

@keyframes rk-spin {
    to {
        transform: rotate(360deg);
    }
}

@media (max-width: 991.98px) {
    .rk-mapmode {
        grid-template-columns: minmax(0, 1fr);
        grid-template-rows: none;
        grid-template-areas:
            "controls"
            "stage"
            "results";
    }

    .rk-mapmode__controls {
        padding: 20px 16px 18px;
        border-right: 0;
    }

    .rk-mapmode__stage {
        position: relative;
        top: auto;
        height: 58vh;
        height: 58svh;
        min-height: 340px;
    }

    .rk-mapmode__results {
        padding: 0 16px 40px;
        border-right: 0;
    }

    .rk-mapmode__summary {
        margin: 0 -16px 14px;
        padding: 12px 16px;
        border-top: 0;
    }

    .rk-radius {
        top: 12px;
        right: 12px;
        left: 12px;
        transform: none;
    }

    .rk-radius__label {
        padding: 0 4px 0 8px;
    }

    .rk-radius__opt {
        flex: 1;
    }

    .rk-radius__opt span {
        min-width: 0;
        padding: 0 4px;
    }

    .rk-mapmode__hint {
        bottom: 12px;
        left: 12px;
    }
}

@media (max-width: 575.98px) {
    .rk-mapitem {
        grid-template-columns: 108px minmax(0, 1fr);
        gap: 12px;
    }

    .rk-mapitem__media,
    .rk-mapitem--skeleton .rk-mapitem__body {
        height: 104px;
    }
}

/* ---------- ฟอร์มลงประกาศ / แก้ไขประกาศ ---------- */

.rk-form-section.row {
    margin: 0 0 20px;
    padding: 24px 16px 8px;
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: var(--rk-radius-lg);
    scroll-margin-top: calc(var(--rk-header-h) + 20px);
}

.rk-form-section > hr,
.rk-apt-form > hr {
    display: none;
}

.rk-form-section__title {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0;
    font-size: var(--rk-fs-lg);
}

.rk-form-section__title span {
    display: grid;
    place-items: center;
    flex: none;
    width: 32px;
    height: 32px;
    color: #fff;
    background: var(--rk-carbon);
    border-radius: 50%;
    font-size: var(--rk-fs-sm);
}

.rk-field-error {
    display: inline-block;
    margin-top: 6px;
    color: var(--bs-danger);
    font-size: var(--rk-fs-sm);
    font-weight: 500;
}

.rk-apt-form .card {
    border-color: var(--rk-line);
    border-radius: 16px;
    box-shadow: none;
}

.rk-apt-form .card-header {
    padding: 12px 18px;
    background: var(--rk-canvas);
    border-bottom: 1px solid var(--rk-line);
    border-radius: 16px 16px 0 0;
}

.rk-apt-form .card-title {
    margin-bottom: 14px;
    font-size: var(--rk-fs-base);
    font-weight: 600;
}

.rk-apt-form hr.dashed-hr {
    margin: 12px 0;
    border: 0;
    border-top: 1px dashed var(--rk-line-strong);
    opacity: 1;
}

.rk-apt-form .form-check-label {
    color: var(--rk-text);
}

/* ภาพหน้าปก: คลิกทั้งกล่องเพื่อเลือกไฟล์ */
.rk-cover-picker {
    position: relative;
    display: block;
    width: 100%;
    max-width: 560px;
    overflow: hidden;
    aspect-ratio: 16 / 10;
    background: var(--rk-stone);
    border: 1px dashed var(--rk-line-strong);
    border-radius: 18px;
    cursor: pointer;
}

.rk-cover-picker input[type="file"] {
    position: absolute;
    inset: 0;
    z-index: 2;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.rk-cover-picker img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.rk-cover-picker__hint {
    position: absolute;
    right: 12px;
    bottom: 12px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 7px 14px;
    color: var(--rk-ink);
    background: rgba(255, 255, 255, .92);
    border-radius: 999px;
    box-shadow: var(--rk-shadow-sm);
    font-size: var(--rk-fs-sm);
    font-weight: 500;
    pointer-events: none;
}

.rk-cover-picker:hover {
    border-color: var(--rk-ink);
}

.rk-cover-picker:focus-within {
    box-shadow: var(--rk-ring);
}

/* แผนที่ปักหมุดตำแหน่ง */
.rk-map-picker {
    display: grid;
    gap: 10px;
}

.rk-map-picker__map {
    z-index: 0;
    height: min(56vh, 460px);
    min-height: 320px;
    overflow: hidden;
    background: var(--rk-stone);
    border: 1px solid var(--rk-line);
    border-radius: 16px;
}

.rk-map-picker__hint {
    margin: 0;
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

/* กล่องลากวางรูปภาพ */
.rk-apt-form .card.rk-dropzone {
    background: var(--rk-canvas);
    border: 1px dashed var(--rk-line-strong);
}

.rk-dropzone #dropzone {
    min-height: 180px;
    padding: 12px;
    color: var(--rk-muted);
}

.rk-dropzone #condition_pic {
    align-self: center;
    padding: 28px 12px;
}

.rk-dropzone__icon {
    display: block;
    margin-bottom: 12px;
    color: var(--rk-line-strong);
    font-size: var(--rk-fs-3xl);
}

.rk-dropzone__text {
    color: var(--rk-ink);
    font-weight: 500;
}

.rk-dropzone__sub {
    margin-top: 2px;
    font-size: var(--rk-fs-sm);
}

.rk-dropzone .img-thumbnail {
    padding: 0;
    border: 0;
    border-radius: 12px;
}

/* แถบปุ่มส่งฟอร์มติดด้านล่างจอ */
.rk-form-actions {
    position: sticky;
    bottom: 12px;
    z-index: 5;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px 20px;
    margin-top: 8px;
    padding: 14px 16px 14px 22px;
    color: var(--rk-muted);
    background: rgba(255, 255, 255, .96);
    border: 1px solid var(--rk-line);
    border-radius: 999px;
    box-shadow: var(--rk-shadow);
    font-size: var(--rk-fs-sm);
    backdrop-filter: blur(8px);
}

@media (max-width: 575.98px) {
    .rk-form-actions {
        bottom: 8px;
        padding: 8px;
        border-radius: 999px;
    }

    .rk-form-actions p {
        display: none;
    }

    .rk-form-actions .btn {
        width: 100%;
    }

    .rk-form-section.row {
        padding: 18px 4px 4px;
    }

    .rk-apt-form .card-body {
        padding: 14px;
    }
}

/* เมนูขั้นตอนด้านข้าง (Bootstrap ScrollSpy ใส่ .active ให้เอง) */
.rk-steps {
    display: grid;
    gap: 2px;
    padding: 16px;
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: var(--rk-radius-lg);
}

.rk-steps__title {
    margin: 0 0 8px 6px;
    color: var(--rk-subtle);
    font-size: var(--rk-fs-sm);
    font-weight: 600;
    letter-spacing: .02em;
}

.rk-steps a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 9px 10px;
    color: var(--rk-muted);
    border-radius: 12px;
    font-weight: 500;
    transition: background-color .18s var(--rk-ease), color .18s var(--rk-ease);
}

.rk-steps a span {
    display: grid;
    place-items: center;
    flex: none;
    width: 26px;
    height: 26px;
    color: var(--rk-muted);
    background: var(--rk-stone);
    border-radius: 50%;
    font-size: var(--rk-fs-sm);
    transition: inherit;
}

.rk-steps a:hover {
    color: var(--rk-ink);
    background: var(--rk-canvas);
}

.rk-steps a.active {
    color: var(--rk-ink);
    background: var(--rk-stone);
}

.rk-steps a.active span {
    color: #fff;
    background: var(--rk-scarlet);
}

/* ---------- เมนูข้างของหน้าสมาชิก ---------- */

.rk-side-menu {
    display: grid;
    gap: 2px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.rk-side-menu a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 14px;
    border-radius: 12px;
    color: var(--rk-text);
    font-weight: 500;
}

.rk-side-menu a i {
    width: 18px;
    color: var(--rk-subtle);
    text-align: center;
}

.rk-side-menu a:hover {
    color: var(--rk-ink);
    background: var(--rk-stone);
}

.rk-side-menu li.active a {
    color: var(--rk-ink);
    background: var(--rk-stone);
}

.rk-side-menu li.active a i {
    color: var(--rk-scarlet);
}

.rk-side-menu__sep {
    margin-top: 6px;
    padding-top: 6px;
    border-top: 1px solid var(--rk-line);
}

/* ---------- หน้าสมาชิก (ประกาศของฉัน / ข้อมูลของฉัน) ---------- */

.rk-account-nav {
    position: sticky;
    top: calc(var(--rk-header-h) + 20px);
    padding: 16px;
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: var(--rk-radius-lg);
}

.rk-account-nav__user {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
    padding: 4px 4px 16px;
    border-bottom: 1px solid var(--rk-line);
}

.rk-account-nav__avatar {
    display: grid;
    place-items: center;
    flex: none;
    width: 46px;
    height: 46px;
    color: #fff;
    background: var(--rk-carbon);
    border-radius: 50%;
    font-size: var(--rk-fs-md);
    font-weight: 600;
}

.rk-account-nav__name {
    color: var(--rk-ink);
    font-weight: 600;
    line-height: 1.4;
}

.rk-account-nav__meta {
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.min-w-0 {
    min-width: 0;
}

@media (max-width: 991.98px) {
    .rk-account-nav {
        position: static;
        padding: 12px;
    }

    .rk-account-nav__user {
        margin-bottom: 10px;
        padding-bottom: 12px;
    }

    .rk-account-nav .rk-side-menu {
        display: flex;
        gap: 6px;
        overflow-x: auto;
        scrollbar-width: none;
    }

    .rk-account-nav .rk-side-menu::-webkit-scrollbar {
        display: none;
    }

    .rk-account-nav .rk-side-menu a {
        padding: 8px 12px;
        white-space: nowrap;
    }

    .rk-account-nav .rk-side-menu__sep {
        margin: 0;
        padding: 0;
        border: 0;
    }
}

.rk-my-list {
    display: grid;
    gap: 14px;
}

.rk-my-item {
    display: grid;
    grid-template-columns: 180px minmax(0, 1fr) auto;
    align-items: center;
    gap: 22px;
    padding: 14px;
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: var(--rk-radius-lg);
    transition: border-color .2s var(--rk-ease), box-shadow .2s var(--rk-ease);
}

.rk-my-item:hover {
    border-color: var(--rk-line-strong);
    box-shadow: var(--rk-shadow-sm);
}

.rk-my-item__media {
    display: block;
    overflow: hidden;
    aspect-ratio: 4 / 3;
    background: var(--rk-stone);
    border-radius: 14px;
}

.rk-my-item__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.rk-my-item__top {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 14px;
    margin-bottom: 8px;
}

.rk-my-item__views {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--rk-subtle);
    font-size: var(--rk-fs-sm);
}

.rk-my-item__title {
    margin: 0 0 4px;
    font-size: var(--rk-fs-md);
    line-height: 1.4;
}

.rk-my-item__title a {
    color: var(--rk-ink);
}

.rk-my-item__title a:hover {
    color: var(--rk-scarlet-ui);
}

.rk-my-item__loc {
    display: flex;
    gap: 8px;
    margin: 0 0 8px;
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-my-item__loc i {
    margin-top: .3em;
    color: var(--rk-subtle);
    font-size: var(--rk-fs-sm);
}

.rk-my-item__actions {
    display: grid;
    gap: 8px;
    align-self: center;
}

@media (max-width: 767.98px) {
    .rk-my-item {
        grid-template-columns: minmax(0, 1fr);
        gap: 14px;
    }

    .rk-my-item__media {
        aspect-ratio: 16 / 9;
    }

    .rk-my-item__actions {
        grid-auto-flow: column;
        grid-auto-columns: 1fr;
    }
}

.rk-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: var(--rk-fs-sm);
    font-weight: 600;
}

.rk-status--live {
    color: #17613F;
    background: #E6F2EC;
}

.rk-status--pending {
    color: #8A5A00;
    background: #FFF4DB;
}

.rk-status--rejected {
    color: var(--rk-scarlet-ui);
    background: var(--rk-scarlet-tint);
}

.rk-panel {
    margin-bottom: 20px;
    padding: clamp(20px, 3vw, 32px);
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: var(--rk-radius-lg);
}

.rk-panel__head {
    margin-bottom: 22px;
}

.rk-panel__title {
    margin: 0 0 4px;
    font-size: var(--rk-fs-md);
}

.rk-panel__lead {
    margin: 0;
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-notice {
    display: flex;
    gap: 14px;
    padding: 16px 18px;
    border-radius: 16px;
}

.rk-notice > i {
    margin-top: .25em;
    font-size: var(--rk-fs-md);
}

.rk-notice b {
    display: block;
    margin-bottom: 4px;
    color: var(--rk-ink);
}

.rk-notice p {
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-notice--success {
    background: #EEF6F1;
    border: 1px solid #CFE5D8;
}

.rk-notice--success > i {
    color: var(--rk-success);
}

/* ---------- หน้า auth แบบการ์ดกลางจอ ---------- */

.rk-auth {
    max-width: 480px;
    margin: 0 auto;
}

.rk-auth__card {
    padding: clamp(24px, 4vw, 40px);
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: var(--rk-radius-lg);
    box-shadow: var(--rk-shadow-sm);
}

.rk-auth__icon {
    display: grid;
    place-items: center;
    width: 56px;
    height: 56px;
    margin: 0 auto 18px;
    border-radius: 16px;
    color: var(--rk-scarlet);
    background: var(--rk-stone);
    font-size: var(--rk-fs-xl);
}

.rk-auth__title {
    margin: 0 0 6px;
    font-size: var(--rk-fs-xl);
    text-align: center;
}

.rk-auth__lead {
    margin: 0 0 24px;
    color: var(--rk-muted);
    text-align: center;
}

.rk-auth--done {
    max-width: 440px;
}

.rk-auth__icon--success {
    color: #fff;
    background: var(--rk-success);
    border-radius: 50%;
}

.rk-auth__foot {
    margin: 20px 0 0;
    color: var(--rk-muted);
    text-align: center;
}

.rk-auth__back {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 16px;
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-auth__back:hover {
    color: var(--rk-ink);
}

.rk-auth__otp {
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid var(--rk-line);
}

/* ช่อง OTP ตัวใหญ่ เว้นระยะตัวเลข */
.rk-otp {
    min-height: 60px;
    font-size: var(--rk-fs-xl);
    font-weight: 600;
    letter-spacing: .5em;
    text-align: center;
    text-indent: .5em; /* ชดเชยระยะหลังตัวสุดท้าย ให้ตัวเลขอยู่กลางจริง */
    font-variant-numeric: tabular-nums;
}

.rk-otp::placeholder {
    color: var(--rk-line-strong);
    letter-spacing: .4em;
}

/* ข้อความ error ของ jquery-validate */
.rk-auth label.error {
    display: block;
    margin-top: 6px;
    color: var(--bs-danger);
    font-size: var(--rk-fs-sm);
}

.rk-auth input.error {
    border-color: var(--bs-danger);
}

/* ตัวเลือกแบบการ์ด (radio) */
.rk-choice {
    display: grid;
    gap: 10px;
    margin: 0;
    padding: 0;
    border: 0;
}

.rk-choice__item {
    display: grid;
    grid-template-columns: auto auto minmax(0, 1fr);
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    border: 1px solid var(--rk-line);
    border-radius: 14px;
    cursor: pointer;
    transition: border-color .18s var(--rk-ease), background-color .18s var(--rk-ease);
}

.rk-choice__item:hover {
    border-color: var(--rk-line-strong);
}

.rk-choice__item:has(input:checked) {
    background: var(--rk-canvas);
    border-color: var(--rk-ink);
    box-shadow: 0 0 0 1px var(--rk-ink);
}

.rk-choice__item .form-check-input {
    margin: 0;
}

.rk-choice__item > i {
    width: 22px;
    color: var(--rk-muted);
    font-size: var(--rk-fs-md);
    text-align: center;
}

.rk-choice__item b {
    display: block;
    color: var(--rk-ink);
    font-weight: 600;
}

.rk-choice__item small {
    color: var(--rk-muted);
}

/* ---------- หลังบ้าน (Backoffice) ---------- */

.rk-admin {
    --rk-admin-side: 264px;
    background: var(--rk-canvas);
}

.rk-admin-side {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 1040;
    width: var(--rk-admin-side);
    padding: 22px 14px;
    overflow-y: auto;
    color: #C9C9C9;
    background: var(--rk-carbon);
}

.rk-admin-offcanvas {
    --bs-offcanvas-width: 280px;
    --bs-offcanvas-bg: var(--rk-carbon);
    --bs-offcanvas-color: #C9C9C9;
}

.rk-admin-side__brand {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin: 0 10px 22px;
}

.rk-admin-side__brand img {
    width: 150px;
    height: auto;
}

.rk-admin-side__brand span {
    color: rgba(255, 255, 255, .45);
    font-size: var(--rk-fs-xs);
    font-weight: 600;
    letter-spacing: .16em;
    text-transform: uppercase;
}

.rk-admin-nav {
    display: grid;
    gap: 2px;
}

.rk-admin-nav__group {
    margin: 18px 12px 6px;
    color: rgba(255, 255, 255, .4);
    font-size: var(--rk-fs-xs);
    font-weight: 600;
    letter-spacing: .04em;
}

.rk-admin-nav__link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    color: #C9C9C9;
    border-radius: 10px;
    font-size: var(--rk-fs-base);
    transition: background-color .18s var(--rk-ease), color .18s var(--rk-ease);
}

.rk-admin-nav__link i {
    width: 18px;
    color: rgba(255, 255, 255, .45);
    text-align: center;
}

.rk-admin-nav__link:hover {
    color: #fff;
    background: rgba(255, 255, 255, .06);
}

.rk-admin-nav__link.active {
    color: #fff;
    background: rgba(255, 255, 255, .1);
    box-shadow: inset 3px 0 0 var(--rk-scarlet);
}

.rk-admin-nav__link.active i {
    color: var(--rk-ember);
}

.rk-admin-top {
    position: sticky;
    top: 0;
    z-index: 1030;
    display: flex;
    align-items: center;
    gap: 14px;
    height: 64px;
    margin-left: var(--rk-admin-side);
    padding: 0 clamp(16px, 3vw, 36px);
    background: rgba(255, 255, 255, .92);
    border-bottom: 1px solid var(--rk-line);
    backdrop-filter: blur(10px);
}

.rk-admin-top__site {
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-admin-top__site:hover {
    color: var(--rk-ink);
}

.rk-admin-top__user {
    display: flex;
    align-items: center;
    gap: 10px;
    max-width: 280px;
    padding: 4px 12px 4px 4px;
    color: var(--rk-ink);
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: 999px;
    font-weight: 500;
}

.rk-admin-top__user .rk-account-nav__avatar {
    width: 32px;
    height: 32px;
    font-size: var(--rk-fs-sm);
}

.rk-admin-main {
    margin-left: var(--rk-admin-side);
    padding: 28px clamp(16px, 3vw, 36px) 56px;
}

@media (max-width: 991.98px) {
    #sidebar {
        display: none;
    }

    .rk-admin-top,
    .rk-admin-main {
        margin-left: 0;
    }
}

.rk-admin-head {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 22px;
}

.rk-admin-title {
    margin: 0 0 4px;
    font-size: var(--rk-fs-title);
}

.rk-admin-lead {
    margin: 0;
    color: var(--rk-muted);
}

.rk-admin-subtitle {
    margin: 34px 0 14px;
    font-size: var(--rk-fs-md);
}

.rk-admin .card {
    overflow: hidden;
    border: 1px solid var(--rk-line);
    border-radius: 18px;
    box-shadow: none;
}

.rk-admin .card-header {
    padding: 16px 22px;
    color: var(--rk-ink);
    background: #fff;
    border-bottom: 1px solid var(--rk-line);
    font-size: var(--rk-fs-base);
}

.rk-admin .card-header b {
    font-weight: 600;
}

.rk-admin .card-body {
    padding: 22px;
}

.rk-admin .card-footer {
    padding: 16px 22px;
    background: var(--rk-canvas);
    border-top: 1px solid var(--rk-line);
}

.rk-admin .card-title.text-end {
    margin-bottom: 18px;
}

/* ตารางในหลังบ้าน: ไม่มีเส้นแนวตั้ง ไม่สลับสี แถวชี้แล้วไฮไลต์ */
.rk-admin .table {
    --bs-table-bg: transparent;
    --bs-table-striped-bg: transparent;
    --bs-table-hover-bg: var(--rk-canvas);
    margin-bottom: 0;
    color: var(--rk-text);
}

.rk-admin .table > thead th,
.rk-admin .table > thead td {
    padding: 12px 14px;
    color: var(--rk-subtle);
    background: var(--rk-canvas);
    border-bottom: 1px solid var(--rk-line);
    font-size: var(--rk-fs-sm);
    font-weight: 600;
    letter-spacing: .02em;
    white-space: nowrap;
}

.rk-admin .table > tbody > tr > * {
    padding: 14px;
    border-color: var(--rk-line);
}

.rk-admin .table > tbody > tr:hover > * {
    --bs-table-accent-bg: var(--rk-canvas);
}

.rk-admin .table-bordered > :not(caption) > * {
    border-width: 0;
}

.rk-admin .table-bordered > :not(caption) > * > * {
    border-width: 0 0 1px;
}

/* DataTables ใส่แถบสลับสีด้วย box-shadow และกรอบนอกเอง ปิดให้เข้ากับตารางหลังบ้าน */
.rk-admin table.dataTable,
.rk-admin table.table-bordered {
    border: 0 !important;
}

.rk-admin table.dataTable > tbody > tr > *,
.rk-admin table.dataTable.table-striped > tbody > tr.odd > *,
.rk-admin table.dataTable.table-striped > tbody > tr:nth-of-type(2n+1) > * {
    box-shadow: none !important;
}

.rk-admin table.dataTable.table-bordered > :not(caption) > * > * {
    border-width: 0 0 1px !important;
}

.rk-admin table.dataTable > tbody > tr:hover > * {
    background: var(--rk-canvas);
}

.rk-admin .table .btn {
    white-space: nowrap;
}

.rk-table__thumb {
    width: 120px;
    height: 84px;
    object-fit: cover;
    background: var(--rk-stone);
    border-radius: 10px;
}

.rk-admin .dataTables_wrapper .dataTables_filter {
    float: right;
    margin-bottom: 16px;
    text-align: right;
}

.rk-admin .dataTables_wrapper .dataTables_filter input {
    min-height: 40px;
    margin-left: 8px;
}

.rk-admin .dataTables_wrapper .dataTables_length select {
    display: inline-block;
    width: auto;
    min-height: 40px;
}

.rk-admin .dataTables_wrapper .dataTables_info {
    padding-top: 14px;
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-stat-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
}

.rk-stat {
    display: grid;
    gap: 2px;
    padding: 20px;
    color: var(--rk-text);
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: 18px;
    transition: border-color .2s var(--rk-ease), box-shadow .2s var(--rk-ease);
}

.rk-stat:hover {
    color: var(--rk-text);
    border-color: var(--rk-line-strong);
    box-shadow: var(--rk-shadow-sm);
}

.rk-stat__icon {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    margin-bottom: 12px;
    color: var(--rk-ink);
    background: var(--rk-stone);
    border-radius: 12px;
}

.rk-stat--pending .rk-stat__icon {
    color: #8A5A00;
    background: #FFF4DB;
}

.rk-stat--live .rk-stat__icon {
    color: #17613F;
    background: #E6F2EC;
}

.rk-stat__value {
    color: var(--rk-ink);
    font-size: var(--rk-fs-2xl);
    font-weight: 600;
    line-height: 1.2;
    font-variant-numeric: tabular-nums;
}

.rk-stat__label {
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

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

.rk-shortcut {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 16px;
    padding: 18px 20px;
    color: var(--rk-text);
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: 16px;
    transition: border-color .2s var(--rk-ease);
}

.rk-shortcut > i:first-child {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    color: var(--rk-ink);
    background: var(--rk-stone);
    border-radius: 12px;
}

.rk-shortcut b {
    display: block;
    color: var(--rk-ink);
    font-weight: 600;
}

.rk-shortcut small {
    color: var(--rk-muted);
}

.rk-shortcut__go {
    color: var(--rk-subtle);
    transition: transform .2s var(--rk-ease), color .2s var(--rk-ease);
}

.rk-shortcut:hover {
    color: var(--rk-text);
    border-color: var(--rk-ink);
}

.rk-shortcut:hover .rk-shortcut__go {
    color: var(--rk-ink);
    transform: translateX(3px);
}

@media (max-width: 991.98px) {
    .rk-stat-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 767.98px) {
    .rk-shortcut-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

/* หน้า login หลังบ้าน */
.rk-admin-login {
    min-height: 100vh;
    background: var(--rk-canvas);
}

.rk-admin-login__wrap {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    min-height: 100vh;
}

.rk-admin-login__brand {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 22px;
    padding: 48px;
    color: rgba(255, 255, 255, .55);
    background:
        radial-gradient(circle at 20% 15%, rgba(240, 43, 36, .22), transparent 42%),
        radial-gradient(circle at 85% 90%, rgba(255, 100, 45, .14), transparent 40%),
        var(--rk-carbon);
}

.rk-admin-login__brand img {
    width: 240px;
    height: auto;
}

.rk-admin-login__brand p {
    margin: 0;
    font-size: var(--rk-fs-base);
    letter-spacing: .08em;
}

.rk-admin-login__form {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px 20px;
}

.rk-admin-login__card {
    width: 100%;
    max-width: 400px;
}

.rk-admin-login__logo {
    display: none;
    width: 164px;
    height: auto;
    margin-bottom: 28px;
}

@media (max-width: 767.98px) {
    .rk-admin-login__wrap {
        grid-template-columns: minmax(0, 1fr);
    }

    .rk-admin-login__brand {
        display: none;
    }

    .rk-admin-login__logo {
        display: block;
    }
}

/* ---------- หน้า error ---------- */

.rk-error {
    display: grid;
    place-items: center;
    min-height: 100vh;
    padding: 32px 16px;
    background:
        radial-gradient(circle at 50% 0%, rgba(240, 43, 36, .08), transparent 55%),
        var(--rk-canvas);
}

.rk-error__card {
    width: 100%;
    max-width: 520px;
    text-align: center;
}

.rk-error__logo img {
    width: 150px;
    height: auto;
}

.rk-error__code {
    margin: 36px 0 4px;
    color: var(--rk-ink);
    font-size: clamp(5rem, 16vw, 8rem);
    font-weight: 300;
    line-height: 1;
    letter-spacing: -.04em;
    font-variant-numeric: tabular-nums;
}

.rk-error__code::after {
    content: "";
    display: block;
    width: 48px;
    height: 3px;
    margin: 18px auto 0;
    background: var(--rk-scarlet);
    border-radius: 3px;
}

.rk-error__title {
    margin: 22px 0 8px;
    font-size: var(--rk-fs-xl);
}

.rk-error__text {
    margin: 0 auto 28px;
    max-width: 420px;
    color: var(--rk-muted);
}

.rk-error__actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
}

/* ---------- ดาวรีวิว ---------- */

.stars i,
.rk-stars i {
    color: var(--rk-ember);
}

/* ---------- ยูทิลิตีเล็ก ๆ ---------- */

.rk-divider {
    height: 1px;
    margin: 28px 0;
    background: var(--rk-line);
    border: 0;
}

.rk-kicker {
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        transition: none !important;
        animation: none !important;
    }
}

/* ---------- แถบราคา/ติดต่อติดขอบล่างบนมือถือ (หน้าประกาศ) QC M02 29/09/2026 ---------- */

.rk-mobile-cta {
    position: fixed;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 1030;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
    background: rgba(255, 255, 255, .96);
    border-top: 1px solid var(--rk-line);
    box-shadow: 0 -8px 30px rgba(23, 23, 25, .08);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    transition: transform .3s var(--rk-ease);
}

.rk-mobile-cta.is-hidden {
    transform: translateY(110%);
}

.rk-mobile-cta__price {
    flex: 1;
    min-width: 0;
    line-height: 1.2;
}

.rk-mobile-cta__price b {
    display: block;
    overflow: hidden;
    color: var(--rk-scarlet-ui);
    font-size: var(--rk-fs-lg);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rk-mobile-cta__price span {
    color: var(--rk-muted);
    font-size: var(--rk-fs-xs);
}

.rk-mobile-cta .dropdown-menu {
    min-width: 220px;
}

@media (max-width: 991.98px) {
    .rk-has-mobile-cta {
        padding-bottom: 84px;
    }
}

/* ---------- หน้าแรกบนจอเล็ก: การ์ดเป็นแถวเลื่อนแนวนอน และสารบัญเป็น accordion (QC M03) ---------- */

@media (max-width: 575.98px) {
    .rk-listing-grid--carousel {
        display: flex;
        gap: 12px;
        margin: 0 -16px;
        padding: 4px 16px 12px;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        scrollbar-width: none;
    }

    .rk-listing-grid--carousel::-webkit-scrollbar {
        display: none;
    }

    .rk-listing-grid--carousel > .rk-listing {
        flex: 0 0 78%;
        scroll-snap-align: start;
    }
}

details.rk-dir-group > summary {
    cursor: pointer;
    list-style: none;
}

details.rk-dir-group > summary::-webkit-details-marker {
    display: none;
}

.rk-dir-group__count {
    margin-left: auto;
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
    font-weight: 500;
}

@media (max-width: 767.98px) {
    details.rk-dir-group > summary::after {
        content: "\f078";
        margin-left: 8px;
        color: var(--rk-subtle);
        font-family: "Font Awesome 6 Free";
        font-size: var(--rk-fs-xs);
        font-weight: 900;
        transition: transform .2s var(--rk-ease);
    }

    details.rk-dir-group[open] > summary::after {
        transform: rotate(180deg);
    }
}

@media (min-width: 768px) {
    details.rk-dir-group > summary {
        pointer-events: none;
    }
}

/* ---------- หน้าแรก: การ์ดที่พัก 4 ใบต่อแถว แบบกระชับ (เจ้าของ 29/09/2026 ต้องการเห็น 4×3) ---------- */

@media (min-width: 1200px) {
    .rk-listing-grid--4 {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 20px;
    }

    :is(.rk-listing-grid--4, .rk-listing-grid--3) .rk-listing__media {
        aspect-ratio: 3 / 2;
    }

    :is(.rk-listing-grid--4, .rk-listing-grid--3) .rk-listing__body {
        gap: 4px;
        padding: 14px 16px;
    }

    :is(.rk-listing-grid--4, .rk-listing-grid--3) .rk-listing__title {
        font-size: var(--rk-fs-base);
    }

    :is(.rk-listing-grid--4, .rk-listing-grid--3) .rk-listing__loc,
    :is(.rk-listing-grid--4, .rk-listing-grid--3) .rk-listing__price small {
        font-size: var(--rk-fs-xs);
    }

    :is(.rk-listing-grid--4, .rk-listing-grid--3) .rk-listing__price b {
        font-size: var(--rk-fs-lg);
    }

    :is(.rk-listing-grid--4, .rk-listing-grid--3) .rk-listing__promo {
        display: block;
        margin: 4px 0 8px;
        padding: 6px 10px;
        overflow: hidden;
        font-size: var(--rk-fs-xs);
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    :is(.rk-listing-grid--4, .rk-listing-grid--3) .rk-listing__foot {
        padding-top: 10px;
        font-size: var(--rk-fs-xs);
    }
}

/* ---------- การ์ดที่พัก: แถบข้อมูลย่อย ราคา + ขนาดห้อง (เจ้าของ 29/09/2026) ---------- */

.rk-listing__strip {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    margin-top: 6px;
}

.rk-listing__tile {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0 6px;
    min-width: 0;
    padding: 7px 10px;
    background: var(--rk-canvas);
    border: 1px solid var(--rk-line);
    border-radius: 10px;
    line-height: 1.25;
}

.rk-listing__tile small {
    color: var(--rk-muted);
    font-size: var(--rk-fs-xs);
}

.rk-listing__tile b {
    color: var(--rk-ink);
    font-size: var(--rk-fs-md);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.rk-listing__tile span {
    color: var(--rk-muted);
    font-size: var(--rk-fs-xs);
}

.rk-listing__tile strong {
    color: var(--rk-ink);
    font-size: var(--rk-fs-sm);
    font-weight: 700;
}

.rk-listing__tile--price {
    background: var(--rk-scarlet-tint);
    border-color: rgba(209, 31, 25, .18);
}

.rk-listing__tile--price b {
    color: var(--rk-scarlet-ui);
    font-size: var(--rk-fs-lg);
}

/* ---------- Hero กระชับลง (เจ้าของ 29/09/2026) คงเอฟเฟกต์เดิมตามที่สั่ง ---------- */

.rk-hero {
    padding: clamp(28px, 3.2vw, 44px) 0 clamp(24px, 3vw, 36px);
}

.rk-hero__layout {
    gap: 32px;
}

.rk-hero__title {
    margin: 16px 0 12px;
    font-size: clamp(2rem, 3.2vw, 3rem);
}

.rk-hero__lead {
    max-width: 520px;
    font-size: var(--rk-fs-base);
    line-height: 1.6;
}

.rk-hero__showcase {
    max-width: 460px;
    height: 340px;
}

.rk-showcase__main {
    height: 300px;
}

.rk-showcase__mini {
    top: 36%;
    width: 220px;
}

.rk-search {
    margin-top: clamp(20px, 2.6vw, 28px);
}

.rk-hero__stats {
    margin-top: 20px;
}

.rk-hero__stats strong {
    font-size: var(--rk-fs-lg);
}

@media (max-width: 575.98px) {
    .rk-hero__title {
        font-size: var(--rk-fs-display-sm);
    }
}

/* ---------- ปุ่มค้นหาบนแผนที่ใน hero เป็น CTA ชัดเจน + สถิติย้ายมาใต้ lead (เจ้าของ 29/09/2026) ---------- */

.rk-hero__copy .rk-hero__stats {
    margin-top: 22px;
}

.rk-showcase__radar--cta {
    right: 12px;
    bottom: -10px;
    padding: 12px 22px 12px 12px;
    color: var(--rk-ink);
    background: #fff;
    border: 2px solid var(--rk-scarlet-ui);
    box-shadow: 0 18px 44px rgba(0, 0, 0, .38), 0 0 0 0 rgba(240, 43, 36, .5);
    animation: rk-float 7s ease-in-out infinite, rk-cta-pulse 2.2s ease-out infinite;
}

.rk-showcase__radar--cta:hover {
    color: var(--rk-ink);
    background: var(--rk-scarlet-tint);
    border-color: var(--rk-scarlet-ui-hover);
}

.rk-showcase__radar--cta b {
    color: var(--rk-scarlet-ui);
    font-size: var(--rk-fs-base);
}

.rk-showcase__radar--cta small {
    color: var(--rk-muted);
}

@keyframes rk-cta-pulse {
    0% { box-shadow: 0 18px 44px rgba(0, 0, 0, .38), 0 0 0 0 rgba(240, 43, 36, .55); }
    100% { box-shadow: 0 18px 44px rgba(0, 0, 0, .38), 0 0 0 16px rgba(240, 43, 36, 0); }
}

/* ---------- การ์ดที่พัก: สไลด์รูป ป้ายมีรายวัน และไอคอนสิ่งอำนวยความสะดวกหลัก (เจ้าของ 29/09/2026) ---------- */

.rk-slider .rk-slider__img {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity .5s var(--rk-ease), transform .7s var(--rk-ease);
}

.rk-slider .rk-slider__img.is-active {
    opacity: 1;
}

.rk-slider__btn {
    position: absolute;
    top: 50%;
    z-index: 2;
    display: inline-grid;
    place-items: center;
    width: 32px;
    height: 32px;
    color: var(--rk-ink);
    background: rgba(255, 255, 255, .92);
    border-radius: 50%;
    box-shadow: var(--rk-shadow-xs);
    opacity: 0;
    transform: translateY(-50%);
    transition: opacity .2s var(--rk-ease), background-color .2s var(--rk-ease);
    font-size: var(--rk-fs-xs);
}

.rk-slider__btn--prev {
    left: 10px;
}

.rk-slider__btn--next {
    right: 10px;
}

.rk-listing:hover .rk-slider__btn,
.rk-slider__btn:focus-visible {
    opacity: 1;
}

.rk-slider__btn:hover {
    background: #fff;
}

@media (hover: none) {
    .rk-slider__btn {
        opacity: 1;
    }
}

.rk-slider__count {
    position: absolute;
    right: 10px;
    bottom: 10px;
    z-index: 2;
    padding: 2px 8px;
    color: #fff;
    background: rgba(23, 23, 25, .55);
    border-radius: 999px;
    font-size: var(--rk-fs-xs);
    font-variant-numeric: tabular-nums;
}

.rk-tag--day {
    color: #9D174D;
    background: #FCE7F3;
}

.rk-listing__tile--facts {
    justify-content: space-between;
}

.rk-facts {
    display: inline-flex;
    gap: 10px;
    margin-left: auto;
}

.rk-facts i {
    position: relative;
    font-size: var(--rk-fs-base);
}

.rk-facts__air.is-on {
    color: #2563EB;
}

.rk-facts__wifi.is-on {
    color: var(--rk-success);
}

.rk-facts__car.is-on {
    color: var(--rk-ink);
}

.rk-facts i.is-off {
    color: var(--rk-line-strong);
}

.rk-facts i.is-off::after {
    content: "";
    position: absolute;
    top: 50%;
    right: -3px;
    left: -3px;
    height: 2px;
    background: var(--rk-scarlet-ui);
    border-radius: 2px;
    transform: rotate(-35deg);
}

/* ---------- การ์ดที่พัก: ช่องราคาและช่องห้องเรียงเป็น 2 แถวเต็มความกว้าง ไม่บีบกัน (29/09/2026) ---------- */

.rk-listing__strip {
    grid-template-columns: minmax(0, 1fr);
    gap: 6px;
}

.rk-listing__tile {
    flex-wrap: nowrap;
    justify-content: flex-start;
    gap: 0 6px;
    padding: 6px 10px;
    white-space: nowrap;
}

.rk-listing__tile--price small {
    margin-right: auto;
}

.rk-listing__tile--price b {
    font-size: var(--rk-fs-lg);
}

.rk-listing__tile--facts b {
    margin-right: 2px;
}

/* ---------- หน้าผลค้นหา: กระชับ โทนแบรนด์ การ์ด 3 ใบต่อแถว (เจ้าของ 29/09/2026) ---------- */

.rk-page--results {
    padding-top: 16px;
}

.rk-page--results .rk-crumbs {
    margin-bottom: 6px;
}

.rk-page--results .rk-results-head {
    align-items: center;
    gap: 8px 20px;
    margin-bottom: 12px;
}

/* หัวข้อแดงเข้ม (scarlet_ui_hover 6.99:1 บนขาว) ไม่แสบตาเท่า scarlet แบรนด์ */
.rk-results-title {
    color: var(--rk-scarlet-ui-hover);
    font-size: var(--rk-fs-title);
    letter-spacing: -.01em;
}

.rk-results-sub {
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

/* แท็บ รายเดือน/รายวัน โทนแบรนด์ */
.rk-segmented--brand {
    background: var(--rk-scarlet-tint);
    border: 1px solid #F6CBC7;
}

.rk-segmented--brand .nav-link {
    min-height: 44px;
    padding: .45rem 1rem;
    color: var(--rk-scarlet-ui-hover);
}

.rk-segmented--brand .nav-link .rk-count {
    color: var(--rk-scarlet-ui-hover);
    background: #fff;
}

.rk-segmented--brand .nav-link.active {
    color: #fff !important;
    background: var(--rk-scarlet-ui) !important;
}

/* กล่องทำเลใกล้เคียง: พื้นอุ่นอ่อนตัดกับพื้นขาว ป้ายกลุ่มสีแบรนด์ แถวกระชับ */
.rk-related-wrap {
    margin-bottom: 16px;
    padding: 2px 16px;
    background: linear-gradient(180deg, #FFF8F4, #FFF1EC);
    border: 1px solid #F8D6CD;
    border-radius: var(--rk-radius-lg);
}

.rk-related-wrap .rk-related {
    gap: 6px 12px;
    padding: 8px 0;
    border-top-color: rgba(209, 31, 25, .12);
}

.rk-related-wrap .rk-related:first-child {
    border-top: 0;
}

.rk-related-wrap .rk-related__label {
    flex-basis: 108px;
    color: var(--rk-scarlet-ui-hover);
    font-weight: 700;
}

.rk-related-wrap .rk-related__chips {
    gap: 6px;
}

.rk-related-wrap .rk-related__chips .rk-chip {
    padding: 4px 8px 4px 10px;
    border-color: #F1CFC8;
}

.rk-related-wrap .rk-related__chips .rk-chip:hover {
    color: var(--rk-scarlet-ui);
    border-color: var(--rk-scarlet-ui);
}

.rk-related-wrap .rk-chip .rk-count {
    min-width: 22px;
    padding: 0 6px;
    color: var(--rk-scarlet-ui-hover);
    background: var(--rk-scarlet-tint);
    font-size: var(--rk-fs-xs);
}

.rk-related-wrap .rk-toggle {
    color: var(--rk-scarlet-ui);
}

@media (max-width: 575.98px) {
    .rk-related-wrap {
        padding: 2px 12px;
    }

    .rk-related-wrap .rk-related__chips {
        margin-right: -12px;
    }
}

/* กริดผลค้นหา: 3 ใบต่อแถวใน col-9 (>=1200), 2 ใบใน col-8 (992-1199) ใช้สไตล์การ์ดกระชับชุดเดียวกับหน้าแรก */
@media (min-width: 992px) and (max-width: 1199.98px) {
    .rk-listing-grid--3 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 16px;
    }
}

@media (min-width: 1200px) {
    .rk-listing-grid--3 {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 16px;
    }
}

/* ตัวกรองด้านข้างกระชับ (ใช้เฉพาะหน้าผลค้นหา) */
.rk-filter {
    padding: 16px;
    border-radius: 16px;
}

.rk-filter__head {
    margin-bottom: 10px;
}

.rk-filter__section {
    padding: 12px 0;
}

.rk-filter__label {
    margin-bottom: 6px;
    font-size: var(--rk-fs-sm);
}

.rk-filter__check,
.rk-check-list .form-check {
    padding: 5px 0;
}

.rk-price-chart {
    height: 56px;
    margin-top: 4px;
}

.rk-filter .rk-slider {
    margin-bottom: 12px;
}

/* ---------- หน้าผลค้นหา: การ์ดแนวนอน รูปซ้าย ข้อมูลขวา (เจ้าของ 29/09/2026 ต้องการเห็นรายการมากขึ้นต่อจอ) ---------- */

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

.rk-listing-list .rk-listing {
    flex-direction: row;
    height: auto;
    border-radius: 16px;
}

.rk-listing-list .rk-listing:hover {
    border-color: rgba(209, 31, 25, .28);
    box-shadow: 0 12px 30px rgba(209, 31, 25, .10);
    transform: translateY(-2px);
}

.rk-listing-list .rk-listing__media {
    flex: 0 0 210px;
    width: 210px;
    min-height: 0; /* ปล่อยให้สูงเท่าเนื้อหาฝั่งขวา (min-height 140 เคยดันแถวเป็น 160) */
    aspect-ratio: auto;
}

.rk-listing-list .rk-listing__tags {
    top: 10px;
    right: 10px;
    left: 10px;
}

.rk-listing-list .rk-listing__body {
    gap: 3px;
    padding: 8px 14px;
}

.rk-listing-list .rk-listing__title {
    font-size: var(--rk-fs-md);
    line-height: 1.35;
    -webkit-line-clamp: 1;
}

.rk-listing-list .rk-listing__strip,
.rk-listing__strip--row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 4px;
}

.rk-listing-list .rk-listing__tile,
.rk-listing__strip--row .rk-listing__tile {
    flex: 0 1 auto;
    padding: 4px 12px;
}

.rk-listing-list .rk-listing__tile--price small,
.rk-listing__strip--row .rk-listing__tile--price small {
    margin-right: 6px;
}

.rk-listing-list .rk-listing__tile--price b {
    font-size: var(--rk-fs-xl);
}

.rk-listing-list .rk-listing__foot {
    margin-top: auto;
    padding-top: 6px;
    font-size: var(--rk-fs-xs);
}

@media (max-width: 575.98px) {
    .rk-listing-list .rk-listing__media {
        flex-basis: 132px;
        width: 132px;
        min-height: 0;
    }

    .rk-listing-list .rk-listing__body {
        padding: 8px 10px;
    }

    .rk-listing-list .rk-listing__title {
        font-size: var(--rk-fs-base);
    }

    .rk-listing-list .rk-listing__tile {
        padding: 4px 8px;
    }

    .rk-listing-list .rk-listing__tile--price b {
        font-size: var(--rk-fs-lg);
    }

    .rk-listing-list .rk-slider__btn {
        width: 26px;
        height: 26px;
    }
}

/* ---------- หน้าผลค้นหา: เอฟเฟกต์พรีเมียมแบบสบายตา (เจ้าของ 29/09/2026) ---------- */

/* แสงแดงวิ่งรอบกรอบตัวกรอง: วงแหวน 2px + แสงฟุ้งรอบนอก หมุนรอบละ 7 วินาที เฉพาะจอกว้าง */
@property --rk-angle {
    syntax: "<angle>";
    inherits: false;
    initial-value: 0deg;
}

@keyframes rk-glow-spin {
    to {
        --rk-angle: 360deg;
    }
}

@media (min-width: 992px) {
    .rk-filter--glow {
        isolation: isolate;
        border-color: transparent;
    }

    .rk-filter--glow::before {
        content: "";
        position: absolute;
        inset: -1px;
        z-index: -1;
        padding: 2px;
        border-radius: 17px;
        pointer-events: none;
        background: conic-gradient(from var(--rk-angle), rgba(209, 31, 25, .14) 0deg, rgba(209, 31, 25, .14) 250deg, rgba(240, 43, 36, .95) 320deg, #FF642D 345deg, rgba(209, 31, 25, .14) 360deg);
        -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
        -webkit-mask-composite: xor;
        mask-composite: exclude;
        animation: rk-glow-spin 7s linear infinite;
    }
}

/* กล่องทำเลใกล้เคียง: แสงขาวกวาดผ่านช้า ๆ ทุก 10 วินาที */
.rk-related-wrap {
    position: relative;
    overflow: hidden;
}

.rk-related-wrap::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background: linear-gradient(110deg, transparent 42%, rgba(255, 255, 255, .75) 50%, transparent 58%);
    background-size: 260% 100%;
    background-position: 130% 0;
    animation: rk-sheen 10s ease-in-out infinite;
}

@keyframes rk-sheen {
    0%, 55% {
        background-position: 130% 0;
    }

    100% {
        background-position: -130% 0;
    }
}

.rk-related-wrap .rk-chip {
    position: relative;
    z-index: 1;
    transition: transform .18s var(--rk-ease), box-shadow .18s var(--rk-ease), border-color .18s var(--rk-ease), color .18s var(--rk-ease);
}

.rk-related-wrap .rk-chip:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 14px rgba(209, 31, 25, .12);
}

/* แท็บที่เลือกมีเงาแดงนุ่ม หัวข้อไล่เฉดแดงเข้ม (ยังคง color #B01A15 สำหรับ contrast) */
.rk-segmented--brand .nav-link.active {
    box-shadow: 0 4px 14px rgba(209, 31, 25, .32);
}

.rk-results-title {
    width: fit-content;
    background: linear-gradient(90deg, #B01A15, #D11F19 55%, #B01A15);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* รายการในหน้าแผนที่: ป้ายและแถบราคา/ห้องแบบเดียวกับการ์ด */
.rk-mapitem__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 2px;
}

.rk-mapitem .rk-listing__strip {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 4px;
}

.rk-mapitem .rk-listing__tile {
    flex: 0 1 auto;
    padding: 4px 10px;
}

.rk-mapitem .rk-listing__tile--price b {
    font-size: var(--rk-fs-lg);
}

@media (prefers-reduced-motion: reduce) {
    .rk-filter--glow::before,
    .rk-related-wrap::after {
        animation: none;
    }
}

/* ---------- ผลค้นหา: แถบสลับมุมมอง แถว/ตาราง (เจ้าของ 29/09/2026: ให้ผู้ใช้เลือกเอง) ---------- */

.rk-results-bar {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    margin-bottom: 10px;
}

.rk-results-bar__label {
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-view-toggle {
    display: inline-flex;
    gap: 4px;
    padding: 3px;
    background: var(--rk-stone);
    border-radius: 999px;
}

.rk-view-toggle__btn {
    display: inline-grid;
    place-items: center;
    width: 44px;
    height: 36px;
    border: 0;
    border-radius: 999px;
    color: var(--rk-muted);
    background: transparent;
    font-size: var(--rk-fs-sm);
    transition: background-color .18s var(--rk-ease), color .18s var(--rk-ease);
}

.rk-view-toggle__btn:hover {
    color: var(--rk-ink);
}

.rk-view-toggle__btn[aria-pressed="true"] {
    color: var(--rk-scarlet-ui);
    background: #fff;
    box-shadow: var(--rk-shadow-xs);
}

/* ---------- หน้าแผนที่: หมุดราคาแดงตัวขาว tooltip ตอนชี้ sidebar กระชับ (เจ้าของ 29/09/2026) ---------- */

.rk-price-pin {
    padding: 5px 11px;
    color: #fff;
    background: var(--rk-scarlet-ui);
    box-shadow: 0 3px 10px rgba(209, 31, 25, .35), 0 0 0 2px #fff;
    font-weight: 700;
}

.rk-pin-wrap:hover .rk-price-pin,
.rk-pin-wrap.is-active .rk-price-pin,
.rk-pin-wrap:focus-visible .rk-price-pin {
    background: var(--rk-scarlet-ui-hover);
}

.rk-map-tip {
    padding: 8px 12px;
    color: var(--rk-ink);
    background: #fff;
    border: 0;
    border-radius: 12px;
    box-shadow: var(--rk-shadow);
    white-space: nowrap;
}

.rk-map-tip__body b {
    display: block;
    color: var(--rk-scarlet-ui);
    font-size: var(--rk-fs-lg);
    font-weight: 700;
    line-height: 1.2;
    font-variant-numeric: tabular-nums;
}

.rk-map-tip__body span {
    display: block;
    margin-top: 2px;
    color: var(--rk-ink);
    font-size: var(--rk-fs-base);
    font-weight: 600;
}

.rk-map-tip__body small {
    display: block;
    max-width: 220px;
    margin-top: 2px;
    overflow: hidden;
    color: var(--rk-muted);
    font-size: var(--rk-fs-xs);
    text-overflow: ellipsis;
}

@media (min-width: 992px) {
    .rk-mapmode__controls {
        gap: 10px;
        padding: 18px 24px 14px;
    }

    .rk-mapmode__title {
        font-size: var(--rk-fs-xl);
    }

    .rk-mapmode__lead {
        margin: -4px 0 0;
        font-size: var(--rk-fs-sm);
        line-height: 1.5;
    }

    .rk-mapmode__results {
        padding: 0 24px 40px;
    }

    .rk-mapmode__summary {
        margin: 0 -24px 12px;
        padding: 10px 24px;
    }

    .rk-mapmode__list {
        gap: 10px;
    }
}

/* ---------- หน้ารายละเอียดที่พัก: กระชับแบบ RentHub (เจ้าของ 03/10/2026) ---------- */

.rk-detail-head {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 10px 24px;
}

.rk-detail-head__main {
    flex: 1 1 520px;
    min-width: 0;
}

.rk-detail-head__tabs {
    flex: none;
}

.rk-detail-title {
    margin: 0 0 4px;
    font-size: var(--rk-fs-title);
}

.rk-badges {
    margin-top: 8px;
}

.rk-badge-soft {
    padding: 4px 10px;
    font-size: var(--rk-fs-xs);
}

/* แท็บสื่อ: รูปภาพ / แผนที่ ใช้พื้นที่เดียวกัน */
.rk-media {
    position: relative;
    margin-top: 14px;
}

.rk-media .rk-gallery {
    margin-top: 0;
}

.rk-media #mediaMap {
    position: relative;
}

.rk-map--hero {
    height: clamp(300px, 42vw, 520px);
    border-radius: 22px;
}

@media (max-width: 767.98px) {
    .rk-map--hero {
        height: 380px;
        border-radius: 18px;
    }
}

/* แถบนำทางส่วนของหน้า ติดใต้ header */
.rk-section-nav {
    position: sticky;
    top: var(--rk-header-h);
    z-index: 5;
    display: flex;
    gap: 4px;
    margin: 14px 0 0;
    padding: 6px 0;
    overflow-x: auto;
    background: rgba(251, 250, 248, .94);
    border-bottom: 1px solid var(--rk-line);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    scrollbar-width: none;
}

.rk-section-nav::-webkit-scrollbar {
    display: none;
}

.rk-section-nav a {
    flex: none;
    min-height: 36px;
    padding: 7px 14px;
    border-radius: 999px;
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
    font-weight: 600;
    white-space: nowrap;
}

.rk-section-nav a:hover {
    color: var(--rk-ink);
}

.rk-section-nav a.is-active {
    color: var(--rk-scarlet-ui);
    background: var(--rk-scarlet-tint);
}

.rk-block[id] {
    scroll-margin-top: 50px; /* html มี scroll-padding-top ชดเชย header อยู่แล้ว เพิ่มแค่ความสูงแถบนำทาง */
}

/* ส่วนเนื้อหาแน่นขึ้น */
.rk-block {
    padding: 20px 0;
}

.rk-block:first-child {
    padding-top: 4px;
}

.rk-block__title {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
    margin: 0 0 12px;
    font-size: var(--rk-fs-md);
}

.rk-block__hint {
    color: var(--rk-muted);
    font-size: var(--rk-fs-xs);
    font-weight: 500;
}

a.rk-block__hint:hover {
    color: var(--rk-scarlet-ui);
}

.rk-prose {
    line-height: 1.6;
}

.rk-prose h1,
.rk-prose h2,
.rk-prose h3,
.rk-prose h4 {
    margin: 12px 0 4px;
    font-size: var(--rk-fs-base);
    font-weight: 700;
}

.rk-prose p,
.rk-prose ul,
.rk-prose ol {
    margin-bottom: 6px;
}

.rk-promo {
    padding: 12px 16px;
}

/* รายละเอียด (ซ้าย) + ค่าใช้จ่าย (ขวา) แบบ RentHub */
.rk-detail-split {
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
    gap: 8px 32px;
}

@media (max-width: 991.98px) {
    .rk-detail-split {
        grid-template-columns: minmax(0, 1fr);
    }
}

.rk-specs--stack {
    grid-template-columns: minmax(0, 1fr);
}

.rk-specs--stack > div {
    padding: 7px 0;
    font-size: var(--rk-fs-sm);
}

.rk-specs--stack dd small {
    display: inline;
    margin-left: 6px;
}

/* ตารางห้อง */
.rk-table--compact th,
.rk-table--compact td {
    padding: 8px 10px;
    font-size: var(--rk-fs-sm);
    vertical-align: middle;
}

.rk-shortterm {
    white-space: nowrap;
}

.rk-shortterm span {
    display: inline-block;
}

.rk-shortterm span + span::before {
    content: "·";
    margin: 0 6px;
    color: var(--rk-subtle);
}

/* สิ่งอำนวยความสะดวก: 2 กลุ่ม × 2 คอลัมน์ รายการที่ไม่มี = จาง/ขีดฆ่า */
.rk-amen-groups {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px 32px;
}

@media (max-width: 767.98px) {
    .rk-amen-groups {
        grid-template-columns: minmax(0, 1fr);
    }
}

.rk-amen-groups__label {
    margin-bottom: 6px;
    color: var(--rk-muted);
    font-size: var(--rk-fs-xs);
    font-weight: 600;
}

.rk-amenities--compact {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 6px 14px;
}

.rk-amenities--compact li {
    gap: 8px;
    font-size: var(--rk-fs-sm);
}

.rk-amenities--compact i {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    font-size: var(--rk-fs-sm);
}

.rk-amenities--compact li.is-off {
    color: var(--rk-subtle);
    text-decoration: line-through;
}

.rk-amenities--compact li.is-off i {
    color: var(--rk-line-strong);
    background: transparent;
    border: 1px solid var(--rk-line);
}

/* ทำเลใกล้เคียง: ชื่อ + ระยะ + จำนวน บรรทัดเดียว */
.rk-nearby-grid {
    gap: 18px 32px;
    margin-top: 0;
}

.rk-nearby-item {
    align-items: center;
    gap: 8px;
    padding: 7px 0;
}

.rk-nearby-item a {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    font-size: var(--rk-fs-sm);
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rk-nearby-item small {
    display: inline;
    flex: none;
    color: var(--rk-subtle);
    font-size: var(--rk-fs-xs);
    white-space: nowrap;
}

.rk-nearby-item .rk-count {
    flex: none;
}

.rk-nearby .rk-toggle {
    margin-top: 8px;
}

/* การ์ดราคา เตี้ยลง และอยู่ใต้แถบนำทาง */
.rk-price-card {
    padding: 18px 20px;
}

.rk-price-card.rk-sticky {
    top: calc(var(--rk-header-h) + 66px);
}

.rk-price-card__price b {
    font-size: var(--rk-fs-xl);
}

.rk-price-card__price + .rk-price-card__price b {
    font-size: var(--rk-fs-lg);
}

.rk-price-card .dropdown {
    margin-top: 14px;
}

.rk-price-card__note {
    margin-top: 10px;
    font-size: var(--rk-fs-xs);
}

/* ---------- หลายภาษา: สวิตช์ภาษาและฟอนต์จีน (03/10/2026) ---------- */

html[lang="zh"] {
    --rk-font: "IBM Plex Sans Thai", "Noto Sans SC", "Microsoft YaHei", "PingFang SC", "Noto Sans Thai", system-ui, sans-serif;
}

.rk-lang .rk-nav__link {
    padding-right: 10px;
    padding-left: 10px;
    font-size: var(--rk-fs-sm);
    letter-spacing: .04em;
}

.rk-lang .dropdown-item.active {
    color: var(--rk-scarlet-ui);
    background: var(--rk-scarlet-tint);
}

.rk-mnav__langs {
    display: flex;
    gap: 8px;
    margin-bottom: 6px;
}

.rk-mnav__langs a {
    flex: 1;
    min-height: 44px;
    padding: 10px 8px;
    border: 1px solid var(--rk-line);
    border-radius: 999px;
    color: var(--rk-muted);
    font-weight: 600;
    text-align: center;
}

.rk-mnav__langs a.is-active {
    color: var(--rk-scarlet-ui);
    background: var(--rk-scarlet-tint);
    border-color: transparent;
}

/* ---------- หน้ารายละเอียด: รูปสไลด์ซ้าย + แผนที่ขวา, ปุ่มแชร์, พิมพ์ (เจ้าของ 03/10/2026) ---------- */

.rk-media--split {
    display: grid;
    grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
    gap: 12px;
    align-items: stretch;
}

.rk-gallery-slider {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
}

.rk-gallery-slider__stage {
    position: relative;
    height: clamp(280px, 34vw, 460px);
    overflow: hidden;
    background: var(--rk-stone);
    border-radius: 22px;
}

.rk-gallery-slider__img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    cursor: zoom-in;
    transition: opacity .5s var(--rk-ease);
}

.rk-gallery-slider__img.is-active {
    opacity: 1;
}

.rk-gallery-slider__btn {
    position: absolute;
    top: 50%;
    z-index: 2;
    display: inline-grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 50%;
    color: var(--rk-ink);
    background: rgba(255, 255, 255, .92);
    box-shadow: var(--rk-shadow-xs);
    transform: translateY(-50%);
    transition: background-color .2s var(--rk-ease);
}

.rk-gallery-slider__btn--prev {
    left: 14px;
}

.rk-gallery-slider__btn--next {
    right: 14px;
}

.rk-gallery-slider__btn:hover {
    background: #fff;
}

.rk-gallery-slider__count {
    position: absolute;
    bottom: 14px;
    left: 14px;
    z-index: 2;
    padding: 3px 10px;
    color: #fff;
    background: rgba(23, 23, 25, .55);
    border-radius: 999px;
    font-size: var(--rk-fs-xs);
    font-variant-numeric: tabular-nums;
}

.rk-gallery-slider__thumbs {
    display: flex;
    gap: 8px;
    padding-bottom: 2px;
    overflow-x: auto;
    scrollbar-width: none;
}

.rk-gallery-slider__thumbs::-webkit-scrollbar {
    display: none;
}

.rk-gallery-slider__thumbs button {
    flex: 0 0 auto;
    width: 96px;
    height: 64px;
    padding: 0;
    overflow: hidden;
    background: var(--rk-stone);
    border: 2px solid transparent;
    border-radius: 12px;
    opacity: .7;
    transition: opacity .2s var(--rk-ease), border-color .2s var(--rk-ease);
}

.rk-gallery-slider__thumbs button img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.rk-gallery-slider__thumbs button.is-active,
.rk-gallery-slider__thumbs button:hover {
    border-color: var(--rk-scarlet-ui);
    opacity: 1;
}

.rk-media__map {
    position: relative;
    min-height: 320px;
    overflow: hidden;
    border-radius: 22px;
}

.rk-media__map .rk-map--hero {
    position: absolute;
    inset: 0;
    height: auto;
    border-radius: 22px;
}

.rk-media__gmaps {
    right: 14px;
    bottom: 14px;
}

@media (max-width: 991.98px) {
    .rk-media--split {
        grid-template-columns: minmax(0, 1fr);
    }

    .rk-gallery-slider__stage {
        height: clamp(240px, 56vw, 420px);
        border-radius: 18px;
    }

    .rk-media__map {
        height: 280px;
        min-height: 280px;
        border-radius: 18px;
    }
}

/* ปุ่มแชร์ */
.rk-share {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-self: flex-end;
}

.rk-share__btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 40px;
    padding: 8px 12px;
    color: var(--rk-ink);
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: 999px;
    font-size: var(--rk-fs-sm);
    font-weight: 600;
    transition: border-color .18s var(--rk-ease), color .18s var(--rk-ease), background-color .18s var(--rk-ease);
}

.rk-share__btn:hover {
    color: var(--rk-ink);
    border-color: var(--rk-ink);
}

.rk-share__btn--line {
    color: #05853F; /* 4.7:1 บนขาว (เขียว LINE แท้ #06C755 อ่อนเกินสำหรับตัวอักษร) */
    border-color: rgba(6, 199, 85, .5);
}

.rk-share__btn--fb {
    color: #145DBF;
    border-color: rgba(24, 119, 242, .45);
}

.rk-share__btn.is-copied {
    color: var(--rk-success);
    border-color: var(--rk-success);
}

/* พิมพ์: ตัดส่วนที่ไม่จำเป็น เหลือข้อมูลที่พัก รูปแรก แผนที่ ราคา */
@media print {
    .rk-header,
    .rk-section-nav,
    .rk-share,
    .rk-mobile-cta,
    .rk-footer,
    footer,
    .rk-gallery-slider__btn,
    .rk-gallery-slider__count,
    .rk-gallery__all,
    .rk-gallery-slider__thumbs,
    .rk-filter-fab,
    .leaflet-control-container,
    .rk-price-card .dropdown,
    .rk-price-card .btn,
    .modal {
        display: none !important;
    }

    body {
        background: #fff;
    }

    .rk-page {
        padding-top: 0;
    }

    .rk-media--split {
        grid-template-columns: 1fr 1fr;
        break-inside: avoid;
    }

    .rk-price-card.rk-sticky {
        position: static;
        box-shadow: none;
    }

    .rk-block {
        break-inside: avoid;
    }

    a[href]::after {
        content: none !important;
    }
}

/* ---------- ยืนยันที่พัก / สถานะประกาศ (ระยะ 1 ตาม RentHub 04/10/2026) ---------- */

.rk-badge-soft--warn {
    color: #8A4B00;
    background: #FFF4E5;
}

a.rk-badge-soft--warn:hover {
    color: #6B3A00;
    background: #FFE9CC;
}

.rk-status--muted {
    color: var(--rk-muted);
    background: var(--rk-stone);
}

.rk-status--closed {
    color: #5B5650;
    background: #ECE8E1;
}

.rk-status--suspended {
    color: #8A1C1C;
    background: #FBE3E3;
}

.rk-my-item__actions form {
    display: inline;
}

/* วิดีโอ YouTube ในหน้าประกาศ */
.rk-video {
    position: relative;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: var(--rk-stone);
    border-radius: 18px;
}

.rk-video iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* ===== เอกสารยืนยันที่พักรายไฟล์ (modal ในหน้า "ประกาศของฉัน") 04/10/2026 ===== */
.rk-doc-list {
    display: grid;
    gap: 10px;
}

.rk-doc {
    padding: 12px 14px;
    border: 1px solid var(--rk-line);
    border-radius: var(--rk-radius);
    background: #fff;
}

.rk-doc--locked {
    background: var(--rk-canvas);
}

.rk-doc__head {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.rk-doc__icon {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 12px;
    background: var(--rk-stone);
    color: var(--rk-ink);
    font-size: 1rem;
}

.rk-doc__title {
    font-weight: 600;
    color: var(--rk-ink);
    line-height: 1.3;
}

.rk-doc__req,
.rk-doc__opt {
    display: inline-block;
    margin-left: 6px;
    padding: 1px 8px;
    border-radius: 999px;
    font-size: var(--rk-fs-xs);
    font-weight: 600;
    vertical-align: middle;
}

.rk-doc__req {
    color: var(--rk-scarlet-ui);
    background: var(--rk-scarlet-tint);
}

.rk-doc__opt {
    color: var(--rk-muted);
    background: var(--rk-stone);
}

.rk-doc__hint {
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-doc__file {
    margin: 8px 0 0 50px;
    font-size: var(--rk-fs-sm);
}

.rk-doc__file a {
    color: var(--rk-ink);
    font-weight: 500;
}

.rk-doc__reason {
    margin: 6px 0 0 50px;
    padding: 8px 10px;
    border-radius: var(--rk-radius-xs);
    background: var(--rk-scarlet-tint);
    color: var(--rk-scarlet-ui);
    font-size: var(--rk-fs-sm);
}

.rk-doc__input {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 220px);
    gap: 8px;
    margin: 10px 0 0 50px;
}

.rk-doc__input > :only-child {
    grid-column: 1 / -1;
}

@media (max-width: 575.98px) {
    .rk-doc__file,
    .rk-doc__reason,
    .rk-doc__input {
        margin-left: 0;
    }

    .rk-doc__input {
        grid-template-columns: 1fr;
    }
}

/* ===== เลื่อนประกาศ + สถิติประกาศ (หน้าสมาชิก) 04/10/2026 ===== */
.rk-bump {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
}

.rk-bump__left {
    margin-left: 4px;
    padding: 0 7px;
    border-radius: 999px;
    background: rgba(255, 255, 255, .22);
    font-size: var(--rk-fs-xs);
}

.rk-bump__last {
    color: var(--rk-muted);
    font-size: var(--rk-fs-xs);
}

a.rk-my-item__views {
    text-decoration: none;
    color: inherit;
}

a.rk-my-item__views:hover {
    color: var(--rk-ink);
}

.rk-stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 12px;
    margin-bottom: 20px;
}

.rk-stat {
    padding: 14px 16px;
    border: 1px solid var(--rk-line);
    border-radius: var(--rk-radius);
    background: #fff;
}

.rk-stat small {
    display: block;
    color: var(--rk-muted);
    font-size: var(--rk-fs-xs);
    letter-spacing: .02em;
}

.rk-stat b {
    display: block;
    margin-top: 2px;
    font-size: var(--rk-fs-xl);
    font-weight: 700;
    color: var(--rk-ink);
    line-height: 1.1;
}

.rk-stat--accent b {
    color: var(--rk-scarlet-ui);
}

.rk-chart {
    position: relative;
    width: 100%;
}

.rk-contact-stats {
    list-style: none;
    margin: 0;
    padding: 0;
}

.rk-contact-stats li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px dashed var(--rk-line);
}

.rk-contact-stats li:last-child {
    border-bottom: 0;
}

.rk-contact-stats b {
    font-size: var(--rk-fs-md);
}

/* ===== รีวิวของประกาศฉัน (หน้าสมาชิก) 04/10/2026 ===== */
.rk-review-filter {
    min-width: 240px;
}

.rk-review-row {
    display: flex;
    gap: 16px;
    padding: 16px 18px;
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: var(--rk-radius-lg);
}

.rk-review-row--hidden {
    background: var(--rk-canvas);
}

.rk-review-row--hidden .rk-review__msg {
    color: var(--rk-muted);
}

.rk-review-row__main {
    flex: 1 1 auto;
    min-width: 0;
}

.rk-review-row__actions {
    display: flex;
    flex-direction: column;
    gap: 6px;
    flex: 0 0 auto;
}

@media (max-width: 767.98px) {
    .rk-review-row {
        flex-direction: column;
    }

    .rk-review-row__actions {
        flex-direction: row;
        flex-wrap: wrap;
    }
}

/* ===== รูปแยกตามประเภทห้อง (แกลเลอรีหน้าประกาศ + ฟอร์ม) 04/10/2026 ===== */
.rk-gallery-filter {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 10px;
}

.rk-gallery-filter button {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 12px;
    border: 1px solid var(--rk-line);
    border-radius: 999px;
    background: #fff;
    color: var(--rk-text);
    font-size: var(--rk-fs-sm);
    font-weight: 500;
    transition: border-color .15s var(--rk-ease), background .15s var(--rk-ease);
}

.rk-gallery-filter button span {
    padding: 0 6px;
    border-radius: 999px;
    background: var(--rk-stone);
    color: var(--rk-muted);
    font-size: var(--rk-fs-xs);
}

.rk-gallery-filter button:hover {
    border-color: var(--rk-line-strong);
}

.rk-gallery-filter button.is-active {
    border-color: var(--rk-ink);
    background: var(--rk-ink);
    color: #fff;
}

.rk-gallery-filter button.is-active span {
    background: rgba(255, 255, 255, .2);
    color: #fff;
}

.rk-room-photos {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-left: 6px;
    padding: 1px 8px;
    border: 1px solid var(--rk-line);
    border-radius: 999px;
    background: #fff;
    color: var(--rk-muted);
    font-size: var(--rk-fs-xs);
    font-weight: 600;
    vertical-align: middle;
}

.rk-room-photos:hover {
    color: var(--rk-ink);
    border-color: var(--rk-ink);
}

.rk-img-room {
    margin-top: 4px;
}

/* ===== LINE Login 04/10/2026 ===== */
.btn-line,
.btn-line:focus {
    color: #fff;
    background: #06C755;
    border-color: #06C755;
    font-weight: 600;
}

.btn-line:hover {
    color: #fff;
    background: #05b04c;
    border-color: #05b04c;
}

.rk-or {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 16px 0;
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-or::before,
.rk-or::after {
    content: "";
    flex: 1;
    height: 1px;
    background: var(--rk-line);
}

.rk-line-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    border: 1px solid var(--rk-line);
    border-radius: var(--rk-radius);
    background: var(--rk-canvas);
}

.rk-line-card img,
.rk-line-card .rk-line-card__icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    flex: 0 0 auto;
}

.rk-line-card .rk-line-card__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #06C755;
    color: #fff;
    font-size: 1.4rem;
}

/* ===== แชทบนเว็บ 04/10/2026 ===== */
.rk-nav-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: 999px;
    background: var(--rk-scarlet-ui);
    color: #fff;
    font-size: var(--rk-fs-xs);
    font-weight: 700;
    line-height: 1;
}

.rk-nav__user-dot {
    position: absolute;
    top: 6px;
    right: 2px;
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: var(--rk-scarlet-ui);
    box-shadow: 0 0 0 2px #fff;
}

.rk-chat {
    display: grid;
    grid-template-columns: minmax(280px, 360px) minmax(0, 1fr);
    height: calc(100vh - var(--rk-header-h) - 48px);
    min-height: 520px;
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: var(--rk-radius-lg);
    overflow: hidden;
}

.rk-chat__list {
    display: flex;
    flex-direction: column;
    min-height: 0;
    border-right: 1px solid var(--rk-line);
    background: var(--rk-canvas);
}

.rk-chat__list-head {
    padding: 16px 16px 10px;
    border-bottom: 1px solid var(--rk-line);
}

.rk-chat__title {
    margin: 0 0 10px;
    font-size: var(--rk-fs-lg);
}

.rk-chat__filters {
    display: grid;
    gap: 6px;
}

.rk-chat__rooms {
    flex: 1 1 auto;
    overflow-y: auto;
    min-height: 0;
}

.rk-chat__item {
    position: relative;
    display: flex;
    gap: 10px;
    padding: 12px 16px;
    border-bottom: 1px solid var(--rk-line);
    color: var(--rk-text);
    text-decoration: none;
    transition: background .15s var(--rk-ease);
}

.rk-chat__item:hover {
    background: #fff;
}

.rk-chat__item.is-active {
    background: #fff;
    box-shadow: inset 3px 0 0 var(--rk-ink);
}

.rk-chat__item img {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    object-fit: cover;
    flex: 0 0 auto;
}

.rk-chat__item-body {
    flex: 1 1 auto;
    min-width: 0;
}

.rk-chat__item-top {
    display: flex;
    justify-content: space-between;
    gap: 8px;
}

.rk-chat__item-top b {
    color: var(--rk-ink);
    font-weight: 600;
}

.rk-chat__item-top small {
    color: var(--rk-subtle);
    white-space: nowrap;
}

.rk-chat__item-apt {
    color: var(--rk-muted);
    font-size: var(--rk-fs-xs);
}

.rk-chat__item-preview {
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-chat__item.is-unread .rk-chat__item-preview {
    color: var(--rk-ink);
    font-weight: 600;
}

.rk-chat__unread {
    align-self: center;
    min-width: 22px;
    height: 22px;
    padding: 0 7px;
    border-radius: 999px;
    background: var(--rk-scarlet-ui);
    color: #fff;
    font-size: var(--rk-fs-xs);
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.rk-chat__pane {
    display: flex;
    flex-direction: column;
    min-height: 0;
    min-width: 0;
}

.rk-chat__head {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border-bottom: 1px solid var(--rk-line);
}

.rk-chat__head img {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    object-fit: cover;
}

.rk-chat__back {
    color: var(--rk-ink);
    padding: 6px 10px 6px 0;
}

.rk-chat__role {
    margin-left: 6px;
    padding: 1px 8px;
    border-radius: 999px;
    background: var(--rk-stone);
    color: var(--rk-muted);
    font-size: var(--rk-fs-xs);
    font-weight: 500;
}

.rk-chat__msgs {
    flex: 1 1 auto;
    overflow-y: auto;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    background: var(--rk-canvas);
}

.rk-chat__day {
    text-align: center;
    margin: 8px 0;
}

.rk-chat__day span {
    padding: 2px 10px;
    border-radius: 999px;
    background: var(--rk-stone);
    color: var(--rk-muted);
    font-size: var(--rk-fs-xs);
}

.rk-chat__hint {
    margin: auto;
    max-width: 360px;
    text-align: center;
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-msg {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    max-width: 78%;
}

.rk-msg--mine {
    align-self: flex-end;
    align-items: flex-end;
}

.rk-msg__bubble {
    padding: 9px 13px;
    border-radius: 16px 16px 16px 4px;
    background: #fff;
    border: 1px solid var(--rk-line);
    color: var(--rk-ink);
    word-break: break-word;
}

.rk-msg--mine .rk-msg__bubble {
    border-radius: 16px 16px 4px 16px;
    background: var(--rk-ink);
    border-color: var(--rk-ink);
    color: #fff;
}

.rk-msg__text {
    white-space: pre-wrap;
}

.rk-msg__bubble img {
    display: block;
    max-width: min(320px, 70vw);
    max-height: 320px;
    border-radius: 10px;
    margin-bottom: 4px;
}

.rk-msg__bubble img:only-child {
    margin-bottom: 0;
}

.rk-msg__meta {
    margin-top: 2px;
    color: var(--rk-subtle);
    font-size: var(--rk-fs-xs);
}

.rk-chat__quick {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 8px 16px 0;
}

.rk-chat__chip {
    padding: 4px 12px;
    border: 1px solid var(--rk-line);
    border-radius: 999px;
    background: #fff;
    color: var(--rk-text);
    font-size: var(--rk-fs-sm);
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rk-chat__chip:hover {
    border-color: var(--rk-ink);
}

.rk-chat__chip--manage {
    color: var(--rk-muted);
}

.rk-chat__quick-manage {
    margin-top: 8px;
    padding: 12px;
    border: 1px dashed var(--rk-line);
    border-radius: var(--rk-radius);
}

.rk-chat__composer {
    position: relative;
    display: flex;
    align-items: flex-end;
    gap: 8px;
    padding: 12px 16px 16px;
    border-top: 1px solid var(--rk-line);
}

.rk-chat__composer textarea {
    resize: none;
    max-height: 160px;
    border-radius: 14px;
}

.rk-chat__attach {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 12px;
    border: 1px solid var(--rk-line);
    color: var(--rk-muted);
    cursor: pointer;
    flex: 0 0 auto;
}

.rk-chat__attach:hover {
    color: var(--rk-ink);
    border-color: var(--rk-ink);
}

.rk-chat__send {
    width: 46px;
    height: 42px;
    padding: 0;
    border-radius: 12px;
    flex: 0 0 auto;
}

.rk-chat__preview {
    position: absolute;
    left: 66px;
    bottom: calc(100% + 6px);
    display: flex;
    align-items: flex-start;
    gap: 4px;
    padding: 6px;
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: 12px;
    box-shadow: var(--rk-shadow-sm);
}

.rk-chat__preview img {
    width: 72px;
    height: 72px;
    object-fit: cover;
    border-radius: 8px;
}

.rk-chat__preview button {
    border: 0;
    background: var(--rk-ink);
    color: #fff;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    line-height: 1;
}

.rk-chat__empty {
    margin: auto;
    text-align: center;
    padding: 40px 20px;
    color: var(--rk-text);
}

.rk-chat__empty > i {
    font-size: 2.4rem;
    color: var(--rk-line-strong);
    margin-bottom: 12px;
}

@media (max-width: 991.98px) {
    .rk-chat {
        grid-template-columns: 1fr;
        height: calc(100vh - var(--rk-header-h) - 24px);
    }

    .rk-chat--room .rk-chat__list,
    .rk-chat:not(.rk-chat--room) .rk-chat__pane {
        display: none;
    }
}

/* ===== แพ็กเกจ + ชำระเงิน 04/10/2026 ===== */
.rk-pkg-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 14px;
}

.rk-pkg {
    display: flex;
    flex-direction: column;
    padding: 18px;
    border: 1px solid var(--rk-line);
    border-radius: var(--rk-radius-lg);
    background: #fff;
    transition: box-shadow .2s var(--rk-ease), border-color .2s var(--rk-ease);
}

.rk-pkg:hover {
    border-color: var(--rk-line-strong);
    box-shadow: var(--rk-shadow-sm);
}

.rk-pkg__name {
    font-weight: 700;
    color: var(--rk-ink);
    font-size: var(--rk-fs-md);
}

.rk-pkg__price {
    margin-top: 6px;
    display: flex;
    align-items: baseline;
    gap: 6px;
}

.rk-pkg__price b {
    font-size: var(--rk-fs-2xl);
    color: var(--rk-scarlet-ui);
    line-height: 1;
}

.rk-pkg__price span {
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-pkg__list {
    list-style: none;
    margin: 0 0 14px;
    padding: 0;
    flex: 1 1 auto;
    display: grid;
    gap: 6px;
    font-size: var(--rk-fs-sm);
}

.rk-pkg__list i {
    color: var(--rk-success);
    margin-right: 6px;
}

.rk-qr {
    display: flex;
    justify-content: center;
    padding: 12px;
    background: #fff;
    border: 1px solid var(--rk-line);
    border-radius: var(--rk-radius);
}

.rk-qr img,
.rk-qr canvas {
    max-width: 100%;
}

/* ===== โปรโมชั่น / เปรียบเทียบ / แจ้งรายงาน 04/10/2026 ===== */
.rk-promo-item {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.rk-promo-item__text {
    padding: 10px 14px;
    border: 1px dashed var(--rk-scarlet-ui);
    border-radius: var(--rk-radius);
    background: #FDF1F0;
    font-size: var(--rk-fs-sm);
}

.rk-promo-item__head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    margin-bottom: 4px;
}

.rk-promo-item__head small {
    color: var(--rk-muted);
}

.rk-promo-item__text p {
    margin: 0;
    color: var(--rk-text);
    white-space: pre-line;
}

.rk-compare-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 3;
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, .92);
    color: var(--rk-ink);
    box-shadow: var(--rk-shadow-xs);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: .85rem;
    transition: transform .15s var(--rk-ease), background .15s var(--rk-ease);
}

.rk-compare-btn:hover {
    transform: scale(1.08);
}

.rk-compare-btn.is-on,
.rk-compare-toggle.is-on {
    background: var(--rk-scarlet-ui);
    color: #fff;
}

.rk-compare-toggle.is-on {
    border-color: var(--rk-scarlet-ui);
}

.rk-compare-bar {
    position: fixed;
    left: 50%;
    bottom: 18px;
    z-index: 1040;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px 8px 16px;
    border-radius: 999px;
    background: var(--rk-ink);
    color: #fff;
    box-shadow: var(--rk-shadow-lg);
    transform: translate(-50%, 120%);
    opacity: 0;
    transition: transform .25s var(--rk-ease), opacity .25s var(--rk-ease);
    font-size: var(--rk-fs-sm);
}

.rk-compare-bar.is-visible {
    transform: translate(-50%, 0);
    opacity: 1;
}

.rk-compare-bar .btn.disabled {
    pointer-events: none;
    opacity: .6;
}

@media (max-width: 991.98px) {
    .rk-compare-bar {
        bottom: 84px; /* เหนือแถบราคามือถือ */
    }
}

.rk-compare-wrap {
    overflow-x: auto;
    border: 1px solid var(--rk-line);
    border-radius: var(--rk-radius-lg);
    background: #fff;
}

.rk-compare {
    width: 100%;
    min-width: 640px;
    border-collapse: separate;
    border-spacing: 0;
}

.rk-compare th,
.rk-compare td {
    padding: 10px 14px;
    border-bottom: 1px solid var(--rk-line);
    vertical-align: middle;
    font-size: var(--rk-fs-sm);
    text-align: left;
}

.rk-compare thead th {
    vertical-align: top;
    border-bottom: 2px solid var(--rk-line-strong);
}

.rk-compare__label {
    position: sticky;
    left: 0;
    z-index: 2;
    width: 160px;
    min-width: 140px;
    background: var(--rk-canvas);
    color: var(--rk-muted);
    font-weight: 600;
}

.rk-compare__label--fac {
    font-weight: 500;
}

.rk-compare__group th {
    background: var(--rk-stone);
    color: var(--rk-ink);
    font-weight: 700;
}

.rk-compare__apt {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 180px;
}

.rk-compare__img img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border-radius: var(--rk-radius-sm);
}

.rk-compare__title {
    color: var(--rk-ink);
    font-weight: 600;
    text-decoration: none;
    line-height: 1.3;
}

.rk-compare__loc {
    color: var(--rk-muted);
    font-size: var(--rk-fs-xs);
}

.rk-compare__price b {
    color: var(--rk-scarlet-ui);
    font-size: var(--rk-fs-md);
}

.rk-compare__yes {
    color: var(--rk-success);
}

.rk-compare__no {
    color: var(--rk-line-strong);
}

.rk-hp {
    position: absolute !important;
    left: -9999px !important;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.rk-share__btn--report:hover {
    color: var(--rk-scarlet-ui);
}

/* ===== Phone/desktop pass จาก QC 04/10/2026 (P1 M01 M03 · P2 M02 M04 M05 · M08) ===== */
/* M01: แถบเปรียบเทียบตอนซ่อนต้องไม่รับการแตะ (เคยทับปุ่ม "โทร" ในแถบราคามือถือและช่องพิมพ์แชท) · M03: กว้างตามเนื้อหา ไม่หักคำ */
.rk-compare-bar {
    width: max-content;
    max-width: calc(100vw - 24px);
    white-space: nowrap;
}

.rk-compare-bar:not(.is-visible) {
    visibility: hidden;
    pointer-events: none;
}

/* M02: ปุ่มในประกาศของฉันบนจอเล็กเรียง 2 คอลัมน์ ไม่ล้นจอ */
@media (max-width: 767.98px) {
    .rk-my-item__actions {
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
    }

    .rk-my-item__actions > *,
    .rk-my-item__actions > form {
        flex: 1 1 calc(50% - 4px);
        min-width: 0;
    }

    .rk-my-item__actions .btn {
        width: 100%;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        min-height: 44px;
    }

    .rk-bump {
        align-items: stretch;
    }
}

/* M04: ราคาในแถบล่างมือถือไม่ถูกตัด */
.rk-mobile-cta__price b {
    font-size: var(--rk-fs-md);
    letter-spacing: -.01em;
}

/* M05: ปุ่มกลับและชิปข้อความตอบกลับในแชทแตะได้ ≥ 44 px บนจอเล็ก */
.rk-chat__back {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    min-height: 44px;
    margin-left: -10px;
}

@media (max-width: 991.98px) {
    .rk-chat__chip {
        min-height: 44px;
        padding: 10px 14px;
    }

    .rk-chat__attach,
    .rk-chat__send {
        min-width: 44px;
        min-height: 44px;
    }
}

/* M08: หน้าแรกจอเล็ก container padding 12px แต่แถวเลื่อนใช้ -16px → ล้น 4 px */
@media (max-width: 575.98px) {
    .rk-listing-grid--carousel {
        margin: 0 -12px;
        padding-right: 12px;
        padding-left: 12px;
    }
}

/* D11 (ทำพร้อมกัน 1 บรรทัด): ชิปสถานะไม่หักคำ */
.rk-status {
    white-space: nowrap;
}

/* ===== rk-ui: toast มุมจอ + modal ยืนยัน/กรอกข้อมูล แทน SweetAlert (เจ้าของ 04/10/2026) ===== */
.rk-toasts {
    position: fixed;
    top: calc(var(--rk-header-h, 64px) + 10px);
    right: 16px;
    z-index: 1090;
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: min(380px, calc(100vw - 32px));
    pointer-events: none;
}

.rk-admin .rk-toasts {
    top: 64px;
}

.rk-toast {
    position: relative;
    display: flex;
    gap: 12px;
    align-items: flex-start;
    padding: 12px 40px 12px 14px;
    border: 1px solid var(--rk-line);
    border-left: 4px solid var(--rk-ink);
    border-radius: 14px;
    background: #fff;
    box-shadow: var(--rk-shadow-lg);
    color: var(--rk-text);
    font-size: var(--rk-fs-sm);
    overflow: hidden;
    opacity: 0;
    transform: translateY(-8px);
    transition: opacity .2s var(--rk-ease), transform .2s var(--rk-ease);
    pointer-events: auto;
}

.rk-toast.is-in {
    opacity: 1;
    transform: none;
}

.rk-toast__icon {
    flex: 0 0 auto;
    margin-top: 2px;
    font-size: 1.15rem;
}

.rk-toast--success { border-left-color: var(--rk-success); }
.rk-toast--success .rk-toast__icon { color: var(--rk-success); }
.rk-toast--error { border-left-color: var(--rk-scarlet-ui); }
.rk-toast--error .rk-toast__icon { color: var(--rk-scarlet-ui); }
.rk-toast--warning { border-left-color: #D98E04; }
.rk-toast--warning .rk-toast__icon { color: #D98E04; }
.rk-toast--info .rk-toast__icon,
.rk-toast--question .rk-toast__icon { color: var(--rk-ink); }

.rk-toast__title {
    font-weight: 600;
    color: var(--rk-ink);
}

.rk-toast__text {
    color: var(--rk-muted);
}

.rk-toast__close {
    position: absolute;
    top: 6px;
    right: 8px;
    width: 28px;
    height: 28px;
    border: 0;
    background: transparent;
    color: var(--rk-subtle);
    font-size: 1.2rem;
    line-height: 1;
}

.rk-toast__bar {
    position: absolute;
    left: 0;
    bottom: 0;
    height: 3px;
    width: 100%;
    background: currentColor;
    opacity: .18;
    transform-origin: left;
    animation: rk-toast-bar linear forwards;
}

.rk-toast.is-paused .rk-toast__bar {
    animation-play-state: paused;
}

@keyframes rk-toast-bar {
    from { transform: scaleX(1); }
    to { transform: scaleX(0); }
}

@media (max-width: 575.98px) {
    .rk-toasts {
        top: 10px;
        right: 16px;
        left: 16px;
        width: auto;
    }
}

.rk-ui-modal .modal-dialog {
    max-width: 440px;
}

.rk-ui-modal .modal-content {
    border: 0;
    border-radius: 20px;
    box-shadow: var(--rk-shadow-lg);
}

.rk-ui-modal .modal-body {
    padding: 28px 28px 8px;
    text-align: center;
}

.rk-ui-modal--compact .modal-body {
    padding-top: 26px;
}

.rk-ui-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    margin-bottom: 12px;
    border-radius: 50%;
    background: var(--rk-stone);
    color: var(--rk-ink);
    font-size: 1.5rem;
}

.rk-ui-icon--success { color: var(--rk-success); background: #EEF7F2; }
.rk-ui-icon--error { color: var(--rk-scarlet-ui); background: var(--rk-scarlet-tint); }
.rk-ui-icon--warning { color: #D98E04; background: #FFF4DB; }

.rk-ui-spinner {
    margin: 4px 0 14px;
    color: var(--rk-ink);
}

.rk-ui-title {
    margin: 0 0 6px;
    font-size: var(--rk-fs-md);
    font-weight: 700;
    color: var(--rk-ink);
    line-height: 1.35;
}

.rk-ui-text {
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
    line-height: 1.5;
}

.rk-ui-field {
    margin-top: 14px;
    text-align: left;
}

.rk-ui-field .form-control,
.rk-ui-field .form-select {
    font-size: 16px; /* iPhone ไม่ซูม */
}

.rk-ui-error {
    margin-top: 6px;
    color: var(--rk-scarlet-ui);
    font-size: var(--rk-fs-sm);
}

.rk-ui-modal .modal-footer {
    justify-content: center;
    gap: 8px;
    padding: 12px 20px 22px;
    border-top: 0;
}

.rk-ui-modal .modal-footer .btn {
    min-width: 120px;
    min-height: 44px;
}

/* ===== หลังบ้าน compact (QC D05 04/10/2026): เป้า body 14 · h1 22 · แถวตาราง ~52 · รูปย่อ 48 · padding 8 · ปุ่มในตาราง 32 · sidebar 220 ===== */
.rk-admin {
    --rk-admin-side: 220px;
    --bs-body-font-size: var(--rk-fs-sm);
    font-size: var(--rk-fs-sm);
}

.rk-admin-side {
    padding: 14px 10px;
}

.rk-admin-side__brand {
    margin: 0 8px 12px;
}

.rk-admin-side__brand img {
    width: 118px;
}

.rk-admin-nav__group {
    margin: 12px 10px 4px;
}

.rk-admin-nav__link {
    gap: 10px;
    padding: 7px 10px;
    border-radius: 8px;
    font-size: var(--rk-fs-sm);
}

.rk-admin-nav__link i {
    width: 16px;
    font-size: .85rem;
}

.rk-admin-offcanvas {
    --bs-offcanvas-width: 250px;
}

.rk-admin-top {
    height: 52px;
    gap: 10px;
}

.rk-admin-main {
    padding: 16px clamp(12px, 2vw, 24px) 40px;
}

.rk-admin-head {
    gap: 10px;
    margin-bottom: 12px;
}

.rk-admin-title {
    font-size: 1.375rem;
}

.rk-admin-lead {
    font-size: var(--rk-fs-sm);
}

.rk-admin-subtitle {
    margin: 20px 0 10px;
    font-size: var(--rk-fs-base);
}

.rk-admin .card {
    border-radius: 12px;
}

.rk-admin .card-header {
    padding: 10px 14px;
    font-size: var(--rk-fs-sm);
}

.rk-admin .card-body {
    padding: 12px 14px;
}

.rk-admin .card-footer {
    padding: 10px 14px;
}

.rk-admin .table > thead th,
.rk-admin .table > thead td {
    padding: 8px 10px;
    font-size: var(--rk-fs-xs);
}

.rk-admin .table > tbody > tr > * {
    padding: 8px 10px;
    font-size: var(--rk-fs-sm);
    line-height: 1.35;
}

.rk-admin .table .small,
.rk-admin .table small {
    font-size: var(--rk-fs-xs);
}

.rk-admin .table .mb-1 {
    margin-bottom: 3px !important;
}

.rk-table__thumb {
    width: 72px;
    height: 48px;
    border-radius: 8px;
}

.rk-admin .btn:not(.btn-lg):not(.rk-burger) {
    --bs-btn-padding-y: .375rem;
    --bs-btn-padding-x: .8rem;
    --bs-btn-font-size: var(--rk-fs-sm);
}

.rk-admin .table .btn,
.rk-admin .btn-sm {
    --bs-btn-padding-y: .25rem;
    --bs-btn-padding-x: .6rem;
    --bs-btn-font-size: var(--rk-fs-xs);
    min-height: 32px;
}

.rk-admin .form-control,
.rk-admin .form-select {
    padding: .4rem .65rem;
    font-size: var(--rk-fs-sm);
}

.rk-admin .form-control-lg,
.rk-admin .form-select-lg {
    font-size: var(--rk-fs-base);
}

.rk-admin .form-floating > .form-control,
.rk-admin .form-floating > .form-select {
    height: calc(3rem + 2px);
    font-size: var(--rk-fs-sm);
}

.rk-admin .form-floating > label {
    font-size: var(--rk-fs-sm);
    padding: .85rem .65rem;
}

.rk-admin .form-label {
    margin-bottom: 4px;
    font-size: var(--rk-fs-xs);
    color: var(--rk-muted);
}

.rk-admin .rk-status {
    padding: 2px 8px;
    font-size: var(--rk-fs-xs);
}

.rk-admin .rk-segmented {
    margin-bottom: 12px !important;
}

.rk-admin .rk-segmented .nav-link,
.rk-admin .rk-segmented > button {
    padding: .35rem .75rem;
    font-size: var(--rk-fs-sm);
}

.rk-admin .rk-empty {
    padding: 24px 16px;
}

.rk-admin .modal-title {
    font-size: var(--rk-fs-md);
}

.rk-admin .modal-content {
    font-size: var(--rk-fs-sm);
}

.rk-admin .alert {
    padding: 8px 12px;
    font-size: var(--rk-fs-sm);
}

.rk-admin .dataTables_wrapper {
    font-size: var(--rk-fs-sm);
}

.rk-admin .dataTables_wrapper .dataTables_filter input,
.rk-admin .dataTables_wrapper .dataTables_length select {
    padding: .3rem .5rem;
    font-size: var(--rk-fs-sm);
}

.rk-admin .pagination {
    --bs-pagination-padding-y: .3rem;
    --bs-pagination-padding-x: .65rem;
    --bs-pagination-font-size: var(--rk-fs-sm);
}

/* หลังบ้าน compact: ปุ่มในตารางเรียงแถวเดียว (เดิม w-100 ซ้อนกันทำให้แถวสูง 90 px) */
.rk-admin .table .btn {
    --bs-btn-line-height: 1.25;
}

.rk-admin .table td .btn.w-100 {
    width: auto !important;
    display: inline-block;
}

.rk-admin .table td .btn.mb-1 {
    margin-bottom: 0 !important;
    margin-right: 4px;
}

.rk-admin .table td .btn + .btn,
.rk-admin .table td .btn + a.btn {
    margin-top: 0;
}

/* ===== 06/10/2026 ย้ายประกาศจากเว็บอื่น (การ์ดบนฟอร์มลงประกาศ + ปุ่มในประกาศของฉัน) ===== */
.rk-my-head-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.rk-import {
    border: 1px solid var(--rk-line);
    border-radius: var(--rk-radius-lg);
    background: linear-gradient(135deg, #fff 0%, var(--rk-scarlet-tint, #fff4f2) 100%);
    box-shadow: var(--rk-shadow-xs);
    margin-bottom: 20px;
    overflow: hidden;
}

.rk-import__toggle {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    min-height: 56px;
    padding: 12px 16px;
    border: 0;
    background: transparent;
    text-align: left;
    color: var(--rk-ink);
    cursor: pointer;
}

.rk-import__icon {
    flex: 0 0 40px;
    width: 40px;
    height: 40px;
    border-radius: 12px;
    display: grid;
    place-items: center;
    background: var(--rk-scarlet-ui);
    color: #fff;
    font-size: 18px;
}

.rk-import__head {
    display: flex;
    flex-direction: column;
    min-width: 0;
    flex: 1 1 auto;
}

.rk-import__title {
    font-weight: 700;
    font-size: var(--rk-fs-md);
}

.rk-import__sub {
    color: var(--rk-muted);
    font-size: var(--rk-fs-sm);
}

.rk-import__chev {
    transition: transform .2s var(--rk-ease);
    color: var(--rk-muted);
}

.rk-import.is-open .rk-import__chev {
    transform: rotate(180deg);
}

.rk-import__body {
    display: none;
    padding: 0 16px 16px;
    border-top: 1px solid var(--rk-line);
}

.rk-import.is-open .rk-import__body {
    display: block;
}

.rk-import__tabs {
    margin: 12px 0;
}

.rk-import__tabs .nav-link {
    min-height: 44px;
}

.rk-import__pane .form-control {
    font-size: 16px; /* กัน iPhone ซูม */
}

.rk-import__hint {
    font-size: var(--rk-fs-sm);
    color: var(--rk-muted);
    margin-top: 6px;
}

.rk-import__consent {
    margin: 12px 0 8px;
    font-size: var(--rk-fs-sm);
}

.rk-import__consent .form-check-input {
    width: 20px;
    height: 20px;
    margin-top: 2px;
}

.rk-import__note {
    display: flex;
    gap: 8px;
    align-items: flex-start;
    font-size: var(--rk-fs-sm);
    color: var(--rk-muted);
    margin-bottom: 12px;
}

.rk-import__actions .btn {
    min-height: 44px;
}

.rk-import__notes {
    padding-left: 18px;
    margin-top: 6px;
    font-size: var(--rk-fs-sm);
}

.rk-import__missing {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
}

.rk-import__missing .btn {
    min-height: 36px;
}

#rkImportResult {
    margin-top: 12px;
}

/* ช่องที่ระบบกรอกให้ (หายเมื่อผู้ใช้แก้) */
.rk-import-filled,
.rk-import-filled.form-control,
.rk-import-filled.form-select,
.select2.rk-import-filled .select2-selection,
.tox.rk-import-filled {
    box-shadow: 0 0 0 2px rgba(255, 196, 0, .55) !important;
    background-color: #fffbe6 !important;
}

.form-check.rk-import-filled {
    border-radius: 8px;
    padding-left: 1.75em;
}

#map.rk-import-filled {
    outline: 3px solid rgba(255, 196, 0, .7);
}

@media (max-width: 575.98px) {
    .rk-import__toggle {
        align-items: flex-start;
    }

    .rk-my-head-actions .btn {
        flex: 1 1 100%;
        min-height: 44px;
    }
}


/* ===== QC มือถือ 4 ความกว้าง 05/10/2026 → แก้ 06/10/2026 (M12–M23, M09, M10, D06) ===== */
/* M12: ราคาแถบล่างหน้าประกาศ — จอ < 390 ปุ่มโทรเหลือไอคอน และแสดง "เริ่ม X" แทนช่วงราคา (ช่วง 6 หลักใช้ "เริ่ม" ทุกจอมือถือ) */
.rk-mobile-cta__price b > span {
    color: inherit;
    font-size: inherit;
}

.rk-mobile-cta__from,
.rk-mobile-cta__price--long .rk-mobile-cta__range {
    display: none;
}

.rk-mobile-cta__price--long .rk-mobile-cta__from {
    display: inline;
}

@media (max-width: 389.98px) {
    .rk-mobile-cta__range {
        display: none;
    }

    .rk-mobile-cta__from {
        display: inline;
    }

    .rk-mobile-cta .btn-primarycus {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-width: 44px;
        min-height: 44px;
        padding-right: 12px;
        padding-left: 12px;
    }

    .rk-mobile-cta__call-text {
        display: none;
    }
}

/* M13: ปุ่มในประกาศของฉันขึ้น 2 บรรทัดได้ ไม่ตัด "…" · จอ < 400 ปุ่มเลื่อนประกาศเต็มแถว · ตัวเลขโควต้าไม่หัก */
@media (max-width: 767.98px) {
    .rk-my-item__actions .btn {
        white-space: normal;
        overflow: visible;
        text-overflow: clip;
        line-height: 1.25;
        padding-top: 8px;
        padding-bottom: 8px;
    }

    .rk-bump__left {
        display: inline-block;
        white-space: nowrap;
    }
}

@media (max-width: 399.98px) {
    .rk-my-item__actions > form.rk-bump {
        flex-basis: 100%;
    }
}

/* M14: การ์ดใต้แผนที่ — กล่อง facts เคยเป็นคอลัมน์ auto กว้างตามเนื้อหา (220 px ในการ์ด 142 px) จึงล้นออกนอกจอ */
.rk-mapitem,
.rk-mapitem__body {
    overflow: hidden;
}

.rk-mapitem .rk-listing__tile--facts {
    flex-wrap: wrap;
    white-space: normal;
    min-width: 0;
}

@media (max-width: 575.98px) {
    .rk-mapitem .rk-listing__strip {
        grid-template-columns: minmax(0, 1fr);
    }

    .rk-mapitem .rk-facts {
        margin-left: 0;
    }
}

/* M15: ช่องพิมพ์แชทไม่ต้องสูง 120 px ตามกฎกลางของ textarea (JS ขยายเองถึง 160) · M19: ป้ายบทบาทขึ้นบรรทัดใหม่เมื่อชื่อยาว */
.rk-chat__composer textarea {
    min-height: 44px;
}

.rk-chat__head-name {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 2px 8px;
    min-width: 0;
}

.rk-chat__head-name > .text-truncate {
    min-width: 0;
    max-width: 100%;
}

.rk-chat__head-name .rk-chat__role {
    margin-left: 0;
    white-space: nowrap;
}

/* M16: แถบเปรียบเทียบจอ < 360 — ซ่อนข้อความนับ (ปุ่มมีตัวเลขอยู่แล้ว) และ "ล้าง" เหลือไอคอน × */
.rk-compare-bar__clear i + span {
    margin-left: 6px;
}

@media (max-width: 359.98px) {
    .rk-compare-bar {
        gap: 6px;
        padding: 6px 8px 6px 12px;
        max-width: calc(100vw - 16px);
    }

    .rk-compare-bar__text,
    .rk-compare-bar__clear span {
        display: none;
    }
}

/* M20: ป้าย .badge ของ Bootstrap = .75em → 10.5 px ในข้อความ 14 px — ขั้นต่ำ 12 px */
.badge {
    font-size: max(.75em, 12px);
}

/* M21: ช่องกรอกบนมือถือ 16 px กัน iPhone ซูม (รวม .form-control-sm ในแชท/หลังบ้าน และช่องใน modal ของ rk-ui) · หลังบ้านจอกว้างยัง compact */
@media (max-width: 767.98px) {
    .form-control,
    .form-select,
    .form-control-sm,
    .form-select-sm,
    .rk-ui-input {
        font-size: 16px;
    }
}

/* M22: พื้นที่แตะ ≥ 44 px โดยไม่เปลี่ยนขนาดที่เห็น — ขยายด้วย ::after (ปุ่ม × toast/modal/เมนู, ปุ่มเปรียบเทียบบนการ์ด, ปุ่มเลื่อนรูป, ปุ่มจำนวนรูปในตารางห้อง) */
.btn-close,
.rk-room-photos {
    position: relative;
}

.rk-toast__close::after,
.btn-close::after,
.rk-compare-btn::after,
.rk-slider__btn::after,
.rk-room-photos::after {
    content: "";
    position: absolute;
    inset: -8px;
}

.rk-compare-btn::after,
.rk-slider__btn::after {
    inset: -6px;
}

.rk-room-photos::after {
    inset: -10px -2px;
}

.rating-modal .star {
    padding: 6px 9px;
}

@media (max-width: 991.98px) {
    .rk-share__btn,
    .rk-compare-bar .btn,
    .rk-compare-remove {
        min-height: 44px;
    }
}

/* M23: ตารางเปรียบเทียบจอ < 360 คอลัมน์ป้ายแคบลง (เดิม 140 px = 47% ของจอ) */
@media (max-width: 359.98px) {
    .rk-compare__label {
        width: 96px;
        min-width: 96px;
    }

    .rk-compare th,
    .rk-compare td {
        padding: 8px 10px;
    }
}

/* M10: ตารางหลังบ้านที่มีปุ่มสั่งงาน (คิวอนุมัติ เอกสาร การชำระเงิน รายงาน รีวิว) จอ < 768 เป็นการ์ด — data-label มาจาก rk-ui.js */
@media (max-width: 767.98px) {
    .rk-admin .rk-table--cards > thead {
        display: none;
    }

    .rk-admin .rk-table--cards,
    .rk-admin .rk-table--cards > tbody,
    .rk-admin .rk-table--cards > tbody > tr {
        display: block;
        width: 100%;
    }

    .rk-admin .rk-table--cards > tbody > tr {
        margin: 0 0 12px;
        padding: 4px 0;
        border: 1px solid var(--rk-line);
        border-radius: 12px;
        background: #fff;
    }

    .rk-admin .rk-table--cards > tbody > tr > td {
        display: flex;
        gap: 10px;
        align-items: flex-start;
        width: 100%;
        padding: 6px 12px;
        border: 0;
        text-align: left;
    }

    .rk-admin .rk-table--cards > tbody > tr > td > * {
        min-width: 0;
    }

    .rk-admin .rk-table--cards > tbody > tr > td[data-label]::before {
        content: attr(data-label);
        flex: 0 0 84px;
        padding-top: 2px;
        color: var(--rk-subtle);
        font-size: var(--rk-fs-xs);
        font-weight: 600;
    }

    .rk-admin .rk-table--cards > tbody > tr > td[data-label=""]::before {
        display: none;
    }

    .rk-admin .rk-table--cards > tbody > tr > td:last-child {
        flex-wrap: wrap;
        gap: 8px;
        margin-top: 4px;
        padding-top: 10px;
        border-top: 1px solid var(--rk-line);
    }

    .rk-admin .rk-table--cards > tbody > tr > td:last-child .btn {
        flex: 1 1 auto;
        min-height: 40px;
        white-space: normal;
    }

    .rk-admin .rk-table--cards .rk-table__thumb {
        width: 100%;
        height: 150px;
    }
}

/* M15 (วัดซ้ำ 07/10/2026): จอมือถือเตี้ย (เช่น 320×568) .rk-chat มี min-height 520 จึงดันกล่องพิมพ์ลงใต้จอ → ให้สูงเท่าที่เหลือจริง (100dvh ตามแถบเบราว์เซอร์ที่ซ่อน/โชว์) */
@media (max-width: 767.98px) and (max-height: 720px) {
    .rk-chat {
        min-height: 0;
        height: calc(100vh - var(--rk-header-h) - 24px);
        height: calc(100dvh - var(--rk-header-h) - 24px);
    }

    .rk-chat__head {
        padding-top: 8px;
        padding-bottom: 8px;
    }
}

/* M19 (วัดซ้ำ 07/10/2026): จอ < 360 หัวห้องแชทเหลือที่ให้ชื่อ ~105 px → ชื่อขึ้น 2 บรรทัดแทนตัด "…" */
@media (max-width: 359.98px) {
    .rk-chat__head-name > .text-truncate {
        white-space: normal !important;
        overflow: visible !important;
        text-overflow: clip !important;
        line-height: 1.2;
    }
}

/* ===== Google / Facebook Login 20/10/2026 (สีตามแนวทางแบรนด์ของผู้ให้บริการ) ===== */
.btn-google,
.btn-google:focus {
    color: #1F1F1F;
    background: #fff;
    border: 1px solid #747775;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-google:hover {
    color: #1F1F1F;
    background: #F8F9FA;
    border-color: #747775;
}

.btn-google .rk-google-g {
    flex: 0 0 auto;
}

.btn-facebook,
.btn-facebook:focus {
    color: #fff;
    background: #1877F2;
    border-color: #1877F2;
    font-weight: 600;
}

.btn-facebook:hover {
    color: #fff;
    background: #166FE5;
    border-color: #166FE5;
}

.rk-social-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 14px;
    padding: 12px 0;
    border-top: 1px solid var(--rk-line);
}

.rk-social-row:first-of-type {
    border-top: 0;
}

.rk-social-row__name {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-width: 120px;
    font-weight: 600;
}

.rk-social-row__name .fa-google {
    color: #4285F4;
}

.rk-social-row__name .fa-facebook {
    color: #1877F2;
}
