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

:root {
    --bg: #071018;
    --bg-deep: #060d15;
    --panel: rgba(13, 23, 36, 0.88);
    --panel-soft: #132235;
    --line: rgba(120, 156, 191, 0.28);
    --line-strong: rgba(123, 244, 255, 0.55);
    --text-primary: #f2fbff;
    --text-secondary: #8ea2b6;
    --accent: #69f0ff;
    --accent-strong: #38d9f5;
    --accent-secondary: #b6ff63;
    --shadow: rgba(0, 0, 0, 0.34);
    --pixel-shadow: 0 0 0 1px rgba(6, 18, 27, 0.85), 6px 6px 0 rgba(5, 11, 18, 0.9);
    --content-width: 1180px;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Space Grotesk', sans-serif;
    background:
        radial-gradient(circle at top right, rgba(105, 240, 255, 0.1), transparent 30%),
        radial-gradient(circle at bottom left, rgba(182, 255, 99, 0.08), transparent 28%),
        linear-gradient(180deg, var(--bg) 0%, #09111b 45%, var(--bg-deep) 100%);
    color: var(--text-primary);
    line-height: 1.65;
    overflow-x: hidden;
    min-height: 100vh;
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    inset: 0;
    background:
        linear-gradient(rgba(8, 17, 28, 0.72), rgba(8, 17, 28, 0.72)),
        linear-gradient(rgba(105, 240, 255, 0.08) 1px, transparent 1px),
        linear-gradient(90deg, rgba(105, 240, 255, 0.08) 1px, transparent 1px);
    background-size: auto, 32px 32px, 32px 32px;
    pointer-events: none;
    z-index: -2;
}

body::after {
    content: '';
    position: fixed;
    inset: 0;
    background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.02) 50%, transparent);
    background-size: 100% 4px;
    opacity: 0.18;
    pointer-events: none;
    z-index: -1;
}

section {
    position: relative;
}

a {
    color: inherit;
}

img {
    max-width: 100%;
}

.container {
    max-width: var(--content-width);
    margin: 0 auto;
    padding: 0 24px;
}

.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 1rem 0;
    background: rgba(7, 16, 24, 0.78);
    backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--line);
    transition: background 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.navbar.scrolled {
    background: rgba(7, 16, 24, 0.94);
    border-color: var(--line-strong);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.22);
}

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

.logo {
    display: flex;
    align-items: center;
    gap: 14px;
    color: var(--text-primary);
}

.logo-img {
    width: 48px;
    height: 48px;
    object-fit: cover;
    border: 1px solid var(--line-strong);
    box-shadow: var(--pixel-shadow);
}

.brand-name {
    font-family: 'Press Start 2P', cursive;
    font-size: 0.82rem;
    line-height: 1.4;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.45);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    list-style: none;
}

.nav-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    padding: 0 14px;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.86rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--text-secondary);
    text-decoration: none;
    border: 1px solid transparent;
    transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
    color: var(--text-primary);
    border-color: var(--line-strong);
    background: rgba(105, 240, 255, 0.08);
    box-shadow: inset 0 0 0 1px rgba(105, 240, 255, 0.08);
}

.cta-link {
    color: var(--accent);
}

.menu-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 5px;
    width: 48px;
    height: 48px;
    background: rgba(105, 240, 255, 0.06);
    border: 1px solid var(--line);
    cursor: pointer;
    box-shadow: var(--pixel-shadow);
}

.menu-toggle span {
    width: 22px;
    height: 2px;
    background: var(--accent);
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 130px 0 72px;
    overflow: hidden;
}

.hero-background {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.gradient-blob {
    position: absolute;
    border: 1px solid rgba(105, 240, 255, 0.18);
    background:
        linear-gradient(135deg, rgba(105, 240, 255, 0.12), rgba(182, 255, 99, 0.04)),
        repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.03) 0 3px, transparent 3px 15px),
        repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.03) 0 3px, transparent 3px 15px);
    box-shadow: 0 0 40px rgba(56, 217, 245, 0.08);
    animation: blob-animation 14s ease-in-out infinite;
}

.blob-1 {
    width: 360px;
    height: 360px;
    top: 60px;
    right: -100px;
}

.blob-2 {
    width: 260px;
    height: 260px;
    bottom: 40px;
    left: 4%;
    animation-delay: 3s;
}

@keyframes blob-animation {
    0%,
    100% {
        transform: translate3d(0, 0, 0);
    }
    50% {
        transform: translate3d(18px, -24px, 0);
    }
}

.hero-content {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(320px, 0.85fr);
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-text {
    animation: fade-in-left 0.8s ease;
}

.hero-title {
    max-width: 12ch;
    font-size: clamp(3rem, 6vw, 5.6rem);
    line-height: 0.98;
    letter-spacing: -0.04em;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
}

.gradient-text {
    color: var(--accent);
    text-shadow: 3px 3px 0 rgba(0, 0, 0, 0.34);
}

.hero-subtitle {
    max-width: 42rem;
    font-size: 1.08rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

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

.btn {
    min-height: 54px;
    padding: 0.95rem 1.4rem;
    border: 1px solid var(--line-strong);
    background: var(--panel-soft);
    color: var(--text-primary);
    font-family: 'Press Start 2P', cursive;
    font-size: 0.72rem;
    line-height: 1.6;
    cursor: pointer;
    text-transform: uppercase;
    box-shadow: var(--pixel-shadow);
    transition: transform 0.18s ease, background 0.18s ease, box-shadow 0.18s ease, color 0.18s ease;
}

.btn:hover {
    transform: translate(-2px, -2px);
    box-shadow: 0 0 0 1px rgba(6, 18, 27, 0.85), 8px 8px 0 rgba(5, 11, 18, 0.95);
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-secondary) 100%);
    color: #061019;
    border-color: transparent;
}

.btn-secondary {
    background: rgba(105, 240, 255, 0.06);
}

.btn-secondary:hover {
    background: rgba(105, 240, 255, 0.14);
}

.btn-large {
    padding-inline: 2rem;
}

.hero-visual {
    position: relative;
    min-height: 420px;
    animation: fade-in-right 0.8s ease;
}

.floating-card,
.service-card,
.portfolio-card,
.tech-category,
.contact-form,
.info-item {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.015), transparent),
        var(--panel);
    border: 1px solid var(--line);
    box-shadow: var(--pixel-shadow), 0 0 0 1px rgba(105, 240, 255, 0.03), 0 16px 40px var(--shadow);
    position: relative;
}

.floating-card::before,
.service-card::before,
.portfolio-card::before,
.tech-category::before,
.contact-form::before,
.info-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent) 0%, var(--accent-secondary) 100%);
}

.floating-card {
    position: absolute;
    width: min(100%, 220px);
    padding: 1.15rem;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    animation: float 4s ease-in-out infinite;
}

.floating-card p {
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.84rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--text-secondary);
}

.card-icon,
.service-icon,
.info-icon {
    width: 64px;
    height: 64px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(105, 240, 255, 0.45);
    background: linear-gradient(180deg, rgba(105, 240, 255, 0.18), rgba(105, 240, 255, 0.04));
    color: var(--accent);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.04);
}

.card-icon {
    font-size: 1.7rem;
}

.card-1 {
    top: 0;
    left: 0;
}

.card-2 {
    top: 88px;
    right: 0;
    animation-delay: 1.2s;
}

.card-3 {
    bottom: 0;
    left: 18%;
    animation-delay: 2.2s;
}

@keyframes float {
    0%,
    100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-12px);
    }
}

@keyframes fade-in-left {
    from {
        opacity: 0;
        transform: translateX(-24px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fade-in-right {
    from {
        opacity: 0;
        transform: translateX(24px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fade-in-up {
    from {
        opacity: 0;
        transform: translateY(28px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.section-header {
    display: grid;
    gap: 0.9rem;
    justify-items: center;
    text-align: center;
    margin-bottom: 3.5rem;
    animation: fade-in-up 0.8s ease;
}

.section-header::before {
    content: '// RABIT.STUDIO';
    font-family: 'Press Start 2P', cursive;
    font-size: 0.62rem;
    line-height: 1.6;
    color: var(--accent-secondary);
    letter-spacing: 0.06em;
}

.section-title {
    font-size: clamp(2.2rem, 4.4vw, 4rem);
    line-height: 1;
    letter-spacing: -0.04em;
    text-transform: uppercase;
}

.section-subtitle {
    max-width: 40rem;
    color: var(--text-secondary);
    font-size: 1.02rem;
}

.services,
.portfolio,
.technologies,
.contact {
    padding: 6rem 0;
}

.services-grid,
.tech-categories {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.75rem;
}

.service-card,
.tech-category {
    padding: 2rem;
    overflow: hidden;
    transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}

.panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.8rem;
    margin-bottom: 1.2rem;
    padding: 0.45rem 0.55rem;
    border: 1px solid rgba(255, 255, 255, 0.09);
    background: rgba(6, 15, 24, 0.5);
}

.panel-header-compact {
    margin-bottom: 0.95rem;
}

.panel-label,
.panel-state,
.form-group label {
    font-family: 'IBM Plex Mono', monospace;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.panel-label {
    font-size: 0.72rem;
    color: var(--text-secondary);
}

.panel-state {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 22px;
    padding: 0.15rem 0.45rem;
    font-size: 0.62rem;
    color: #061019;
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-secondary) 100%);
}

.service-card:hover,
.portfolio-card:hover,
.tech-category:hover,
.info-item:hover {
    transform: translate(-3px, -3px);
    border-color: var(--line-strong);
    box-shadow: 0 0 0 1px rgba(6, 18, 27, 0.85), 9px 9px 0 rgba(5, 11, 18, 0.96), 0 16px 48px rgba(0, 0, 0, 0.38);
}

.service-icon {
    font-size: 1.8rem;
    margin-bottom: 1.25rem;
}

.service-card h3,
.portfolio-content h3,
.tech-category h4,
.cta-content h2,
.info-item h4,
.footer-section h4 {
    font-size: 1.45rem;
    line-height: 1.1;
    letter-spacing: -0.03em;
    text-transform: uppercase;
}

.service-card p,
.portfolio-content p,
.cta-content p,
.footer-section p,
.info-item p,
.footer-bottom {
    color: var(--text-secondary);
}

.service-card p {
    margin-bottom: 1.4rem;
}

.tech-list {
    list-style: none;
    display: grid;
    gap: 0.7rem;
}

.tech-list li {
    position: relative;
    padding-left: 1.3rem;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.92rem;
    color: var(--text-primary);
}

.tech-list li::before {
    content: '>';
    position: absolute;
    left: 0;
    color: var(--accent-secondary);
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 2rem;
}

.portfolio-card {
    overflow: hidden;
    transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.portfolio-image {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 260px;
    padding: 2rem;
    border-bottom: 1px solid var(--line);
    overflow: hidden;
}

.portfolio-image::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.06), transparent),
        repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.03) 0 2px, transparent 2px 14px);
    transform: translateX(-100%);
    animation: shimmer 4s linear infinite;
}

.portfolio-image::after {
    content: '';
    position: absolute;
    inset: 16px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.portfolio-image img {
    position: relative;
    z-index: 1;
    display: block;
    width: min(100%, 220px);
    max-height: 140px;
    object-fit: contain;
    filter: drop-shadow(0 20px 28px rgba(0, 0, 0, 0.35));
    transition: transform 0.28s ease, filter 0.28s ease;
}

.portfolio-card:hover .portfolio-image img {
    transform: translateY(-4px) scale(1.03);
    filter: drop-shadow(0 24px 34px rgba(0, 0, 0, 0.45));
}

@keyframes shimmer {
    from {
        transform: translateX(-100%);
    }
    to {
        transform: translateX(100%);
    }
}

.spenzo {
    background:
        radial-gradient(circle at top left, rgba(105, 240, 255, 0.12), transparent 34%),
        radial-gradient(circle at bottom right, rgba(182, 255, 99, 0.12), transparent 38%),
        linear-gradient(135deg, #091621 0%, #0d1d20 100%);
}

.chartpad {
    background:
        radial-gradient(circle at top right, rgba(105, 240, 255, 0.18), transparent 30%),
        radial-gradient(circle at bottom left, rgba(129, 100, 255, 0.18), transparent 32%),
        linear-gradient(135deg, #111226 0%, #161b2f 100%);
}

.portfolio-content {
    padding: 2rem;
}

.portfolio-content h3 {
    margin-bottom: 0.5rem;
}

.app-type {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    margin-bottom: 1rem;
    color: var(--accent);
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.86rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.portfolio-content p {
    margin-bottom: 1.25rem;
}

.portfolio-tags,
.tech-items,
.social-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.7rem;
}

.tag,
.tech-item,
.social-link {
    display: inline-flex;
    align-items: center;
    min-height: 36px;
    padding: 0.45rem 0.8rem;
    border: 1px solid var(--line);
    background: rgba(105, 240, 255, 0.05);
    color: var(--text-primary);
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.82rem;
    text-decoration: none;
    text-transform: uppercase;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.tag:hover,
.tech-item:hover,
.social-link:hover {
    background: rgba(105, 240, 255, 0.14);
    border-color: var(--line-strong);
    color: var(--accent);
}

.tech-category {
    padding: 2rem;
}

.tech-category h4 {
    margin-bottom: 1.3rem;
}

.cta-section {
    padding: 2rem 0;
}

.cta-content {
    padding: 3rem;
    text-align: center;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.015), transparent),
        linear-gradient(135deg, rgba(105, 240, 255, 0.08), rgba(182, 255, 99, 0.05)),
        var(--panel);
    border: 1px solid var(--line-strong);
    box-shadow: var(--pixel-shadow), 0 20px 52px rgba(0, 0, 0, 0.32);
    position: relative;
    overflow: hidden;
}

.cta-content::before {
    content: '';
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.03) 0 2px, transparent 2px 18px);
    pointer-events: none;
}

.cta-content h2 {
    margin-bottom: 1rem;
    font-size: clamp(2rem, 4vw, 3.4rem);
}

.cta-content p {
    max-width: 44rem;
    margin: 0 auto 2rem;
}

.contact-content {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.9fr);
    gap: 2rem;
    align-items: start;
}

.contact-form {
    padding: 2rem;
    display: grid;
    gap: 1rem;
}

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

.form-group label {
    font-size: 0.72rem;
    color: var(--text-secondary);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1rem 1rem 1rem 1.1rem;
    background: rgba(7, 16, 24, 0.76);
    border: 1px solid var(--line);
    color: var(--text-primary);
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.95rem;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.02);
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-secondary);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--line-strong);
    background: rgba(17, 29, 44, 0.92);
    box-shadow: 0 0 0 3px rgba(105, 240, 255, 0.08);
}

.contact-info {
    display: grid;
    gap: 1rem;
}

.info-item {
    padding: 1.35rem;
    display: grid;
    grid-template-columns: 64px 1fr;
    gap: 1rem;
    align-items: start;
    text-decoration: none;
    transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.info-icon {
    font-size: 1.35rem;
}

.info-item h4 {
    margin-bottom: 0.35rem;
}

.info-item a {
    color: var(--text-primary);
    text-decoration: none;
}

.info-item a:hover {
    color: var(--accent);
}

.footer {
    padding: 4rem 0 1.5rem;
    border-top: 1px solid var(--line);
    background: rgba(5, 11, 18, 0.78);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 2rem;
    padding-bottom: 2rem;
    margin-bottom: 1rem;
    border-bottom: 1px solid var(--line);
}

.footer-section h4 {
    margin-bottom: 1rem;
}

.footer-section ul {
    list-style: none;
    display: grid;
    gap: 0.6rem;
}

.footer-section a {
    color: var(--text-secondary);
    text-decoration: none;
}

.footer-section a:hover {
    color: var(--accent);
}

.footer-bottom {
    text-align: center;
    font-family: 'IBM Plex Mono', monospace;
    font-size: 0.82rem;
}

@media (max-width: 960px) {
    .hero-content,
    .contact-content,
    .services-grid,
    .portfolio-grid,
    .tech-categories,
    .footer-content {
        grid-template-columns: 1fr;
    }

    .hero {
        padding-top: 120px;
    }

    .hero-visual {
        min-height: 380px;
    }

    .card-2 {
        top: 70px;
    }

    .card-3 {
        left: 8%;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 18px;
    }

    .menu-toggle {
        display: inline-flex;
    }

    .nav-links {
        display: none;
        position: absolute;
        top: calc(100% + 12px);
        right: 18px;
        left: 18px;
        padding: 1rem;
        background: rgba(7, 16, 24, 0.96);
        border: 1px solid var(--line-strong);
        box-shadow: var(--pixel-shadow);
        flex-direction: column;
        align-items: stretch;
        gap: 0.5rem;
    }

    .nav-links.is-open {
        display: flex;
    }

    .nav-link {
        justify-content: flex-start;
        padding: 0.8rem 0.9rem;
    }

    .hero-title {
        max-width: none;
    }

    .hero-buttons {
        flex-direction: column;
    }

    .btn {
        width: 100%;
    }

    .floating-card {
        width: min(100%, 180px);
    }

    .portfolio-image {
        min-height: 220px;
        padding: 1.4rem;
    }

    .portfolio-image img {
        width: min(100%, 190px);
        max-height: 118px;
    }

    .cta-content,
    .contact-form,
    .service-card,
    .portfolio-content,
    .tech-category {
        padding: 1.5rem;
    }
}

@media (max-width: 560px) {
    .brand-name,
    .btn,
    .section-header::before {
        font-size: 0.58rem;
    }

    .hero {
        min-height: auto;
        padding-bottom: 4rem;
    }

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

    .section-title,
    .cta-content h2 {
        font-size: 1.9rem;
    }

    .hero-subtitle,
    .section-subtitle,
    .cta-content p {
        font-size: 0.98rem;
    }

    .hero-visual {
        min-height: 330px;
    }

    .floating-card {
        width: 160px;
        padding: 1rem;
    }

    .card-1 {
        left: 0;
    }

    .card-2 {
        right: 0;
    }

    .card-3 {
        left: 0;
        bottom: 10px;
    }

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

    .panel-header {
        flex-wrap: wrap;
    }
}
