/* ========== Reset & Base ========== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --primary: #014099;
    --primary-light: #3A6BB0;
    --primary-lighter: #5B8ED1;
    --primary-dark: #002D6E;
    --primary-alpha: rgba(1, 64, 153, 0.08);
    --primary-alpha-strong: rgba(1, 64, 153, 0.15);
    --text: #1a1a2e;
    --text-light: #555;
    --text-muted: #888;
    --bg: #f8f9fb;
    --white: #ffffff;
    --border: #e8ecf1;
    --shadow-sm: 0 2px 12px rgba(0,0,0,.06);
    --shadow: 0 4px 24px rgba(0,0,0,.08);
    --shadow-lg: 0 8px 40px rgba(0,0,0,.12);
    --radius: 12px;
    --radius-sm: 8px;
    --transition: .3s cubic-bezier(.4,0,.2,1);
}

html { scroll-behavior: smooth; }

body {
    font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Helvetica Neue", sans-serif;
    color: var(--text);
    background: var(--white);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

a { text-decoration: none; color: inherit; }
img { max-width: 100%; display: block; }
ul, ol { list-style: none; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }

/* ========== Page Loader ========== */
.page-loader {
    position: fixed; inset: 0; z-index: 9999; background: var(--white);
    display: flex; align-items: center; justify-content: center;
    transition: opacity .5s, visibility .5s;
}
.page-loader.hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.loader-inner {
    width: 40px; height: 40px;
    border: 3px solid var(--border); border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin .8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ========== Header ========== */
.header {
    position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
    padding: 0 40px;
    transition: var(--transition);
}
.header.scrolled {
    background: rgba(255,255,255,.97);
    backdrop-filter: blur(12px);
    box-shadow: var(--shadow-sm);
}
.header-inner {
    max-width: 1200px; margin: 0 auto;
    display: flex; align-items: center; justify-content: space-between;
    height: 72px;
}
.logo {
    display: flex; align-items: center; gap: 12px;
}
.logo-img { height: 42px; width: auto; filter: brightness(0) invert(1); transition: var(--transition); }
.logo-text { display: flex; flex-direction: column; line-height: 1.2; }
.logo-name { font-size: 20px; font-weight: 700; color: var(--white); letter-spacing: 1px; transition: var(--transition); }
.logo-sub { font-size: 11px; color: rgba(255,255,255,.7); letter-spacing: 2px; transition: var(--transition); }

.header.scrolled .logo-img { filter: none; }
.header.scrolled .logo-name { color: var(--text); }
.header.scrolled .logo-sub { color: var(--text-muted); }

.nav { display: flex; align-items: center; gap: 4px; }
.nav-link {
    padding: 8px 20px; font-size: 15px; color: rgba(255,255,255,.85); border-radius: 6px;
    transition: var(--transition); position: relative; font-weight: 500;
}
.nav-link:hover, .nav-link.active { color: var(--white); background: rgba(255,255,255,.12); }
.header.scrolled .nav-link { color: var(--text-light); }
.header.scrolled .nav-link:hover, .header.scrolled .nav-link.active { color: var(--primary); background: var(--primary-alpha); }

.menu-toggle {
    display: none; flex-direction: column; gap: 5px; padding: 8px;
    background: none; border: none; cursor: pointer; z-index: 1001;
}
.menu-toggle span {
    display: block; width: 26px; height: 2px; background: var(--white); border-radius: 2px;
    transition: var(--transition);
}
.header.scrolled .menu-toggle span { background: var(--text); }

/* ========== Hero Slider ========== */
.hero-slider {
    position: relative; height: 100vh; min-height: 600px;
    overflow: hidden;
}
.slider-wrapper { position: relative; width: 100%; height: 100%; }

.slider-slide {
    position: absolute; inset: 0; opacity: 0; visibility: hidden;
    transition: opacity .8s ease, visibility .8s ease;
}
.slider-slide.active { opacity: 1; visibility: visible; }

.slide-bg {
    position: absolute; inset: 0;
    background: linear-gradient(135deg, #001a3a 0%, #002D6E 30%, #014099 60%, #1a4fa8 100%);
}
.slide-bg.bg-1 { background: linear-gradient(135deg, #001233 0%, #00225A 35%, #014099 65%, #1a4fa8 100%); }
.slide-bg.bg-2 { background: linear-gradient(135deg, #001a3a 0%, #002D6E 30%, #003D8F 55%, #2f63ab 100%); }
.slide-bg.bg-3 { background: linear-gradient(135deg, #001428 0%, #002860 40%, #014099 70%, #1a4fa8 100%); }
.slide-bg::after {
    content: ''; position: absolute; inset: 0;
    background: radial-gradient(ellipse at 30% 50%, rgba(58,107,176,.25) 0%, transparent 60%),
                radial-gradient(ellipse at 70% 30%, rgba(1,64,153,.3) 0%, transparent 55%);
}

.slide-content {
    position: relative; z-index: 2; height: 100%;
    display: flex; align-items: center; justify-content: center;
    padding: 0 60px; max-width: 1200px; margin: 0 auto;
}
.slide-illustration { flex: 0 0 400px; }
.slide-svg { width: 100%; height: auto; max-height: 340px; }
.slide-text {
    flex: 0 0 auto; max-width: 480px;
    padding: 40px 0 40px 60px;
    animation: fadeSlideIn .8s ease forwards;
}
.slider-slide.active .slide-text { animation: fadeSlideIn .8s ease forwards; }
@keyframes fadeSlideIn {
    from { opacity: 0; transform: translateX(30px); }
    to { opacity: 1; transform: translateX(0); }
}
.slide-title {
    font-size: clamp(32px, 5vw, 52px); font-weight: 700; color: var(--white);
    letter-spacing: 3px; margin-bottom: 12px; line-height: 1.2;
}
.slide-sub {
    font-size: clamp(13px, 1.5vw, 15px); color: rgba(255,255,255,.7);
    letter-spacing: 6px; margin-bottom: 20px; font-weight: 400;
}
.slide-desc {
    font-size: clamp(14px, 1.6vw, 17px); color: rgba(255,255,255,.6);
    margin-bottom: 36px; line-height: 1.7;
}
.slide-btn {
    display: inline-block; padding: 14px 44px;
    border: 2px solid rgba(255,255,255,.5); color: var(--white);
    border-radius: 50px; font-size: 15px; letter-spacing: 2px;
    transition: var(--transition);
}
.slide-btn:hover { background: rgba(255,255,255,.12); border-color: var(--white); }

/* Slider Arrows */
.slider-arrow {
    position: absolute; top: 50%; transform: translateY(-50%); z-index: 3;
    width: 48px; height: 48px; border-radius: 50%;
    background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.2);
    color: rgba(255,255,255,.7); cursor: pointer; display: flex;
    align-items: center; justify-content: center; transition: var(--transition);
}
.slider-arrow:hover { background: rgba(255,255,255,.18); color: var(--white); }
.slider-arrow svg { width: 22px; height: 22px; }
.slider-prev { left: 28px; }
.slider-next { right: 28px; }

/* Slider Dots */
.slider-dots {
    position: absolute; bottom: 70px; left: 50%; transform: translateX(-50%);
    display: flex; gap: 12px; z-index: 3;
}
.dot {
    width: 12px; height: 12px; border-radius: 50%;
    background: rgba(255,255,255,.3); cursor: pointer; transition: var(--transition);
}
.dot.active { background: var(--white); box-shadow: 0 0 8px rgba(255,255,255,.4); }

/* Scroll hint */
.hero-scroll {
    position: absolute; bottom: 26px; left: 50%; transform: translateX(-50%); z-index: 3;
}
.hero-scroll span {
    display: block; width: 24px; height: 38px; border: 2px solid rgba(255,255,255,.35); border-radius: 12px;
    position: relative;
}
.hero-scroll span::after {
    content: ''; width: 3px; height: 7px; background: rgba(255,255,255,.7); border-radius: 2px;
    position: absolute; top: 7px; left: 50%; transform: translateX(-50%);
    animation: scrollWheel 1.8s ease-in-out infinite;
}
@keyframes scrollWheel {
    0% { opacity: 1; top: 7px; }
    100% { opacity: 0; top: 22px; }
}

/* ========== Section Common ========== */
.section { padding: 100px 0; }
.section-header { text-align: center; margin-bottom: 60px; }
.section-title {
    font-size: clamp(26px, 4vw, 36px); font-weight: 700; color: var(--text);
    margin-bottom: 8px; letter-spacing: 2px;
}
.section-subtitle {
    font-size: 14px; color: var(--primary); letter-spacing: 4px; font-weight: 500;
    margin-bottom: 16px;
}
.section-divider {
    width: 50px; height: 3px; background: var(--primary); margin: 0 auto; border-radius: 2px;
}
.section-desc {
    margin-top: 16px; color: var(--text-muted); font-size: 16px;
}

/* ========== About ========== */
.about { background: var(--bg); }
.about-grid {
    display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: start;
}
.about-text p {
    font-size: 16px; color: var(--text-light); margin-bottom: 16px;
    text-indent: 2em; line-height: 1.9;
}
.about-services {
    display: grid; grid-template-columns: 1fr 1fr; gap: 16px;
}
.service-item {
    display: flex; align-items: center; gap: 14px;
    padding: 20px 22px; background: var(--white); border-radius: var(--radius-sm);
    box-shadow: var(--shadow-sm); transition: var(--transition); cursor: default;
    position: relative; overflow: hidden;
}
.service-item::before {
    content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 0;
    background: linear-gradient(180deg, var(--primary) 0%, var(--primary-light) 100%);
    transition: width .35s ease; border-radius: 0 4px 4px 0;
}
.service-item:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.service-item:hover::before { width: 4px; }
.service-icon {
    width: 48px; height: 48px; border-radius: 12px;
    background: linear-gradient(135deg, var(--primary-alpha) 0%, var(--primary-alpha-strong) 100%);
    color: var(--primary);
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0; transition: var(--transition);
}
.service-icon svg { width: 26px; height: 26px; transition: var(--transition); }
.service-item:hover .service-icon {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: var(--white);
    box-shadow: 0 6px 20px rgba(1,64,153,.35);
}
.service-item span { font-size: 14px; color: var(--text); font-weight: 500; transition: var(--transition); }
.service-item:hover span { color: var(--primary); }

/* ========== Products ========== */
.products { background: var(--white); }
.products-grid {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px;
}
.product-card {
    background: var(--white); border-radius: var(--radius);
    overflow: hidden; box-shadow: var(--shadow-sm); transition: var(--transition);
    border: 1px solid var(--border);
}
.product-card:hover { transform: translateY(-8px); box-shadow: var(--shadow-lg); }
.product-img {
    height: 220px; position: relative; overflow: hidden;
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(160deg, #eef3fa 0%, #e3eaf5 40%, #dce5f2 100%);
}
.product-bg {
    position: absolute; inset: 0; opacity: 0;
    background: linear-gradient(160deg, var(--primary) 0%, var(--primary-light) 100%);
    transition: opacity .4s ease;
}
.product-card:hover .product-bg { opacity: 1; }
.product-icon {
    width: 90px; height: 90px; color: var(--primary); position: relative; z-index: 1;
    transition: all .4s cubic-bezier(.4,0,.2,1);
}
.product-card:hover .product-icon {
    color: var(--white); transform: scale(1.15) translateY(-4px);
}
.product-img::after {
    content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--primary-light));
    transform: scaleX(0); transition: transform .4s; z-index: 2;
}
.product-card:hover .product-img::after { transform: scaleX(1); }
.product-info { padding: 28px 24px; }
.product-info h3 {
    font-size: 18px; font-weight: 600; color: var(--text); margin-bottom: 10px;
    transition: var(--transition);
}
.product-card:hover .product-info h3 { color: var(--primary); }
.product-info p { font-size: 14px; color: var(--text-light); line-height: 1.8; }

/* ========== Contact ========== */
.contact { background: var(--bg); }
.contact-grid {
    display: grid; grid-template-columns: 1fr 1fr; gap: 40px;
}
.contact-card {
    background: var(--white); padding: 40px; border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
}
.contact-card h3 {
    font-size: 22px; font-weight: 600; color: var(--text); margin-bottom: 28px;
    padding-bottom: 16px; border-bottom: 2px solid var(--primary-alpha-strong);
}
.contact-item {
    display: flex; padding: 14px 0; border-bottom: 1px solid var(--border);
    align-items: flex-start; gap: 16px;
}
.contact-item:last-child { border-bottom: none; }
.contact-label {
    font-size: 14px; color: var(--primary); font-weight: 600; white-space: nowrap;
    min-width: 70px; padding-top: 1px;
}
.contact-item span, .contact-item a {
    font-size: 15px; color: var(--text-light); word-break: break-all;
}
.contact-item a { color: var(--primary); transition: var(--transition); }
.contact-item a:hover { color: var(--primary-dark); text-decoration: underline; }

.contact-map { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); }
.map-wrapper { position: relative; width: 100%; height: 100%; min-height: 400px; }
.map-wrapper iframe { width: 100%; height: 100%; min-height: 400px; border: 0; }

/* ========== Footer ========== */
.footer {
    background: #001433; color: rgba(255,255,255,.7); padding: 40px 0 24px;
}
.footer-content {
    display: flex; align-items: center; justify-content: space-between;
    padding-bottom: 28px; border-bottom: 1px solid rgba(255,255,255,.1);
    margin-bottom: 20px;
}
.footer-brand { display: flex; align-items: center; gap: 12px; }
.footer-logo { height: 36px; width: auto; filter: brightness(0) invert(1); }
.footer-name { font-size: 16px; color: var(--white); font-weight: 600; letter-spacing: 1px; }
.footer-links { display: flex; gap: 28px; }
.footer-links a { font-size: 14px; transition: var(--transition); }
.footer-links a:hover { color: var(--white); }
.footer-bottom { text-align: center; }
.footer-bottom p { font-size: 13px; margin-bottom: 4px; }
.footer-bottom a { transition: var(--transition); }
.footer-bottom a:hover { color: var(--white); }

/* ========== Animations ========== */
.animate-fadeUp {
    opacity: 0; transform: translateY(30px);
    animation: fadeUp .8s ease forwards;
}
.delay-200 { animation-delay: .2s; }
.delay-400 { animation-delay: .4s; }
.delay-600 { animation-delay: .6s; }
@keyframes fadeUp {
    to { opacity: 1; transform: translateY(0); }
}

.reveal {
    opacity: 0; transform: translateY(40px);
    transition: opacity .7s ease, transform .7s ease;
}
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ========== Responsive ========== */
/* Tablet Landscape / Small Laptop (≤1024px) */
@media (max-width: 1024px) {
    .container { padding: 0 28px; }
    .section { padding: 80px 0; }

    .slide-content { padding: 0 36px; }
    .slide-illustration { flex: 0 0 340px; }
    .slide-svg { max-height: 280px; }
    .slide-text { padding-left: 36px; max-width: 380px; }
    .slide-title { font-size: 36px; letter-spacing: 2px; }
    .slider-arrow { width: 40px; height: 40px; }
    .slider-arrow svg { width: 18px; height: 18px; }
    .slider-prev { left: 16px; }
    .slider-next { right: 16px; }

    .products-grid { grid-template-columns: repeat(2, 1fr); gap: 24px; }
    .product-img { height: 180px; }
    .product-icon { width: 72px; height: 72px; }
    .about-grid { gap: 36px; }
    .about-services { gap: 12px; }
    .service-item { padding: 16px 18px; }
    .contact-grid { gap: 28px; }
    .contact-card { padding: 28px; }
}

/* Tablet Portrait (≤768px) */
@media (max-width: 768px) {
    .header { padding: 0 20px; }
    .header-inner { height: 60px; }
    .logo-img { height: 32px; }
    .logo-name { font-size: 16px; }
    .logo-sub { font-size: 10px; }
    .menu-toggle { display: flex; }
    .nav {
        position: fixed; top: 0; right: -280px; width: 280px; height: 100vh;
        flex-direction: column; gap: 0; padding: 80px 20px 20px;
        background: var(--white); box-shadow: -4px 0 20px rgba(0,0,0,.1);
        transition: right .35s ease; z-index: 999;
    }
    .nav.open { right: 0; }
    .nav-link { padding: 14px 16px; color: var(--text-light) !important; font-size: 16px; border-radius: 8px; }
    .nav-link:hover, .nav-link.active { color: var(--primary) !important; background: var(--primary-alpha) !important; }
    .nav-overlay.active { display: block; }

    .hero-slider { min-height: 560px; }
    .slide-content { flex-direction: column; padding: 80px 28px 0; text-align: center; }
    .slide-illustration { flex: 0 0 auto; width: 240px; margin: 0 auto; }
    .slide-svg { max-height: 180px; }
    .slide-text { padding: 20px 0 0; max-width: 100%; }
    .slide-title { font-size: 26px; letter-spacing: 1px; }
    .slide-sub { letter-spacing: 4px; }
    .slide-desc { font-size: 14px; }
    .slide-btn { padding: 12px 36px; font-size: 14px; }
    .slider-arrow { width: 36px; height: 36px; }
    .slider-prev { left: 8px; }
    .slider-next { right: 8px; }
    .slider-dots { bottom: 52px; }
    .hero-scroll { bottom: 18px; }

    .section { padding: 60px 0; }
    .section-title { font-size: 26px; }
    .section-desc { font-size: 14px; }
    .about-grid { grid-template-columns: 1fr; gap: 28px; }
    .about-services { grid-template-columns: 1fr 1fr; gap: 12px; }
    .about-text p { font-size: 15px; }
    .service-item { padding: 14px 16px; }
    .service-icon { width: 40px; height: 40px; border-radius: 10px; }
    .service-icon svg { width: 22px; height: 22px; }

    .products-grid { grid-template-columns: 1fr 1fr; gap: 16px; }
    .product-img { height: 160px; }
    .product-icon { width: 60px; height: 60px; }
    .product-info { padding: 18px 14px; }
    .product-info h3 { font-size: 15px; }
    .product-info p { font-size: 13px; }

    .contact-grid { grid-template-columns: 1fr; gap: 24px; }
    .contact-card { padding: 24px; }
    .map-wrapper { min-height: 280px; }
    .map-wrapper iframe { min-height: 280px; }

    .footer-content { flex-direction: column; gap: 18px; text-align: center; }
    .footer-links { flex-wrap: wrap; justify-content: center; gap: 16px; }
    .footer-name { font-size: 14px; }
}

/* Phone (≤480px) */
@media (max-width: 480px) {
    .container { padding: 0 16px; }

    .hero-slider { min-height: 500px; }
    .slide-content { padding: 70px 16px 0; }
    .slide-illustration { width: 180px; }
    .slide-svg { max-height: 140px; }
    .slide-title { font-size: 22px; }
    .slide-sub { font-size: 11px; letter-spacing: 3px; }
    .slide-desc { font-size: 13px; margin-bottom: 24px; }
    .slide-btn { padding: 10px 28px; font-size: 13px; }
    .slider-dots { bottom: 46px; gap: 8px; }
    .dot { width: 10px; height: 10px; }
    .hero-scroll span { width: 20px; height: 32px; }

    .section { padding: 50px 0; }
    .section-title { font-size: 22px; }
    .section-subtitle { font-size: 12px; letter-spacing: 3px; }
    .about-services { grid-template-columns: 1fr; gap: 10px; }

    .products-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
    .product-img { height: 140px; }
    .product-icon { width: 52px; height: 52px; }
    .product-info { padding: 14px 12px; }
    .product-info h3 { font-size: 14px; }
    .product-info p { font-size: 12px; line-height: 1.5; }

    .contact-card h3 { font-size: 18px; }
    .contact-item { flex-direction: column; gap: 4px; padding: 10px 0; }
    .contact-label { min-width: auto; }

    .footer { padding: 28px 0 18px; }
    .footer-logo { height: 30px; }
    .footer-links a { font-size: 13px; }
}

/* Small Phone (≤360px) */
@media (max-width: 360px) {
    .hero-slider { min-height: 440px; }
    .slide-content { padding: 60px 12px 0; }
    .slide-illustration { width: 150px; }
    .slide-svg { max-height: 120px; }
    .slide-title { font-size: 20px; }
    .slide-sub { font-size: 10px; letter-spacing: 2px; }
    .slide-desc { font-size: 12px; margin-bottom: 20px; }
    .slide-btn { padding: 8px 22px; font-size: 12px; letter-spacing: 1px; }
    .slider-arrow { display: none; }

    .products-grid { grid-template-columns: 1fr; }
    .product-img { height: 180px; }
    .product-icon { width: 66px; height: 66px; }
}
