/* HERO */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 100px 60px 60px;
    position: relative;
    overflow: hidden;
    background: url('../assets/hero.png') top center/cover no-repeat;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--color-white-85);
    z-index: 0;
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 900px;
}

.hero h1 {
    font-size: 72px;
    margin-bottom: 20px;
    color: var(--color-dark);
    animation: fadeInUp 0.8s ease;
}

.hero .subtitle {
    font-size: 24px;
    color: var(--color-gray-700);
    margin-bottom: 30px;
    animation: fadeInUp 0.8s ease 0.2s both;
}

.hero .tagline {
    font-size: 18px;
    color: var(--color-gray-600);
    margin-bottom: 40px;
    max-width: 650px;
    margin-left: auto;
    margin-right: auto;
    animation: fadeInUp 0.8s ease 0.4s both;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    animation: fadeInUp 0.8s ease 0.6s both;
}

.btn-primary, .btn-secondary {
    padding: 16px 32px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 16px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: var(--gradient-primary);
    color: var(--color-white);
    box-shadow: 0 10px 30px var(--color-primary-30);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 40px var(--color-primary-30);
}

.btn-secondary {
    background: var(--color-white-90);
    border: 2px solid var(--color-primary);
    color: var(--color-primary);
    backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    background: var(--color-white);
    border-color: var(--color-primary-light);
    color: var(--color-primary-light);
    transform: translateY(-2px);
}

/* SERVICES */
.services {
    padding: 120px 60px;
    position: relative;
    background: var(--gradient-bg);
}

.section-header {
    max-width: 600px;
    margin: 0 auto 80px;
    text-align: center;
}

.section-title {
    font-size: 56px;
    margin-bottom: 20px;
    color: var(--color-dark);
    line-height: 1.1;
}

.section-subtitle {
    color: var(--color-gray-600);
    font-size: 20px;
    line-height: 1.6;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 30px;
    max-width: 1400px;
    margin: 0 auto;
}

.service-card {
    background: var(--color-white);
    border-radius: 24px;
    padding: 50px 40px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    border: 2px solid transparent;
}

.service-card:nth-child(1) {
    grid-column: span 6;
    background: var(--gradient-primary);
    color: white;
}

.service-card:nth-child(2) {
    grid-column: span 6;
    background: var(--color-dark);
    color: white;
}

.service-card:nth-child(3) {
    grid-column: span 4;
    border: 2px solid var(--color-gray-200);
}

.service-card:nth-child(4) {
    grid-column: span 4;
    border: 2px solid var(--color-gray-200);
}

.service-card:nth-child(5) {
    grid-column: span 4;
    border: 2px solid var(--color-gray-200);
}

.service-card:nth-child(6) {
    grid-column: span 12;
    background: var(--gradient-bg-reverse);
    border: 2px solid var(--color-gray-200);
    display: flex;
    align-items: center;
    gap: 40px;
    padding: 40px 50px;
}

.service-card::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.service-card:hover::after {
    opacity: 1;
}

.service-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

.service-card:nth-child(1):hover,
.service-card:nth-child(2):hover {
    box-shadow: 0 20px 60px rgba(102, 126, 234, 0.4);
}

.service-icon {
    font-size: 56px;
    margin-bottom: 24px;
    display: block;
    transition: transform 0.3s ease;
}

.service-card:hover .service-icon {
    transform: scale(1.1) rotate(5deg);
}

.service-card h3 {
    font-size: 28px;
    margin-bottom: 16px;
    position: relative;
    z-index: 1;
}

.service-card:nth-child(1) h3,
.service-card:nth-child(2) h3 {
    color: white;
}

.service-card:not(:nth-child(1)):not(:nth-child(2)) h3 {
    color: var(--color-dark);
}

.service-card p {
    line-height: 1.8;
    position: relative;
    z-index: 1;
    font-size: 16px;
}

.service-card:nth-child(1) p,
.service-card:nth-child(2) p {
    color: var(--color-white-90);
}

.service-card:not(:nth-child(1)):not(:nth-child(2)) p {
    color: var(--color-gray-700);
}

.service-card:nth-child(6) {
    flex-direction: row;
}

.service-card:nth-child(6) .service-icon {
    margin-bottom: 0;
    font-size: 72px;
    flex-shrink: 0;
}

.service-card:nth-child(6) div {
    flex: 1;
}

/* PORTFOLIO */
.portfolio {
    padding: 120px 60px;
    background: var(--color-gray-100);
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(450px, 1fr));
    gap: 40px;
    max-width: 1400px;
    margin: 0 auto;
}

.portfolio-card {
    border-radius: 24px;
    padding: 60px 40px 40px;
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
    min-height: 500px;
}

.portfolio-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.2);
}

/* DEVICE MOCKUPS */
.device {
    position: relative;
    transition: transform 0.4s ease;
}

.portfolio-card:hover .device {
    transform: scale(1.05);
}

/* LAPTOP */
.device.laptop {
    width: 100%;
    max-width: 400px;
    position: relative;
}

.device.laptop::before {
    content: '';
    display: block;
    padding-bottom: 62.5%;
}

.device.laptop .device-screen {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--color-black);
    border-radius: 12px;
    padding: 8px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
}

.device.laptop .device-screen::after {
    content: '';
    position: absolute;
    bottom: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 120%;
    height: 8px;
    background: linear-gradient(to bottom, #333, var(--color-black));
    border-radius: 0 0 8px 8px;
}

.device.laptop .device-screen img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 6px;
    display: block;
}

.device.phone {
    width: 180px;
    height: 360px;
    position: relative;
    background: var(--color-black);
    border-radius: 30px;
    padding: 12px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
}

.device.phone .device-frame {
    position: absolute;
    top: 12px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 20px;
    background: var(--color-black);
    border-radius: 0 0 15px 15px;
    z-index: 2;
}

.device.phone .device-screen {
    width: 100%;
    height: 100%;
    background: var(--color-white);
    border-radius: 22px;
    overflow: hidden;
    position: relative;
}

.device.phone .device-screen img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* PORTFOLIO INFO */
.portfolio-info {
    text-align: center;
    color: white;
    z-index: 1;
}

.portfolio-info h3 {
    font-size: 24px;
    margin-bottom: 8px;
    color: white;
}

.portfolio-info p {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
}

/* CUSTOMER PORTAL */
.customer-portal {
    padding: 100px 60px;
    background: var(--gradient-primary);
    position: relative;
    overflow: hidden;
}

.customer-portal::before {
    content: '';
    position: absolute;
    top: -100px;
    left: -100px;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    border-radius: 50%;
}

.customer-portal::after {
    content: '';
    position: absolute;
    bottom: -150px;
    right: -150px;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.08) 0%, transparent 70%);
    border-radius: 50%;
}

.portal-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 40px;
    align-items: center;
    position: relative;
    z-index: 1;
}

.portal-icon {
    font-size: 80px;
    color: var(--color-white);
    opacity: 0.9;
}

.portal-text h2 {
    font-size: 42px;
    margin-bottom: 16px;
    color: var(--color-white);
    line-height: 1.2;
}

.portal-text p {
    font-size: 18px;
    color: var(--color-white-90);
    line-height: 1.7;
    margin: 0;
}

.portal-action .btn-primary {
    background: var(--color-white);
    color: var(--color-primary);
    padding: 18px 36px;
    font-size: 17px;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.portal-action .btn-primary:hover {
    transform: translateY(-4px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
}

.portal-action .btn-primary i {
    transition: transform 0.3s ease;
}

.portal-action .btn-primary:hover i {
    transform: translateX(5px);
}

/* ABOUT */
.about {
    padding: 140px 60px;
    background: var(--color-white);
    position: relative;
    overflow: hidden;
}

.about::before {
    content: '';
    position: absolute;
    top: -200px;
    right: -200px;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(102, 126, 234, 0.08) 0%, transparent 70%);
    border-radius: 50%;
}

.about-wrapper {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 100px;
    align-items: center;
}

.about-content {
    position: relative;
    z-index: 1;
}

.about h2 {
    font-size: 52px;
    margin-bottom: 30px;
    color: var(--color-dark);
    line-height: 1.2;
}

.about p {
    font-size: 19px;
    color: var(--color-gray-700);
    line-height: 1.8;
    margin-bottom: 24px;
}

.about-highlight {
    background: var(--gradient-primary);
    padding: 40px;
    margin: 50px 0;
    border-radius: 20px;
    position: relative;
    overflow: hidden;
}

.about-highlight::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 60%);
}

.about-highlight p {
    margin: 0;
    color: white;
    font-size: 18px;
    position: relative;
    z-index: 1;
}

.about-highlight strong {
    display: block;
    font-size: 22px;
    margin-bottom: 12px;
}

/* TECH STACK */
.tech-stack {
    position: relative;
    z-index: 1;
}

.tech-stack h3 {
    margin-bottom: 40px;
    font-size: 28px;
    color: var(--color-dark);
}

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

.tech-tag {
    padding: 16px 24px;
    background: var(--color-gray-100);
    border: 2px solid var(--color-gray-200);
    border-radius: 12px;
    font-size: 15px;
    font-weight: 500;
    color: var(--color-gray-900);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.tech-tag::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--gradient-primary);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.tech-tag:hover {
    border-color: var(--color-primary);
    color: white;
    transform: translateY(-4px);
    box-shadow: 0 8px 20px var(--color-primary-30);
}

.tech-tag:hover::before {
    opacity: 1;
}

.tech-tag span {
    position: relative;
    z-index: 1;
}

/* PORTFOLIO INLINE STYLES */
.portfolio-card.dark-bg {
    background: var(--color-dark);
}

.portfolio-card img {
    width: auto;
    max-height: 360px;
    border-radius: 30px;
}

.portfolio-card.purple-bg img {
    width: 100%;
    max-width: 400px;
    border-radius: 12px;
}

/* CTA */
.cta {
    padding: 140px 60px;
    position: relative;
    overflow: hidden;
    background: var(--color-dark);
}

.cta::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(circle at 20% 30%, rgba(102, 126, 234, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(118, 75, 162, 0.15) 0%, transparent 50%);
    z-index: 0;
}

.cta-content {
    position: relative;
    z-index: 1;
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 80px;
    align-items: center;
}

.cta-text h2 {
    font-size: 56px;
    margin-bottom: 24px;
    color: var(--color-white);
    line-height: 1.2;
}

.cta-text p {
    font-size: 20px;
    color: var(--color-white-80);
    line-height: 1.7;
    margin-bottom: 0;
}

.cta-action {
    background: var(--color-white-05);
    backdrop-filter: blur(10px);
    border: 2px solid var(--color-white-10);
    border-radius: 24px;
    padding: 50px;
    text-align: center;
}

.cta-action .btn-primary {
    background: var(--color-white);
    color: var(--color-dark);
    width: 100%;
    padding: 20px 40px;
    font-size: 18px;
    margin-bottom: 20px;
}

.cta-action .btn-primary:hover {
    transform: translateY(-4px);
    box-shadow: 0 15px 40px var(--color-primary-30);
}

.cta-info {
    color: var(--color-white-60);
    font-size: 14px;
    margin-top: 16px;
}

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

/* RESPONSIVE */
@media (max-width: 1024px) {
    .about-wrapper {
        grid-template-columns: 1fr;
        gap: 60px;
    }

    .cta-content {
        grid-template-columns: 1fr;
        gap: 50px;
    }

    .tech-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* RESPONSIVE */
@media (max-width: 768px) {
    .hero {
        padding: 80px 30px 40px;
    }

    .hero h1 {
        font-size: 42px;
    }

    .hero .subtitle {
        font-size: 18px;
    }

    .hero .tagline {
        font-size: 16px;
    }

    .hero-buttons {
        flex-direction: column;
        gap: 15px;
    }

    .services, .about, .cta, .portfolio, .customer-portal {
        padding: 60px 30px;
    }

    .portal-content {
        grid-template-columns: 1fr;
        gap: 30px;
        text-align: center;
    }

    .portal-icon {
        font-size: 60px;
    }

    .portal-text h2 {
        font-size: 32px;
    }

    .portal-text p {
        font-size: 16px;
    }

    .portal-action .btn-primary {
        width: 100%;
        justify-content: center;
    }

    .section-title, .about h2, .cta-text h2 {
        font-size: 36px;
    }

    .section-subtitle, .cta-text p {
        font-size: 16px;
    }

    .services-grid {
        grid-template-columns: 1fr !important;
    }

    .service-card {
        grid-column: span 1 !important;
    }

    .service-card:nth-child(6) {
        flex-direction: column;
    }

    .service-card:nth-child(6) .service-icon {
        margin-bottom: 20px;
        font-size: 56px;
    }

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

    .portfolio-card {
        min-height: 400px;
        padding: 40px 20px 30px;
    }

    .device.laptop {
        max-width: 100%;
    }

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

    .cta-action {
        padding: 30px;
    }
}