/* ==========================================================================
   Phú Poly — stylesheet dùng chung cho toàn site
   Tách ra từ index.html khi site chuyển từ 1 trang sang kiến trúc đa trang,
   để trình duyệt cache 1 lần và dùng lại cho mọi trang khu vực/blog.
   ========================================================================== */

:root {
    --bg-dark:       #0b0e14;
    --bg-card:       #151a22;
    --bg-card2:      #1b2030;
    --text-light:    #e0e0e0;
    --text-muted:    #a0a6b4;
    --gold:          #c5a059;
    --gold-dim:      rgba(197,160,89,.12);
    --gold-border:   rgba(197,160,89,.22);
    --call-green:    #007a3a;
    --border:        #252b38;
    --link:          #4da8da;
}
*   { box-sizing:border-box; margin:0; padding:0; font-family:'Segoe UI',Tahoma,Verdana,sans-serif; }
body{ background:var(--bg-dark); color:var(--text-light); line-height:1.6; padding-bottom:90px; }
a   { text-decoration:none; transition:color .3s; }
.seo-link{ color:var(--link); border-bottom:1px dashed var(--link); }
.seo-link:hover{ color:var(--gold); border-bottom-color:var(--gold); }

/* ── TOP BAR ── */
.top-bar{
    background:#0e121a;
    text-align:center; padding:9px 16px;
    font-size:13px; color:var(--text-muted);
    border-bottom:1px solid var(--border);
    letter-spacing:.3px;
}
.top-bar strong{ color:var(--gold); font-weight:700; }

/* ── HEADER ── */
.header-nav{
    display:flex; justify-content:space-between; align-items:center;
    padding:18px 20px; max-width:920px; margin:0 auto;
}
.logo{ font-size:21px; font-weight:800; color:#fff; letter-spacing:1px; }
.logo span{ color:var(--gold); }
.company-badge{
    font-size:13px; color:#aaa;
    border-left:2px solid var(--gold); padding-left:10px; line-height:1.5;
}
.company-badge small{ display:block; font-size:11px; color:var(--text-muted); }

/* ── MAIN NAV (đa trang) ── */
.main-nav{
    border-top:1px solid var(--border); border-bottom:1px solid var(--border);
    background:#0e121a;
}
.main-nav ul{
    max-width:960px; margin:0 auto; padding:0 12px;
    display:flex; flex-wrap:wrap; justify-content:center; gap:2px;
    list-style:none;
}
.main-nav a{
    display:block; padding:12px 14px;
    font-size:14px; font-weight:600; color:var(--text-muted);
    border-bottom:2px solid transparent;
}
.main-nav a:hover{ color:#fff; }
.main-nav a[aria-current="page"]{ color:var(--gold); border-bottom-color:var(--gold); }

/* ── BREADCRUMB ── */
.breadcrumb{
    max-width:960px; margin:0 auto; padding:14px 20px 0;
    font-size:13px; color:var(--text-muted);
}
.breadcrumb a{ color:var(--text-muted); }
.breadcrumb a:hover{ color:var(--gold); }
.breadcrumb span{ color:#6d7382; margin:0 6px; }

/* ── HERO BANNER (trang chủ) ── */
.hero-banner{ position:relative; width:100%; height:320px; overflow:hidden; }
.hero-banner img{
    width:100%; height:100%; object-fit:cover; object-position:center 60%;
    display:block; filter:brightness(.48);
}
.hero-banner-overlay{
    position:absolute; inset:0;
    background:linear-gradient(to bottom,rgba(11,14,20,.1) 0%,rgba(11,14,20,.55) 58%,rgba(11,14,20,1) 100%);
}
.hero-banner-text{
    position:absolute; bottom:30px; left:0; right:0;
    text-align:center; padding:0 20px;
}
.banner-tag{
    display:inline-block;
    background:var(--gold); color:#0b0e14;
    font-size:11px; font-weight:800; letter-spacing:1px;
    text-transform:uppercase; padding:4px 14px; border-radius:4px; margin-bottom:10px;
}
.hero-banner-text h1{
    font-size:25px; font-weight:800; color:#fff;
    line-height:1.35; text-shadow:0 2px 12px rgba(0,0,0,.6);
}
.hero-banner-text h1 span{ color:var(--gold); }
.hero-sub{
    font-size:15px; font-weight:600; color:var(--gold);
    margin-top:8px; text-shadow:0 2px 10px rgba(0,0,0,.7);
}

/* ── PAGE HERO (trang con — không dùng ảnh, nhẹ & nhanh) ── */
.page-hero{
    max-width:860px; margin:0 auto; padding:38px 20px 8px;
}
.page-hero .banner-tag{ margin-bottom:14px; }
.page-hero h1{
    font-size:28px; font-weight:800; color:#fff; line-height:1.35; margin-bottom:14px;
}
.page-hero h1 span{ color:var(--gold); }
.page-hero .lede{
    font-size:16.5px; color:var(--text-muted); line-height:1.85;
}
.page-hero .lede strong{ color:#fff; }

/* ── PROFILE ── */
.profile-section{
    text-align:center; padding:44px 20px 30px;
    max-width:700px; margin:0 auto;
}
.avatar-container{
    width:130px; height:130px; margin:0 auto 20px;
    border-radius:50%; border:3px solid var(--gold); padding:4px;
    background:var(--bg-card); overflow:hidden;
}
.avatar-container img{ width:100%; height:100%; object-fit:cover; border-radius:50%; }
.profile-name{ font-size:27px; font-weight:800; color:#fff; margin-bottom:4px; }
.profile-title{ font-size:14px; color:var(--gold); margin-bottom:18px; }
.profile-desc{
    font-size:16px; color:var(--text-muted);
    line-height:1.9; max-width:620px; margin:0 auto 26px;
}
.profile-desc strong{ color:#fff; }

/* Info chips */
.chips{ display:flex; flex-wrap:wrap; justify-content:center; gap:9px; margin-bottom:26px; }
.chip{
    display:inline-flex; align-items:center; gap:5px;
    background:var(--bg-card); border:1px solid var(--border);
    color:#ccc; font-size:13px; padding:6px 13px; border-radius:50px;
}

/* CTA row */
.cta-row{ display:flex; justify-content:center; gap:12px; flex-wrap:wrap; }
.btn-call{
    display:inline-flex; align-items:center; gap:8px;
    padding:14px 30px; background:var(--call-green);
    color:#fff; font-size:16px; font-weight:700; border-radius:50px;
    box-shadow:0 4px 16px rgba(0,166,81,.3);
}
.btn-ghost{
    display:inline-flex; align-items:center; gap:8px;
    padding:14px 28px; background:transparent;
    color:var(--gold); font-size:15px; font-weight:700; border-radius:50px;
    border:1px solid var(--gold-border);
}
.btn-ghost:hover{ background:var(--gold-dim); }

/* ── SLOGAN BANNER ── */
.slogan-bar{
    background:linear-gradient(135deg,#1a1428 0%,#151a22 100%);
    border-top:1px solid var(--gold-border);
    border-bottom:1px solid var(--gold-border);
    padding:22px 20px;
    text-align:center;
}
.slogan-bar h2{
    font-size:22px; font-weight:900; color:var(--gold);
    letter-spacing:.5px; margin-bottom:6px;
}
.slogan-bar p{ font-size:15px; color:var(--text-muted); }

/* ── SECTIONS WRAPPER ── */
.section-wrap{ max-width:960px; margin:0 auto; padding:56px 20px 0; }
.section-heading{ text-align:center; font-size:22px; font-weight:700; color:#fff; margin-bottom:10px; }
.section-divider{ width:46px; height:3px; background:var(--gold); margin:0 auto 12px; border-radius:2px; }
.section-desc{ text-align:center; font-size:15px; color:var(--text-muted); max-width:560px; margin:0 auto 30px; line-height:1.75; }

/* ── PROSE (nội dung dài: landing khu vực, blog, trang giới thiệu) ── */
.prose{ max-width:800px; margin:0 auto; padding:30px 20px 0; }
.prose h2{
    font-size:22px; font-weight:800; color:#fff;
    margin:38px 0 12px; padding-left:13px; border-left:3px solid var(--gold);
    line-height:1.4;
}
.prose h3{ font-size:17.5px; font-weight:700; color:var(--gold); margin:26px 0 9px; }
.prose p{ font-size:16px; color:var(--text-muted); line-height:1.9; margin-bottom:15px; }
.prose p strong, .prose li strong{ color:#fff; }
.prose ul, .prose ol{ margin:0 0 18px 20px; }
.prose li{ font-size:16px; color:var(--text-muted); line-height:1.85; margin-bottom:9px; }
.prose li::marker{ color:var(--gold); }
.prose a{ color:var(--link); border-bottom:1px dashed var(--link); }
.prose a:hover{ color:var(--gold); border-bottom-color:var(--gold); }
.prose figure{ margin:26px 0; }

/* Bảng trong prose */
.table-scroll{ overflow-x:auto; margin:0 0 22px; -webkit-overflow-scrolling:touch; }
.prose table{ width:100%; border-collapse:collapse; min-width:520px; font-size:14.5px; }
.prose th, .prose td{
    border:1px solid var(--border); padding:11px 13px;
    text-align:left; vertical-align:top; line-height:1.7;
}
.prose th{ background:var(--bg-card2); color:#fff; font-weight:700; font-size:14px; }
.prose td{ color:var(--text-muted); }
.prose tbody tr:nth-child(even) td{ background:rgba(255,255,255,.014); }

/* Khối nhấn mạnh */
.callout{
    background:var(--bg-card); border:1px solid var(--gold-border);
    border-left:3px solid var(--gold);
    border-radius:10px; padding:18px 20px; margin:22px 0;
}
.callout p{ margin-bottom:0; font-size:15px; }
.callout p + p{ margin-top:10px; }
.callout-title{
    display:block; font-size:12px; font-weight:800; letter-spacing:.7px;
    text-transform:uppercase; color:var(--gold); margin-bottom:7px;
}

/* ── PRODUCT CARDS ── */
.product-grid{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(260px,1fr));
    gap:18px; margin-bottom:56px;
}
.product-card{
    background:var(--bg-card); border:1px solid var(--border);
    border-radius:14px; padding:24px 22px;
    transition:border-color .25s,transform .25s;
}
.product-card:hover{ border-color:var(--gold); transform:translateY(-3px); }
.p-icon{ font-size:30px; margin-bottom:12px; }
.p-name{ font-size:17px; font-weight:700; color:#fff; margin-bottom:8px; }
.p-desc{ font-size:14px; color:var(--text-muted); line-height:1.75; }
.p-specs{
    margin-top:14px; padding-top:14px; border-top:1px solid var(--border);
    display:flex; flex-wrap:wrap; gap:6px;
}
.spec-tag{
    font-size:11px; color:var(--gold); background:var(--gold-dim);
    border:1px solid var(--gold-border);
    padding:3px 9px; border-radius:4px; font-weight:500;
}
.p-note{ font-size:12px; color:#888; margin-top:10px; font-style:italic; }

/* ── CNC / CUTTING SECTION ── */
.cnc-section{
    background:var(--bg-card2);
    border-top:1px solid var(--border);
    border-bottom:1px solid var(--border);
    padding:50px 20px;
    margin-bottom:0;
}
.cnc-inner{ max-width:960px; margin:0 auto; }
.cnc-grid{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(220px,1fr));
    gap:18px; margin-top:30px;
}
.cnc-card{
    background:var(--bg-dark); border:1px solid var(--border);
    border-radius:12px; padding:22px 20px;
    transition:border-color .25s;
}
.cnc-card:hover{ border-color:var(--gold); }
.cnc-icon{ font-size:28px; margin-bottom:10px; }
.cnc-title{ font-size:16px; font-weight:700; color:#fff; margin-bottom:8px; }
.cnc-desc{ font-size:14px; color:var(--text-muted); line-height:1.75; }

/* ── IMAGES ── */
.image-grid{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(290px,1fr));
    gap:22px; margin-top:28px;
}
figure{
    background:var(--bg-card); border-radius:14px; overflow:hidden;
    border:1px solid var(--border);
    box-shadow:0 8px 24px rgba(0,0,0,.2);
    transition:transform .25s,border-color .25s;
}
figure:hover{ transform:translateY(-3px); border-color:var(--gold); }
figure img{ width:100%; height:248px; object-fit:cover; display:block; }
figcaption{ padding:18px 20px; font-size:14px; color:#ccc; line-height:1.75; }
figcaption strong{ color:#fff; }
.fig-label{
    display:inline-block; font-size:11px; font-weight:700;
    text-transform:uppercase; letter-spacing:.7px;
    color:var(--gold); background:var(--gold-dim);
    border:1px solid var(--gold-border);
    padding:3px 10px; border-radius:4px; margin-bottom:9px;
}

/* ── TRUST ROW ── */
.trust-row{
    display:flex; flex-wrap:wrap; justify-content:center;
    gap:14px; padding:44px 20px 56px;
    max-width:960px; margin:0 auto;
}
.trust-card{
    background:var(--bg-card); border:1px solid var(--border);
    border-radius:12px; padding:18px 20px;
    text-align:center; flex:1; min-width:130px; max-width:190px;
}
.t-icon{ font-size:24px; margin-bottom:7px; }
.t-val{ font-size:19px; font-weight:800; color:var(--gold); }
.t-label{ font-size:12px; color:var(--text-muted); margin-top:4px; }

/* ── FAQ ── */
.faq-wrap{ max-width:760px; margin:0 auto; padding:56px 20px 0; }
.faq-item{
    background:var(--bg-card); border:1px solid var(--border);
    border-radius:12px; padding:2px 20px; margin-bottom:12px;
}
.faq-item summary{
    cursor:pointer; padding:17px 0; font-weight:700; color:#fff; font-size:15.5px;
    list-style:none; display:flex; justify-content:space-between; align-items:center; gap:16px;
}
.faq-item summary::-webkit-details-marker{ display:none; }
.faq-item summary::after{ content:'+'; color:var(--gold); font-size:22px; font-weight:400; flex-shrink:0; }
.faq-item[open] summary::after{ content:'−'; }
.faq-item p{ padding:0 0 18px; color:var(--text-muted); font-size:14px; line-height:1.8; margin:0; }

/* ── LIÊN KẾT TRANG LIÊN QUAN ── */
.related{ max-width:960px; margin:0 auto; padding:52px 20px 0; }
.related-grid{
    display:grid; grid-template-columns:repeat(auto-fit,minmax(240px,1fr));
    gap:14px; margin-top:22px;
}
.related-card{
    display:block;
    background:var(--bg-card); border:1px solid var(--border);
    border-radius:12px; padding:18px 20px;
    transition:border-color .25s,transform .25s;
}
.related-card:hover{ border-color:var(--gold); transform:translateY(-3px); }
.related-card .rc-kicker{
    font-size:11px; font-weight:700; letter-spacing:.7px; text-transform:uppercase;
    color:var(--gold); display:block; margin-bottom:6px;
}
.related-card .rc-title{ font-size:16px; font-weight:700; color:#fff; margin-bottom:6px; }
.related-card .rc-desc{ font-size:13.5px; color:var(--text-muted); line-height:1.7; }

/* ── CONTACT BOX ── */
.contact-wrap{ max-width:680px; margin:0 auto; padding:0 20px 60px; }
.contact-wrap.spaced{ padding-top:56px; }
.contact-box{
    background:var(--bg-card); border:1px solid var(--border);
    border-radius:18px; padding:36px 30px; text-align:center;
}
.contact-box h3{ font-size:21px; font-weight:700; color:#fff; margin-bottom:10px; }
.contact-box p{ font-size:15px; color:var(--text-muted); margin-bottom:22px; line-height:1.75; }
.contact-box p strong{ color:var(--gold); }
.contact-phone{ font-size:28px; font-weight:800; color:#fff; letter-spacing:1px; margin-bottom:5px; }
.contact-sub{ font-size:13px; color:var(--text-muted); margin-bottom:22px; }
.contact-btns{ display:flex; justify-content:center; gap:12px; flex-wrap:wrap; }

/* ── FOOTER ── */
footer{
    text-align:center; padding:34px 20px;
    background:#080a0f; border-top:1px solid var(--border);
    color:var(--text-muted); font-size:13px; line-height:1.9;
}
footer p{ margin-bottom:4px; }
footer strong{ color:var(--gold); }
.footer-links{ margin:12px 0 10px; display:flex; flex-wrap:wrap; justify-content:center; gap:6px 16px; }
.footer-links a{ color:var(--text-muted); font-size:13px; }
.footer-links a:hover{ color:var(--gold); }

/* ── FAB ── */
.fab-wrapper{
    position:fixed; bottom:20px; left:15px;
    pointer-events:none; z-index:9999;
    display:flex; gap:10px;
}
.fab-btn{
    pointer-events:auto;
    display:flex; align-items:center; gap:8px;
    padding:13px 22px; border-radius:50px; color:#fff;
    font-weight:700; font-size:15px; box-shadow:0 4px 16px rgba(0,0,0,.35);
    border:none; cursor:pointer; font-family:inherit;
}
.fab-call{ background:linear-gradient(135deg,#007a3a,#00551f); }

/* ── CHAT CSKH (chatbot tự viết + form báo giá, ruột panel do assets/cskh.js dựng) ── */
.fab-cskh{
    position:fixed; bottom:20px; right:15px; z-index:9999;
    display:flex; align-items:center; gap:8px;
    padding:15px 24px; border-radius:50px;
    background:linear-gradient(135deg,var(--gold),#a8823f);
    color:#0b0e14; font-weight:800; font-size:16px; font-family:inherit;
    border:none; cursor:pointer;
    box-shadow:0 4px 20px rgba(197,160,89,.5);
    animation:cskh-pulse 2.4s ease-in-out infinite;
}
.fab-cskh-dot{
    width:9px; height:9px; border-radius:50%; background:#00e05a;
    box-shadow:0 0 0 3px rgba(0,224,90,.35); flex-shrink:0;
}
@keyframes cskh-pulse{
    0%,100%{ box-shadow:0 4px 20px rgba(197,160,89,.5); }
    50%{ box-shadow:0 4px 26px rgba(197,160,89,.85), 0 0 0 9px rgba(197,160,89,.14); }
}
.cskh-panel{
    position:fixed; z-index:10000;
    right:15px; bottom:92px;
    width:380px; max-width:calc(100% - 30px);
    height:min(600px, 72vh);
    background:var(--bg-card); border:1px solid var(--gold-border);
    border-radius:16px; overflow:hidden;
    display:none; flex-direction:column;
    box-shadow:0 12px 40px rgba(0,0,0,.5);
}
.cskh-panel.open{ display:flex; }
.cskh-head{
    background:linear-gradient(135deg,#1a1428,#151a22);
    padding:14px 16px; border-bottom:1px solid var(--gold-border);
    display:flex; justify-content:space-between; align-items:center;
    flex-shrink:0;
}
.cskh-head-title{ font-size:14px; font-weight:700; color:#fff; }
.cskh-head-sub{ font-size:11px; color:var(--gold); }
.cskh-close{
    background:none; border:none; color:#888; font-size:18px; cursor:pointer;
    min-width:44px; min-height:44px; display:flex; align-items:center; justify-content:center;
}
/* Ruột panel: 2 tab dùng chung khung, chỉ 1 tab hiện mỗi lúc */
.cskh-inner{ flex:1; display:flex; flex-direction:column; min-height:0; }
.cskh-tabs{ display:flex; border-bottom:1px solid var(--border); flex-shrink:0; }
.cskh-tab{
    flex:1; padding:11px 8px; background:none; border:none; cursor:pointer;
    color:var(--text-muted); font-size:13.5px; font-weight:600; font-family:inherit;
    border-bottom:2px solid transparent; min-height:44px;
}
.cskh-tab.is-on{ color:var(--gold); border-bottom-color:var(--gold); }
.cskh-pane{ display:none; flex:1; min-height:0; flex-direction:column; }
.cskh-pane.is-on{ display:flex; }

/* — tab chat — */
.cskh-log{ flex:1; overflow-y:auto; padding:14px; display:flex; flex-direction:column; gap:10px; }
.cskh-msg{ max-width:85%; padding:9px 13px; border-radius:12px; font-size:13.5px; line-height:1.55; white-space:pre-wrap; }
.cskh-msg-bot{ align-self:flex-start; background:var(--bg-card2); color:var(--text-light); border-bottom-left-radius:3px; }
.cskh-msg-user{ align-self:flex-end; background:var(--gold); color:#0b0e14; border-bottom-right-radius:3px; font-weight:500; }
.cskh-msg-typing{ align-self:flex-start; color:var(--text-muted); font-size:12px; font-style:italic; }
.cskh-inputrow{
    display:flex; gap:8px; padding:10px; border-top:1px solid var(--border);
    background:var(--bg-card); flex-shrink:0;
}
.cskh-input{
    flex:1; background:var(--bg-dark); border:1px solid var(--border); color:#fff;
    padding:10px 12px; border-radius:20px; font-size:16px; font-family:inherit; outline:none;
}
.cskh-input:focus{ border-color:var(--gold); }
.cskh-send{
    background:var(--gold); border:none; border-radius:50%; color:#0b0e14;
    width:44px; height:44px; flex-shrink:0; cursor:pointer; font-size:16px;
    display:flex; align-items:center; justify-content:center;
}
.cskh-send:disabled{ opacity:.5; cursor:default; }

/* — tab form báo giá — */
#cskhPaneForm{ overflow-y:auto; padding:14px; gap:9px; }
.cskh-formnote{ font-size:12.5px; color:var(--text-muted); line-height:1.5; margin-bottom:2px; }
.cskh-f{ display:block; }
.cskh-f span{ display:block; font-size:12px; color:var(--text-muted); margin-bottom:4px; }
.cskh-f span b{ color:var(--gold); }
.cskh-f input, .cskh-f select{
    width:100%; background:var(--bg-dark); border:1px solid var(--border); color:#fff;
    padding:9px 11px; border-radius:8px; font-size:16px; font-family:inherit; outline:none;
}
.cskh-f input:focus, .cskh-f select:focus{ border-color:var(--gold); }
.cskh-err{ color:#ff8a80; font-size:12.5px; min-height:1em; }
.cskh-submit{
    background:linear-gradient(135deg,var(--gold),#a8823f); color:#0b0e14;
    border:none; border-radius:8px; padding:13px; font-size:15px; font-weight:800;
    font-family:inherit; cursor:pointer; min-height:46px; margin-top:2px;
}
.cskh-submit:disabled{ opacity:.6; cursor:default; }
.cskh-done{ padding:18px 4px; font-size:14px; line-height:1.6; }
.cskh-done b{ color:var(--gold); display:block; margin-bottom:6px; }
.cskh-done a{ color:var(--gold); border-bottom:1px dashed var(--gold); }

/* ── RESPONSIVE ── */
@media(max-width:600px){
    .hero-banner{ height:230px; }
    .hero-banner-text h1{ font-size:19px; }
    .hero-sub{ font-size:13px; }
    .page-hero h1{ font-size:23px; }
    .page-hero .lede{ font-size:15.5px; }
    .profile-name{ font-size:23px; }
    .slogan-bar h2{ font-size:18px; }
    .prose h2{ font-size:19px; }
    .prose p, .prose li{ font-size:15.5px; }
    .main-nav a{ padding:10px 10px; font-size:13px; }
    .fab-btn{ padding:11px 16px; font-size:14px; }
    .fab-cskh{ padding:12px 18px; font-size:14px; }
    .cskh-panel{ right:8px; left:8px; width:auto; bottom:78px; }
}
@media(max-width:400px){
    .btn-call{ width:100%; justify-content:center; }
}
