.hero {
    perspective: 1000px;
}

.hero .section-container {
    transform-style: preserve-3d;
    animation: floatTerminal 12s ease-in-out infinite;
    flex-direction: column;
    gap: 1rem;
}

@keyframes floatTerminal {
    0%, 100% { transform: rotateX(2deg) rotateY(-2deg) translateY(0px); }
    50% { transform: rotateX(-2deg) rotateY(2deg) translateY(-10px); }
}

.hero-welcome-section {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-muted);
    animation: fadeIn 2s ease forwards;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.hero-terminal {
    width: 100%;
    max-width: 800px;
    min-height: 50vh;
    height: auto;
    background: var(--tech-terminal);
    border-radius: var(--radius-xl);
    border: 1px solid var(--border-subtle);
    box-shadow: 0 0 30px var(--glow-subtle);
    backdrop-filter: blur(20px);
    overflow: hidden;
    position: relative;
    display: flex;
    flex-direction: column;
}

.hero-terminal-header {
    background: linear-gradient(90deg, var(--secondary), var(--primary));
    display: flex;
    align-items: center;
    padding: 0.75rem 1.5rem;
    gap: 0.75rem;
}

.hero-terminal-btn {
    width: 12px;
    height: 12px;
    border-radius: var(--radius-full);
    opacity: 0.8;
}

.hero-terminal-btn.first { background: #ff5f56; }
.hero-terminal-btn.second { background: #ffbd2e; }
.hero-terminal-btn.third { background: #27ca3f; }

.hero-terminal-content {
    padding: 2rem;
    font-family: var(--font-mono);
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0.6rem;
}

.hero-code-line {
    font-size: 0.95rem;
    line-height: 1.6;
    opacity: 0;
    animation: typeIn 0.5s ease forwards;
}

.hero-code-line:nth-child(1) { animation-delay: 0.5s; }
.hero-code-line:nth-child(2) { animation-delay: 1s; }
.hero-code-line:nth-child(3) { animation-delay: 1.5s; }
.hero-code-line:nth-child(4) { animation-delay: 2s; }
.hero-code-line:nth-child(5) { animation-delay: 2.5s; }
.hero-code-line:nth-child(6) { animation-delay: 3s; }

@keyframes typeIn {
    from { opacity: 0; transform: translateX(-10px); }
    to { opacity: 1; transform: translateX(0); }
}

.hero-terminal-var-keyword { color: #ff0080; }
.hero-terminal-string { color: #00ff00; }
.hero-terminal-function { color: #00ffff; }
.hero-terminal-comment { color: #666; opacity: 0.7; }

.hero-terminal-glitch-name {
    font-size: 2.5rem;
    font-weight: 900;
    background: linear-gradient(45deg, #ff0080, #00ffff, #ff0080);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: glitchMove 6s ease-in-out infinite;
}

.terminal-content-image {
    position: absolute;
    bottom: 2rem;
    right: 2rem;
    width: 30%;
}

.hero-image {
    width: 100%;
    height: auto;
    transition: transform 0.3s ease;
}

@keyframes glitchMove {
    0%, 100% { background-position: 0% 50%; }
    25% { background-position: 100% 50%; }
    50% { background-position: 50% 100%; }
    75% { background-position: 0% 0%; }
}

.hero-fab-container {
    position: absolute;
    bottom: -3rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 3rem;
}

.hero-fab-icon {
    border-radius: 50%;
    background: linear-gradient(45deg, var(--secondary), var(--primary));
    border: none;
    padding: 1.25rem;
    font-size: 1.5rem;
    color: #fff;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: visible;
}

.hero-fab-icon::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-full);
    transition: all 0.4s ease;
    transform: translate(-50%, -50%);
    z-index: 1;
}

.hero-fab-icon:hover::before {
    width: 120%;
    height: 120%;
}

.hero-fab-icon:hover {
    transform: scale(1.1);
    box-shadow: 0 0 20px var(--glow-medium);
}

.hero-fab-icon .hero-fab-tooltip {
    position: absolute;
    bottom: 120%;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(45deg, var(--secondary), var(--primary));
    padding: 0.5rem 1rem;
    border-radius: var(--radius-lg);
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
    z-index: 10;
    pointer-events: none;
}

.hero-fab-icon .hero-fab-tooltip::after {
    content: '';
    position: absolute;
    top: 75%;
    left: 50%;
    transform: translateX(-50%) rotate(45deg);
    width: 0.75rem;
    height: 0.75rem;
    background: linear-gradient(45deg, var(--secondary), var(--primary));
    z-index: -1;
}

.hero-fab-icon:hover .hero-fab-tooltip {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(-5px);
}
