/* --- General Styling & Variables --- */
:root {
    --bg-color: #FFFFFF;
    --primary-color: #F9F9F9;
    --text-color: #333333;
    --accent-color: #007BFF;
    --heading-color: #111111;
    --card-bg: #FFFFFF;
    --border-color: #DDDDDD;
    --subtle-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.7;
}

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

h1, h2, h3 {
    font-family: "Mona Sans", "Segoe UI", system-ui, sans-serif;
    font-weight: 600;
    color: var(--heading-color);
}

h2 {
    text-align: center;
    font-size: 2.2rem;
    margin-bottom: 50px;
}

section {
    padding: 80px 0;
}

.btn-secondary {
    margin-top: 10px;
    display: inline-block;
    background: #8a8a8a;
    color: #fff;
    padding: 8px 12px;
    text-decoration: none;
    border-radius: 5px;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: var(--subtle-shadow);
}

.btn-secondary:hover {
    background: var(--accent-color);
    color: #fff;
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(0, 123, 255, 0.2);
}

.btn-secondary:active {
    transform: translateY(0);
    box-shadow: var(--subtle-shadow);
}

/* --- Header & Navigation --- */
.site-header {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    padding: 15px 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid var(--border-color);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.site-header.hidden {
    opacity: 0;
    transform: translateY(-100%);
}

.site-header.visible {
    opacity: 1;
    transform: translateY(0);
}

.main-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.main-nav .logo-container {
    display: flex;
    align-items: center;
    gap: 10px;
}

.main-nav .logo {
    font-family: 'Montserrat', sans-serif;
    color: var(--heading-color);
    text-decoration: none;
    font-size: 1.8rem;
    font-weight: 700;
}

.main-nav ul {
    list-style: none;
    display: flex;
}

.main-nav ul li {
    margin-left: 30px;
}

.main-nav ul li a {
    color: var(--text-color);
    text-decoration: none;
    font-size: 1rem;
    font-weight: 500;
    padding: 5px 10px;
    transition: color 0.3s ease;
}

.main-nav ul li a:hover {
    color: var(--accent-color);
}

/* --- Hero Section --- */
.hero {
    position: relative;
    height: 100vh;
    display: flex;
    align-items: center;
    text-align: center;
    background: linear-gradient(
        to bottom,
        rgba(255, 255, 255, 0) 0%,   /* fully transparent at top */
        rgba(255, 255, 255, 0.1) 70%, /* semi-transparent in the middle */
        rgba(255, 255, 255, 1) 100%  /* fully white at bottom */
    );
}

.hero-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: -1;
    transform: rotateX(180deg);
    -webkit-transform:rotateX(180deg); /* Safari and Chrome */
    -moz-transform:rotateX(180deg); /* Firefox */
}

.hero .container {
    position: relative;
    z-index: 1;
}

.hero h1 {
    font-size: 3.2rem;
    margin-bottom: 20px;
    font-weight: 700;
}

.hero #typewriter {
    color: var(--accent-color);
    border-right: 3px solid var(--accent-color);
    animation: blink 0.7s steps(1) infinite;
}

@keyframes blink {
    50% { border-color: transparent; }
}

.hero .subtitle {
    font-size: 1.2rem;
    max-width: 600px;
    margin: 0 auto 40px;
    color: #555;
}

.home-btn {
    display: inline-block;
    padding: 10px 20px;
    margin: 5px;
    text-decoration: none;
    border-radius: 20px;
    border: 1px solid var(--border-color);
    background-color: rgba(158, 158, 158, 0.01);
    font-weight: 500;
    transition: all 0.3s ease;
    color: var(--text-color);
}

.home-btn:hover {
    transform: translateY(-3px);
    border: 1px solid var(--accent-color);
    color: var(--accent-color);
    box-shadow: var(--subtle-shadow);
}

.home-btn:active {
    transform: translateY(0);
    box-shadow: none;
}

.btn {
    display: inline-block;
    background: var(--accent-color);
    color: #fff;
    padding: 12px 25px;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    transition: all 0.3s ease;
    border: 1px solid var(--accent-color);
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(0, 123, 255, 0.2);
}

/* --- Alternating Section Background --- */
.projects-section, .our-process, .contact-section {
    background-color: var(--primary-color);
    text-align: center;
}

/* --- About Me / Our Process Section --- */
.about-content, .contact-header .about-text {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    color: var(--text-color);
}

.profile-pic {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    object-fit: cover;
    border: 5px solid var(--bg-color);
    box-shadow: 0 0 20px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.process-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 30px 25px;
    text-align: center;
    box-shadow: var(--subtle-shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.08);
}

.card-icon {
    width: 45px;
    height: 45px;
    margin-bottom: 20px;
}

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

.card p {
    font-size: 0.95rem;
    color: #555;
    line-height: 1.6;
}

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

.project-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--subtle-shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.08);
}

.project-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    display: block;
}

.card-content {
    padding: 25px;
    height: calc(100% - 200px);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.card-content h3 {
    margin-bottom: 10px;
    color: var(--heading-color);
}

.card-content p {
    color: #555;
    font-size: 0.95rem;
}

#sumi-img {
    background: linear-gradient(to bottom right, #0a65af, #9fc3e1);
}

/* --- Skills Section --- */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 50px;
    text-align: left;
}

.skill-category h3 {
    font-size: 1.5rem;
    margin-bottom: 25px;
    color: var(--heading-color);
    border-bottom: 2px solid var(--accent-color);
    padding-bottom: 10px;
    display: inline-block;
}

.skill-category ul {
    list-style: none;
}

ul.tech-list li {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    font-size: 1rem;
    color: var(--text-color);
}

.tech-icon {
    width: 32px;
    height: 32px;
    margin-right: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tech-icon img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

/* --- Contact Section --- */
.contact-header {
    text-align: center;
    margin-bottom: 40px;
}

.contact-header h2 {
    margin-bottom: 15px;
}

.contact-form-container h2 {
    margin-bottom: 10px;
}

#contact-form {
    max-width: 600px;
    margin: 30px auto 0;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

#contact-form input,
#contact-form textarea {
    width: 100%;
    resize: none;
    padding: 15px;
    border-radius: 5px;
    border: 1px solid var(--border-color);
    background: var(--bg-color);
    color: var(--text-color);
    font-family: 'Inter', sans-serif;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

#contact-form input:focus,
#contact-form textarea:focus {
    outline: none;
    border-color: var(--accent-color);
}

/* --- Footer & Social Icons --- */
.site-footer {
    text-align: center;
    padding: 40px 0;
    background: var(--primary-color);
    border-top: 1px solid var(--border-color);
}

.footer-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

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

.social-icon {
    color: var(--text-color);
    font-size: 1.2rem;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 44px;
    height: 44px;
    text-decoration: none;
    border-radius: 50%;
    border: 2px solid var(--border-color);
    transition: all 0.3s ease;
}

.social-icon:hover {
    color: var(--accent-color);
    border-color: var(--accent-color);
    transform: translateY(-3px);
}

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

/* --- Responsive Design --- */
@media (max-width: 768px) {
    h2 {
        font-size: 1.8rem;
    }
    
    .main-nav {
        flex-direction: column;
        gap: 15px;
    }

    .main-nav ul {
        padding: 0;
    }

    .main-nav ul li {
        margin: 0 10px;
    }

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

    .skills-grid {
        grid-template-columns: 1fr;
        gap: 40px;
        text-align: center;
    }

    .skill-category h3 {
        display: inline-block;
        border-bottom: 2px solid var(--accent-color);
        padding-bottom: 10px;
    }

    ul.tech-list li {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .main-nav ul li a {
        font-size: 0.9rem;
    }
    .hero h1 {
        font-size: 2rem;
    }
    .process-grid, .project-grid {
        grid-template-columns: 1fr;
    }
}