/* ============================================
   R & D Lock & Key - Custom Styles
   ============================================ */

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

html {
    scroll-behavior: smooth;
}

body {
    overflow-x: hidden;
}

/* Selection */
::selection {
    background: #64ffda;
    color: #0a192f;
}

/* ============================================
   Navigation
   ============================================ */
#navbar {
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

#navbar.scrolled {
    background: rgba(10, 25, 47, 0.95);
    backdrop-filter: blur(20px);
    padding: 1rem 0;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

.nav-link {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: color 0.3s ease;
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: #64ffda;
    transition: width 0.3s ease;
}

.nav-link:hover {
    color: #64ffda;
}

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

/* Mobile Menu */
.mobile-menu-btn {
    display: flex;
    flex-direction: column;
    gap: 6px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 50;
}

.mobile-menu-btn .line {
    width: 24px;
    height: 1px;
    background: #ffffff;
    transition: all 0.3s ease;
    transform-origin: center;
}

.mobile-menu-btn.active .line:nth-child(1) {
    transform: rotate(45deg) translate(4px, 4px);
}

.mobile-menu-btn.active .line:nth-child(2) {
    opacity: 0;
}

.mobile-menu-btn.active .line:nth-child(3) {
    transform: rotate(-45deg) translate(4px, -4px);
}

.mobile-menu.open {
    opacity: 1;
    pointer-events: all;
}

.mobile-link {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.3s ease;
}

.mobile-link:hover {
    color: #64ffda;
}

/* ============================================
   Buttons
   ============================================ */
.btn-primary {
    background: transparent;
    color: #64ffda;
    border: 1px solid #64ffda;
    padding: 1rem 2rem;
    text-decoration: none;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: #64ffda;
    transition: left 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: -1;
}

.btn-primary:hover {
    color: #0a192f;
}

.btn-primary:hover::before {
    left: 0;
}

.btn-cta {
    background: #0a192f;
    color: #0a192f;
    padding: 1rem 2.5rem;
    text-decoration: none;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid #0a192f;
}

.btn-cta:hover {
    background: transparent;
    color: #ffffff;
    border-color: #ffffff;
}

/* ============================================
   Hero Section
   ============================================ */
.hero {
    position: relative;
}

.hero-gradient {
    background: linear-gradient(135deg, #0a192f 0%, #112240 50%, #233554 100%);
}

.hero-pattern {
    background-image: 
        radial-gradient(circle at 25% 25%, rgba(100, 255, 218, 0.03) 0%, transparent 50%),
        radial-gradient(circle at 75% 75%, rgba(100, 255, 218, 0.03) 0%, transparent 50%);
}

.hero-content {
    padding-top: 80px;
}

.hero-subtitle {
    animation: fadeInUp 0.8s ease forwards;
    animation-delay: 0.2s;
}

.hero-title {
    animation: fadeInUp 0.8s ease forwards;
    animation-delay: 0.4s;
}

.hero-description {
    animation: fadeInUp 0.8s ease forwards;
    animation-delay: 0.6s;
}

.hero-buttons {
    animation: fadeInUp 0.8s ease forwards;
    animation-delay: 0.8s;
}

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

/* Scroll Indicator */
.scroll-indicator {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.scroll-line {
    width: 1px;
    height: 40px;
    background: linear-gradient(to bottom, rgba(100, 255, 218, 0.8), transparent);
    animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
    0%, 100% {
        opacity: 1;
        transform: scaleY(1);
    }
    50% {
        opacity: 0.5;
        transform: scaleY(0.8);
    }
}

/* ============================================
   Section Styles
   ============================================ */
.section-header {
    margin-bottom: 5rem;
}

.section-label {
    display: block;
}

.section-title {
    font-weight: 400;
}

.section-line {
    transition: width 0.6s ease;
}

/* ============================================
   Services Section
   ============================================ */
.services-grid {
    display: grid;
    gap: 2rem;
}

.service-card {
    position: relative;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #64ffda, #48c9b0);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.service-card:hover::before {
    transform: scaleX(1);
}

.service-title {
    font-weight: 400;
}

.service-desc {
    font-weight: 300;
}

/* ============================================
   About Section
   ============================================ */
.about-image-container {
    position: relative;
}

.about-image {
    position: relative;
    z-index: 2;
}

.about-image-accent {
    position: absolute;
    top: 20px;
    left: 20px;
    width: 100%;
    height: 100%;
    border: 1px solid rgba(100, 255, 218, 0.3);
    z-index: 1;
}

.about-text {
    font-weight: 300;
}

/* ============================================
   Why Us Section
   ============================================ */
.why-grid {
    display: grid;
    gap: 3rem;
}

.why-item {
    padding: 2rem 0;
    border-bottom: 1px solid rgba(10, 25, 47, 0.1);
    transition: all 0.3s ease;
}

.why-item:last-child {
    border-bottom: none;
}

.why-item:hover {
    padding-left: 1rem;
}

.why-title {
    font-weight: 400;
}

.why-desc {
    font-weight: 300;
}

/* ============================================
   Contact Section
   ============================================ */
.contact-form {
    position: relative;
}

.form-group {
    position: relative;
}

.form-label {
    display: block;
    margin-bottom: 0.75rem;
}

.form-input,
.form-textarea,
.form-select {
    width: 100%;
    background: transparent;
    border: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
    color: #ffffff;
    padding: 0.75rem 0;
    font-size: 1rem;
    font-family: inherit;
    font-weight: 300;
    transition: border-color 0.3s ease;
    outline: none;
}

.form-input::placeholder,
.form-textarea::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
    border-color: #64ffda;
}

.form-select {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364ffda' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0 center;
}

.form-select option {
    background: #112240;
    color: #ffffff;
}

.form-textarea {
    resize: vertical;
    min-height: 100px;
}

.form-success {
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* ============================================
   Footer
   ============================================ */
.footer-link {
    text-decoration: none;
}

/* ============================================
   Animations
   ============================================ */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(40px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.animate-on-scroll.animated {
    opacity: 1;
    transform: translateY(0);
}

/* ============================================
   Responsive
   ============================================ */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .about-stats {
        grid-template-columns: repeat(3, 1fr);
        gap: 2rem;
    }
    
    .why-grid {
        grid-template-columns: 1fr;
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
