/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #e2dac9;
    background-color: #6e5b49;
    overflow-x: hidden;
}

/* Hero Section */
.hero-section {
    position: relative;
    height: 800px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: url('bg-1.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    overflow: hidden;
}

.flying-f {
    position: absolute;
    top: 3%;
    font-weight: 900;
    pointer-events: none;
    will-change: transform, opacity;
    backface-visibility: hidden;
    transform-style: preserve-3d;
    left: 50%;
    transform: translate3d(-50%, -50%, 0);
    font-size: clamp(2rem, 8vw, 10rem);
    line-height: 1;
    white-space: nowrap;
    z-index: 3;
    mix-blend-mode: difference;
    animation: flyInText 1.2s ease-out forwards;
    background: darkred;
    -webkit-background-clip: text;
    background-clip: text;
    color: green;
    -webkit-text-fill-color: transparent;
    color: transparent;
}

@keyframes flyInText {
    from {
        transform: translate3d(-80%, -50%, 0);
        opacity: 0;
    }
    to {
        transform: translate3d(-50%, -50%, 0);
        opacity: 1;
    }
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
}

.hero-title {
    font-size: clamp(3rem, 10vw, 8rem);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    position: relative;
    min-height: 0;
    line-height: 1.2;
    visibility: hidden;
}

.hero-title::after,
.hero-tagline::after {
    content: '|';
    font-weight: 100;
    transform: scaleX(0.5);
    display: inline-block;
}

.hero-title::after {
    margin-left: 0.1em;
    color: #e2dac9;
}

.hero-title-black {
    color: #e2dac9;
    z-index: 1;
}

.hero-tagline {
    font-size: clamp(1rem, 2vw, 1.5rem);
    color: #bab7ac;
    font-weight: 300;
    letter-spacing: 0.05em;
    margin-top: 1rem;
    position: relative;
    z-index: 4;
    opacity: 0;
    visibility: hidden;
    mix-blend-mode: exclusion;
}

.hero-tagline::after {
    margin-left: 0.2em;
    color: #bab7ac;
}

.hero-tagline.typing-complete::after,
.hero-title.typing-complete::after {
    display: none;
}

/* Main Content */
.main-content {
    background-color: #6e5b49;
}

.cv-section {
    padding: 5rem 0;
    border-bottom: 1px solid #766c57;
}

.cv-section:last-child {
    border-bottom: none;
}

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

.section-title {
    font-size: 2.25rem;
    font-weight: 700;
    color: #e2dac9;
    margin-bottom: 2rem;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -0.5rem;
    left: 0;
    width: 72px;
    height: 4px;
    background: linear-gradient(90deg, #bab7ac, #e2dac9);
    border-radius: 2px;
}

/* About Section */
.about-text {
    font-size: 1.2rem;
    line-height: 1.8;
    color: #bab7ac;
    max-width: 800px;
}

/* Experience Section */
.experience-item {
    margin-bottom: 3rem;
    padding: 2rem;
    background: rgba(226, 218, 201, 0.05);
    border-radius: 16px;
    border: 1px solid rgba(226, 218, 201, 0.14);
    box-shadow: 0 10px 40px rgba(110, 91, 73, 0.35);
    transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}

.experience-item:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 48px rgba(118, 108, 87, 0.45);
    border-color: rgba(186, 183, 172, 0.35);
}

.experience-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.experience-header h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #e2dac9;
    margin: 0;
}

.company {
    color: #e2dac9;
    font-weight: 500;
}

.period {
    color: #828f89;
    font-size: 0.9rem;
}

.responsibilities {
    list-style: none;
    padding: 0;
}

.responsibilities li {
    padding: 0.5rem 0;
    padding-left: 1.5rem;
    position: relative;
    color: #bab7ac;
}

.responsibilities li::before {
    content: '▹';
    position: absolute;
    left: 0;
    color: #e2dac9;
    font-weight: bold;
}

/* Skills Section */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.skill-category h3 {
    font-size: 1.3rem;
    color: #e2dac9;
    margin-bottom: 1rem;
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.skill-tag {
    background: linear-gradient(135deg, rgba(226,218,201,0.06), rgba(186,183,172,0.04));
    color: #e2dac9;
    padding: 0.5rem 1rem;
    border-radius: 999px;
    font-size: 0.9rem;
    border: 1px solid rgba(226,218,201,0.14);
    transition: transform 0.25s ease, border-color 0.25s ease, background 0.25s ease;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.skill-tag:hover {
    background: linear-gradient(135deg, rgba(186,183,172,0.22), rgba(226,218,201,0.18));
    color: #e2dac9;
    transform: translateY(-3px);
    border-color: rgba(226,218,201,0.35);
}

/* Education Section */
.education-item {
    background: rgba(226, 218, 201, 0.05);
    padding: 2rem;
    border-radius: 16px;
    border: 1px solid rgba(226, 218, 201, 0.14);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.35);
}

.education-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.education-header h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #e2dac9;
    margin: 0;
}

.institution {
    color: #bab7ac;
    font-weight: 500;
}

.education-description {
    color: #bab7ac;
    line-height: 1.6;
}

/* Projects Section */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.project-card {
    background: rgba(226, 218, 201, 0.05);
    padding: 2rem;
    border-radius: 16px;
    border: 1px solid rgba(226, 218, 201, 0.14);
    box-shadow: 0 10px 40px rgba(110, 91, 73, 0.35);
    transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}

.project-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 16px 48px rgba(118, 108, 87, 0.45);
    border-color: rgba(186, 183, 172, 0.35);
}

.project-card h3 {
    font-size: 1.3rem;
    color: #e2dac9;
    margin-bottom: 1rem;
}

.project-card p {
    color: #bab7ac;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tech-tag {
    background: linear-gradient(135deg, rgba(226,218,201,0.06), rgba(186,183,172,0.04));
    color: #828f89;
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
    font-size: 0.8rem;
    border: 1px solid rgba(226,218,201,0.14);
}

/* Contact Section */
.contact-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.contact-item {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.contact-label {
    font-weight: 600;
    color: #e2dac9;
    font-size: 0.9rem;
}

.contact-value {
    color: #bab7ac;
    font-size: 1rem;
}

/* New interactive sections */
.expertise-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.5rem;
}

.glass-card,
.expertise-card,
.stat,
.slider {
    background: rgba(226, 218, 201, 0.05);
    border: 1px solid rgba(226, 218, 201, 0.14);
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(110, 91, 73, 0.35);
}

.expertise-card {
    padding: 1.5rem;
    transition: transform 0.25s ease, border-color 0.25s ease;
}

.expertise-card h3 {
    color: #e2dac9;
    margin-bottom: 0.5rem;
    font-size: 1.2rem;
}

.expertise-card p {
    color: #bab7ac;
    margin-bottom: 0.75rem;
}

.chips { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.chip {
    padding: 0.35rem 0.7rem;
    border-radius: 999px;
    border: 1px solid rgba(226,218,201,0.14);
    color: #e2dac9;
    background: linear-gradient(135deg, rgba(226,218,201,0.06), rgba(186,183,172,0.04));
    font-size: 0.8rem;
}

.tilt-card:hover { border-color: rgba(186,183,172,0.35); }

.timeline {
    position: relative;
    margin-left: 0.75rem;
    padding-left: 1.5rem;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 0.25rem;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(#766c57, #828f89);
    border-radius: 2px;
}

.timeline-item {
    position: relative;
    margin-bottom: 1.25rem;
}

.timeline-item .dot {
    position: absolute;
    left: -0.55rem;
    top: 0.4rem;
    width: 10px;
    height: 10px;
    background: linear-gradient(135deg, #bab7ac, #e2dac9);
    border-radius: 50%;
    box-shadow: 0 0 0 4px rgba(186,183,172,0.22);
}

.timeline-item .content {
    padding: 1rem 1.25rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.25rem;
}

.stat {
    padding: 1.5rem;
    text-align: center;
}

.stat-value {
    font-size: 2.25rem;
    font-weight: 800;
    color: #e2dac9;
}

.stat-label {
    color: #bab7ac;
    margin-top: 0.25rem;
}

.marquee {
    overflow: hidden;
    position: relative;
    border-radius: 12px;
    border: 1px solid rgba(226,218,201,0.14);
    background: rgba(226,218,201,0.05);
    -webkit-mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
            mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
}

.marquee-track {
    display: inline-flex;
    gap: 2rem;
    padding: 1rem 2rem;
    white-space: nowrap;
    animation: marquee 28s linear infinite;
    will-change: transform;
}

.marquee-track span {
    color: #bab7ac;
    font-weight: 600;
    letter-spacing: 0.04em;
}

@keyframes marquee {
    0% { transform: translateX(0%); }
    100% { transform: translateX(-50%); }
}

.marquee-logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 160px;
    height: 48px;
    color: #bab7ac;
    opacity: 0.8;
    filter: grayscale(15%) contrast(1.05);
    transition: opacity 0.2s ease, filter 0.2s ease, transform 0.2s ease;
}
.marquee-logo:hover { opacity: 1; filter: none; transform: translateY(-2px); }
.marquee-logo svg { width: 100%; height: 100%; }

.slider {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
}

.slides { overflow: hidden; position: relative; }
.slide { display: none; color: #bab7ac; }
.slide.active { display: block; }
.slider-btn {
    background: rgba(226,218,201,0.08);
    color: #e2dac9;
    border: 1px solid rgba(226,218,201,0.16);
    border-radius: 10px;
    width: 40px; height: 40px;
    cursor: pointer;
}
.slider-btn:hover { border-color: rgba(186,183,172,0.35); }

.accordion { display: grid; gap: 0.75rem; }
.accordion-item { border-radius: 12px; overflow: hidden; }
.accordion-header {
    width: 100%;
    text-align: left;
    padding: 0.9rem 1.1rem;
    background: rgba(226,218,201,0.05);
    border: 1px solid rgba(226,218,201,0.14);
    color: #e2dac9;
    cursor: pointer;
}
.accordion-panel {
    display: none;
    padding: 0.9rem 1.1rem;
    color: #bab7ac;
    background: rgba(226,218,201,0.04);
    border: 1px solid rgba(226,218,201,0.12);
    border-top: none;
}
.accordion-item.open .accordion-panel { display: block; }

.cta {
    padding: 2rem;
    text-align: center;
}
.btn-primary {
    display: inline-block;
    margin-top: 1rem;
    padding: 0.75rem 1.25rem;
    color: #6e5b49;
    font-weight: 700;
    border-radius: 12px;
    background: linear-gradient(135deg, #bab7ac, #e2dac9);
    border: 1px solid rgba(226,218,201,0.16);
}
.btn-primary:hover { filter: brightness(1.05); }

/* Scroll animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.cv-section {
    animation: fadeInUp 0.8s ease-out forwards;
}

/* Responsive Design */
@media (max-width: 768px) {
    .hero-title {
        font-size: clamp(2rem, 15vw, 4rem);
    }

    .container {
        padding: 0 1rem;
    }

    .cv-section {
        padding: 3rem 0;
    }

    .section-title {
        font-size: 2rem;
    }

    .experience-header {
        flex-direction: column;
        align-items: flex-start;
    }

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

    .skills-grid {
        grid-template-columns: 1fr;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #6e5b49;
}

::-webkit-scrollbar-thumb {
    background: #766c57;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #828f89;
}
