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

:root {
    --bg-dark: #0a0a0f;
    --bg-light: #f5f3f0;
    --text-dark: #1a1a1a;
    --text-light: #e8e8e8;
    --text-secondary: #666666;
    --accent: #5eb3d4;
    --font-main: 'Akatab', sans-serif;
}

html {
    scroll-behavior: smooth;
}

body {
    background: var(--bg-dark);
    color: var(--text-dark);
    font-family: var(--font-main);
    overflow-x: hidden;
}

/* ===== Navigation ===== */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 3rem;
    background: transparent;
    transition: background 0.4s, color 0.4s;
}

.nav.nav-light {
    background: rgba(245, 243, 240, 0.9);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.nav-logo {
    font-family: var(--font-main);
    font-size: 1.8rem;
    letter-spacing: 0.3em;
    color: var(--text-light);
    transition: color 0.4s;
}

.nav.nav-light .nav-logo {
    color: var(--text-dark);
}

.nav-links {
    display: flex;
    gap: 2.5rem;
}

.nav-link {
    font-family: var(--font-main);
    font-size: 1.1rem;
    letter-spacing: 0.2em;
    color: #ffffff;
    text-decoration: none;
    position: relative;
    transition: color 0.3s;
}

.nav.nav-light .nav-link {
    color: #000000;
}

.nav-link:hover {
    opacity: 0.6;
}

/* ===== Hero Section ===== */
.hero {
    position: relative;
    width: 100%;
    height: 100vh;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    transform: scale(1.05);
    animation: kenBurns 20s ease-in-out infinite alternate;
}

.hero-bg::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 150px;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.5) 0%, transparent 100%);
    z-index: 1;
}

@keyframes kenBurns {
    0% { transform: scale(1.05); }
    100% { transform: scale(1.15); }
}

.hero-content {
    position: relative;
    z-index: 1;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.hero-title {
    font-size: clamp(4rem, 12vw, 10rem);
    letter-spacing: 0.8em;
    line-height: 1;
    margin-right: -0.8em;
    color: var(--text-light);
}

.hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.5rem);
    letter-spacing: 0.3em;
    color: #ffffff;
    margin-top: 1.5rem;
    opacity: 0.9;
}

.scroll-hint {
    position: absolute;
    bottom: 3rem;
}

.scroll-arrow {
    width: 24px;
    height: 24px;
    border-right: 2px solid #ffffff;
    border-bottom: 2px solid #ffffff;
    transform: rotate(45deg);
    animation: scrollBounce 2s ease-in-out infinite;
    opacity: 0.6;
}

@keyframes scrollBounce {
    0%, 100% { transform: rotate(45deg) translate(0, 0); opacity: 0.6; }
    50% { transform: rotate(45deg) translate(5px, 5px); opacity: 1; }
}

/* ===== Breathing Space Transitions ===== */
.breathing-space {
    height: 35vh;
}

.breathing-dark-to-light {
    background: linear-gradient(to bottom, var(--bg-dark) 0%, var(--bg-light) 100%);
}

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

/* ===== Gallery ===== */
.gallery {
    background: var(--bg-light);
    padding: 4rem 0 8rem;
}

.gallery-item {
    display: flex;
    align-items: center;
    margin-bottom: 10rem;
    padding: 0 5%;
    opacity: 0;
    transform: translateY(60px);
}

.gallery-item:last-child {
    margin-bottom: 0;
}

.gallery-item-reverse {
    flex-direction: row-reverse;
}

.gallery-image {
    width: 75%;
    flex-shrink: 0;
    overflow: hidden;
}

.gallery-image img {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.6s ease;
}

.gallery-image:hover img {
    transform: scale(1.03);
}

.gallery-info {
    width: 25%;
    padding: 2rem 3rem;
}

.gallery-number {
    font-size: 0.85rem;
    color: var(--text-secondary);
    letter-spacing: 0.15em;
    display: block;
    margin-bottom: 1.5rem;
}

.gallery-place {
    font-size: clamp(1.5rem, 3vw, 2.5rem);
    letter-spacing: 0.1em;
    color: var(--text-dark);
    margin-bottom: 1.5rem;
    font-weight: 600;
    line-height: 1.2;
}

.gallery-desc {
    font-size: 0.95rem;
    line-height: 2;
    color: var(--text-secondary);
    letter-spacing: 0.02em;
}

/* ===== Tools ===== */
.tools {
    background: var(--bg-light);
    padding: 4rem 0 8rem;
    overflow: hidden;
}

.tools-heading {
    font-size: clamp(2rem, 5vw, 4rem);
    letter-spacing: 0.4em;
    text-align: center;
    color: var(--text-dark);
    margin-bottom: 4rem;
    font-weight: 600;
}

.tools-track-wrapper {
    width: 100%;
    overflow: hidden;
    cursor: grab;
    padding: 2rem 0;
}

.tools-track-wrapper:active {
    cursor: grabbing;
}

.tools-track {
    display: flex;
    gap: 2rem;
    padding: 0 5%;
    transition: transform 0.1s ease-out;
    will-change: transform;
}

a.tool-item {
    text-decoration: none;
    color: inherit;
}

.tool-item {
    position: relative;
    flex-shrink: 0;
    width: 220px;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
}

.tool-item.active {
    width: 500px;
}

.tool-item-img {
    width: 100%;
    height: 280px;
    overflow: hidden;
    position: relative;
}

.tool-item.active .tool-item-img {
    height: 400px;
}

.tool-item-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
    border-radius: 4px;
}

/* LIMS Dashboard Mockup */
.lims-mockup {
    width: 100%;
    height: 100%;
    background: #1a1a2e;
    border-radius: 4px;
    display: flex;
    overflow: hidden;
}

.lims-sidebar {
    width: 20%;
    background: #16213e;
    padding: 15px 8px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.lims-nav-item {
    height: 8px;
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.1);
}

.lims-nav-item.active {
    background: var(--accent);
}

.lims-content {
    flex: 1;
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.lims-topbar {
    height: 10px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 3px;
}

.lims-cards {
    display: flex;
    gap: 6px;
}

.lims-card {
    flex: 1;
    height: 50px;
    background: rgba(94, 179, 212, 0.15);
    border-radius: 4px;
    border: 1px solid rgba(94, 179, 212, 0.2);
}

.lims-table {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.lims-row {
    height: 8px;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 2px;
}

/* DOTs Coming Soon */
.dots-placeholder {
    width: 100%;
    height: 100%;
    background: #ffffff;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: 1px solid rgba(0, 0, 0, 0.06);
}

.dots-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--text-secondary);
    opacity: 0.3;
    animation: dotPulse 1.5s ease-in-out infinite;
}

.dots-dot:nth-child(2) {
    animation-delay: 0.3s;
}

.dots-dot:nth-child(3) {
    animation-delay: 0.6s;
}

@keyframes dotPulse {
    0%, 100% { opacity: 0.3; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.3); }
}

.tool-item-coming-soon {
    cursor: default;
}

.tool-item-coming-soon .tool-item-info p {
    font-style: italic;
}

.tool-item:hover .tool-item-img img {
    transform: scale(1.05);
}

.tool-item-label {
    display: block;
    font-size: 0.8rem;
    color: var(--text-secondary);
    letter-spacing: 0.15em;
    margin-top: 1rem;
    transition: opacity 0.3s;
}

.tool-item-info {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    margin-top: 0;
}

.tool-item.active .tool-item-info {
    max-height: 200px;
    opacity: 1;
    margin-top: 1rem;
}

.tool-item-info h3 {
    font-size: 1.3rem;
    letter-spacing: 0.1em;
    color: var(--text-dark);
    margin-bottom: 0.6rem;
    font-weight: 600;
}

.tool-item-info p {
    font-size: 0.9rem;
    line-height: 1.7;
    color: var(--text-secondary);
}

/* ===== About ===== */
.about {
    background: var(--bg-light);
    padding: 4rem 10% 8rem;
}

.about-name-block {
    margin-bottom: 5rem;
    opacity: 0;
    transform: translateY(60px);
}

.about-name-large {
    font-size: clamp(3rem, 8vw, 7rem);
    letter-spacing: 0.05em;
    line-height: 1.1;
    color: var(--text-dark);
    margin-bottom: 2rem;
    font-weight: 700;
}

.about-intro {
    font-size: 1rem;
    line-height: 1.8;
    color: var(--text-secondary);
    max-width: 500px;
}

.about-divider {
    width: 100%;
    height: 1px;
    background: #ccc;
    margin-bottom: 4rem;
}

.about-section {
    display: flex;
    gap: 4rem;
    margin-bottom: 4rem;
    opacity: 0;
    transform: translateY(40px);
}

.about-section-label {
    font-size: 0.85rem;
    color: var(--text-secondary);
    letter-spacing: 0.15em;
    min-width: 120px;
    flex-shrink: 0;
}

.about-section-text {
    font-size: 1rem;
    line-height: 1.8;
    color: var(--text-secondary);
    max-width: 500px;
}

/* ===== Footer ===== */
.footer {
    background: var(--bg-dark);
    padding: 5rem 3rem;
    text-align: center;
}

.footer-icons {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-icon {
    width: 28px;
    height: 28px;
    color: var(--text-light);
    opacity: 0.6;
    transition: opacity 0.3s, transform 0.3s;
}

.footer-icon:hover {
    opacity: 1;
    transform: translateY(-3px);
}

.footer-icon svg {
    width: 100%;
    height: 100%;
}

.footer-copy {
    font-size: 0.8rem;
    color: var(--text-secondary);
    letter-spacing: 0.15em;
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
    .nav {
        padding: 1rem 1.5rem;
    }

    .nav-links {
        gap: 1.2rem;
    }

    .nav-link {
        font-size: 0.85rem;
    }

    .gallery-item,
    .gallery-item-reverse {
        flex-direction: column;
    }

    .gallery-image,
    .gallery-info {
        width: 100%;
    }

    .gallery-info {
        padding: 1.5rem 0;
    }

    .gallery-item {
        margin-bottom: 5rem;
    }

    .tools-strip {
        flex-wrap: wrap;
    }

    .tool-thumb {
        width: 120px;
        height: 90px;
    }

    .tool-detail {
        flex-direction: column;
    }

    .tool-detail-image,
    .tool-detail-info {
        width: 100%;
    }

    .about {
        padding: 4rem 5% 6rem;
    }

    .about-section {
        flex-direction: column;
        gap: 1rem;
    }
}
