/* Custom CSS for MCPByte Website */

/* Additional animations and effects */
.hover-scale {
    transition: transform 0.3s ease;
}

.hover-scale:hover {
    transform: scale(1.02);
}

/* Header styles */
#main-header {
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.04);
    border-bottom: 1px solid rgba(226, 232, 240, 0.7);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

#main-header.scrolled {
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    background-color: rgba(255, 255, 255, 0.95);
    border-bottom: 1px solid rgba(226, 232, 240, 0.9);
}

/* Logo styles */
.logo-text {
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.logo-text::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 3px;
    bottom: -3px;
    left: 0;
    background: linear-gradient(90deg, #0ea5e9, #8b5cf6);
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    transform-origin: left;
    transform: scaleX(0);
    opacity: 0;
}

.logo-text:hover::before {
    transform: scaleX(1);
    opacity: 1;
}

/* Nav link styles */
.nav-link {
    position: relative;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    padding: 0.5rem 0.75rem;
    margin: 0 0.25rem;
    border-radius: 0.5rem;
    overflow: hidden;
    z-index: 1;
}

.nav-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(120deg, rgba(14, 165, 233, 0.08), rgba(139, 92, 246, 0.08));
    z-index: -1;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    border-radius: 0.5rem;
}

.nav-link:hover::before {
    transform: translateY(0);
}

.nav-link[aria-current="page"]::before {
    transform: translateY(0);
    background: linear-gradient(120deg, rgba(14, 165, 233, 0.12), rgba(139, 92, 246, 0.12));
}

.nav-link i {
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), color 0.3s ease;
}

.nav-link:hover i {
    transform: translateY(-3px) scale(1.1);
}

.nav-link span {
    position: relative;
    z-index: 2;
}

.nav-link span::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -2px;
    left: 0;
    background: linear-gradient(90deg, #0ea5e9, #8b5cf6);
    transition: width 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    border-radius: 2px;
}

.nav-link:hover span::after {
    width: 100%;
}

.nav-link[aria-current="page"] span::after {
    width: 100%;
    height: 3px;
}

/* CTA button glow effect */
.cta-button {
    position: relative;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    overflow: hidden;
    z-index: 1;
}

.cta-button::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(45deg, #0ea5e9, #8b5cf6, #0ea5e9);
    background-size: 400% 400%;
    z-index: -1;
    animation: ctaGradient 4s ease infinite;
    filter: blur(10px);
    opacity: 0;
    transition: opacity 0.4s ease;
    border-radius: 0.5rem;
}

.cta-button:hover::before {
    opacity: 0.7;
}

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

/* Mobile menu styles */
.mobile-menu {
    transform-origin: top;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.mobile-menu-item {
    transform: translateX(-10px);
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.mobile-menu.open .mobile-menu-item {
    transform: translateX(0);
    opacity: 1;
}

/* Delay each menu item for staggered animation */
.mobile-menu.open .mobile-menu-item:nth-child(1) { transition-delay: 0.1s; }
.mobile-menu.open .mobile-menu-item:nth-child(2) { transition-delay: 0.15s; }
.mobile-menu.open .mobile-menu-item:nth-child(3) { transition-delay: 0.2s; }
.mobile-menu.open .mobile-menu-item:nth-child(4) { transition-delay: 0.25s; }
.mobile-menu.open .mobile-menu-item:nth-child(5) { transition-delay: 0.3s; }

#header-content.scrolled {
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
}

/* Custom gradients and effects for sections */
.gradient-mesh {
    background-image: radial-gradient(#e0f2fe 1px, transparent 1px), radial-gradient(#e0f2fe 1px, transparent 1px);
    background-size: 20px 20px;
    background-position: 0 0, 10px 10px;
}

/* Code block styling */
pre code {
    font-family: 'Roboto Mono', monospace;
    line-height: 1.5;
}

/* Custom form styling */
input:focus, select:focus, textarea:focus {
    border-color: #0ea5e9;
    box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.2);
}

/* Custom bullet points and list items */
.custom-list-item {
    position: relative;
    padding-left: 1.5rem;
}

.custom-list-item:before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.5rem;
    width: 0.5rem;
    height: 0.5rem;
    background-color: #0ea5e9;
    border-radius: 50%;
}

/* New Section Styles */
.new-section {
    padding: 4rem 0;
    background-color: #f9f9f9;
}

.new-section-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.new-section-item {
    text-align: center;
    padding: 20px;
}

.new-section-icon {
    font-size: 3em;
    color: #007bff;
}

.new-section-title {
    font-size: 1.5em;
    font-weight: bold;
    margin-top: 10px;
}

.new-section-description {
    font-size: 1em;
    color: #666;
    margin-top: 5px;
}

/* Footer link underscore animation */
footer a {
    position: relative;
    display: inline-block;
    overflow: hidden;
}

footer a span {
    position: relative;
    z-index: 1;
}

footer a span::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -2px;
    left: 0;
    background: linear-gradient(90deg, #0ea5e9, #8b5cf6);
    transition: width 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    border-radius: 2px;
}

footer a:hover span::after,
footer a:focus span::after {
    width: 100%;
}
