/* --------------------------------
    common css and utilities 
----------------------------------*/

body {
    font-family: 'Poppins', sans-serif;
    margin: auto;
    max-width: 1700px;
    background-color: var(--bg-body);
    color: var(--text-nav);
}

h1 {
    font-size: 50px;
    margin: 0px;
    color: var(--text-header);
}

h2 {
    font-size: 40px;
    color: var(--text-header);
}

p {
    color: var(--text-secondary);
    padding: 0px 0px;
    line-height: 1.6;
}

/* font colors */

.text-orange {
    color: orange;
}

.text-red {
    color: var(--accent-red);
}

/* elements and containers */
section {
    margin-bottom: 100px;
}

.container {
    margin: 0 4.2em;
}

.half-width {
    width: 40%;
    max-width: 600px;
}

.half-width img {
    width: 100%;
}

/* display and alingment */
.flex {
    display: flex;
    justify-content: space-between;
}

.grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
}

.vartical-center {
    align-items: center;
}


/* buttons */
.theme-toggle {
    background: transparent;
    border: 1px solid var(--border-light);
    color: var(--text-nav);
    padding: 8px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    width: 40px;
    height: 40px;
}

.theme-toggle:hover {
    background: var(--bg-input);
    color: var(--accent);
}

[data-theme="dark"] .icon-moon {
    display: none;
}

[data-theme="dark"] .icon-sun {
    display: block;
}

[data-theme="light"] .icon-sun {
    display: none;
}

[data-theme="light"] .icon-moon {
    display: block;
}

.anchor-button {
    position: relative;
    display: inline-block;
    text-transform: uppercase;
    text-decoration: none;
    color: white;
    font-weight: 600;
    padding: 14px 40px;
    border-radius: 50px;
    border: none;
    cursor: pointer;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    font-size: 0.9rem;
    letter-spacing: 1px;
}

.anchor-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.6s;
}

.anchor-button:hover::before {
    left: 100%;
}

.anchor-button:hover {
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

.anchor-button:active {
    transform: translateY(0) scale(0.98);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.button-bg-primary {
    background: linear-gradient(135deg, #ff6b6b 0%, #ff8e53 100%);
    background-size: 200% 200%;
    animation: gradientShift 3s ease infinite;
}

.button-bg-primary:hover {
    background: linear-gradient(135deg, #ff8e53 0%, #ff6b6b 100%);
}

.button-bg-secondary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    background-size: 200% 200%;
    animation: gradientShift 3s ease infinite;
}

.button-bg-secondary:hover {
    background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
}

@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

/* stylish border */
.border-style-1 {
    border-left: 7px solid;
    border-image: linear-gradient(180deg, lightsalmon, tomato);
    border-image-slice: 1;
}

.border-style-2 {
    border-left: 7px solid;
    border-image: linear-gradient(180deg, #ff008c, #ff47d7);
    border-image-slice: 1;
}

.border-style-3 {
    border-left: 7px solid;
    border-image: linear-gradient(180deg, blue, cyan);
    border-image-slice: 1;
}

/* --------------------
    dream big section
----------------------*/

#dream-big {
    background-image: url(../images/dream-bg.png);
    background-size: 80px;
    background-repeat: no-repeat;
    background-position: right;
    padding-right: 80px;
}

/* -------------------
    exprience section
---------------------*/
#exprience {
    background-image: url(../images/exp-bg.png);
    background-repeat: no-repeat;
    background-position: left;
}

.info-box {
    background-color: var(--bg-nav);
    border-bottom: 1px solid var(--border-light);
    border-radius: 5px;
    margin: 5px;
    padding: 5px;
    box-shadow: 5px 10px 18px gray;
}

/* --------------------
    footer section
----------------------- */
footer p {
    text-align: center;
}


/* -----------------
    media quaries
------------------- */
/* medium devices */
@media only screen and (max-width:992px) {
    h1 {
        font-size: 35px;
        display: inline;
    }

    p {
        text-align: justify;
    }

    .container {
        margin: 0 1em;
    }

    .half-width {
        width: 100%;
    }

    .half-width img {
        margin: 10% 0;
    }

    .flex {
        flex-wrap: wrap;
    }

    #dream-big {
        padding-right: 0px;
    }

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

    .anchor-button {
        display: inline-block;
        margin: 2px 0;
    }
}

/* small devices */
@media only screen and (max-width: 688px) {

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

/* ============================================
   SPA COMPONENT STYLES
   ============================================ */

/* Section Titles */
.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 0.5rem;
    background: linear-gradient(45deg, tomato, orange);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-subtitle {
    text-align: center;
    color: #666;
    margin-bottom: 3rem;
    font-size: 1.1rem;
}

/* Hero Section */
.hero {
    padding: 4rem 0;
}

.hero-title {
    line-height: 1.2;
    margin-bottom: 1rem;
}

.hero-subtitle {
    color: #666;
    margin-bottom: 1.5rem;
}

.hero-description {
    margin-bottom: 2rem;
    line-height: 1.8;
}

.hero-cta {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* Timeline Styles */
.timeline {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.timeline-item {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    padding: 1.5rem 2rem;
    border-radius: 8px;
    box-shadow: var(--shadow-card);
}

.timeline-date {
    font-weight: 600;
    display: block;
    margin-bottom: 0.5rem;
}

/* Skills Grid */
.skill-card {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    padding: 1.5rem;
    border-radius: 12px;
    text-align: center;
    box-shadow: var(--shadow-card);
}

.skill-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.skill-card h4 {
    margin: 0.5rem 0;
    color: var(--text-header);
}

.skill-card p {
    font-size: 0.9rem;
    margin: 0;
}

/* Service Cards */
.services-grid {
    margin-bottom: 3rem;
}

.service-card {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    padding: 2rem;
    border-radius: 12px;
    box-shadow: var(--shadow-card);
}

.service-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.service-card h3 {
    margin: 0 0 1rem;
    color: var(--text-header);
}

.service-features {
    list-style: none;
    padding: 0;
    margin-top: 1rem;
}

.service-features li {
    padding: 0.3rem 0;
    color: #aaa;
    font-size: 0.9rem;
}

.services-cta {
    text-align: center;
    padding: 3rem;
    background: var(--grad-card);
    border: 1px solid var(--border-light);
    border-radius: 12px;
}

/* Portfolio Grid */
.portfolio-grid {
    margin-bottom: 3rem;
}

.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    row-gap: 60px;
}

.project-card {
    background: var(--bg-card);
    border: 1px solid var(--border-card);
    padding: 1.2rem;
    /* Reduced from 1.5rem */
    border-radius: 12px;
    border-left: 4px solid var(--accent);
    box-shadow: var(--shadow-card);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.project-icon img {
    width: 100px;
    height: 100px;
    object-fit: contain;
    border-radius: 4px;
}

.project-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.8rem;
    /* Reduced */
}

.project-title {
    margin: 0;
    font-size: 1.1rem;
    /* Reduced from 1.2rem */
}

.project-language {
    background: linear-gradient(45deg, lightsalmon, tomato);
    color: #fff;
    padding: 0.2rem 0.6rem;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 600;
}

.project-description {
    margin-bottom: 0.8rem;
    font-size: 0.9rem;
    /* Reduced from 0.95rem */
    flex-grow: 1;
}

.project-links .anchor-button {
    font-size: 0.8rem;
    padding: 0.3rem 0.8rem;
}

.project-tech-pills {
    display: flex;
    gap: 5px;
    flex-wrap: wrap;
}

.tech-pill {
    background: var(--bg-tag);
    color: var(--text-secondary);
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.75rem;
    border: 1px solid var(--border-light);
}

.portfolio-cta {
    text-align: center;
    padding: 2rem;
}

/* Media Queries for Grid-4 */
@media only screen and (max-width: 1200px) {
    .grid-4 {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media only screen and (max-width: 900px) {
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media only screen and (max-width: 600px) {
    .grid-4 {
        grid-template-columns: 1fr;
    }

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

/* Contact Form */
.contact-wrapper {
    gap: 3rem;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-weight: 600;
    color: var(--text-muted);
}

.form-group input,
.form-group textarea {
    padding: 0.8rem 1rem;
    border: 1px solid var(--border-light);
    background: var(--bg-input);
    color: var(--text-primary);
    border-radius: 8px;
    font-family: inherit;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

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

.form-status .success {
    color: var(--accent-green);
    padding: 1rem;
    background: var(--bg-badge);
    border: 1px solid rgba(76, 175, 80, 0.3);
    border-radius: 8px;
}

/* Social Links */
.social-links {
    list-style: none;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin: 2rem 0;
}

.social-links li a {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: var(--bg-input);
    border-radius: 8px;
    text-decoration: none;
    color: var(--text-nav);
    transition: background 0.3s ease;
}

.social-links li a:hover {
    background: var(--bg-tag);
}

.social-icon {
    font-size: 1.5rem;
}

.availability-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.8rem 1.2rem;
    background: var(--bg-badge);
    border: 1px solid rgba(76, 175, 80, 0.3);
    border-radius: 30px;
    color: var(--accent-green);
    font-weight: 500;
}

.status-dot {
    width: 10px;
    height: 10px;
    background: #4caf50;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

/* Error Page */
.error-page {
    text-align: center;
    padding: 5rem 2rem;
}

.error-page h1 {
    font-size: 6rem;
    background: linear-gradient(45deg, tomato, orange);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}