/*
 * Plastomer Corporation - Contemporary Theme
 * A modern, sleek design with a clean layout and subtle animations
 * Inspired by competitor websites like derbyfab.com, creativefoam.com, rogersfoam.com
 */

/* ======================================
   Variables & Base Styles
   ====================================== */
:root {
    --primary-color: #2c3e50;
    --primary-dark: #1a252f;
    --primary-light: #34495e;
    --secondary-color: #3498db;
    --secondary-light: #5dade2;
    --accent-color: #e74c3c;
    --dark-color: #2c3e50;
    --light-color: #ffffff;
    --gray-color: #95a5a6;
    --light-gray: #ecf0f1;
    --border-radius: 8px;

    --transition-base: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
    --transition-bounce: all 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    --box-shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.05);
    --box-shadow-md: 0 5px 15px rgba(0, 0, 0, 0.08);
    --box-shadow-lg: 0 10px 30px rgba(0, 0, 0, 0.12);
}

body {
    font-family: 'Inter', 'Roboto', sans-serif;
    color: #333;
    overflow-x: hidden;
    background-color: #f9fafb;
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Poppins', 'Montserrat', sans-serif;
    font-weight: 600;
    color: var(--dark-color);
}

a {
    color: var(--secondary-color);
    text-decoration: none;
    transition: var(--transition-base);
}

a:hover {
    color: var(--secondary-light);
}

/* ======================================
   Header & Navigation
   ====================================== */
header {
    position: relative;
    margin-bottom: 0;
}

/* Top Bar - Removed */

/* Main Header with Logo */
.main-header {
    background-color: white;
    box-shadow: var(--box-shadow-sm);
    position: relative;
    z-index: 100;
    padding: 15px 0;
}

.logo {
    max-height: 80px;
    width: auto;
    transition: var(--transition-base);
    transform-origin: left center;
    animation: logoEnlarge 1s ease-out forwards;
}

@keyframes logoEnlarge {
    0% { transform: scale(0.95); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

/* Desktop Navigation Menu */
.desktop-menu {
    background-color: white;
    border-radius: var(--border-radius);
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.menu-row {
    display: flex;
    flex-wrap: nowrap;
    justify-content: flex-end;
    gap: 10px;
}

/* Menu items */
.menu-item {
    display: block;
    color: var(--dark-color);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9rem;
    padding: 12px 16px;
    text-align: center;
    transition: var(--transition-base);
    white-space: normal;
    height: 100%;
    min-height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: white;
    position: relative;
    overflow: hidden;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow-sm);
    animation: menuItemAppear 0.5s ease-out forwards;
    animation-fill-mode: both;
    opacity: 0;
    transform: translateY(10px);
}

/* First row menu items */
.menu-row:first-child .col-2 {
    flex: 0 0 16.666%;
    max-width: 16.666%;
    padding: 0 0.25rem;
}

/* Second row menu items (smaller font) */
.menu-row:nth-child(2) {
    margin-top: 0.5rem;
}

.menu-item-wrapper {
    flex: 0 0 19%;
    max-width: 19%;
    padding: 0 0.25rem;
}

.menu-row:nth-child(2) .menu-item {
    font-size: 0.8rem;
    min-height: 45px;
}

/* Staggered animation delay for menu items */
.menu-row:first-child .col-2:nth-child(1) .menu-item { animation-delay: 0.1s; }
.menu-row:first-child .col-2:nth-child(2) .menu-item { animation-delay: 0.2s; }
.menu-row:first-child .col-2:nth-child(3) .menu-item { animation-delay: 0.3s; }
.menu-row:first-child .col-2:nth-child(4) .menu-item { animation-delay: 0.4s; }
.menu-row:first-child .col-2:nth-child(5) .menu-item { animation-delay: 0.5s; }
.menu-row:first-child .col-2:nth-child(6) .menu-item { animation-delay: 0.6s; }

.menu-row:nth-child(2) .menu-item-wrapper:nth-child(1) .menu-item { animation-delay: 0.7s; }
.menu-row:nth-child(2) .menu-item-wrapper:nth-child(2) .menu-item { animation-delay: 0.8s; }
.menu-row:nth-child(2) .menu-item-wrapper:nth-child(3) .menu-item { animation-delay: 0.9s; }
.menu-row:nth-child(2) .menu-item-wrapper:nth-child(4) .menu-item { animation-delay: 1.0s; }
.menu-row:nth-child(2) .menu-item-wrapper:nth-child(5) .menu-item { animation-delay: 1.1s; }

@keyframes menuItemAppear {
    0% { opacity: 0; transform: translateY(10px); }
    100% { opacity: 1; transform: translateY(0); }
}

.menu-item::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--secondary-color);
    transform: scaleX(0);
    transform-origin: right;
    transition: transform 0.3s ease;
}

.menu-item:hover::before,
.menu-item.active::before {
    transform: scaleX(1);
    transform-origin: left;
}

.menu-item:hover,
.menu-item.active {
    color: var(--secondary-color);
    transform: translateY(-3px);
    box-shadow: var(--box-shadow-md);
}

/* Mobile Navigation Menu */
.mobile-menu {
    background-color: white;
    padding: 0;
    margin-top: 0;
    box-shadow: var(--box-shadow-md);
}

.mobile-menu-items {
    display: flex;
    flex-direction: column;
}

.mobile-menu-item {
    color: var(--dark-color);
    text-decoration: none;
    padding: 15px;
    border-bottom: 1px solid var(--light-gray);
    transition: var(--transition-base);
    font-weight: 500;
}

.mobile-menu-item:hover,
.mobile-menu-item.active {
    background-color: var(--light-gray);
    color: var(--secondary-color);
    padding-left: 20px;
}

/* Navbar Toggler */
.navbar-toggler {
    border: none;
    padding: 10px;
    background-color: var(--light-gray);
    color: var(--dark-color);
    border-radius: var(--border-radius);
    transition: var(--transition-base);
}

.navbar-toggler:hover {
    background-color: var(--secondary-light);
    color: white;
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%2844, 62, 80, 0.85%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* ======================================
   Page Header
   ====================================== */
.page-header {
    background-color: var(--primary-color);
    color: white;
    padding: 100px 0 60px; /* Increased top padding to compensate for removed top bar */
    position: relative;
    overflow: hidden;
}

.page-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../../shared/images/backgrounds/original-bg.jpg');
    background-size: cover;
    background-position: center;
    opacity: 0.1;
    z-index: 0;
}

.page-header-content {
    position: relative;
    z-index: 1;
}

.page-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: white;
}

/* Breadcrumbs */
.breadcrumb {
    background-color: transparent;
    padding: 0;
    margin-bottom: 0;
}

.breadcrumb-item a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
}

.breadcrumb-item.active {
    color: white;
}

.breadcrumb-item + .breadcrumb-item::before {
    color: rgba(255, 255, 255, 0.5);
}

/* ======================================
   Hero Section
   ====================================== */
.hero-section {
    position: relative;
    height: 85vh; /* Increased height to compensate for removed top bar */
    min-height: 650px; /* Increased min-height to compensate for removed top bar */
    display: flex;
    align-items: center;
    overflow: hidden;
    background-color: var(--primary-color);
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('../../shared/images/backgrounds/original-bg.jpg');
    background-size: cover;
    background-position: center;
    opacity: 0.2;
    z-index: 0;
}

.hero-content {
    position: relative;
    z-index: 1;
    color: white;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    line-height: 1.2;
    color: white;
}

.hero-description {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    max-width: 700px;
    opacity: 0.9;
}

/* ======================================
   Section Styles
   ====================================== */
.section {
    padding: 80px 0;
}

.section-title {
    font-size: 2.25rem;
    font-weight: 700;
    margin-bottom: 2.5rem;
    position: relative;
    padding-bottom: 15px;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background-color: var(--secondary-color);
}

.section-title.text-center::after {
    left: 50%;
    transform: translateX(-50%);
}

/* ======================================
   Cards & Features
   ====================================== */
.card {
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow-sm);
    transition: var(--transition-base);
    border: none;
    height: 100%;
    display: flex;
    flex-direction: column;
    background-color: white;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: var(--box-shadow-lg);
}

.card-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 25px;
}

/* Service Cards - specific styling for the Our Services section */
.service-card {
    background-color: white;
    border: none;
    box-shadow: var(--box-shadow-sm);
    transition: all 0.5s ease;
    position: relative;
    z-index: 5;
    opacity: 0;
    transform: translateY(20px);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--box-shadow-lg);
}

.feature-icon {
    margin-bottom: 1.5rem;
    transition: var(--transition-bounce);
    display: block;
    text-align: center;
}

.feature-icon i {
    display: inline-block;
    font-size: 2.5rem;
    color: var(--secondary-color);
    width: 70px;
    height: 70px;
    line-height: 70px;
    background-color: rgba(52, 152, 219, 0.1);
    border-radius: 50%;
}

.card:hover .feature-icon {
    transform: scale(1.1);
}

.card-title {
    font-weight: 600;
    color: var(--dark-color);
    margin-bottom: 1rem;
}

.card-text {
    color: var(--gray-color);
    margin-bottom: 1.5rem;
}

/* Product Cards */
.product-image {
    height: 200px;
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;
    transition: var(--transition-base);
    position: relative;
    z-index: 1;
    padding: 20px;
    background-color: var(--light-gray);
}

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

/* About Section */
.about-section {
    background-color: white;
}

.about-section img {
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow-md);
    transition: var(--transition-base);
}

.about-section img:hover {
    transform: scale(1.02);
    box-shadow: var(--box-shadow-lg);
}

/* CTA Section */
.cta-section {
    background-color: var(--secondary-color);
    color: white;
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(52, 152, 219, 0.8), rgba(41, 128, 185, 0.8));
    z-index: 0;
}

.cta-section .container {
    position: relative;
    z-index: 1;
}

.cta-section .section-title {
    color: white;
    border-bottom: none;
}

.cta-section .section-title::after {
    background-color: white;
}

/* ======================================
   Buttons & Interactive Elements
   ====================================== */
.btn {
    padding: 12px 24px;
    font-weight: 500;
    border-radius: var(--border-radius);
    transition: var(--transition-bounce);
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 0.5px;
}

.btn-primary {
    background-color: var(--secondary-color);
    border-color: var(--secondary-color);
}

.btn-primary:hover {
    background-color: var(--secondary-light);
    border-color: var(--secondary-light);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(52, 152, 219, 0.3);
}

.btn-outline-primary {
    border-color: var(--secondary-color);
    color: var(--secondary-color);
}

.btn-outline-primary:hover {
    background-color: var(--secondary-color);
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(52, 152, 219, 0.3);
}

.btn-light {
    background-color: white;
    color: var(--secondary-color);
}

.btn-light:hover {
    background-color: #f8f9fa;
    color: var(--secondary-light);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.8rem;
}

/* ======================================
   Footer
   ====================================== */
.footer {
    background-color: var(--primary-dark);
    color: white;
    padding: 80px 0 30px;
}

.footer-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    position: relative;
    padding-bottom: 0.75rem;
    color: white;
}

.footer-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 2px;
    background-color: var(--secondary-color);
}

.footer-links {
    list-style: none;
    padding: 0;
    margin: 0;
}

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

.footer-links a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: var(--transition-base);
    display: block;
    padding: 5px 0;
}

.footer-links a:hover {
    color: white;
    padding-left: 5px;
}

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

.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.1);
    color: white;
    transition: var(--transition-bounce);
}

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

.copyright {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 2rem;
    margin-top: 3rem;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
}

/* ======================================
   Utility Classes
   ====================================== */
.back-to-top {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: var(--secondary-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-base);
    box-shadow: var(--box-shadow-md);
}

.back-to-top.active {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background-color: var(--secondary-light);
    transform: translateY(-5px);
}

.theme-selector {
    position: fixed;
    top: 50%;
    left: 0;
    transform: translateY(-50%);
    background-color: white;
    border-radius: 0 10px 10px 0;
    box-shadow: var(--box-shadow-md);
    z-index: 999;
    padding: 1rem;
}

.theme-selector a {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--dark-color);
    text-decoration: none;
    transition: var(--transition-base);
}

.theme-selector a:hover {
    color: var(--secondary-color);
}

/* Password Protected Area */
.password-protected {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
}

.password-protected-btn {
    background-color: var(--light-gray);
    color: var(--dark-color);
    border: none;
    padding: 8px 15px;
    border-radius: var(--border-radius);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: var(--transition-base);
}

.password-protected-btn:hover {
    background-color: var(--secondary-color);
    color: white;
}

.password-modal .modal-content {
    border-radius: var(--border-radius);
    border: none;
    box-shadow: var(--box-shadow-lg);
}

.password-modal .modal-header {
    border-bottom: none;
    padding: 20px 20px 0;
}

.password-modal .modal-body {
    padding: 20px;
}

.password-modal .modal-footer {
    border-top: none;
    padding: 0 20px 20px;
}

/* ======================================
   Animations
   ====================================== */
[data-aos] {
    opacity: 0;
    transition-property: opacity, transform;
}

[data-aos].aos-animate {
    opacity: 1;
}

[data-aos="fade-up"] {
    transform: translateY(30px);
}

[data-aos="fade-down"] {
    transform: translateY(-30px);
}

[data-aos="fade-right"] {
    transform: translateX(-30px);
}

[data-aos="fade-left"] {
    transform: translateX(30px);
}

[data-aos].aos-animate {
    transform: translateY(0) translateX(0);
}

/* ======================================
   Responsive Adjustments
   ====================================== */
@media (max-width: 992px) {
    .hero-title, .page-title {
        font-size: 2.5rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .hero-section {
        height: auto;
        min-height: 500px;
        padding: 100px 0;
    }

    .desktop-menu {
        display: none;
    }
}

@media (max-width: 768px) {
    .hero-title, .page-title {
        font-size: 2rem;
    }

    .hero-description {
        font-size: 1rem;
    }

    .section {
        padding: 60px 0;
    }

    .section-title {
        font-size: 1.75rem;
        margin-bottom: 2rem;
    }

    .hero-section {
        min-height: 400px;
        padding: 80px 0;
    }
}

/* Mobile Menu Fixes */
@media (max-width: 992px) {
    .main-header {
        padding: 10px 0;
    }

    .logo {
        max-height: 60px;
    }

    .navbar-toggler {
        margin-left: auto;
    }

    .mobile-menu {
        max-height: 80vh;
        overflow-y: auto;
    }
}
