/* 
    PT. Spesial Karya Mandiri 
    Main Stylesheet
*/

:root {
    --primary-color: #1976D2;
    --primary-light: #E3F2FD;
    --secondary-color: #388E3C;
    --secondary-light: #E8F5E9;
    --accent-color: #FFA000;
    --text-dark: #333333;
    --text-light: #666666;
    --bg-light: #FAFAFA;
    --white: #FFFFFF;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

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

body {
    font-family: 'Open Sans', sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background-color: var(--bg-light);
    overflow-x: hidden;
}

/* Typography */
h1,
h2,
h3,
h4 {
    margin-bottom: 1rem;
    font-weight: 700;
    line-height: 1.2;
}

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

/* Layout Containers */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

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

/* Navigation */
nav {
    background-color: var(--white);
    height: 80px;
    display: flex;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo {
    width: 70px;
    height: 40px;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 30px;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--primary-color);
}

.mobile-menu-btn {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
}

/* Hero Section */
.hero {
    height: 80vh;
    background-color: blueviolet;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--white);
}

.hero-content h1 {
    font-size: 3.5rem;
    margin-bottom: 20px;
}

.hero-content p {
    font-size: 1.25rem;
    margin-bottom: 30px;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 5px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: var(--transition);
}

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

.btn-primary:hover {
    background-color: #1565C0;
    transform: translateY(-2px);
}

/* Featured Products & Grid */
.section-title {
    text-align: center;
    margin-bottom: 50px;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
}

.product-card {
    background: var(--white);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.product-card:hover {
    transform: translateY(-10px);
}

.product-image {
    width: 300px;
    height: 200px;
    object-fit: contain;
    object-position: center;
    padding: 20px;
}

.product-info {
    padding: 20px;
}

.product-category {
    font-size: 0.8rem;
    color: var(--primary-color);
    text-transform: uppercase;
    font-weight: 600;
}

.product-price {
    font-weight: 700;
    color: var(--secondary-color);
    margin: 10px 0;
}

/* Values Section */
.values-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    text-align: center;
}

.value-item i {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

/* Footer */
footer {
    background-color: #222;
    color: var(--white);
    padding: 60px 0 20px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-col h4 {
    margin-bottom: 20px;
    color: var(--primary-light);
}

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

.footer-col ul li {
    margin-bottom: 10px;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #444;
    font-size: 0.9rem;
}

/* Product Filtering */
.filter-controls {
    margin-bottom: 40px;
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    align-items: center;
    justify-content: space-between;
}

.search-bar {
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    width: 300px;
}

.filter-btns {
    display: flex;
    gap: 10px;
}

.filter-btn {
    padding: 8px 15px;
    border: 1px solid var(--primary-color);
    background: transparent;
    color: var(--primary-color);
    border-radius: 5px;
    cursor: pointer;
}

.filter-btn.active {
    background: var(--primary-color);
    color: var(--white);
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    overflow-y: auto;
}

.modal-content {
    background-color: var(--white);
    margin: 5% auto;
    padding: 40px;
    width: 90%;
    max-width: 800px;
    border-radius: 10px;
    position: relative;
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
}

.close-modal {
    position: absolute;
    right: 20px;
    top: 20px;
    font-size: 1.5rem;
    cursor: pointer;
}

/* Forms */
.contact-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-family: inherit;
}

/* Animations */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive */
@media (max-width: 768px) {
    .nav-links {
        display: none;
        /* In production, implement mobile drawer */
    }

    .mobile-menu-btn {
        display: block;
    }

    .hero-content h1 {
        font-size: 2.2rem;
    }

    .contact-container {
        grid-template-columns: 1fr;
    }

    .modal-content {
        flex-direction: column;
    }
}

/* Toast */
#toast {
    visibility: hidden;
    min-width: 250px;
    background-color: var(--secondary-color);
    color: #fff;
    text-align: center;
    border-radius: 5px;
    padding: 16px;
    position: fixed;
    z-index: 3000;
    left: 50%;
    bottom: 30px;
    transform: translateX(-50%);
}

#toast.show {
    visibility: visible;
    animation: fadein 0.5s, fadeout 0.5s 2.5s;
}

@keyframes fadein {
    from {
        bottom: 0;
        opacity: 0;
    }

    to {
        bottom: 30px;
        opacity: 1;
    }
}

@keyframes fadeout {
    from {
        bottom: 30px;
        opacity: 1;
    }

    to {
        bottom: 0;
        opacity: 0;
    }
}