/* MaSoThue — kiểu dáng công khai (mobile-first), tông cam tham chiếu thuvienphapluat.com/ma-so-thue. */
:root {
    --orange: #f7941e;
    --orange-dark: #e28617;
    --orange-soft: #fdf3e3;
    --brand-red: #d62b2b;
    --bg: #ffffff;
    --zone: #f8f9fa;
    --card: #ffffff;
    --border: #e7e7e7;
    --text: #222222;
    --muted: #777777;
    --green: #17803d;
    --green-soft: #e6f4ea;
    --green-border: #bfe3c8;
    --amber: #b45309;
    --gray: #607080;
    --radius: 8px;
    --shadow: 0 2px 8px rgba(0, 0, 0, .08);
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif; font-size: 15px; line-height: 1.6; color: var(--text); background: var(--bg); }
img, svg { max-width: 100%; }
a { color: var(--orange-dark); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { line-height: 1.4; margin: 0 0 .5em; }
p { margin: 0 0 .75em; }
ul { margin: 0; padding: 0 0 1.2em; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -999px; top: 0; background: #fff; padding: 8px 14px; z-index: 300; }
.skip-link:focus { left: 8px; }
.container { width: 100%; max-width: 1140px; margin: 0 auto; padding: 0 14px; }
.main-content { padding: 14px 14px 40px; background: var(--zone); min-height: 55vh; }

/* ===== Đầu trang cam ===== */
.site-header { background: var(--orange); }
.header-inner { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; padding: 10px 14px; }
.brand { display: flex; align-items: center; gap: 8px; text-decoration: none; order: 1; }
.brand:hover { text-decoration: none; }
.brand-logo { width: 40px; height: 40px; flex: none; background: #fff; border: 2px solid var(--brand-red); border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.brand-logo svg { width: 22px; height: 22px; fill: var(--brand-red); }
.brand-pill { background: #fff; color: var(--brand-red); font-weight: 800; font-size: 1.02rem; padding: 5px 18px; border-radius: 999px; white-space: nowrap; }
.header-search { position: relative; display: flex; order: 3; width: 100%; }
.header-search-input { flex: 1; min-width: 0; height: 40px; border: 0; border-radius: 6px 0 0 6px; padding: 0 16px; font-size: .92rem; outline: none; }
.header-search-btn { width: 52px; flex: none; border: 0; border-radius: 0 6px 6px 0; background: var(--orange-dark); cursor: pointer; display: flex; align-items: center; justify-content: center; }
.header-search-btn svg { width: 20px; height: 20px; fill: #fff; }
.header-search-btn:hover { background: #cf7a12; }
.nav-toggle { order: 2; margin-left: auto; display: flex; flex-direction: column; justify-content: center; gap: 4px; width: 42px; height: 42px; padding: 10px; border: 0; border-radius: 8px; background: transparent; cursor: pointer; }
.nav-toggle-bar { display: block; height: 2px; width: 100%; background: #fff; border-radius: 2px; }

/* ===== Menu ngang ===== */
.main-nav { display: none; background: #fff; border-bottom: 1px solid var(--border); box-shadow: 0 1px 4px rgba(0, 0, 0, .05); }
.main-nav.open { display: block; }
.main-nav-inner { display: flex; flex-direction: column; }
.main-nav-link { padding: 12px 14px; color: #333; font-weight: 700; font-size: .82rem; text-transform: uppercase; border-bottom: 1px solid #f0f0f0; border-left: 3px solid transparent; }
.main-nav-link:hover { color: var(--orange-dark); text-decoration: none; }
.main-nav-link.active { color: var(--orange); border-left-color: var(--orange); }

/* ===== Hàng breadcrumb + ngày ===== */
.crumb-row { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 6px; padding-top: 12px; }
.crumb { display: flex; align-items: center; gap: 6px; min-width: 0; }
.crumb-home { background: var(--orange-soft); color: #b26a00; font-weight: 700; font-size: .78rem; padding: 4px 14px; border-radius: 999px; }
.crumb-home:hover { text-decoration: none; background: #fbe8c8; }
.crumb-sep { color: #999; }
.crumb-current { color: #666; font-size: .84rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 60vw; }
.crumb-date { color: #777; font-size: .84rem; }

/* ===== Bố cục cột ===== */
.page-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; margin-top: 12px; }
.page-main { min-width: 0; }

/* ===== Ô tra cứu có tab ===== */
.search-panel { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 12px; margin-bottom: 14px; }
.sp-tabs { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 10px; }
.sp-tab { border: 0; background: transparent; padding: 8px 16px; border-radius: 6px; font-weight: 600; font-size: .88rem; color: #333; cursor: pointer; }
.sp-tab:hover { background: #f5f5f5; }
.sp-tab.active { background: var(--orange-soft); box-shadow: inset 0 0 0 1px #f0dcb8; }
.sp-form { position: relative; display: flex; }
.sp-input { flex: 1; min-width: 0; height: 44px; border: 1px solid #d9d9d9; border-right: 0; border-radius: 6px 0 0 6px; padding: 0 14px; font-size: .95rem; outline: none; }
.sp-input:focus { border-color: var(--orange); }
.sp-btn { display: flex; align-items: center; gap: 8px; border: 0; border-radius: 0 6px 6px 0; background: var(--orange); color: #fff; font-weight: 700; font-size: .92rem; padding: 0 20px; cursor: pointer; }
.sp-btn svg { width: 17px; height: 17px; fill: #fff; }
.sp-btn:hover { background: var(--orange-dark); }


/* ===== Dải tab danh sách ===== */
.list-tabs { display: flex; flex-wrap: wrap; gap: 4px; border-bottom: 2px solid var(--orange); margin: 4px 0 14px; }
.list-tab { padding: 10px 20px; background: #fff; border: 1px solid #e5e5e5; border-bottom: 0; border-radius: 8px 8px 0 0; color: #333; font-weight: 600; font-size: .88rem; }
.list-tab:hover { color: var(--orange-dark); text-decoration: none; }
.list-tab.active { background: var(--orange); border-color: var(--orange); color: #fff; }

/* ===== Thẻ doanh nghiệp ===== */
.company-list { display: flex; flex-direction: column; gap: 12px; }
.company-card { display: block; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px 16px; color: inherit; }
.company-card:hover { border-color: #f2c67a; box-shadow: var(--shadow); text-decoration: none; }
.cc-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.cc-name { margin: 0; font-size: .95rem; font-weight: 800; text-transform: uppercase; color: #222; line-height: 1.45; }
.cc-check { width: 18px; height: 18px; flex: none; margin-top: 2px; fill: #1a9e4b; }
.cc-row { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.cc-label { color: #8b8b8b; font-size: .75rem; font-weight: 600; text-transform: uppercase; letter-spacing: .4px; }
.cc-mst { background: var(--green-soft); color: var(--green); border: 1px solid var(--green-border); border-radius: 4px; padding: 2px 10px; font-weight: 700; font-size: .82rem; letter-spacing: .6px; }
.cc-mst-orange { background: var(--orange-soft); color: #b26a00; border-color: #f0d9ac; }
.cc-date { color: #555; font-size: .82rem; }
.cc-date svg { width: 15px; height: 15px; fill: #999; }
.cc-addr { display: block; margin: 8px 0 0; color: #777; font-size: .82rem; }
.home-more { margin: 14px 0 0; text-align: center; }
.badge { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: .72rem; font-weight: 700; white-space: nowrap; }
.badge-active { background: var(--green-soft); color: var(--green); }
.badge-suspended { background: var(--orange-soft); color: var(--amber); }
.badge-dissolved { background: #eceff1; color: var(--gray); }

/* ===== Cột phải ===== */
.side-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; margin-bottom: 14px; }
.side-head { display: flex; align-items: center; gap: 8px; margin: 0; padding: 10px 14px; background: #eef3f8; font-size: .82rem; font-weight: 800; text-transform: uppercase; color: #333; }
.side-head svg { width: 16px; height: 16px; fill: var(--orange); flex: none; }
.side-head.cream { background: var(--orange-soft); }
.support-row { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-top: 1px solid #f1f1f1; }
.support-ico { width: 34px; height: 34px; flex: none; border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.support-ico svg { width: 16px; height: 16px; }
.ico-blue { background: #e8f0fe; } .ico-blue svg { fill: #4285f4; }
.ico-red { background: #fde8e8; } .ico-red svg { fill: #e05252; }
.ico-orange { background: var(--orange-soft); } .ico-orange svg { fill: var(--orange); }
.support-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.support-label { font-size: .7rem; color: #9a9a9a; text-transform: uppercase; letter-spacing: .5px; font-weight: 700; }
.support-value { font-size: .88rem; font-weight: 700; color: #222; word-break: break-word; }
.support-link { font-size: .85rem; font-weight: 700; color: #b26a00; }
.side-link-row { align-items: center; }
.side-search { display: flex; padding: 12px 14px; position: relative; }
.side-search-input { flex: 1; min-width: 0; height: 40px; border: 1px solid #d9d9d9; border-right: 0; border-radius: 6px 0 0 6px; padding: 0 12px; outline: none; }
.side-search-btn { width: 44px; flex: none; border: 0; border-radius: 0 6px 6px 0; background: var(--orange); cursor: pointer; display: flex; align-items: center; justify-content: center; }
.side-search-btn svg { width: 18px; height: 18px; fill: #fff; }
.side-title-bar { margin: 18px 0 10px; padding-bottom: 6px; border-bottom: 2px solid var(--orange); font-size: .95rem; font-weight: 800; text-transform: uppercase; color: #222; }
.fav-card { display: block; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 12px 14px; margin-bottom: 12px; color: inherit; }
.fav-card:hover { border-color: #f2c67a; box-shadow: var(--shadow); text-decoration: none; }
.fav-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.fav-name { font-weight: 800; text-transform: uppercase; font-size: .85rem; color: #222; line-height: 1.4; }
.fav-addr { display: flex; gap: 6px; margin-top: 8px; color: #777; font-size: .78rem; }
.fav-addr svg { width: 13px; height: 13px; fill: #aaa; flex: none; margin-top: 3px; }


/* ===== Trang chi tiết ===== */
.d-head { margin: 2px 0 12px; }
.d-title { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 8px; margin: 0; font-size: 1.12rem; font-weight: 800; text-transform: uppercase; color: #222; }
.d-sub { margin: 6px 0 0; color: #8a8a8a; font-size: .8rem; }
.d-card { margin-bottom: 14px; }
.info-table { margin: 0; }
.info-row { display: grid; grid-template-columns: 1fr; gap: 2px; padding: 10px 0; border-bottom: 1px dashed #ddd; }
.info-row:last-child { border-bottom: 0; }
.info-label { margin: 0; color: #8b8b8b; font-size: .75rem; font-weight: 800; text-transform: uppercase; letter-spacing: .3px; }
.info-sub { display: block; font-weight: 600; text-transform: none; letter-spacing: 0; }
.info-value { margin: 0; font-size: .92rem; color: #333; min-width: 0; }
.status-text { font-weight: 700; }
.status-active { color: var(--green); }
.status-suspended { color: var(--amber); }
.status-dissolved { color: var(--gray); }
.invoice-btn { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; background: #dcead9; color: var(--green); border: 0; border-radius: 6px; padding: 12px 14px; margin: 16px 0 12px; font-weight: 800; font-size: .88rem; cursor: pointer; }
.invoice-btn svg { width: 18px; height: 18px; fill: var(--green); flex: none; }
.invoice-btn:hover { background: #cfe3cb; }
.d-note { margin: 0; color: #555; font-size: .82rem; }
.d-note-label { color: var(--brand-red); }
.d-section-title { margin: 0 0 10px; padding-bottom: 6px; border-bottom: 2px solid var(--orange); font-size: .98rem; font-weight: 800; color: #222; }

/* ===== Cột giữa (chi tiết) ===== */
.mid-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 14px; margin-bottom: 14px; }
.mid-head { margin: 0 0 10px; text-align: center; color: #8b8b8b; font-size: .8rem; font-weight: 800; text-transform: uppercase; }
.mid-head.left { text-align: left; color: #333; border-bottom: 1px solid #eee; padding-bottom: 8px; }
.mid-row { margin-bottom: 10px; }
.mid-row:last-child { margin-bottom: 0; }
.mid-label { display: block; color: #9a9a9a; font-size: .75rem; }
.mid-value { display: block; font-weight: 700; font-size: .88rem; color: #222; }
.feedback-btn { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; background: #dcead9; color: var(--green); font-weight: 700; font-size: .88rem; padding: 10px; border-radius: 999px; margin-bottom: 14px; }
.feedback-btn svg { width: 16px; height: 16px; fill: var(--green); }
.feedback-btn:hover { background: #cfe3cb; text-decoration: none; }
.rule-list { list-style: none; margin: 0; padding: 0; }
.rule-list li { display: flex; align-items: flex-start; gap: 10px; padding: 8px 0; border-bottom: 1px dashed #eee; font-size: .82rem; color: #333; }
.rule-list li:last-child { border-bottom: 0; }
.rule-ico { width: 30px; height: 30px; flex: none; background: var(--orange-soft); border-radius: 6px; display: flex; align-items: center; justify-content: center; }
.rule-ico svg { width: 15px; height: 15px; fill: var(--orange); }

/* ===== Modal thông tin xuất hóa đơn ===== */
.modal-backdrop { position: fixed; inset: 0; background: rgba(0, 0, 0, .45); display: flex; align-items: flex-start; justify-content: center; padding: 40px 14px; z-index: 200; overflow: auto; }
.modal-backdrop[hidden] { display: none; }
.modal { background: #fff; border-radius: 8px; width: min(680px, 100%); padding: 18px 22px 24px; box-shadow: 0 10px 40px rgba(0, 0, 0, .25); }
.modal-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 10px; }
.modal-title { margin: 0; font-size: 1.15rem; font-weight: 700; color: #222; }
.modal-close { border: 0; background: transparent; font-size: 1.7rem; line-height: 1; cursor: pointer; color: #555; padding: 0 4px; }
.modal-close:hover { color: #000; }
.modal-desc { color: #1a0dab; font-size: .9rem; font-weight: 600; }
.copy-label { display: block; font-weight: 700; font-size: .9rem; margin: 12px 0 6px; color: #222; }
.copy-field { width: 100%; padding: 10px 12px; border: 1px solid #ccc; border-radius: 6px; font-size: .92rem; background: #fff; cursor: copy; }
.copy-field:focus { outline: 2px solid var(--orange); }
.copy-field.copied { border-color: var(--green); background: var(--green-soft); }


/* ===== Khối nội dung chung ===== */
.card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); margin-bottom: 16px; overflow: hidden; }
.card-body { padding: 14px; }
.section-title { display: flex; align-items: center; gap: 8px; font-size: 1rem; color: #222; padding: 12px 14px; border-bottom: 1px solid var(--border); background: #fafafa; margin: 0; }
.section-title::before { content: ""; width: 4px; height: 18px; border-radius: 2px; background: var(--orange); flex: none; }

/* ===== Gợi ý khi gõ ===== */
.autocomplete { position: absolute; top: calc(100% + 4px); left: 0; right: 0; background: #fff; border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow); z-index: 60; overflow: hidden; text-align: left; }
.autocomplete-item { display: flex; flex-direction: column; gap: 2px; padding: 10px 14px; border-bottom: 1px solid #f0f0f0; color: var(--text); }
.autocomplete-item:last-child { border-bottom: 0; }
.autocomplete-item:hover, .autocomplete-item.active { background: var(--orange-soft); text-decoration: none; }
.ac-name { font-weight: 600; }
.ac-mst { color: var(--muted); font-size: .82rem; }

/* ===== Accordion & lịch sử thay đổi ===== */
.accordion { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); margin-bottom: 14px; overflow: hidden; }
.accordion-header { display: flex; width: 100%; align-items: center; justify-content: space-between; gap: 8px; background: none; border: 0; cursor: pointer; padding: 0; }
.accordion-header .section-title { width: 100%; border-bottom: 0; }
.accordion-chevron { margin-right: 14px; transition: transform .2s ease; color: #666; flex: none; }
.accordion-header[aria-expanded="true"] .accordion-chevron { transform: rotate(180deg); }
.accordion-panel { border-top: 1px solid var(--border); }
.event-item { padding: 12px 14px; border-bottom: 1px solid #f0f0f0; }
.event-item:last-child { border-bottom: 0; }
.event-head { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; margin-bottom: 4px; }
.event-type { font-weight: 700; color: #222; }
.event-date { color: var(--muted); font-size: .82rem; }
.event-change { display: grid; grid-template-columns: 1fr; gap: 2px; padding: 6px 10px; margin-top: 4px; background: var(--orange-soft); border-left: 3px solid var(--orange); border-radius: 0 6px 6px 0; font-size: .86rem; }
.event-change-label { font-weight: 600; color: #4b5563; }
.event-change-value { color: var(--muted); }

/* ===== Bảng ngành nghề / hóa đơn ===== */
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.invoice-table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.invoice-table th, .invoice-table td { border: 1px solid #ececec; padding: 8px 10px; text-align: left; vertical-align: top; }
.invoice-table thead th { background: #fafafa; color: #555; font-weight: 700; text-transform: uppercase; font-size: .75rem; }
.invoice-table tbody th { color: var(--muted); font-weight: 600; background: #fafafa; white-space: nowrap; }
.invoice-empty { color: var(--muted); font-size: .88rem; }
.source-note { color: var(--muted); font-size: .78rem; margin: 4px 0 0; }


/* ===== Bộ lọc, nút, cảnh báo, trạng thái rỗng ===== */
.filters { margin-bottom: 14px; }
.filters-toggle { display: flex; align-items: center; justify-content: space-between; width: 100%; padding: 11px 14px; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); font-weight: 700; color: #222; cursor: pointer; }
.filters-panel { background: var(--card); border: 1px solid var(--border); border-top: 0; border-radius: 0 0 var(--radius) var(--radius); padding: 14px; }
.form-grid { display: grid; grid-template-columns: 1fr; gap: 12px; }
.form-item label { display: block; font-weight: 600; font-size: .86rem; margin-bottom: 4px; }
.form-item input, .form-item select, .form-item textarea { width: 100%; padding: 10px 12px; border: 1px solid #d9d9d9; border-radius: 8px; font-size: .95rem; font-family: inherit; background: #fff; }
.form-item input:focus, .form-item select:focus { outline: none; border-color: var(--orange); box-shadow: 0 0 0 2px rgba(247, 148, 30, .18); }
.btn { display: inline-block; padding: 10px 16px; border-radius: 8px; border: 1px solid transparent; font-size: .92rem; font-weight: 600; cursor: pointer; text-align: center; min-height: 44px; }
.btn:hover { text-decoration: none; filter: brightness(.97); }
.btn-primary { background: var(--orange); color: #fff; }
.btn-outline { background: #fff; color: var(--orange-dark); border-color: var(--orange); }
.btn-light { background: #f1f1f1; color: #333; }
.btn-sm { padding: 6px 10px; font-size: .82rem; border-radius: 6px; min-height: 34px; }
.alert { padding: 11px 14px; border-radius: 8px; margin-bottom: 14px; font-size: .9rem; border: 1px solid; }
.alert-info { background: #eef4fb; border-color: #cfe0f1; color: #0b4a80; }
.alert-warning { background: var(--orange-soft); border-color: #f3ddba; color: #8a5a10; }
.alert-error { background: #fdecec; border-color: #f2c6c6; color: #8f2020; }
.alert-success { background: var(--green-soft); border-color: #c5e8d3; color: #0d5a2c; }
.empty-state { text-align: center; padding: 36px 16px; color: var(--muted); }
.empty-state-title { font-size: 1.05rem; font-weight: 700; color: var(--text); margin-bottom: 4px; }

/* ===== Tóm tắt kết quả & phân trang ===== */
.result-summary { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 8px; margin-bottom: 12px; }
.result-count { font-weight: 700; color: #222; }
.result-source { color: var(--muted); font-size: .82rem; }
.pagination { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin: 18px 0 4px; }
.page-link { display: inline-flex; align-items: center; justify-content: center; min-width: 38px; height: 38px; padding: 0 10px; border: 1px solid var(--border); border-radius: 8px; background: #fff; color: #333; font-weight: 600; }
.page-link:hover { border-color: var(--orange); color: var(--orange-dark); text-decoration: none; }
.page-link.active { background: var(--orange); border-color: var(--orange); color: #fff; }
.page-link.disabled { color: #b3b3b3; pointer-events: none; }

/* ===== Chân trang ===== */
.site-footer { background: #33383d; color: #cfd4d9; margin-top: 24px; }
.footer-grid { display: grid; grid-template-columns: 1fr; gap: 22px; padding: 26px 14px 10px; }
.footer-title { color: #fff; font-weight: 700; margin-bottom: 8px; font-size: .95rem; }
.footer-text { font-size: .88rem; }
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: 6px; }
.footer-links a { color: #b9c1c9; font-size: .88rem; }
.footer-links a:hover { color: #fff; }
.footer-bottom { padding: 14px; border-top: 1px solid #474d53; font-size: .78rem; }
.footer-bottom p { margin: 0 0 4px; }

/* ===== Responsive ===== */
@media (min-width: 768px) {
    .header-inner { flex-wrap: nowrap; padding: 12px 14px; }
    .header-search { order: 2; width: auto; flex: 1; max-width: 620px; margin: 0 auto; }
    .nav-toggle { display: none; }
    .main-nav { display: block; }
    .main-nav-inner { flex-direction: row; align-items: center; gap: 26px; }
    .main-nav-link { padding: 12px 2px; border-bottom: 3px solid transparent; border-left: 0; }
    .main-nav-link.active { border-left: 0; border-bottom-color: var(--orange); }
    .info-row { grid-template-columns: 200px 1fr; gap: 12px; }
    .form-grid { grid-template-columns: 1fr 1fr; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .crumb-current { max-width: 480px; }
    .d-title { font-size: 1.25rem; }
}
@media (min-width: 992px) {
    .page-grid { grid-template-columns: minmax(0, 1fr) 320px; align-items: start; }
    .detail-grid { grid-template-columns: minmax(0, 1fr) 290px; }
    .detail-grid .page-mid { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr 1fr; gap: 14px; align-items: start; }
    .detail-grid .page-mid .mid-card, .detail-grid .page-mid .feedback-btn { margin-bottom: 0; }
}
@media (min-width: 1200px) {
    .detail-grid { grid-template-columns: minmax(0, 1fr) 240px 300px; }
    .detail-grid .page-mid { grid-column: auto; display: block; }
    .detail-grid .page-mid .mid-card { margin-bottom: 14px; }
    .detail-grid .page-mid .feedback-btn { margin-bottom: 14px; }
}
