/* ========================================
   ALLWINN PRECISION TOOLS - Main Stylesheet
   ======================================== */

:root {
    --primary: #0a2540;
    --secondary: #ff6f00;
    --accent: #00b8d4;
    --dark: #1a1a1a;
    --light: #f8f9fa;
    --gray: #6c757d;
    --success: #28a745;
    --gradient-1: linear-gradient(135deg, #0a2540 0%, #1e4976 100%);
    --gradient-2: linear-gradient(135deg, #ff6f00 0%, #ff9100 100%);
    --gradient-3: linear-gradient(135deg, #00b8d4 0%, #0097a7 100%);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: var(--dark);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
}

h1 { font-size: 3.5rem; }
h2 { font-size: 2.5rem; }
h3 { font-size: 2rem; }
h4 { font-size: 1.5rem; }

/* Utility Classes */
.container-custom {
    max-width: 1320px;
    margin: 0 auto;
    padding: 0 2rem;
}

.section-padding {
    padding: 100px 0;
}

.text-gradient {
    background: var(--gradient-2);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ========================================
   HEADER & NAVIGATION
   ======================================== */

.top-bar {
    background: var(--dark);
    color: white;
    padding: 0.75rem 0;
    font-size: 0.9rem;
}

.top-bar a {
    color: white;
    text-decoration: none;
    margin-left: 2rem;
    transition: color 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.top-bar a:hover {
    color: var(--secondary);
}

.top-bar i {
    color: var(--secondary);
    margin-right: 0.5rem;
}

.main-header {
    background: white;
    box-shadow: 0 2px 20px rgba(0,0,0,0.08);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: all 0.3s ease;
}

.main-header.scrolled {
    box-shadow: 0 2px 30px rgba(0,0,0,0.15);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 0;
}

.logo {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary);
    text-decoration: none;
    z-index: 10001;
}

.logo-icon {
    width: 50px;
    height: 50px;
    background: var(--gradient-2);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.5rem;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 3rem;
    align-items: center;
}

.nav-menu a {
    color: var(--dark);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
    position: relative;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--secondary);
    transition: width 0.3s;
}

.nav-menu a:hover {
    color: var(--secondary);
}

.nav-menu a:hover::after,
.nav-menu a.active::after {
    width: 100%;
}

.cta-button {
    background: var(--gradient-2);
    color: white !important;
    padding: 0.75rem 2rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: transform 0.3s, box-shadow 0.3s, background 0.3s;
}

.cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(255, 111, 0, 0.4);
    background: linear-gradient(135deg, #ff8c00 0%, #ffa500 100%);
    color: white !important;
}

.cta-button::after {
    display: none;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 10001;
    position: relative;
    color: var(--primary);
}

/* Mobile Menu Overlay */
.mobile-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 9998;
    opacity: 0;
    transition: opacity 0.3s;
}

.mobile-menu-overlay.active {
    display: block;
    opacity: 1;
}

/* ========================================
   HERO SECTION
   ======================================== */

.hero {
    background: var(--gradient-1);
    position: relative;
    overflow: hidden;
    padding: 120px 0 80px;
}

.hero::before {
    content: '';
    position: absolute;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(255,111,0,0.1) 0%, transparent 70%);
    top: -200px;
    right: -200px;
    border-radius: 50%;
}

.hero::after {
    content: '';
    position: absolute;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(0,184,212,0.1) 0%, transparent 70%);
    bottom: -150px;
    left: -150px;
    border-radius: 50%;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 2;
}

.hero-content h1 {
    color: white;
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.hero-content .highlight {
    color: var(--secondary);
}

.hero-content p {
    color: rgba(255,255,255,0.9);
    font-size: 1.2rem;
    margin-bottom: 2rem;
    line-height: 1.8;
}

.hero-buttons {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.btn-primary {
    background: var(--gradient-2);
    color: white !important;
    padding: 1rem 2.5rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    display: inline-block;
    transition: all 0.3s;
    border: none;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #ff8c00 0%, #ffa500 100%);
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(255, 111, 0, 0.4);
    color: white !important;
}

.btn-secondary {
    background: rgba(255,255,255,0.1);
    color: white !important;
    padding: 1rem 2.5rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    border: 2px solid rgba(255,255,255,0.3);
    backdrop-filter: blur(10px);
    display: inline-block;
    transition: all 0.3s;
}

.btn-secondary:hover {
    background: rgba(255,255,255,0.2);
    border-color: white;
    color: white !important;
    transform: translateY(-3px);
}

.hero-stats {
    display: flex;
    gap: 3rem;
    margin-top: 3rem;
}

.stat-item {
    text-align: center;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--secondary);
}

.stat-label {
    color: rgba(255,255,255,0.8);
    font-size: 0.9rem;
}

.hero-image {
    position: relative;
}

.hero-image-main {
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    transform: perspective(1000px) rotateY(-5deg);
    transition: transform 0.5s;
}

.hero-image-main:hover {
    transform: perspective(1000px) rotateY(0deg);
}

.hero-image-main img {
    width: 100%;
    height: auto;
    display: block;
}

.floating-card {
    position: absolute;
    background: white;
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    animation: float 3s ease-in-out infinite;
}

.floating-card-1 {
    top: 10%;
    left: -10%;
}

.floating-card-2 {
    bottom: 10%;
    right: -10%;
    animation-delay: 1.5s;
}

.floating-card i {
    font-size: 2rem;
    color: var(--secondary);
    margin-bottom: 0.5rem;
}

.floating-card h4 {
    font-size: 1rem;
    margin-bottom: 0.25rem;
}

.floating-card p {
    font-size: 0.85rem;
    color: var(--gray);
    margin: 0;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-20px); }
}

/* ========================================
   FEATURES SECTION
   ======================================== */

.features {
    background: white;
    padding: 100px 0;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    margin-top: 3rem;
}

.feature-card {
    text-align: center;
    padding: 2.5rem 1.5rem;
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
    transition: all 0.3s;
    border: 1px solid rgba(0,0,0,0.05);
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.1);
}

.feature-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 1.5rem;
    background: var(--gradient-2);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: white;
}

.feature-card h3 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
}

.feature-card p {
    color: var(--gray);
    font-size: 0.95rem;
}

/* ========================================
   ABOUT SECTION
   ======================================== */

.about {
    background: var(--light);
    padding: 100px 0;
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5rem;
    align-items: center;
    margin-top: 3rem;
}

.about-images {
    position: relative;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.about-images img {
    width: 100%;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.about-images img:nth-child(2) {
    margin-top: 3rem;
}

.experience-badge {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    padding: 2rem;
    border-radius: 50%;
    box-shadow: 0 15px 50px rgba(0,0,0,0.2);
    text-align: center;
    width: 150px;
    height: 150px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.experience-badge .number {
    font-size: 3rem;
    font-weight: 700;
    color: var(--secondary);
    line-height: 1;
}

.experience-badge .text {
    font-size: 0.9rem;
    color: var(--gray);
    font-weight: 600;
}

.about-content h2 {
    color: var(--primary);
    margin-bottom: 1.5rem;
}

.about-content p {
    color: var(--gray);
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.about-points {
    list-style: none;
    margin: 2rem 0;
}

.about-points li {
    padding: 1rem;
    background: white;
    border-radius: 10px;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    box-shadow: 0 3px 10px rgba(0,0,0,0.05);
}

.about-points i {
    color: var(--secondary);
    font-size: 1.5rem;
}

/* ========================================
   PRODUCTS SECTION
   ======================================== */

.products {
    padding: 100px 0;
    background: white;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    color: var(--primary);
    margin-bottom: 1rem;
}

.section-header p {
    color: var(--gray);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.product-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
    transition: all 0.3s;
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.15);
}

.product-image {
    position: relative;
    overflow: hidden;
    height: 300px;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.product-card:hover .product-image img {
    transform: scale(1.1);
}

.product-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: var(--secondary);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
}

.product-info {
    padding: 2rem;
}

.product-info h3 {
    color: var(--primary);
    margin-bottom: 0.75rem;
}

.product-info p {
    color: var(--gray);
    margin-bottom: 1.5rem;
}

.product-specs {
    list-style: none;
    margin-bottom: 1.5rem;
}

.product-specs li {
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(0,0,0,0.05);
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
}

.product-specs strong {
    color: var(--primary);
}

.learn-more {
    color: var(--secondary);
    text-decoration: none;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: gap 0.3s, color 0.3s;
}

.learn-more:hover {
    gap: 1rem;
    color: var(--primary);
}

.learn-more i {
    transition: transform 0.3s;
}

.learn-more:hover i {
    transform: translateX(5px);
}

/* ========================================
   CTA SECTION
   ======================================== */

.cta-section {
    background: var(--gradient-1);
    padding: 80px 0;
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(255,111,0,0.1) 0%, transparent 70%);
    top: -300px;
    right: -200px;
    border-radius: 50%;
}

.cta-content {
    text-align: center;
    position: relative;
    z-index: 2;
}

.cta-content h2 {
    color: white;
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.cta-content p {
    color: rgba(255,255,255,0.9);
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

/* ========================================
   FOOTER
   ======================================== */

.footer {
    background: var(--dark);
    color: white;
    padding: 80px 0 30px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 4rem;
    margin-bottom: 3rem;
}

.footer-about h3 {
    color: white;
    margin-bottom: 1rem;
}

.footer-about p {
    color: rgba(255,255,255,0.7);
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-links a {
    width: 40px;
    height: 40px;
    background: rgba(255,255,255,0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    transition: all 0.3s;
}

.social-links a:hover {
    background: var(--secondary);
    transform: translateY(-3px);
}

.footer-links h4 {
    color: white;
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    transition: color 0.3s;
}

.footer-links a:hover {
    color: var(--secondary);
}

.footer-contact p {
    color: rgba(255,255,255,0.7);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.footer-contact i {
    color: var(--secondary);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.5);
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */

@media (max-width: 1200px) {
    .container-custom {
        padding: 0 1.5rem;
    }
    
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .hero-content h1 {
        font-size: 3rem;
    }
}

@media (max-width: 992px) {
    h1 { font-size: 2.5rem; }
    h2 { font-size: 2rem; }
    h3 { font-size: 1.5rem; }
    
    .hero-grid,
    .about-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    
    .hero-content h1 {
        font-size: 2.5rem;
    }
    
    .hero-image {
        order: -1;
    }
    
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 2rem;
    }
    
    .mobile-menu-btn {
        display: block;
        color: var(--primary);
    }
    
    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        height: 100vh;
        width: 280px;
        background: white;
        flex-direction: column;
        padding: 6rem 2rem 2rem;
        box-shadow: -5px 0 20px rgba(0,0,0,0.2);
        transition: right 0.3s ease;
        z-index: 9999;
        gap: 0;
        align-items: flex-start;
    }
    
    .nav-menu li {
        width: 100%;
        margin-bottom: 1rem;
    }
    
    .nav-menu a {
        display: block;
        padding: 0.75rem 0;
        width: 100%;
    }
    
    .nav-menu .cta-button {
        margin-top: 1rem;
        width: 100%;
        text-align: center;
    }
    
    .nav-menu.active {
        right: 0;
    }
    
    /* Mobile menu close button */
    .mobile-menu-btn {
        position: relative;
        z-index: 10000;
    }
}

@media (max-width: 768px) {
    .container-custom {
        padding: 0 1rem;
    }
    
    .section-padding {
        padding: 60px 0;
    }
    
    h1 { font-size: 2rem !important; }
    h2 { font-size: 1.75rem; }
    
    .hero {
        padding: 60px 0 40px;
    }
    
    .hero-content h1 {
        font-size: 2rem;
        line-height: 1.3;
    }
    
    .hero-content p {
        font-size: 1rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        gap: 1rem;
    }
    
    .btn-primary,
    .btn-secondary {
        width: 100%;
        text-align: center;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: 1.5rem;
    }
    
    .floating-card {
        display: none;
    }
    
    .features-grid,
    .products-grid {
        grid-template-columns: 1fr;
    }
    
    .feature-card {
        padding: 2rem 1rem;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
    }
    
    .about-images {
        grid-template-columns: 1fr;
    }
    
    .about-images img:nth-child(2) {
        margin-top: 0;
    }
    
    .experience-badge {
        position: static;
        transform: none;
        margin: 2rem auto;
    }
    
    .top-bar {
        font-size: 0.8rem;
        padding: 0.5rem 0;
    }
    
    .top-bar > div > div {
        flex-direction: column;
        text-align: center;
        gap: 0.5rem;
    }
    
    .top-bar a {
        margin: 0 0.5rem;
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    .container-custom {
        padding: 0 0.75rem;
    }
    
    .hero-content h1 {
        font-size: 1.75rem;
    }
    
    .section-header h2 {
        font-size: 1.5rem;
    }
    
    .stat-number {
        font-size: 2rem;
    }
    
    .product-card,
    .feature-card {
        padding: 1.5rem 1rem;
    }
    
    .nav-menu {
        width: 100%;
        right: -100%;
    }
    
    .logo {
        font-size: 1.5rem;
    }
    
    .logo-icon {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }
}

/* ========================================
   ANIMATIONS
   ======================================== */

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.fade-in {
    animation: fadeIn 1s ease;
}

.fade-in-up {
    animation: fadeInUp 0.8s ease;
}
