:root {
    --color-primary: #004080;
    --color-primary-dark: #003060;
    --color-primary-light: #336699;
    --color-accent: #007bff;
    --color-text: #333;
    --color-text-light: #666;
    --color-bg: #fff;
    --color-bg-light: #f5f7fa;
    --color-border: #e0e0e0;
    --font-base: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --max-width: 1200px;
    --header-height: 70px;
}

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-base);
    color: var(--color-text);
    line-height: 1.6;
    background: var(--color-bg);
}

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 20px;
}

a {
    color: var(--color-primary);
    text-decoration: none;
    transition: color 0.2s;
}

a:hover {
    color: var(--color-accent);
}

img {
    max-width: 100%;
    height: auto;
}

.btn {
    display: inline-block;
    padding: 12px 28px;
    font-size: 1rem;
    font-weight: 500;
    border: 2px solid transparent;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
    text-align: center;
}

.btn-primary {
    background: var(--color-primary);
    color: #fff;
}

.btn-primary:hover {
    background: var(--color-primary-dark);
    color: #fff;
}

.btn-white {
    background: #fff;
    color: var(--color-primary);
}

.btn-white:hover {
    background: rgba(255,255,255,0.9);
    color: var(--color-primary-dark);
}

.btn-outline {
    background: transparent;
    border-color: var(--color-primary);
    color: var(--color-primary);
}

.btn-outline:hover {
    background: var(--color-primary);
    color: #fff;
}

/* Header */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: #fff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: var(--header-height);
}

.site-logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-primary);
}

.site-nav {
    position: relative;
}

.nav-list {
    list-style: none;
    display: flex;
    gap: 30px;
    margin: 0;
    padding: 0;
}

.nav-item {
    position: relative;
}

.nav-link {
    color: var(--color-text);
    font-weight: 500;
    padding: 20px 0;
    display: flex;
    align-items: center;
    gap: 5px;
}

.nav-arrow {
    font-size: 0.7em;
    transition: transform 0.2s;
}

/* Submenu / Dropdown */
.nav-submenu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 180px;
    background: #fff;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    border-radius: 0 0 4px 4px;
    list-style: none;
    padding: 8px 0;
    z-index: 100;
    border-top: 2px solid var(--color-primary);
}

.nav-item:hover > .nav-submenu {
    display: block;
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(5px); }
    to { opacity: 1; transform: translateY(0); }
}

.nav-submenu li a {
    display: block;
    padding: 10px 20px;
    color: var(--color-text);
    transition: all 0.2s;
    white-space: nowrap;
}

.nav-submenu li a:hover {
    background: var(--color-bg-light);
    color: var(--color-primary);
    padding-left: 25px;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--color-primary);
    transition: width 0.3s;
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

/* Hero Slider */
.hero-slider {
    position: relative;
    overflow: hidden;
}

.hero-slides {
    position: relative;
}

.hero-slide {
    display: none;
    padding: 120px 0;
    color: #fff;
    text-align: center;
}

.hero-slide.active {
    display: block;
}

.hero-content h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.hero-content p {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    opacity: 0.9;
}

.hero-controls {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    transform: translateY(-50%);
    display: flex;
    justify-content: space-between;
    padding: 0 20px;
    pointer-events: none;
}

.hero-btn {
    background: rgba(255,255,255,0.3);
    border: none;
    color: #fff;
    font-size: 1.5rem;
    /*padding: 10px 15px;*/
    width: 50px;
    height: 50px;
    cursor: pointer;
    pointer-events: auto;
    border-radius: 50%;
    transition: background 0.2s;
}

.hero-btn:hover {
    background: rgba(255,255,255,0.5);
}

.hero-dots {
    display: flex;
    justify-content: center;
    gap: 10px;
    padding: 20px 0;
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
}

.hero-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid #fff;
    background: transparent;
    cursor: pointer;
    transition: background 0.2s;
}

.hero-dot.active {
    background: #fff;
}

/* Sections */
section.home, .section-contact {
    padding: 60px 0;
}

.section-products {
    padding: 0 0 60px 0;
}

.section-about {
    padding: 30px 0 60px 0;
}

.section-title {
    font-size: 2rem;
    text-align: center;
    margin-bottom: 0.5rem;
    color: var(--color-primary);
}

.section-subtitle {
    text-align: center;
    color: var(--color-text-light);
    margin-bottom: 3rem;
    font-style: italic;
}

.section-more {
    text-align: center;
    margin-top: 3rem;
}


/* Products */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
}

.product-card {
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.product-image {
    position: relative;
    height: 200px;
    background: var(--color-bg-light);
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.product-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: var(--color-primary);
    color: #fff;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
}

.product-info {
    padding: 20px;
}

.product-info h3 {
    font-size: 1.2rem;
    margin-bottom: 8px;
}

.product-info p {
    color: var(--color-text-light);
    font-size: 0.9rem;
    margin-bottom: 12px;
}

.product-more {
    color: var(--color-primary);
    font-weight: 500;
    font-size: 0.9rem;
}

.placeholder-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
}

.placeholder-card {
    background: var(--color-bg-light);
    padding: 40px 30px;
    border-radius: 8px;
    text-align: center;
    border: 2px dashed var(--color-border);
}

.placeholder-card span {
    display: block;
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--color-primary);
    margin-bottom: 8px;
}

.placeholder-text {
    text-align: center;
    padding: 60px 0;
    color: var(--color-text-light);
}

/* About */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.about-title {
    font-size: 2rem;
    color: var(--color-primary);
    margin-bottom: 0.5rem;
}

.about-subtitle {
    color: var(--color-text-light);
    font-style: italic;
    margin-bottom: 1.5rem;
}

.about-text p {
    margin-bottom: 1rem;
    color: var(--color-text-light);
}

.about-stats {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.stat-item {
    background: var(--color-bg-light);
    padding: 25px;
    border-radius: 8px;
    text-align: center;
}

.stat-num {
    display: block;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--color-primary);
}

.stat-item span:last-child {
    color: var(--color-text-light);
}

/* News */
.news-list {
    /*max-width: 800px;*/
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
}

.news-item {
    padding: 25px 0;
    border-bottom: 1px solid var(--color-border);
}

/*.news-item:last-child {
    border-bottom: none;
}*/

.news-item time {
    color: var(--color-text-light);
    font-size: 0.9rem;
}

.news-item h3 {
    margin: 8px 0;
}

.news-item h3 a:hover {
    color: var(--color-primary);
}

.news-item p {
    color: var(--color-text-light);
    font-size: 0.95rem;
}

.read-more {
    display: inline-block;
    margin-top: 10px;
    font-weight: 500;
}

.news-placeholder {
    text-align: center;
    padding: 60px 0;
    color: var(--color-text-light);
}

/* Page Header */
.page-header {
    background: var(--color-primary);
    color: #fff;
    padding: 60px 0;
    text-align: center;
}

.page-header h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.page-header p {
    font-size: 1.1rem;
    opacity: 0.8;
}

/* Detail Pages */
.section-detail, .section-content {
    padding: 60px 0;
}

.detail-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: start;
}

.detail-image {
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.detail-image img {
    width: 100%;
    display: block;
}

.detail-info h2 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--color-text-light);
}

.detail-info .desc {
    margin-bottom: 1.5rem;
    color: var(--color-text-light);
}

.specs {
    background: var(--color-bg-light);
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 1.5rem;
}

.specs h3 {
    margin-bottom: 10px;
    color: var(--color-primary);
}

.content-wrapper {
    max-width: 800px;
    margin: 0 auto;
}

.content-wrapper .lead {
    font-size: 1.1rem;
    color: var(--color-text-light);
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--color-border);
}

.content-wrapper .body {
    line-height: 1.8;
}

/* About Page */
.about-content {
    max-width: 800px;
    margin: 0 auto;
}

.about-content h2 {
    font-size: 1.5rem;
    margin: 2rem 0 1rem;
    color: var(--color-primary);
}

.about-content p {
    margin-bottom: 1rem;
    color: var(--color-text-light);
}

.timeline {
    list-style: none;
    padding-left: 20px;
    border-left: 3px solid var(--color-primary);
}

.timeline li {
    margin-bottom: 15px;
    padding-left: 15px;
    position: relative;
}

.timeline li::before {
    content: '';
    position: absolute;
    left: -26px;
    top: 8px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--color-primary);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 1.5rem;
}

.feature-item {
    background: var(--color-bg-light);
    padding: 25px;
    border-radius: 8px;
    text-align: center;
}

.feature-item h3 {
    margin-bottom: 10px;
    color: var(--color-primary);
}

.feature-item p {
    font-size: 0.9rem;
}

/* Contact Page */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
}

.contact-info h2, .contact-form-wrapper h2 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: var(--color-primary);
}

.info-item {
    margin-bottom: 20px;
}

.info-item h3 {
    font-size: 1rem;
    margin-bottom: 5px;
    color: var(--color-text);
}

.info-item p {
    color: var(--color-text-light);
}

.contact-form .form-group {
    margin-bottom: 20px;
}

.contact-form label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--color-border);
    border-radius: 4px;
    font-size: 1rem;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--color-primary);
}

/* Footer */
.site-footer {
    background: var(--color-primary-dark);
    color: #fff;
    padding: 60px 0 30px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-col h4 {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    color: #fff;
}

.footer-col p,
.footer-col a {
    color: rgba(255,255,255,0.8);
    font-size: 0.9rem;
}

.footer-col a {
    display: block;
    margin-bottom: 8px;
}

.footer-col a:hover {
    color: #fff;
}

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255,255,255,0.2);
    font-size: 0.85rem;
    color: rgba(255,255,255,0.6);
}

/* Responsive */
@media (max-width: 768px) {
    .header-inner {
        flex-direction: column;
        height: auto;
        padding: 15px 0;
    }

    .site-nav {
        gap: 15px;
        width: 100%;
    }

    .nav-list {
        flex-wrap: wrap;
        justify-content: center;
        gap: 10px;
    }

    .nav-submenu {
        position: static;
        box-shadow: none;
        background: var(--color-bg-light);
        border-top: none;
        border-radius: 4px;
        margin-top: 5px;
        padding: 5px 0;
    }
        flex-wrap: wrap;
        justify-content: center;
        margin-top: 10px;
    }

    .hero-content h1 {
        font-size: 2rem;
    }


}

/* ==================== Category Filter ==================== */


.section-news .category-filter {
    max-width: 800px;
    padding: 20px 0 0;
    margin: 0px auto;
}
.category-filter {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 40px;
    /*padding-bottom: 20px;*/
    padding: 15px 0;
    border-bottom: 1px solid var(--color-border);
}

.category-tag {
    display: inline-block;
    padding: 8px 16px;
    margin: 10px 5px;
    border: 1px solid var(--color-border);
    border-radius: 20px;
    color: var(--color-text-light);
    text-decoration: none;
    font-size: 0.9rem;
    transition: all 0.2s;
    background: var(--color-bg);
}

.category-tag:hover {
    border-color: var(--color-accent);
    color: var(--color-accent);
}

.category-tag.active {
    background: var(--color-accent);
    border-color: var(--color-accent);
    color: #fff;
}

.news-category-tag {
    display: inline-block;
    padding: 3px 10px;
    background: var(--color-bg-light);
    border-radius: 12px;
    font-size: 0.75rem;
    color: var(--color-text-light);
    margin-bottom: 10px;
}

/* Contact Form */
.required {
    color: var(--color-accent);
}

.flash-messages {
    margin-bottom: 20px;
}

.flash {
    padding: 12px 15px;
    border-radius: 4px;
    margin-bottom: 10px;
    font-size: 0.9rem;
}

.flash-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.flash-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}
