/* About Page Styles */
body { 
    font-family: 'IBM Plex Sans', sans-serif; 
    background-color: #F7F7F8; 
    overflow-x: hidden; 
}

/* Use Bebas Neue for all headings */
h1, h2, h3, h4, h5, h6,
.font-display,
.font-bebas {
    font-family: 'Bebas Neue', sans-serif !important;
}

.material-symbols-outlined { 
    font-variation-settings: 'FILL' 0, 'wght' 300, 'GRAD' 0, 'opsz' 24; 
}

.hotspot-trigger:hover .hotspot-content { 
    opacity: 1; 
    transform: translateY(0); 
    pointer-events: auto; 
}

.hotspot-content {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
    background: rgba(0,0,0,0.8);
    border: 1px solid #FF1901;
    padding: 8px 12px;
    white-space: nowrap;
    z-index: 20;
}

.liquid-metal-text {
    background: linear-gradient(to right, #FF1901 20%, #ffdfd7 40%, #FF1901 60%, #FF1901 80%);
    background-size: 200% auto;
    color: transparent;
    -webkit-background-clip: text;
    background-clip: text;
    animation: shine 5s linear infinite;
    display: inline-block;
}

@keyframes shine {
    to { background-position: 200% center; }
}

/* Heat Haze Effect */
.heat-haze { 
    position: relative; 
    overflow: hidden; 
}

.heat-haze::before {
    content: "";
    position: absolute;
    inset: -10%;
    background: linear-gradient(to right, rgba(19, 21, 24, 0.10), rgba(19, 21, 24, 0.45));
    filter: url(#hazeFilter);
    z-index: 1;
    pointer-events: none;
    mix-blend-mode: multiply;
}

.technical-grid-line { 
    height: 1px; 
    background: rgba(143, 112, 105, 0.15); 
    width: 100%; 
}

.btn-industrial { 
    position: relative; 
    overflow: hidden; 
    transition: all 0.3s ease; 
}

.btn-industrial::before {
    content: "";
    position: absolute;
    top: 0; 
    left: -100%; 
    width: 100%; 
    height: 100%;
    background: #FF1901; 
    transition: all 0.3s ease; 
    z-index: -1;
}

.btn-industrial:hover::before { 
    left: 0; 
}

/* Perspective for 3D Cards */
.perspective-container { 
    perspective: 1000px; 
}

.tilt-card { 
    transition: transform 0.1s ease-out; 
    transform-style: preserve-3d; 
}

/* Glitch Animation */
.glitch-text { 
    animation: glitch 2s infinite; 
}

@keyframes glitch {
    0% { transform: translate(0); }
    1% { transform: translate(-2px, 2px); }
    2% { transform: translate(2px, -2px); }
    3% { transform: translate(0); }
    100% { transform: translate(0); }
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    /* Hero Section Adjustments */
    #hero-title {
        font-size: 18vw !important;
    }
    
    #hero-sub {
        font-size: 1.5rem !important;
    }
    
    #hero-desc {
        font-size: 1rem !important;
    }
    
    /* Hide side metadata on mobile */
    #side-meta {
        display: none !important;
    }
    
    /* Company Profile Section - Image Sizing */
    .col-span-12.lg\:col-span-5 img {
        max-height: 400px;
        object-position: center top;
    }
    
    .company-profile-image {
        max-height: 400px;
        aspect-ratio: 3/4;
    }
    
    /* Prevent horizontal overflow on mobile */
    section.px-8 {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }
    
    /* Grid container - prevent overflow */
    .grid.grid-cols-12 {
        max-width: 100%;
        overflow-x: hidden;
    }
    
    /* Company Profile Section */
    .perspective-container {
        perspective: none;
    }
    
    .tilt-card {
        transform: none !important;
        transition: all 0.3s ease;
    }
    
    .tilt-card:hover {
        transform: translateY(-4px);
    }
    
    /* Timeline Section */
    .timeline-year {
        font-size: 4rem !important;
    }
    
    /* Pithampur Core Section */
    #parallax-title {
        font-size: 3.5rem !important;
    }
    
    /* Quality Audit Section */
    h2.font-display.text-6xl {
        font-size: 2.5rem !important;
    }
    
    /* Hotspot adjustments for touch */
    .hotspot-trigger {
        cursor: pointer;
    }
    
    .hotspot-content {
        display: none;
    }
    
    .hotspot-trigger:active .hotspot-content {
        display: block;
        opacity: 1;
        transform: translateX(-50%) translateY(0);
        pointer-events: auto;
    }
}

@media (max-width: 480px) {
    /* Extra Small Devices */
    body {
        font-size: 14px;
    }
    
    #hero-title {
        font-size: 20vw !important;
    }
    
    #hero-sub {
        font-size: 1.2rem !important;
    }
    
    #hero-desc {
        font-size: 0.9rem !important;
    }
    
    /* Navigation */
    nav.sticky {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }
    
    /* Sections Padding */
    section.py-32 {
        padding-top: 4rem !important;
        padding-bottom: 4rem !important;
    }
    
    section.px-8 {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }
    
    /* Grid Adjustments */
    .grid.grid-cols-12 {
        gap: 2rem !important;
    }
    
    /* Company Profile Image - Mobile Optimization */
    .col-span-12.lg\:col-span-5 img {
        max-height: 300px;
        width: 100%;
        object-fit: cover;
    }
    
    .company-profile-image {
        max-height: 300px;
        aspect-ratio: 3/4;
        width: 100%;
    }
    
    /* Value Cards - Stack vertically and prevent overflow */
    .grid.grid-cols-1.md\:grid-cols-3 {
        grid-template-columns: 1fr !important;
        gap: 1rem !important;
    }
    
    /* Card spacing and text wrapping */
    .tilt-card {
        padding: 1.5rem !important;
        min-width: 0; /* Prevent flex item from overflowing */
    }
    
    .tilt-card h4 {
        font-size: 1.5rem !important;
        word-wrap: break-word;
    }
    
    .tilt-card p {
        font-size: 0.75rem !important;
        line-height: 1.4 !important;
    }
    
    .tilt-card .material-symbols-outlined {
        font-size: 2.5rem !important;
    }
    
    /* Timeline Adjustments */
    .timeline-item {
        flex-direction: column !important;
    }
    
    .md\:w-5\/12 {
        width: 100% !important;
        text-align: center !important;
    }
    
    .timeline-year {
        font-size: 3rem !important;
        margin-bottom: 0.5rem;
    }
    
    /* Additional timeline spacing for very small screens */
    .timeline-path-container {
        left: 16px;
    }
    
    .timeline-node {
        left: 16px;
        width: 32px;
        height: 32px;
    }
    
    [data-purpose^="milestone-"] {
        padding-left: 40px !important;
    }
    
    /* Stats Cards */
    .text-5xl {
        font-size: 2.5rem !important;
    }
    
    /* Certification Grid */
    .grid.grid-cols-2.md\:grid-cols-4 {
        grid-template-columns: repeat(2, 1fr) !important;
    }
    
    /* Footer */
    footer.pt-24 {
        padding-top: 3rem !important;
    }
}

/* ============================================
   COMPETENCY SECTION GRID OVERLAY
   ============================================ */

.grid-overlay {
    background-image: 
        linear-gradient(to right, rgba(255,255,255,0.05) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(255,255,255,0.05) 1px, transparent 1px);
    background-size: 80px 80px;
}

/* ============================================
   MISSION & VISION SECTION
   ============================================ */

.mission-card {
    background: white;
    transition: transform 0.1s ease-out, box-shadow 0.3s ease;
    transform-style: preserve-3d;
    will-change: transform;
}

.mission-card:hover {
    box-shadow: 0 20px 40px rgba(255, 25, 1, 0.1);
}

/* Heat haze container for images */
.heat-haze-container {
    position: relative;
    overflow: hidden;
}

/* Gradient overlay for images */
.gradient-overlay {
    background: linear-gradient(180deg, rgba(255,255,255,0) 0%, rgba(255,25,1,0.05) 100%);
}

/* ============================================
   HISTORY TIMELINE SECTION
   ============================================ */

/* Timeline central line container */
.timeline-path-container {
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 2px;
    transform: translateX(-50%);
    background: #e2e8f0;
    z-index: 10;
}

.timeline-progress-line {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 0%;
    background: #C0310A;
}

/* Pulsating timeline nodes */
.timeline-node {
    position: absolute;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 48px;
    height: 48px;
    background: #F7F5F2;
    border: 2px solid #C0310A;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 20;
    transition: background-color 0.3s ease;
}

.node-pulse {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 2px solid #C0310A;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); opacity: 0.8; }
    100% { transform: scale(1.8); opacity: 0; }
}

/* Milestone cards reveal effect */
.milestone-card {
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    border-left: 4px solid #C0310A;
}

.milestone-card.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* 1px Hairlines */
.hairline-y {
    width: 1px;
    background: rgba(0,0,0,0.1);
}

.hairline-x {
    height: 1px;
    background: rgba(0,0,0,0.1);
}

/* Responsive timeline adjustments */
@media (max-width: 768px) {
    /* Timeline Section Mobile Fix */
    .timeline-path-container {
        left: 24px; /* Move line to the left side */
        transform: none; /* Remove centering transform */
    }
    
    .timeline-node {
        left: 10px; /* Align nodes with the line */
        transform: translate(-50%, -50%); /* Keep vertical centering */
        width: 36px;
        height: 36px;
    }
    
    /* Ensure milestone sections have proper spacing */
    [data-purpose^="milestone-"] {
        flex-direction: column !important;
        align-items: flex-start !important;
        padding-left: 48px !important; /* Space for the line */
        margin-bottom: 3rem !important; /* Reduced from mb-48 */
    }
    
    /* Hide the desktop year display on mobile (already hidden via md:hidden in HTML) */
    .hidden.md\:block {
        display: none !important;
    }
    
    /* Adjust milestone card spacing */
    .milestone-card {
        margin-top: 16px;
    }
    
    /* Ensure proper text alignment on mobile */
    [data-purpose^="milestone-"] .text-right {
        text-align: left !important;
    }
    
    /* Mobile timeline content adjustments */
    [data-purpose^="milestone-"] > div:last-child {
        width: 100% !important;
        padding-left: 0 !important;
        margin-top: 16px;
    }
    
    /* Hide desktop-only year on mobile */
    [data-purpose^="milestone-"] > div:first-child {
        display: none !important;
    }
    
    /* Ensure milestone cards don't overflow */
    .milestone-card {
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }
    
    /* Timeline section container */
    #history-timeline-section {
        overflow-x: hidden;
    }
    
    .node-pulse {
        border-width: 1px;
    }
}
