@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Poppins:wght@400;500;600;700;800&display=swap');

:root {
    --primary: #0B2D5C;
    --teal: #008C95;
    --orange: #FF6B1A;
    --green: #63B246;
    --bg-light: #F7FAFC;
    --bg-dark: #08111F;
    --text-light: #1F2937;
    --text-dark: #E2E8F0;
    
    --bg-color: var(--bg-light);
    --text-color: var(--text-light);
    --card-bg: #FFFFFF;
    --header-bg: rgba(247, 250, 252, 0.95);
    --border-color: #E2E8F0;
    --footer-bg: var(--primary);
    --footer-text: #F7FAFC;
}

[data-theme="dark"] {
    --bg-color: var(--bg-dark);
    --text-color: var(--text-dark);
    --card-bg: #0F1C2E;
    --header-bg: rgba(8, 17, 31, 0.95);
    --border-color: #1E3A5F;
    --footer-bg: #040810;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    transition: background-color 0.3s ease, color 0.3s ease;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Poppins', sans-serif;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

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

/* Header & Nav */
header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background-color: var(--header-bg);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 90px;
}

.logo img {
    height: 65px;
    max-width: 250px;
    width: auto;
    object-fit: contain;
}

.nav-links {
    display: flex;
    gap: 30px;
    align-items: center;
}

.nav-links a {
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: var(--teal);
}

.theme-toggle {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
    color: var(--text-color);
    padding: 5px;
}

.mobile-menu-btn {
    display: none;
    font-size: 1.5rem;
    background: none;
    border: none;
    color: var(--text-color);
    cursor: pointer;
}

/* Hero Section */
.hero {
    padding: 100px 0;
    text-align: center;
    background: linear-gradient(135deg, rgba(11, 45, 92, 0.05) 0%, rgba(0, 140, 149, 0.05) 100%);
}

.hero h1 {
    font-size: 3.5rem;
    color: var(--primary);
    margin-bottom: 20px;
    font-weight: 700;
    line-height: 1.2;
}

[data-theme="dark"] .hero h1 {
    color: var(--bg-light);
}

.hero p {
    font-size: 1.2rem;
    max-width: 800px;
    margin: 0 auto 40px;
    color: var(--text-color);
    opacity: 0.9;
}

.hero-btns {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.btn {
    display: inline-block;
    padding: 15px 30px;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
}

.btn-primary {
    background-color: var(--teal);
    color: white;
    box-shadow: 0 4px 15px rgba(0, 140, 149, 0.3);
}

.btn-primary:hover {
    background-color: #00737a;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 140, 149, 0.4);
}

.btn-secondary {
    background-color: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
}

[data-theme="dark"] .btn-secondary {
    border-color: var(--bg-light);
    color: var(--bg-light);
}

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

[data-theme="dark"] .btn-secondary:hover {
    background-color: var(--bg-light);
    color: var(--primary);
}

/* Sections General */
section {
    padding: 80px 0;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 50px;
    color: var(--primary);
}

[data-theme="dark"] .section-title {
    color: var(--bg-light);
}

/* Grid Layouts */
.grid-3 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.grid-2 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 40px;
    align-items: center;
}

/* Cards */
.card {
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 30px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    border-color: var(--teal);
}

.card h3 {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: var(--primary);
}

[data-theme="dark"] .card h3 {
    color: var(--teal);
}

.card-icon {
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: var(--orange);
}

/* Calculators */
.calculator-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.form-group label {
    font-weight: 500;
    font-size: 0.9rem;
}

.form-control {
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: inherit;
    transition: border-color 0.3s ease;
}

.form-control:focus {
    outline: none;
    border-color: var(--teal);
    box-shadow: 0 0 0 3px rgba(0, 140, 149, 0.1);
}

.calc-result {
    margin-top: 20px;
    padding: 15px;
    background-color: rgba(99, 178, 70, 0.1);
    border-left: 4px solid var(--green);
    border-radius: 4px;
    font-weight: 600;
    display: none;
}

.calc-result.active {
    display: block;
}

/* Footer */
footer {
    background-color: var(--footer-bg);
    color: var(--footer-text);
    padding: 60px 0 20px;
}

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

.footer-logo img {
    height: 60px;
    filter: brightness(0) invert(1);
    margin-bottom: 20px;
}

.footer-links h4 {
    margin-bottom: 20px;
    font-size: 1.2rem;
    color: var(--teal);
}

.footer-links ul {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-links a {
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.footer-links a:hover {
    opacity: 1;
    color: var(--orange);
}

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

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

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

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    opacity: 0.8;
    font-size: 0.9rem;
}

/* Content Pages (About, Privacy, etc.) */
.page-header {
    background: var(--primary);
    color: white;
    padding: 60px 0;
    text-align: center;
}

.page-header h1 {
    font-size: 3rem;
    margin-bottom: 10px;
}

.content-section {
    max-width: 800px;
    margin: 0 auto;
    font-size: 1.1rem;
}

.content-section h2 {
    color: var(--primary);
    margin: 40px 0 20px;
    font-size: 2rem;
}

[data-theme="dark"] .content-section h2 {
    color: var(--teal);
}

.content-section h3 {
    margin: 30px 0 15px;
    font-size: 1.5rem;
}

.content-section p {
    margin-bottom: 20px;
}

.content-section ul {
    list-style: disc;
    margin-left: 20px;
    margin-bottom: 20px;
}

.content-section li {
    margin-bottom: 10px;
}

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

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

/* Responsive */
@media (max-width: 768px) {
    .nav-links {
        display: none;
        position: absolute;
        top: 80px;
        left: 0;
        width: 100%;
        background-color: var(--header-bg);
        flex-direction: column;
        padding: 20px;
        box-shadow: 0 10px 20px rgba(0,0,0,0.1);
    }

    .nav-links.active {
        display: flex;
    }

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

    .hero h1 {
        font-size: 2.5rem;
    }

    .hero-btns {
        flex-direction: column;
    }
}

/* Product Cards */
.product-card {
    padding: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}
.product-thumb {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-bottom: 1px solid var(--border-color);
}
.product-info {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}
.product-cat {
    font-size: 0.8rem;
    color: white;
    background-color: var(--teal);
    padding: 3px 8px;
    border-radius: 4px;
    align-self: flex-start;
    margin-bottom: 10px;
    font-weight: 600;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.6);
    backdrop-filter: blur(5px);
    opacity: 0;
    transition: opacity 0.3s ease;
}
.modal.active {
    display: block;
    opacity: 1;
}
.modal-content {
    background-color: var(--bg-color);
    margin: 5% auto;
    padding: 30px;
    border: 1px solid var(--border-color);
    width: 80%;
    max-width: 900px;
    position: relative;
    border-radius: 12px;
}
.close-modal {
    position: absolute;
    top: 15px;
    right: 20px;
    color: var(--text-color);
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.2s;
}
.close-modal:hover {
    color: var(--orange);
}
.product-gallery {
    display: flex;
    gap: 15px;
    overflow-x: auto;
    padding-bottom: 10px;
}
.product-gallery img {
    height: 150px;
    width: 200px;
    object-fit: cover;
    border-radius: 8px;
}
