/* =========================
   Digital Molecules V2.0
   Global Stylesheet
   ========================= */

/* ===== CSS Reset ===== */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* ===== Root Variables ===== */
:root {
    --primary-color: #0b3c5d;
    --secondary-color: #328cc1;
    --accent-color: #d9b310;
    --text-color: #1a1a1a;
    --light-text: #666;
    --bg-color: #ffffff;
    --light-bg: #f7f9fb;
    --border-color: #e0e0e0;

    --font-main: "Segoe UI", Roboto, Arial, sans-serif;

    --container-width: 1200px;
    --transition: all 0.3s ease;
}

/* ===== Base Styles ===== */
body {
    font-family: var(--font-main);
    color: var(--text-color);
    background-color: var(--bg-color);
    line-height: 1.6;
}

img {
    max-width: 100%;
    display: block;
    object-fit: contain;
}

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

ul {
    list-style: none;
}

/* ===== Container ===== */
.container {
    width: 90%;
    max-width: var(--container-width);
    margin: 0 auto;
}

/* ===== Typography ===== */
h1, h2, h3, h4 {
    font-weight: 600;
    color: var(--primary-color);
}

h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

h2 {
    font-size: 2rem;
    margin-bottom: 0.8rem;
}

h3 {
    font-size: 1.4rem;
}

p {
    margin-bottom: 1rem;
    color: var(--light-text);
}

/* ===== Header ===== */
.header {
    background: var(--bg-color);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    position: relative;
}

.logo {
    font-size: 1.4rem;
    font-weight: bold;
    color: var(--primary-color);
}

.nav-links {
    display: flex;
    gap: 25px;
}

.nav-links a {
    font-weight: 500;
    transition: var(--transition);
}

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

/* ===== Buttons ===== */
.btn {
    display: inline-block;
    padding: 10px 18px;
    background: var(--primary-color);
    color: #fff;
    border-radius: 4px;
    transition: var(--transition);
    font-size: 0.95rem;
}

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

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

.btn-outline:hover {
    background: var(--primary-color);
    color: #fff;
}

/* ===== Hero Section ===== */
.hero {
    background: linear-gradient(to right, #0b3c5d, #328cc1);
    color: #fff;
    padding: 80px 0;
}

.hero h1 {
    color: #fff;
}

.hero p {
    color: #e6e6e6;
    max-width: 600px;
}

/* ===== Sections ===== */
.section {
    padding: 60px 0;
}

.section.light {
    background: var(--light-bg);
}

/* ===== Grid ===== */
.grid {
    display: grid;
    gap: 20px;
}

.grid-2 {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.grid-3 {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.grid-4 {
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

/* ===== Cards ===== */
.card {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    padding: 20px;
    transition: var(--transition);
}

.card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.card h3 {
    margin-bottom: 10px;
}

/* ===== Product Card ===== */
.product-card {
    border: 1px solid var(--border-color);
    border-radius: 6px;
    overflow: hidden;
    transition: var(--transition);
    background: #fff;
}

.product-card:hover {
    box-shadow: 0 6px 16px rgba(0,0,0,0.08);
}

.product-image {
    height: 180px;
    background: var(--light-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px;
}

.product-image img {
    max-height: 100%;
}

/* ===== Product Info ===== */
.product-info {
    padding: 15px;
}

.product-name {
    font-weight: 600;
    margin-bottom: 6px;
}

.product-meta {
    font-size: 0.9rem;
    color: var(--light-text);
}

/* ===== Table ===== */
.table {
    width: 100%;
    border-collapse: collapse;
}

.table th,
.table td {
    padding: 12px;
    border: 1px solid var(--border-color);
    text-align: left;
}

.table th {
    background: var(--light-bg);
}

/* ===== Footer ===== */
.footer {
    background: var(--primary-color);
    color: #fff;
    padding: 40px 0;
}

.footer p {
    color: #ddd;
    font-size: 0.9rem;
}

/* ===== Forms ===== */
input,
select,
textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-family: inherit;
}

input:focus,
textarea:focus {
    outline: none;
    border-color: var(--secondary-color);
}

/* ===== Utility Classes ===== */
.text-center {
    text-align: center;
}

.mt-20 {
    margin-top: 20px;
}

.mb-20 {
    margin-bottom: 20px;
}

/* ===== Mobile Navigation ===== */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
}

/* ===== Responsive ===== */
@media (max-width: 768px) {

    .nav-toggle {
        display: block;
    }

    .nav-links {
        position: absolute;
        top: 60px;
        right: 0;
        background: #fff;
        flex-direction: column;
        width: 200px;
        border: 1px solid var(--border-color);
        display: none;
        box-shadow: 0 8px 20px rgba(0,0,0,0.08);
    }

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

    .nav-links a {
        padding: 12px;
        border-bottom: 1px solid var(--border-color);
    }

    .hero {
        padding: 60px 0;
    }

    h1 {
        font-size: 2rem;
    }
}
