/* ===============================
   RESET & BASE STYLES
   =============================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #00d4ff;
    --secondary-color: #7b2ff7;
    --accent-color: #ff006e;
    --bg-dark: #0a0e27;
    --bg-darker: #050814;
    --bg-card: #121736;
    --text-primary: #ffffff;
    --text-secondary: #a0aec0;
    --gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-accent: linear-gradient(135deg, #00d4ff 0%, #7b2ff7 100%);
    --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.5);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

/* ===============================
   LOADER
   =============================== */
.loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-darker);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10000;
    transition: opacity 0.5s, visibility 0.5s;
}

.loader.hidden {
    opacity: 0;
    visibility: hidden;
}

.loader-content {
    text-align: center;
}

.spinner {
    width: 50px;
    height: 50px;
    margin: 0 auto 20px;
    border: 3px solid rgba(0, 212, 255, 0.2);
    border-top: 3px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ===============================
   NAVIGATION - HORIZONTAL TOP BAR
   =============================== */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(10, 14, 39, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
    transition: var(--transition);
}

.navbar.scrolled {
    background: rgba(5, 8, 20, 0.98);
    box-shadow: 0 5px 30px rgba(0, 0, 0, 0.5);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.nav-brand a {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
}

.brand-icon {
    font-size: 1.8rem;
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 5px;
    align-items: center;
    margin: 0;
    padding: 0;
}

.nav-menu li {
    display: inline-block;
    position: relative;
}

.nav-menu li a {
    color: var(--text-secondary);
    text-decoration: none;
    padding: 10px 16px;
    border-radius: 8px;
    transition: var(--transition);
    font-weight: 500;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}

.nav-menu li a i {
    font-size: 0.9rem;
}

.nav-menu li a:hover,
.nav-menu li a.active {
    color: var(--primary-color);
    background: rgba(0, 212, 255, 0.1);
    transform: translateY(-2px);
}

/* Dropdown Menu Styles */
.dropdown {
    position: relative;
}

.dropdown-toggle::after {
    content: '▼';
    font-size: 0.7rem;
    margin-left: 5px;
    transition: var(--transition);
}

.dropdown:hover .dropdown-toggle::after {
    transform: rotate(180deg);
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: rgba(18, 23, 54, 0.98);
    backdrop-filter: blur(10px);
    border-radius: 8px;
    min-width: 180px;
    padding: 10px 0;
    margin-top: 5px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: var(--transition);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(0, 212, 255, 0.2);
    z-index: 1000;
}

.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu li {
    display: block;
    width: 100%;
}

.dropdown-menu li a {
    padding: 12px 20px;
    border-radius: 0;
    width: 100%;
    justify-content: flex-start;
}

.dropdown-menu li a:hover {
    background: rgba(0, 212, 255, 0.15);
    transform: translateX(5px);
}

.dropdown-menu li a i {
    width: 20px;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
    z-index: 1001;
}

.nav-toggle span {
    width: 25px;
    height: 3px;
    background: var(--text-primary);
    margin: 3px 0;
    transition: var(--transition);
    border-radius: 3px;
}

/* ===============================
   MAIN CONTENT
   =============================== */
.main-content {
    min-height: 100vh;
    padding-top: 70px;
}

.page-container {
    opacity: 0;
    animation: fadeIn 0.6s forwards;
}

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

/* ===============================
   HERO SECTION
   =============================== */
.hero {
    min-height: calc(100vh - 70px);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, var(--bg-darker) 0%, var(--bg-dark) 100%);
}

.hero::before {
    content: '';
    position: absolute;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(0, 212, 255, 0.15) 0%, transparent 70%);
    top: -250px;
    right: -250px;
    animation: float 20s infinite alternate;
}

.hero::after {
    content: '';
    position: absolute;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(123, 47, 247, 0.15) 0%, transparent 70%);
    bottom: -200px;
    left: -200px;
    animation: float 15s infinite alternate-reverse;
}

@keyframes float {
    to {
        transform: translate(50px, 50px);
    }
}

.hero-content {
    text-align: center;
    z-index: 1;
    max-width: 900px;
    padding: 40px 20px;
}

.hero-title {
    font-size: 4rem;
    font-weight: 800;
    margin-bottom: 20px;
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: slideUp 0.8s ease-out;
}

.hero-subtitle {
    font-size: 1.5rem;
    color: var(--text-secondary);
    margin-bottom: 30px;
    animation: slideUp 0.8s ease-out 0.2s backwards;
}

.hero-description {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 40px;
    line-height: 1.8;
    animation: slideUp 0.8s ease-out 0.4s backwards;
}

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

.hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
    animation: slideUp 0.8s ease-out 0.6s backwards;
}

.btn {
    padding: 14px 32px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 10px;
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background: var(--gradient-accent);
    color: var(--text-primary);
    box-shadow: 0 10px 30px rgba(0, 212, 255, 0.3);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(0, 212, 255, 0.4);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
    border-color: var(--primary-color);
}

/* ===============================
   SECTION STYLES
   =============================== */
.section {
    padding: 100px 20px;
    max-width: 1400px;
    margin: 0 auto;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 15px;
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: var(--gradient-accent);
    border-radius: 2px;
}

.section-subtitle {
    color: var(--text-secondary);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 20px auto 0;
}

/* ===============================
   CARD STYLES
   =============================== */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.card {
    background: var(--bg-card);
    border-radius: 20px;
    padding: 30px;
    transition: var(--transition);
    border: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--gradient-accent);
    opacity: 0;
    transition: var(--transition);
    z-index: 0;
}

.card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-color);
}

.card:hover::before {
    opacity: 0.05;
}

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

.card-icon {
    font-size: 3rem;
    margin-bottom: 20px;
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.card-title {
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: var(--text-primary);
}

.card-description {
    color: var(--text-secondary);
    line-height: 1.8;
}

/* ===============================
   TIMELINE
   =============================== */
.timeline {
    position: relative;
    padding: 40px 0;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 2px;
    height: 100%;
    background: rgba(0, 212, 255, 0.3);
}

.timeline-item {
    display: flex;
    margin-bottom: 50px;
    position: relative;
}

.timeline-item:nth-child(odd) {
    flex-direction: row-reverse;
}

.timeline-content {
    width: 45%;
    background: var(--bg-card);
    padding: 30px;
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
}

.timeline-dot {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 20px;
    background: var(--primary-color);
    border-radius: 50%;
    border: 4px solid var(--bg-dark);
    z-index: 1;
}

.timeline-date {
    color: var(--primary-color);
    font-weight: 600;
    margin-bottom: 10px;
}

.timeline-title {
    font-size: 1.3rem;
    margin-bottom: 10px;
}

.timeline-description {
    color: var(--text-secondary);
}

/* ===============================
   SKILLS
   =============================== */
.skills-category {
    margin-bottom: 50px;
}

.skills-category h3 {
    font-size: 1.8rem;
    margin-bottom: 30px;
    color: var(--primary-color);
}

.skills-list {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.skill-tag {
    background: rgba(0, 212, 255, 0.1);
    color: var(--primary-color);
    padding: 10px 20px;
    border-radius: 25px;
    border: 1px solid rgba(0, 212, 255, 0.3);
    transition: var(--transition);
    font-weight: 500;
}

.skill-tag:hover {
    background: rgba(0, 212, 255, 0.2);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 212, 255, 0.3);
}

/* ===============================
   CONTACT FORM
   =============================== */
.contact-container {
    max-width: 800px;
    margin: 0 auto;
}

.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    margin-bottom: 10px;
    color: var(--text-primary);
    font-weight: 500;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 15px;
    background: var(--bg-card);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    color: var(--text-primary);
    font-size: 1rem;
    transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(0, 212, 255, 0.1);
}

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

/* ===============================
   FOOTER
   =============================== */
.footer {
    background: var(--bg-darker);
    padding: 60px 20px 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

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

.footer-section h3 {
    margin-bottom: 20px;
    color: var(--primary-color);
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 10px;
}

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

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

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    transition: var(--transition);
}

.social-links a:hover {
    background: var(--primary-color);
    transform: translateY(-3px);
}

.footer-bottom {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    color: var(--text-secondary);
}

/* ===============================
   SCROLL TO TOP
   =============================== */
.scroll-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--gradient-accent);
    border: none;
    border-radius: 50%;
    color: white;
    font-size: 1.2rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 999;
    box-shadow: 0 5px 20px rgba(0, 212, 255, 0.4);
}

.scroll-top.visible {
    opacity: 1;
    visibility: visible;
}

.scroll-top:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 212, 255, 0.5);
}

/* ===============================
   RESPONSIVE DESIGN
   =============================== */
@media (max-width: 1024px) {
    .timeline::before {
        left: 30px;
    }
    
    .timeline-item {
        flex-direction: row !important;
    }
    
    .timeline-content {
        width: calc(100% - 80px);
        margin-left: 60px;
    }
    
    .timeline-dot {
        left: 30px;
    }
}

@media (max-width: 1200px) {
    .nav-menu {
        gap: 2px;
    }
    
    .nav-menu li a {
        padding: 8px 12px;
        font-size: 0.9rem;
    }
}

@media (max-width: 992px) {
    .nav-menu li a {
        padding: 8px 10px;
        font-size: 0.85rem;
    }
    
    .nav-menu li a i {
        display: none;
    }
}

@media (max-width: 768px) {
    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background: rgba(5, 8, 20, 0.98);
        width: 100%;
        text-align: center;
        transition: var(--transition);
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
        padding: 20px 0;
        gap: 0;
        height: calc(100vh - 70px);
        overflow-y: auto;
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    .nav-menu li {
        margin: 0;
        display: block;
        width: 100%;
        position: relative;
    }
    
    .nav-menu li a {
        display: flex;
        justify-content: center;
        padding: 15px 20px;
        font-size: 1rem;
        width: 100%;
    }
    
    .nav-menu li a i {
        display: inline-block;
    }
    
    /* Mobile Dropdown Styles */
    .dropdown-menu {
        position: static;
        opacity: 0;
        visibility: hidden;
        max-height: 0;
        overflow: hidden;
        transform: none;
        margin-top: 0;
        background: rgba(0, 0, 0, 0.3);
        border: none;
        border-radius: 0;
        transition: all 0.3s ease;
    }
    
    .dropdown.active .dropdown-menu {
        opacity: 1;
        visibility: visible;
        max-height: 300px;
    }
    
    .dropdown-toggle::after {
        margin-left: auto;
    }
    
    .dropdown-menu li a {
        padding-left: 40px;
        font-size: 0.95rem;
    }
    
    .nav-toggle {
        display: flex;
    }
    
    .nav-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(8px, 8px);
    }
    
    .nav-toggle.active span:nth-child(2) {
        opacity: 0;
    }
    
    .nav-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -7px);
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.2rem;
    }
    
    .section {
        padding: 60px 20px;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .card-grid {
        grid-template-columns: 1fr;
    }
}
