:root {
    --ink: #edf2f7;
    --slate-900: #f8fafc;
    --slate-800: #f1f5f9;
    --slate-700: #cbd5e1;
    --slate-600: #94a3b8;
    --slate-400: #475569;
    --slate-300: #1e293b;
    --slate-100: #0f172a;
    --amber: #3b82f6;
    --amber-light: #60a5fa;
    --amber-dark: #2563eb;
    --accent-glow: rgba(59, 130, 246, 0.1);
    --text-primary: #0f172a;
    --text-secondary: #475569;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    font-family: 'Noto Sans SC', sans-serif;
    background-color: var(--ink);
    color: var(--text-primary);
    line-height: 1.7;
    overflow-x: hidden;
}

::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--slate-900); }
::-webkit-scrollbar-thumb { background: var(--slate-700); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--amber); }

/* ===== Top Bar ===== */
.top-bar {
    position: fixed; top: 0; left: 0; width: 100%; height: 36px;
    background: var(--amber-dark); color: #fff;
    display: flex; align-items: center; justify-content: center;
    gap: 32px; font-size: 13px; z-index: 1001; letter-spacing: 0.3px;
}
.top-bar-item { display: flex; align-items: center; gap: 6px; }
.top-bar-item svg { width: 14px; height: 14px; fill: currentColor; }
.top-bar a { color: #fff; text-decoration: none; }
.top-bar a:hover { opacity: 0.85; }

/* ===== Navigation ===== */
.navbar {
    position: fixed; top: 36px; left: 0; width: 100%; z-index: 1000;
    padding: 0 5%; height: 72px;
    display: flex; align-items: center; justify-content: space-between;
    background: rgba(237, 242, 247, 0.92);
    backdrop-filter: blur(20px);
    box-shadow: 0 4px 30px rgba(0,0,0,0.08);
}
.logo { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.logo img { height: 42px; width: auto; object-fit: contain; }
.logo-text { font-weight: 700; font-size: 18px; color: var(--text-primary); letter-spacing: 1px; }
.logo-text span { color: var(--amber); }
.nav-links { display: flex; gap: 40px; list-style: none; }
.nav-links a {
    color: var(--text-secondary); text-decoration: none; font-size: 15px; font-weight: 500;
    position: relative; transition: color 0.3s ease; letter-spacing: 0.5px;
}
.nav-links a::after {
    content: ''; position: absolute; bottom: -6px; left: 0; width: 0; height: 2px;
    background: var(--amber); transition: width 0.3s ease;
}
.nav-links a:hover { color: var(--text-primary); }
.nav-links a:hover::after { width: 100%; }
.nav-links a.active { color: var(--amber); }
.nav-links a.active::after { width: 100%; }

.mobile-menu-btn {
    display: none; flex-direction: column; gap: 5px;
    background: none; border: none; cursor: pointer; padding: 8px;
}
.mobile-menu-btn span { display: block; width: 26px; height: 2px; background: var(--text-primary); }

.mobile-menu-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.6); z-index: 1001;
    opacity: 0; visibility: hidden; transition: all 0.3s ease;
}
.mobile-menu-overlay.open { opacity: 1; visibility: visible; }
.mobile-menu {
    position: fixed; top: 0; right: -100%; width: 80%; max-width: 320px; height: 100vh;
    background: var(--slate-900); z-index: 1002; padding: 80px 30px 30px;
    transition: right 0.4s ease; border-left: 1px solid var(--slate-700);
}
.mobile-menu.open { right: 0; }
.mobile-menu ul { list-style: none; }
.mobile-menu li { margin-bottom: 24px; }
.mobile-menu a { color: var(--text-primary); text-decoration: none; font-size: 18px; font-weight: 500; }
.mobile-menu-close { position: absolute; top: 24px; right: 24px; background: none; border: none; color: var(--text-primary); font-size: 28px; cursor: pointer; }

/* ===== Page Layout ===== */
.page-wrap { padding-top: 108px; min-height: 100vh; display: flex; flex-direction: column; }
.page-header {
    padding: 40px 5% 30px;
    background: linear-gradient(to bottom, var(--slate-900), var(--ink));
    border-bottom: 1px solid var(--slate-800);
}
.page-header h1 { font-size: 32px; font-weight: 700; margin-bottom: 8px; }
.page-header p { color: var(--text-secondary); font-size: 15px; }

.product-page {
    display: flex; flex: 1;
    max-width: 1400px; margin: 0 auto; width: 100%;
    padding: 30px 5% 60px; gap: 30px;
}

/* ===== Left Sidebar (Product List) ===== */
.product-sidebar {
    width: 300px; min-width: 300px;
    background: var(--slate-900);
    border: 1px solid var(--slate-700);
    border-radius: 16px;
    overflow: hidden;
    display: flex; flex-direction: column;
    max-height: calc(100vh - 200px);
    position: sticky; top: 92px;
}
.sidebar-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--slate-700);
    background: rgba(59, 130, 246, 0.05);
}
.sidebar-header h3 {
    font-size: 16px; font-weight: 700; display: flex; align-items: center; gap: 10px;
}
.sidebar-header h3::before {
    content: ''; width: 4px; height: 18px; background: var(--amber); border-radius: 2px;
}
.product-list {
    list-style: none; overflow-y: auto; flex: 1;
}
.product-list-item {
    display: flex; align-items: center; gap: 14px;
    padding: 16px 24px;
    border-bottom: 1px solid rgba(203, 213, 225, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    color: inherit;
}
.product-list-item:hover {
    background: rgba(59, 130, 246, 0.05);
}
.product-list-item.active {
    background: rgba(59, 130, 246, 0.1);
    border-left: 3px solid var(--amber);
    padding-left: 21px;
}
.product-list-item .item-icon {
    width: 44px; height: 44px; min-width: 44px;
    background: var(--slate-800);
    border: 1px solid var(--slate-700);
    border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    font-size: 20px;
}
.product-list-item.active .item-icon {
    background: rgba(59, 130, 246, 0.15);
    border-color: var(--amber);
}
.product-list-item .item-info h4 {
    font-size: 14px; font-weight: 600; margin-bottom: 4px;
}
.product-list-item .item-info p {
    font-size: 12px; color: var(--slate-400); line-height: 1.4;
}
.product-list-item .item-tag {
    font-size: 11px; padding: 2px 8px; border-radius: 100px;
    margin-left: auto; white-space: nowrap;
}
.tag-core { background: rgba(59, 130, 246, 0.12); color: var(--amber-dark); }
.tag-acc { background: rgba(148, 163, 184, 0.12); color: var(--slate-300); }

/* ===== Right Detail Panel ===== */
.product-detail {
    flex: 1;
    background: var(--slate-900);
    border: 1px solid var(--slate-700);
    border-radius: 16px;
    overflow: hidden;
    display: flex; flex-direction: column;
}
.detail-visual {
    width: 100%; aspect-ratio: 21/9; min-height: 280px;
    background: linear-gradient(145deg, var(--slate-800), var(--slate-700));
    display: flex; flex-direction: column; align-items: center; justify-content: center;
    gap: 16px; position: relative; overflow: hidden;
    border-bottom: 1px solid var(--slate-700);
}
.detail-visual::before {
    content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: radial-gradient(ellipse at 80% 20%, rgba(59, 130, 246, 0.08) 0%, transparent 60%);
}
.detail-visual .bg-icon {
    font-size: 120px; opacity: 0.08; color: var(--amber);
    position: absolute; right: 40px; bottom: 20px; line-height: 1;
}
.detail-visual .main-icon {
    font-size: 64px; color: var(--amber); opacity: 0.8; z-index: 1;
}
.detail-visual .label {
    font-size: 14px; color: var(--slate-400); letter-spacing: 2px; z-index: 1;
}
.detail-visual img {
    width: 100%; height: 100%; object-fit: contain;
    position: absolute; top: 0; left: 0; z-index: 1;
}

/* ===== Gallery Layout for Accessories ===== */
.detail-gallery {
    padding: 32px 40px;
    overflow-y: auto;
}
.detail-gallery h2 {
    font-size: 24px; font-weight: 700; color: var(--text-primary);
    margin-bottom: 6px;
}
.detail-gallery .gallery-desc {
    font-size: 14px; color: var(--text-secondary); margin-bottom: 24px;
    line-height: 1.8;
}
.detail-gallery .gallery-tag {
    display: inline-block; padding: 4px 14px; border-radius: 20px;
    font-size: 12px; font-weight: 600; margin-bottom: 16px;
    background: rgba(59, 130, 246, 0.1); color: var(--amber);
}
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-bottom: 28px;
}
.gallery-grid .gallery-item {
    position: relative;
    aspect-ratio: 1/1;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    border: 1px solid var(--slate-700);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.gallery-grid .gallery-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.1);
}
.gallery-grid .gallery-item img {
    width: 100%; height: 100%; object-fit: cover;
    transition: transform 0.4s ease;
}
.gallery-grid .gallery-item:hover img {
    transform: scale(1.05);
}
.gallery-actions {
    display: flex; gap: 12px; margin-top: 8px;
}

/* Gallery lightbox */
.gallery-lightbox {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.85); z-index: 1010;
    display: none; align-items: center; justify-content: center;
    cursor: zoom-out;
}
.gallery-lightbox.open { display: flex; }
.gallery-lightbox img {
    max-width: 90%; max-height: 90%; object-fit: contain;
    border-radius: 8px; box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}
.gallery-lightbox-close {
    position: absolute; top: 20px; right: 28px;
    background: none; border: none; color: #fff;
    font-size: 36px; cursor: pointer; opacity: 0.8;
    transition: opacity 0.2s;
}
.gallery-lightbox-close:hover { opacity: 1; }
.gallery-lightbox-nav {
    position: absolute; top: 50%; transform: translateY(-50%);
    background: rgba(255,255,255,0.15); border: none; color: #fff;
    font-size: 28px; width: 48px; height: 48px; border-radius: 50%;
    cursor: pointer; display: flex; align-items: center; justify-content: center;
    transition: background 0.2s;
}
.gallery-lightbox-nav:hover { background: rgba(255,255,255,0.3); }
.gallery-lightbox-nav.prev { left: 20px; }
.gallery-lightbox-nav.next { right: 20px; }
.gallery-lightbox-counter {
    position: absolute; bottom: 24px; left: 50%; transform: translateX(-50%);
    color: rgba(255,255,255,0.7); font-size: 14px;
}

.detail-body {
    padding: 36px 40px;
    overflow-y: auto;
}
.detail-body h2 {
    font-size: 28px; font-weight: 700; margin-bottom: 8px;
}
.detail-body .detail-tag {
    display: inline-block; padding: 4px 14px;
    background: rgba(59, 130, 246, 0.12); color: var(--amber-dark);
    font-size: 12px; font-weight: 600; border-radius: 100px;
    margin-bottom: 20px; letter-spacing: 1px;
}
.detail-body .detail-desc {
    color: var(--text-secondary); font-size: 15px; line-height: 1.9;
    margin-bottom: 32px; max-width: 700px;
}
.detail-section-title {
    font-size: 18px; font-weight: 700; margin-bottom: 20px;
    display: flex; align-items: center; gap: 10px;
}
.detail-section-title::before {
    content: ''; width: 4px; height: 18px; background: var(--amber); border-radius: 2px;
}
.spec-table {
    width: 100%; border-collapse: collapse; margin-bottom: 36px;
}
.spec-table tr {
    border-bottom: 1px solid var(--slate-800);
}
.spec-table td {
    padding: 14px 0; font-size: 14px;
}
.spec-table td:first-child {
    color: var(--slate-400); width: 40%;
}
.spec-table td:last-child {
    color: var(--text-primary); font-weight: 500;
}
.detail-actions {
    display: flex; gap: 16px; flex-wrap: wrap; padding-top: 8px;
}
.btn {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 14px 32px; border-radius: 8px; font-size: 15px; font-weight: 600;
    text-decoration: none; transition: all 0.3s ease; cursor: pointer;
    border: none; font-family: inherit;
}
.btn-primary {
    background: linear-gradient(135deg, var(--amber), var(--amber-dark));
    color: var(--ink); box-shadow: 0 8px 30px rgba(59, 130, 246, 0.3);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 40px rgba(59, 130, 246, 0.4); }
.btn-secondary {
    background: transparent; color: var(--text-primary); border: 1.5px solid var(--slate-700);
}
.btn-secondary:hover { border-color: var(--amber); color: var(--amber); }

/* ===== Mobile Sidebar Toggle ===== */
.mobile-sidebar-toggle {
    display: none;
    width: 100%; padding: 14px 20px;
    background: var(--slate-800); border: 1px solid var(--slate-700);
    border-radius: 12px; color: var(--text-primary);
    font-size: 15px; font-weight: 600; cursor: pointer;
    margin-bottom: 16px; align-items: center; justify-content: space-between;
}
.mobile-sidebar-toggle span { color: var(--amber); }

/* ===== Footer ===== */
.footer {
    background: var(--ink);
    padding: 80px 5% 40px;
    border-top: 1px solid var(--slate-800);
    margin-top: auto;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: 50px;
    max-width: 1200px;
    margin: 0 auto 60px;
}

.footer-brand img {
    height: 48px;
    width: auto;
    margin-bottom: 12px;
    display: block;
}

.footer-brand-text {
    font-family: 'Noto Sans SC', sans-serif;
    font-weight: 700;
    font-size: 20px;
    color: var(--text-primary);
    letter-spacing: 1px;
    margin-bottom: 16px;
}

.footer-brand-text span {
    color: var(--amber);
}

.footer-brand p {
    color: var(--slate-400);
    font-size: 14px;
    line-height: 1.8;
    max-width: 300px;
}

.footer-col h4 {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 20px;
    letter-spacing: 1px;
}

.footer-col ul {
    list-style: none;
}

.footer-col li {
    margin-bottom: 12px;
}

.footer-col a {
    color: var(--slate-400);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.footer-col a:hover {
    color: var(--amber);
}

.contact-info p {
    color: var(--slate-400);
    font-size: 14px;
    margin-bottom: 12px;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    line-height: 1.6;
}

.footer-bottom {
    max-width: 1200px;
    margin: 0 auto;
    padding-top: 30px;
    border-top: 1px solid var(--slate-800);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
}

.footer-bottom p {
    color: var(--slate-600);
    font-size: 13px;
}

/* ===== Floating Contact Panel ===== */
.floating-contact {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 999;
}

.floating-contact-toggle {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--amber), var(--amber-dark));
    border: none;
    color: var(--ink);
    font-size: 24px;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(59, 130, 246, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    position: relative;
}

.floating-contact-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 30px rgba(59, 130, 246, 0.5);
}

.floating-contact-toggle .toggle-close {
    display: none;
    font-size: 28px;
    line-height: 1;
}

.floating-contact.open .floating-contact-toggle .toggle-icon {
    display: none;
}

.floating-contact.open .floating-contact-toggle .toggle-close {
    display: block;
}

.floating-contact-panel {
    position: absolute;
    bottom: 70px;
    right: 0;
    width: 320px;
    background: linear-gradient(145deg, var(--slate-800), var(--slate-900));
    border: 1px solid var(--slate-700);
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.12);
    overflow: hidden;
    opacity: 0;
    transform: translateY(20px) scale(0.95);
    pointer-events: none;
    transition: all 0.3s ease;
}

.floating-contact.open .floating-contact-panel {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: all;
}

.floating-header {
    background: linear-gradient(135deg, var(--amber), var(--amber-dark));
    color: var(--ink);
    padding: 20px;
}

.floating-header h4 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 4px;
}

.floating-header p {
    font-size: 13px;
    opacity: 0.9;
}

.floating-body {
    padding: 16px;
}

.floating-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid var(--slate-800);
}

.floating-item:last-child {
    border-bottom: none;
}

.fi-icon {
    font-size: 18px;
    color: var(--amber);
    margin-top: 2px;
    flex-shrink: 0;
}

.fi-label {
    font-size: 12px;
    color: var(--slate-400);
    margin-bottom: 2px;
}

.fi-value {
    font-size: 14px;
    color: var(--text-primary);
    font-weight: 500;
    line-height: 1.4;
}

.floating-footer {
    padding: 0 16px 16px;
}

/* ===== Back to Top ===== */
.back-to-top {
    position: fixed;
    bottom: 100px;
    right: 32px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--amber);
    color: var(--ink);
    border: none;
    font-size: 20px;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(59, 130, 246, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    z-index: 998;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 24px rgba(59, 130, 246, 0.45);
}

/* ===== Responsive ===== */
@media (max-width: 1024px) {
    .product-page { flex-direction: column; padding: 20px 5% 40px; }
    .product-sidebar {
        width: 100%; min-width: auto; max-height: none;
        position: static; display: none;
    }
    .product-sidebar.open { display: flex; }
    .mobile-sidebar-toggle { display: flex; }
    .detail-body { padding: 28px; }
    .detail-visual { aspect-ratio: 16/9; min-height: 220px; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
    .top-bar { font-size: 12px; gap: 16px; }
    .top-bar-hide-mobile { display: none; }
    .nav-links { display: none; }
    .mobile-menu-btn { display: flex; }
    .page-header h1 { font-size: 24px; }
    .detail-body h2 { font-size: 22px; }
    .detail-body { padding: 24px 20px; }
    .detail-visual .main-icon { font-size: 48px; }
    .detail-visual .bg-icon { font-size: 80px; }
    .btn { width: 100%; justify-content: center; }
    .detail-actions { flex-direction: column; }
    .detail-gallery { padding: 24px 20px; }
    .detail-gallery h2 { font-size: 20px; }
    .gallery-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
    .gallery-actions { flex-direction: column; }
    .footer-grid { grid-template-columns: 1fr; gap: 40px; }
    .footer-bottom { flex-direction: column; text-align: center; }
    .floating-contact { bottom: 16px; right: 16px; }
    .floating-contact-panel { width: 280px; right: 0; bottom: 64px; }
    .back-to-top { bottom: 84px; right: 18px; width: 40px; height: 40px; font-size: 18px; }
}

@media (max-width: 480px) {
    .floating-contact-panel {
        width: calc(100vw - 32px);
        right: 0;
    }
}

/* ===== Inquiry Modal ===== */
.modal-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(15, 23, 42, 0.4); backdrop-filter: blur(4px);
    z-index: 1003; opacity: 0; visibility: hidden; transition: all 0.3s ease;
}
.modal-overlay.open { opacity: 1; visibility: visible; }
.modal {
    position: fixed; top: 50%; left: 50%;
    transform: translate(-50%, -50%) scale(0.95);
    width: 90%; max-width: 520px; max-height: 90vh; overflow-y: auto;
    background: linear-gradient(145deg, var(--slate-800), var(--slate-900));
    border: 1px solid var(--slate-700); border-radius: 20px; padding: 32px;
    z-index: 1004; opacity: 0; visibility: hidden; transition: all 0.3s ease;
    box-shadow: 0 30px 80px rgba(0,0,0,0.12);
}
.modal.open { opacity: 1; visibility: visible; transform: translate(-50%, -50%) scale(1); }
.modal-close {
    position: absolute; top: 16px; right: 20px; background: none; border: none;
    color: var(--slate-400); font-size: 28px; cursor: pointer; transition: color 0.3s ease;
    line-height: 1; padding: 0; width: 32px; height: 32px;
    display: flex; align-items: center; justify-content: center;
}
.modal-close:hover { color: var(--amber); }
.modal-header { margin-bottom: 24px; }
.modal-header h3 { font-size: 22px; font-weight: 700; margin-bottom: 6px; }
.modal-header p { color: var(--text-secondary); font-size: 14px; }
.form-group { margin-bottom: 18px; }
.form-label { display: block; font-size: 14px; font-weight: 500; color: var(--text-primary); margin-bottom: 6px; }
.required { color: var(--amber); }
.form-input, .form-select, .form-textarea {
    width: 100%; padding: 12px 16px; background: rgba(0,0,0,0.02);
    border: 1px solid var(--slate-700); border-radius: 10px;
    color: var(--text-primary); font-size: 15px; font-family: inherit;
    transition: all 0.3s ease; outline: none;
}
.form-input:focus, .form-select:focus, .form-textarea:focus {
    border-color: var(--amber); background: rgba(59, 130, 246, 0.05);
}
.form-textarea { resize: vertical; min-height: 100px; }
.form-select option { background: var(--slate-800); color: var(--text-primary); }
.form-success {
    text-align: center; padding: 40px 20px;
}
.form-success .check-icon {
    width: 64px; height: 64px; border-radius: 50%;
    background: rgba(34, 197, 94, 0.15); color: #22c55e;
    display: flex; align-items: center; justify-content: center;
    font-size: 32px; margin: 0 auto 20px;
}
.form-success h3 { font-size: 20px; margin-bottom: 8px; }
.form-success p { color: var(--text-secondary); font-size: 14px; }