/* =================================================================
   MARIAN SERGHE PORTFOLIO - ORIGINAL
   ================================================================= */

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

:root {
    --bg-primary: #0a0a0a;
    --bg-secondary: #0f0f0f;
    --bg-card: #141414;
    --text-primary: #ffffff;
    --text-secondary: #86868b;
    --text-muted: #6e6e73;
    --accent: #f5f5f7;
    --accent-gold: #c9a962;
    --border: rgba(255,255,255,0.1);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Barlow', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

/* Navigation */
nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 15px 50px 5px 50px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(0,0,0,0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.logo {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 24px;
    letter-spacing: 2px;
    display: flex;
    align-items: center;
}

/* Option 3: MS with gold bar */
.logo-mark {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    gap: 5px;
    color: #ffffff;
}

.logo-ms {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 32px;
    letter-spacing: 0;
    line-height: 1;
    color: #ffffff;
}

.logo-bar {
    width: 32px;
    height: 3px;
    background: #c9a962;
    transition: all 0.3s ease;
}

.logo-mark:hover .logo-ms {
    opacity: 0.9;
}

.logo-mark:hover .logo-bar {
    box-shadow: 0 0 12px #c9a962;
    width: 36px;
}

.logo-mark:focus {
    outline: none;
}

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

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    font-weight: 400;
    transition: color 0.3s ease;
}

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

.nav-links a.active {
    color: var(--text-primary);
    font-weight: 600;
}

/* Hamburger Menu */
.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 10px;
    z-index: 1002;
}

.nav-toggle span {
    width: 24px;
    height: 2px;
    background: var(--text-primary);
    transition: all 0.3s ease;
}

.nav-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle.active span:nth-child(2) {
    opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 100px 20px;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(ellipse at 50% 0%, rgba(201,169,98,0.115) 0%, transparent 50%);
    pointer-events: none;
}

.hero-subtitle {
    font-size: 14px;
    font-weight: 500;
    color: var(--accent-gold);
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: 20px;
    opacity: 0;
    animation: fadeInUpHero 0.8s ease forwards;
}

.hero-title {
    font-family: 'Bebas Neue', sans-serif;
    font-size: clamp(64px, 12vw, 120px);
    font-weight: 400;
    letter-spacing: 4px;
    margin-bottom: 15px;
    opacity: 0;
    animation: fadeInUpHero 0.8s ease 0.2s forwards;
    cursor: default;
    transition: text-shadow 0.3s ease;
}

.hero-title:hover {
    text-shadow: 0 0 30px rgba(201, 169, 98, 0.4);
}

.hero-divider {
    width: 128px;
    height: 3px;
    background: var(--accent-gold);
    margin: 0 auto 15px auto;
    opacity: 0;
    animation: fadeInUpHero 0.8s ease 0.35s forwards;
}

.hero-tagline {
    font-size: clamp(18px, 3vw, 24px);
    font-weight: 300;
    color: var(--text-secondary);
    max-width: 600px;
    margin-bottom: 40px;
    opacity: 0;
    animation: fadeInUpHero 0.8s ease 0.4s forwards;
}

.hero-brands {
    display: flex;
    gap: 40px;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 60px;
    opacity: 0;
    animation: fadeInUpHero 0.8s ease 0.6s forwards;
}

.hero-brands span {
    font-size: 12px;
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 2px;
}

.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    opacity: 0;
    animation: fadeInUpScroll 0.8s ease 1s forwards, bounce 2s ease-in-out infinite 1.5s;
    text-decoration: none;
    cursor: pointer;
    transition: opacity 0.3s ease;
}

.scroll-indicator:hover {
    opacity: 0.7;
}

.scroll-indicator svg {
    width: 24px;
    height: 24px;
    stroke: var(--accent-gold);
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

@keyframes fadeInUpHero {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInUpScroll {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

@keyframes bounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(10px); }
}

/* Section Styles */
section {
    padding: 120px 50px;
    max-width: 1400px;
    margin: 0 auto;
}

.section-label {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 11px;
    font-weight: 400;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 4px;
    margin-bottom: 20px;
}

.section-title {
    font-family: 'Bebas Neue', sans-serif;
    font-size: clamp(40px, 6vw, 64px);
    font-weight: 400;
    letter-spacing: 2px;
    margin-bottom: 40px;
}

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

.portfolio-item {
    position: relative;
    aspect-ratio: 4/5;
    overflow: hidden;
    background: var(--bg-card);
    cursor: pointer;
    transition: transform 0.5s ease, box-shadow 0.4s ease;
}

.portfolio-item:hover {
    transform: scale(1.02);
    box-shadow: 0 0 30px rgba(201, 162, 39, 0.173), 0 0 60px rgba(201, 162, 39, 0.086);
}

.portfolio-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease, opacity 0.4s ease, filter 0.4s ease;
    opacity: 0.75;
    filter: grayscale(100%);
}

.portfolio-item:hover img {
    transform: scale(1.05);
    opacity: 1;
    filter: grayscale(0%);
}

.portfolio-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 40px 30px;
    background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, transparent 100%);
    transform: translateY(20px);
    opacity: 0;
    transition: all 0.4s ease;
}

.portfolio-item:hover .portfolio-overlay {
    transform: translateY(0);
    opacity: 1;
}

.portfolio-category {
    font-size: 12px;
    font-weight: 500;
    color: var(--accent-gold);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 8px;
}

.portfolio-title {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 22px;
    letter-spacing: 1px;
}

/* About Section */
.about {
    background: var(--bg-secondary);
    padding: 120px 50px;
    margin: 0;
    max-width: none;
}

.about-content {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: stretch;
}

/* Hide mobile-only elements on desktop */
.about-header-mobile,
.about-text-mobile {
    display: none;
}

.about-text p {
    font-size: 18px;
    color: var(--text-secondary);
    margin-bottom: 30px;
    line-height: 1.8;
}

.about-text p:first-of-type {
    font-size: 24px;
    color: var(--text-primary);
    font-weight: 300;
}

.about-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    margin-top: 50px;
}

.stat {
    text-align: left;
}

.stat-number {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 56px;
    letter-spacing: 1px;
    color: var(--accent-gold);
}

.stat-label {
    font-size: 14px;
    color: var(--text-muted);
    margin-top: 5px;
}

.about-image {
    position: relative;
    display: flex;
    align-items: stretch;
}

.about-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 20px;
    transition: box-shadow 0.4s ease;
}

.about-image img:hover {
    box-shadow: 0 0 40px rgba(201, 162, 39, 0.3);
}

/* Brands Section */
.brands {
    text-align: center;
    padding: 80px 50px;
    background: linear-gradient(to bottom, var(--bg-secondary), var(--bg-primary));
}

.brands-title {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 40px;
}

.brands-grid {
    display: flex;
    justify-content: center;
    gap: 60px;
    flex-wrap: wrap;
    max-width: 800px;
    margin: 0 auto;
}

.brand-item {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 20px;
    letter-spacing: 2px;
    color: var(--text-secondary);
    transition: color 0.3s ease;
}

.brand-item:hover {
    color: var(--text-primary);
}

/* Contact Section */
.contact {
    max-width: 800px;
    text-align: center;
}

.contact-intro {
    font-size: 24px;
    font-weight: 300;
    color: var(--text-secondary);
    margin-bottom: 50px;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
    text-align: left;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

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

.form-group label {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
}

.form-group input,
.form-group textarea {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 16px 20px;
    font-size: 16px;
    color: var(--text-primary);
    font-family: inherit;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-gold);
    box-shadow: 0 0 0 3px rgba(201,169,98,0.1);
}

.form-group textarea {
    min-height: 150px;
    resize: vertical;
}

.submit-btn {
    background: var(--text-primary);
    color: var(--bg-primary);
    border: none;
    border-radius: 12px;
    padding: 18px 40px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
}

.submit-btn:hover {
    background: var(--accent-gold);
    transform: translateY(-2px);
}

/* Footer */
footer {
    padding: 60px 50px;
    border-top: 1px solid var(--border);
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
    gap: 20px;
}

.footer-links {
    display: flex;
    gap: 30px;
    justify-self: start;
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--text-primary);
}

.footer-social {
    display: flex;
    gap: 20px;
    justify-self: end;
}

footer p {
    justify-self: center;
}

.footer-social a {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.3s ease;
}

.footer-social a:hover {
    border-color: var(--accent-gold);
    color: var(--accent-gold);
}

/* Image Protection */
img {
    -webkit-user-drag: none;
    -khtml-user-drag: none;
    -moz-user-drag: none;
    -o-user-drag: none;
    user-drag: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    pointer-events: none;
}

.portfolio-item,
.portfolio-item a {
    pointer-events: auto;
}

/* Mobile Menu Overlay */
.mobile-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #0a0a0a;
    z-index: 1000;
    display: none;
}

.mobile-overlay.active {
    display: block;
}

/* Responsive */
@media (max-width: 768px) {
    nav {
        padding: 15px 20px;
    }
    
    .logo .logo-ms {
        font-size: 26px;
    }
    
    .logo .logo-bar {
        width: 26px;
        height: 2px;
    }

    .nav-toggle {
        display: flex;
        z-index: 1003;
    }

    nav.menu-open {
        background: #0a0a0a !important;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }

    .nav-links {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 30px;
        display: none;
        z-index: 1002;
    }

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

    .nav-links a {
        font-size: 24px;
        font-weight: 500;
    }

    section {
        padding: 80px 20px;
    }

    /* Hero - larger name on mobile */
    .hero-title {
        font-size: clamp(56px, 15vw, 80px);
        letter-spacing: 2px;
    }
    
    /* Hero brands - pharma only, smaller */
    .hero-brands {
        gap: 20px;
        margin-top: 40px;
    }
    
    .hero-brands span {
        font-size: 10px;
    }
    
    .hero-brands span:nth-child(n+9) {
        display: none;
    }

    /* About - image next to headline on mobile */
    /* Hide desktop layout, show mobile layout */
    .about-content {
        display: none;
    }
    
    .about-header-mobile {
        display: flex;
        align-items: center;
        gap: 15px;
        margin-bottom: 20px;
    }
    
    .about-image-mobile {
        width: 70px;
        flex-shrink: 0;
    }
    
    .about-image-mobile img {
        width: 100%;
        aspect-ratio: 1/1;
        object-fit: cover;
        border-radius: 12px;
        opacity: 0.85;
    }
    
    .about-header-mobile .section-label {
        margin-bottom: 4px;
    }
    
    .about-header-mobile .section-title {
        margin-bottom: 0;
        font-size: 28px;
    }
    
    .about-text-mobile {
        display: block;
    }
    
    .about-text-mobile p {
        font-size: 14px;
        color: var(--text-secondary);
        margin-bottom: 20px;
        line-height: 1.7;
    }
    
    .about-stats {
        grid-template-columns: repeat(3, 1fr);
        gap: 15px;
    }
    
    .stat-number {
        font-size: 36px;
    }
    
    .stat-label {
        font-size: 11px;
    }

    /* Career Timeline - smaller fonts */
    #experience h3 {
        font-size: 22px !important;
    }
    
    #experience p {
        font-size: 13px !important;
    }

    /* Brands Grid - pharma only, smaller */
    .brands-grid {
        gap: 25px;
    }
    
    .brand-item {
        font-size: 14px;
    }
    
    /* Show first 12 brands on mobile */
    .brand-item:nth-child(n+13) {
        display: none;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .portfolio-grid {
        grid-template-columns: 1fr;
    }
    
    .portfolio-item {
        aspect-ratio: 1/1;
    }
    
    /* Show overlay by default on mobile */
    .portfolio-item img {
        opacity: 1;
        filter: grayscale(0%);
    }
    
    .portfolio-overlay {
        opacity: 1;
        transform: translateY(0);
    }

    footer {
        display: flex;
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }

    .footer-links {
        flex-wrap: wrap;
        justify-content: center;
    }
}

/* =================================================================
   PASSWORD MODAL
   ================================================================= */

.password-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    z-index: 2000;
    justify-content: center;
    align-items: center;
    backdrop-filter: blur(5px);
}

.password-modal.active {
    display: flex;
}

.password-modal-content {
    background: var(--bg-card);
    border: 1px solid var(--border);
    padding: 40px;
    border-radius: 12px;
    text-align: center;
    max-width: 360px;
    width: 90%;
}

.password-modal-content h3 {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 28px;
    color: var(--text-primary);
    margin-bottom: 10px;
    letter-spacing: 2px;
}

.password-modal-content p {
    color: var(--text-secondary);
    font-size: 14px;
    margin-bottom: 20px;
}

.password-modal-content input {
    width: 100%;
    padding: 14px 18px;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 16px;
    text-align: center;
    outline: none;
    transition: border-color 0.3s ease;
}

.password-modal-content input:focus {
    border-color: var(--accent-gold);
}

.password-error {
    color: #ff6b6b;
    font-size: 13px;
    margin-top: 10px;
    margin-bottom: 0;
    display: none;
}

.password-error.show {
    display: block;
}

.password-buttons {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

.password-btn {
    flex: 1;
    padding: 12px 20px;
    background: var(--accent-gold);
    border: none;
    border-radius: 8px;
    color: var(--bg-primary);
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.password-btn:hover {
    background: #d4b572;
    transform: translateY(-2px);
}

.password-btn-cancel {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-secondary);
}

.password-btn-cancel:hover {
    background: var(--bg-secondary);
    border-color: var(--text-secondary);
}