/* ===== 2025 TEXCEL SOLUTIONS - INDEX PAGE ===== */
/* Modern, Professional Design with Glassmorphism & Gradient Focus */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

:root {
    --primary-gradient: linear-gradient(135deg, #F6A514 0%, #FDD707 100%);
    --secondary-gradient: linear-gradient(135deg, #ffffff 0%, #000000 100%);
    --accent-gradient: linear-gradient(135deg, #F6A514 0%, #FDD707 100%);
    --success-gradient: linear-gradient(135deg, #ffffff 0%, #000000 100%);
    --warning-gradient: linear-gradient(135deg, #000000 0%, #ffffff 100%);
    --info-gradient: linear-gradient(135deg, #ffffff 0%, #000000 100%);
    --primary-color: #000000;
    --secondary-color: #ffffff;
    --accent-color: #F6A514;
    --success-color: #ffffff;
    --warning-color: #000000;
    --info-color: #ffffff;
    --text-primary: #0b1a23; /* darker, warmer for better contrast on light bg */
    --text-secondary: #475569; /* muted but readable */
    --text-muted: #6b7280;
    --nav-hover-bg: rgba(0,0,0,0.03);
    --bg-primary: #ffffff;
    --bg-secondary: #f5f5f5;
    --bg-tertiary: #e0e0e0;
    --glass-bg: rgba(255, 255, 255, 0.9);
    --glass-border: rgba(0, 0, 0, 0.1);
    --glass-bg-dark: rgba(0, 0, 0, 0.9);
    --glass-border-dark: rgba(255, 255, 255, 0.1);
    --shadow-light: 0 4px 20px rgba(246, 165, 20, 0.10);
    --shadow-medium: 0 8px 32px rgba(246, 165, 20, 0.14);
    --shadow-strong: 0 20px 60px rgba(246, 165, 20, 0.18);
    --border-radius: 16px;
    --border-radius-lg: 24px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="dark"] {
    --text-primary: #ffffff;
    --text-secondary: #cbd5e1;
    --text-muted: #94a3b8;
    --bg-primary: #0f172a;
    --bg-secondary: #1e293b;
    --bg-tertiary: #334155;
    --glass-bg: rgba(15, 23, 42, 0.8);
    --glass-border: rgba(255, 255, 255, 0.1);
    --nav-hover-bg: rgba(255,255,255,0.04);
    --shadow-light: 0 4px 20px rgba(246, 165, 20, 0.12);
    --shadow-medium: 0 8px 32px rgba(246, 165, 20, 0.20);
    --shadow-strong: 0 20px 60px rgba(246, 165, 20, 0.28);
}

/* ===== RESET & BASE ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background: var(--bg-primary);
    overflow-x: hidden;
    position: relative;
}

body::before {
    content: none;
}

@keyframes backgroundShift {
    0% { transform: translateX(0) translateY(0); }
    100% { transform: translateX(0) translateY(0); }
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* ===== NAVIGATION ===== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
    transition: var(--transition);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 80px;
}

.logo img {
    height: 40px;
    width: auto;
    transition: var(--transition);
}

.logo:hover img {
    transform: scale(1.05);
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-link {
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    position: relative;
    transition: var(--transition);
    padding: 0.5rem 1rem;
    border-radius: 8px;
}

.nav-link:hover,
.nav-link.active {
    color: var(--accent-color);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--primary-gradient);
    transition: var(--transition);
    transform: translateX(-50%);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.contact-btn {
    background: var(--primary-gradient);
    color: white !important;
    padding: 1rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    box-shadow: var(--shadow-medium);
    transition: var(--transition);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    position: relative;
    overflow: hidden;
}

.contact-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.6s;
}

.contact-btn:hover::before {
    left: 100%;
}

.contact-btn:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-strong);
}

.theme-toggle {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    font-size: 1.2rem;
    cursor: pointer;
    padding: 0.6rem;
    border-radius: var(--border-radius);
    transition: var(--transition);
    color: var(--text-secondary);
    backdrop-filter: blur(10px);
    margin-left: 0.5rem;
}

.theme-toggle:hover {
    background: var(--primary-gradient);
    color: white;
    transform: scale(1.05);
    box-shadow: var(--shadow-light);
    border-color: var(--primary-color);
}

.mobile-menu-btn {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 4px;
    padding: 0.5rem;
    border-radius: 6px;
    transition: var(--transition);
}

.mobile-menu-btn span {
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    transition: var(--transition);
    transform-origin: center;
}

.mobile-menu-btn.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.mobile-menu-btn.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-btn.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

.mobile-menu {
    position: fixed;
    top: 80px;
    left: 0;
    right: 0;
    background: var(--bg-primary);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 999;
}

.mobile-menu.active {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
}

.mobile-link {
    display: block;
    padding: 1.5rem 2rem;
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 500;
    border-bottom: 1px solid var(--glass-border);
    transition: var(--transition);
}

.mobile-link:hover,
.mobile-link.active {
    background: var(--glass-bg);
    color: var(--accent-color);
    padding-left: 2.5rem;
}

/* ===== HERO SECTION ===== */
.hero {
    position: relative;
    /* center within viewport while accounting for fixed navbar */
    min-height: calc(100vh - 80px);
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-primary);
    overflow: hidden;
    padding: 4rem 0;
}

/* Only add margin-top to hero on home page (index.html) */
body:not(.about-page):not(.company-page):not(.cyber-page):not(.recruitment-page):not(.contact-page) .hero {
    margin-top: 80px;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.1) 0%, rgba(255, 255, 255, 0.1) 100%);
    z-index: 1;
}

/* Particle Network Canvas */
#particleCanvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    opacity: 0.4;
}

.hero-container {
    position: relative;
    z-index: 2;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    text-align: center;
}

.hero-content {
    flex: 1;
    text-align: center;
    max-width: 900px;
}

.hero-welcome {
    font-size: clamp(0.85rem, 1.5vw, 1rem);
    color: var(--text-secondary);
    margin-bottom: 1rem;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.hero-title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 2.5rem;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.25rem);
    color: var(--text-secondary);
    margin-bottom: 2.5rem;
    line-height: 1.6;
    max-width: 500px;
}

.hero-cta {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    justify-content: center;
}

.hero-visual {
    display: none;
}

.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    font-size: 0.9rem;
    z-index: 3;
    animation: bounce 2s infinite;
}

.scroll-mouse {
    width: 24px;
    height: 36px;
    border: 2px solid var(--text-secondary);
    border-radius: 12px;
    position: relative;
    display: flex;
    justify-content: center;
}

.scroll-wheel {
    width: 4px;
    height: 8px;
    background: var(--text-secondary);
    border-radius: 2px;
    position: absolute;
    top: 6px;
    animation: scroll 2s infinite;
}

.hero-visual {
    position: relative;
    height: 400px;
    overflow: hidden;
    display: none; /* Hide the old floating shapes */
}

.floating-shapes {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
}

.shape {
    position: absolute;
    border-radius: 50%;
    animation: float 6s ease-in-out infinite;
    opacity: 0.8;
}

.shape-1 {
    width: 120px;
    height: 120px;
    background: linear-gradient(135deg, #FDD707 0%, #F6A514 100%);
    top: 20%;
    left: 10%;
    animation-delay: 0s;
}

.shape-2 {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #F6A514 0%, #FDD707 100%);
    top: 60%;
    right: 15%;
    animation-delay: 2s;
}

.shape-3 {
    width: 100px;
    height: 100px;
    background: linear-gradient(135deg, #FDD707 0%, #F6A514 100%);
    bottom: 10%;
    left: 20%;
    animation-delay: 4s;
}

/* ===== SERVICES SECTION ===== */
.services {
    padding: 4rem 0;
    background: var(--bg-secondary);
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text-primary);
    text-align: center;
    margin-bottom: 2rem;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.service-card {
    background: var(--bg-primary);
    border: 1px solid var(--text-secondary);
    padding: 2rem;
    text-align: center;
    border-radius: 8px;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-medium);
    border-color: var(--accent-color);
}

.service-icon {
    margin-bottom: 1.5rem;
}

.icon-wrapper {
    width: 80px;
    height: 80px;
    margin: 0 auto;
    background: var(--primary-gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2rem;
    transition: var(--transition);
}

.service-card:hover .icon-wrapper {
    transform: scale(1.1);
    box-shadow: var(--shadow-light);
}

.icon-wrapper svg {
    width: 40px;
    height: 40px;
}

.service-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1rem;
}

.service-description {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

/* ===== FOOTER ===== */
.footer {
    /* Use theme-aware colors: light theme -> light bg with dark text; dark theme handled below */
    background: var(--bg-primary);
    color: var(--text-primary);
    border-top: 1px solid rgba(0,0,0,0.06);
    padding: 3rem 0 1rem;
    margin-top: 0;
    position: relative; /* ensure footer sits above accidental overlays */
    z-index: 3;
}

/* Dark theme: stronger footer background and white text for contrast */
[data-theme="dark"] .footer {
    background: linear-gradient(135deg, #1a365d 0%, #2d3748 100%);
    color: #ffffff;
    border-top: 1px solid rgba(255,255,255,0.06);
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section {
    display: flex;
    flex-direction: column;
    /* Make footer sections visible by default so pages without the observer still show content */
    opacity: 1;
    transform: none;
    transition: var(--transition);
}

.footer-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: var(--text-primary);
    text-decoration: none;
    transition: var(--transition);
    font-size: 0.95rem;
}

.footer-links a:hover {
    color: var(--accent-color);
}

.social-links {
    display: flex;
    gap: 1rem;
    margin-top: 0.5rem;
}

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 50%;
    color: var(--text-secondary);
    transition: var(--transition);
    text-decoration: none;
}

.social-link:hover {
    background: var(--primary-gradient);
    color: white;
    transform: translateY(-2px);
    box-shadow: var(--shadow-light);
}

.social-link svg {
    width: 20px;
    height: 20px;
}

.footer-bottom {
    border-top: 1px solid var(--glass-border);
    padding-top: 1.5rem;
    text-align: center;
}

.copyright {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.attribution {
    color: var(--text-muted);
    font-size: 0.85rem;
}

.itify-link {
    color: var(--accent-color);
    text-decoration: none;
    font-weight: 500;
}

.itify-link:hover {
    text-decoration: underline;
}

/* ===== ANIMATIONS ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-20px);
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-10px);
    }
    60% {
        transform: translateY(-5px);
    }
}

@keyframes scroll {
    0% {
        transform: translateY(0);
        opacity: 1;
    }
    100% {
        transform: translateY(12px);
        opacity: 0;
    }
}

.animate-in {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

/* ===== RESPONSIVE DESIGN ===== */

/* Laptops and smaller desktops (1024px - 1440px) */
@media (max-width: 1440px) {
    .hero-container {
        max-width: 1000px;
    }

    .hero-content {
        max-width: 800px;
    }
}

/* Tablets and small laptops (769px - 1024px) */
@media (max-width: 1024px) {
    .hero-container {
        max-width: 900px;
        padding: 0 1.5rem;
    }

    .hero-content {
        max-width: 700px;
    }

    .hero {
        min-height: calc(100vh - 70px);
        padding: 3rem 0;
    }

    body:not(.about-page):not(.company-page):not(.cyber-page):not(.recruitment-page):not(.contact-page) .hero {
        margin-top: 70px;
    }
}

/* Mobile and small tablets */
@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }

    .mobile-menu-btn {
        display: flex;
    }

    .nav-container {
        padding: 0 1rem;
        height: 70px;
    }

    .hero {
        padding: 2rem 0;
    }

    body:not(.about-page):not(.company-page):not(.cyber-page):not(.recruitment-page):not(.contact-page) .hero {
        margin-top: 70px;
    }

    .hero-container {
        flex-direction: column;
        text-align: center;
        gap: 3rem;
        padding: 0 1rem;
    }

    .hero-content {
        text-align: center;
        max-width: none;
    }

    .hero-title {
        font-size: 2rem;
    }

    .hero-welcome {
        font-size: 0.85rem;
    }

    .hero-cta {
        justify-content: center;
    }

    .hero-visual {
        height: 300px;
    }

    .scroll-indicator {
        display: none; /* Hide on mobile */
    }

    .services {
        padding: 4rem 0;
    }

    .services-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .service-card {
        padding: 2rem 1.5rem;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }

    .footer-section {
        align-items: center;
    }

    .social-links {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 1rem;
    }

    .hero-title {
        font-size: 2rem;
    }

    .cta-button {
        padding: 1rem 1.75rem;
        font-size: 0.95rem;
        min-height: 48px; /* Ensure touch-friendly size */
    }

    .section-title {
        font-size: 2rem;
    }

    .service-card {
        padding: 1.5rem 1rem;
    }

    .service-title {
        font-size: 1.5rem;
    }
}

/* ===== ACCESSIBILITY ===== */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Focus styles for keyboard navigation */
.nav-link:focus,
.cta-button:focus,
.social-link:focus {
    outline: 2px solid var(--accent-color);
    outline-offset: 2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    :root {
        --glass-bg: rgba(255, 255, 255, 0.95);
        --glass-border: rgba(0, 0, 0, 0.3);
    }

    [data-theme="dark"] {
        --glass-bg: rgba(0, 0, 0, 0.95);
        --glass-border: rgba(255, 255, 255, 0.3);
    }
}
