/* Thuận Phát Business Core – base styles for the plugin's blocks.
 * Loaded only on pages that render one of these blocks. Colours read the theme's --tp-* tokens
 * when the Thuận Phát theme is active and fall back to the brand values under any other theme. */
.tp-icon { display: inline-block; vertical-align: middle; }
.tp-hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
/* ---------- Buttons ---------- */
.tp-btn { display: inline-flex; align-items: center; gap: .5rem; min-height: 44px; padding: .55rem 1rem; border-radius: 6px; border: 1.5px solid var(--tp-navy, #00467c); background: #fff; color: var(--tp-navy, #00467c); font-weight: 600; font-size: .95rem; line-height: 1.2; text-decoration: none; cursor: pointer; transition: background-color .15s, color .15s, border-color .15s; }
.tp-btn:hover { background: var(--tp-navy, #00467c); color: #fff; }
.tp-btn--primary { background: var(--tp-cta, #cf2429); border-color: var(--tp-cta, #cf2429); color: #fff; }
.tp-btn--primary:hover { background: var(--tp-maroon, #961a20); border-color: var(--tp-maroon, #961a20); color: #fff; }
.tp-btn--ghost { border-color: var(--tp-line, #d8e1eb); }
.tp-btn--zalo { border-color: var(--tp-blue, #006cb6); color: var(--tp-blue, #006cb6); }
.tp-btn--zalo:hover { background: var(--tp-blue, #006cb6); color: #fff; }
.tp-btn .tp-icon { flex: none; }
.tp-btn__num { font-variant-numeric: tabular-nums; }
.tp-btn[aria-disabled="true"], .tp-btn:disabled { opacity: .6; cursor: progress; }

.tp-contact-buttons { display: flex; flex-wrap: wrap; gap: .5rem; }
.tp-contact-buttons--compact .tp-btn { min-height: 40px; padding: .4rem .75rem; font-size: .875rem; }
.tp-contact-buttons--compact .tp-btn--zalo { display: none; }

.tp-copy { display: inline-flex; align-items: center; gap: .35rem; margin-left: .5rem; padding: .3rem .6rem; min-height: 32px; border: 1px solid var(--tp-line, #d8e1eb); border-radius: 6px; background: #fff; color: var(--tp-ink, #1a2b3f); font: inherit; font-size: .8125rem; cursor: pointer; vertical-align: middle; }
.tp-copy .tp-icon { width: 16px; height: 16px; }
.tp-copy:hover { border-color: var(--tp-navy, #00467c); }

/* ---------- Contact info / map ---------- */
.tp-info__label { color: var(--tp-muted, #4a5a6e); }
.tp-map { border: 1px solid var(--tp-line, #d8e1eb); border-radius: var(--tp-radius, 8px); padding: 1.25rem; background: #fff; }
.tp-map__address { display: flex; gap: .6rem; margin: 0 0 .75rem; font-weight: 600; color: var(--tp-ink, #1a2b3f); }
.tp-map__address .tp-icon { color: var(--tp-red, #e52c2f); margin-top: .2rem; }
.tp-map__actions { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.tp-map__actions .tp-copy { margin-left: 0; }
.tp-map__pending { margin: .9rem 0 0; padding: .7rem .9rem; border-radius: 6px; background: var(--tp-tint, #f5f8fc); color: var(--tp-muted, #4a5a6e); font-size: .875rem; }

/* ---------- Product cards / grid ---------- */
.tp-grid { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.25rem; }
.tp-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 960px) { .tp-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 720px) { .tp-grid, .tp-grid--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem; } .tp-card__body { padding: .7rem .75rem .9rem; } }
@media (max-width: 380px) { .tp-grid--3 { grid-template-columns: 1fr; } }
.tp-card { min-width: 0; }
.tp-card__link { display: flex; flex-direction: column; height: 100%; background: #fff; border: 1px solid var(--tp-line, #d8e1eb); border-radius: var(--tp-radius, 8px); overflow: hidden; text-decoration: none; color: var(--tp-ink, #1a2b3f); transition: border-color .15s, box-shadow .15s; }
.tp-card__link:hover { border-color: var(--tp-blue, #006cb6); box-shadow: var(--tp-shadow, 0 1px 2px rgba(0, 40, 80, .06), 0 8px 24px rgba(0, 40, 80, .07)); }
.tp-card__media { display: block; aspect-ratio: 1 / 1; background: var(--tp-tint, #f5f8fc); overflow: hidden; }
.tp-card__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tp-card__noimg { display: block; width: 100%; height: 100%; background: repeating-linear-gradient(45deg, var(--tp-tint, #f5f8fc) 0 10px, #eaf0f7 10px 11px); }
.tp-card__body { padding: .9rem 1rem 1.1rem; display: grid; gap: .25rem; }
.tp-card__eyebrow { font-size: .75rem; letter-spacing: .06em; text-transform: uppercase; color: var(--tp-blue, #006cb6); font-weight: 600; }
.tp-card__title { font-weight: 600; color: var(--tp-navy, #00467c); line-height: 1.35; }
.tp-card__excerpt { color: var(--tp-muted, #4a5a6e); font-size: .9rem; }
.tp-empty { padding: 1.5rem; border: 1px dashed var(--tp-line, #d8e1eb); border-radius: var(--tp-radius, 8px); color: var(--tp-muted, #4a5a6e); background: var(--tp-tint, #f5f8fc); }
.tp-filter ul { list-style: none; margin: 0 0 1.5rem; padding: 0; display: flex; flex-wrap: wrap; gap: .5rem; }
.tp-filter a { display: inline-block; padding: .45rem .9rem; border: 1px solid var(--tp-line, #d8e1eb); border-radius: 999px; text-decoration: none; color: var(--tp-ink, #1a2b3f); font-size: .9rem; }
.tp-filter a[aria-current="page"] { background: var(--tp-navy, #00467c); border-color: var(--tp-navy, #00467c); color: #fff; }

.tp-specs { margin: 0; border-top: 1px solid var(--tp-line, #d8e1eb); }
.tp-specs > div { display: grid; grid-template-columns: 11rem 1fr; gap: .5rem 1rem; padding: .8rem 0; border-bottom: 1px solid var(--tp-line, #d8e1eb); }
.tp-specs dt { color: var(--tp-muted, #4a5a6e); font-weight: 500; }
.tp-specs dd { margin: 0; }
@media (max-width: 560px) { .tp-specs > div { grid-template-columns: 1fr; } }
/* ---------- Quote form ---------- */
.tp-quote { background: #fff; border: 1px solid var(--tp-line, #d8e1eb); border-radius: 12px; padding: clamp(1.25rem, 3vw, 2rem); box-shadow: var(--tp-shadow, 0 1px 2px rgba(0, 40, 80, .06), 0 8px 24px rgba(0, 40, 80, .07)); scroll-margin-top: 110px; }
.tp-quote__title { margin-top: 0; }
.tp-quote__form { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem 1.25rem; }
.tp-field { display: grid; gap: .35rem; min-width: 0; margin: 0; padding: 0; border: 0; }
.tp-field--full { grid-column: 1 / -1; }
.tp-field label, .tp-field legend { font-weight: 600; font-size: .9rem; color: var(--tp-ink, #1a2b3f); padding: 0; }
.tp-req { color: var(--tp-cta, #cf2429); }
.tp-field input[type="text"], .tp-field input[type="tel"], .tp-field input[type="email"], .tp-field select, .tp-field textarea { width: 100%; box-sizing: border-box; font: inherit; font-size: 1rem; color: var(--tp-ink, #1a2b3f); background: var(--tp-tint, #f5f8fc); border: 1px solid var(--tp-line, #d8e1eb); border-radius: 6px; padding: .7rem .8rem; min-height: 46px; }
.tp-field textarea { min-height: 110px; resize: vertical; }
.tp-field input:focus, .tp-field select:focus, .tp-field textarea:focus { outline: 2px solid var(--tp-blue, #006cb6); outline-offset: 0; border-color: transparent; background: #fff; }
.tp-field [aria-invalid="true"] { border-color: var(--tp-cta, #cf2429); background: #fff5f5; }
.tp-field__err { margin: 0; color: var(--tp-cta, #cf2429); font-size: .85rem; }
.tp-field__help { margin: 0; color: var(--tp-muted, #4a5a6e); font-size: .85rem; }
.tp-chips { display: flex; flex-wrap: wrap; gap: .5rem; }
.tp-chip { position: relative; }
.tp-chip input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.tp-chip span { display: inline-block; padding: .5rem .9rem; border: 1px solid var(--tp-line, #d8e1eb); border-radius: 999px; background: var(--tp-tint, #f5f8fc); cursor: pointer; font-weight: 500; font-size: .9rem; }
.tp-chip input:checked + span { background: var(--tp-navy, #00467c); border-color: var(--tp-navy, #00467c); color: #fff; }
.tp-chip input:focus-visible + span { outline: 2px solid var(--tp-blue, #006cb6); outline-offset: 2px; }
.tp-consent { display: flex !important; gap: .6rem; align-items: flex-start; font-weight: 400 !important; }
.tp-consent input { margin-top: .3rem; width: 18px; height: 18px; flex: none; }
.tp-quote__foot { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; justify-content: space-between; }
.tp-quote__alt { margin: 0; color: var(--tp-muted, #4a5a6e); font-size: .9rem; }
.tp-alert { margin: 0 0 1rem; padding: .85rem 1rem; border-radius: 6px; font-weight: 500; }
.tp-alert--ok { background: #e8f5ec; color: #14532d; border: 1px solid #a7d7b5; }
.tp-alert--error { background: #fdecec; color: #8a1116; border: 1px solid #f3b5b7; }
@media (max-width: 600px) { .tp-quote__form { grid-template-columns: 1fr; } }

