/* --- Global & Typography --- */
:root {
    --primary-color: #2563EB;
    --background-color: #0F172A;
    --text-color: #F8FAFC;
    --card-bg: #1E293B;
    --border-color: #334155;
}

html { 
    scroll-behavior: smooth; 
}

body {
    background-color: var(--background-color);
    color: var(--text-color);
    font-family: 'Inter', sans-serif;
    font-size: 16px;
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6, .navbar-brand {
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
}

.section-title {
    font-size: 2.5rem; 
    margin-bottom: 2rem; 
    color: var(--primary-color);
    position: relative; 
    display: inline-block;
}

.section-title::after {
    content: ''; 
    position: absolute; 
    bottom: -10px; 
    left: 0;
    width: 60px; 
    height: 3px; 
    background-color: var(--primary-color);
}

.section-title.text-center::after { 
    left: 50%; 
    transform: translateX(-50%); 
}

/* --- Animated Background --- */
.background-icons { 
    position: fixed; 
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%; 
    overflow: hidden; 
    z-index: -1; 
}

.background-icons i {
    position: absolute; 
    color: rgba(37, 99, 235, 0.1); 
    font-size: 4rem;
    bottom: -150px; 
    animation: moveIcons 20s linear infinite;
    text-shadow: 0 0 5px rgba(37, 99, 235, 0.5), 0 0 10px rgba(37, 99, 235, 0.3);
}

.background-icons i:nth-child(1) { left: 10%; animation-duration: 22s; font-size: 3rem; }
.background-icons i:nth-child(2) { left: 20%; animation-duration: 18s; font-size: 5rem; }
.background-icons i:nth-child(3) { left: 30%; animation-duration: 25s; }
.background-icons i:nth-child(4) { left: 40%; animation-duration: 15s; font-size: 3.5rem; }
.background-icons i:nth-child(5) { left: 50%; animation-duration: 28s; }

@keyframes moveIcons { 
    0% { transform: translateY(0); } 
    100% { transform: translateY(-120vh); } 
}

/* --- Navbar --- */
.navbar { 
    background-color: rgba(15, 23, 42, 0.9); 
    backdrop-filter: blur(10px); 
    border-bottom: 1px solid var(--border-color); 
    padding: 15px 0;
}

.navbar-brand { 
    font-weight: 600; 
    cursor: pointer; 
    color: #fff !important; 
    font-size: 1.5rem;
}

.nav-gap { gap: 10px; }

/* ================= SPLIT FACE CSS ================= */
.split-container { 
    display: flex; 
    width: 100%; 
    height: calc(100vh - 85px); 
    background: #000; 
    overflow: hidden; 
}

.half-screen { 
    flex: 1; 
    position: relative; 
    cursor: pointer; 
    overflow: hidden; 
    transition: flex 0.5s ease; 
}

.half-screen:hover { flex: 1.05; } 

.face-img { 
    width: 200%; 
    height: 100%; 
    object-fit: cover; 
    position: absolute; 
    top: 0; 
    transition: filter 0.4s ease; 
    filter: grayscale(40%) brightness(0.7); 
}

.left-img { left: 0; object-position: left center; }
.right-img { right: 0; object-position: right center; }
.half-screen:hover .face-img { filter: grayscale(0%) brightness(1.1); }

.overlay-text {
    position: absolute; 
    top: 50%; 
    left: 50%; 
    transform: translate(-50%, -50%);
    text-align: center; 
    background: rgba(15, 23, 42, 0.85); 
    padding: 20px 30px;
    border-radius: 12px; 
    border: 2px solid var(--primary-color); 
    opacity: 0;
    transition: opacity 0.4s ease, transform 0.4s ease; 
    pointer-events: none; 
    z-index: 2;
}

.half-screen:hover .overlay-text { 
    opacity: 1; 
    transform: translate(-50%, -60%); 
}

.overlay-text h3 { 
    margin-bottom: 5px; 
    color: var(--primary-color); 
    font-size: 2rem;
}

.overlay-text p { 
    margin: 0; 
    font-size: 1rem; 
    color: #fff;
}

/* ================= VERTICAL TITLES (Student & Developer) ================= */
.vertical-title {
    position: absolute;
    top: 50%;
    font-family: 'Poppins', sans-serif;
    font-size: 6vw; 
    font-weight: 800;
    letter-spacing: 5px;
    z-index: 5;
    pointer-events: none; 
    writing-mode: vertical-rl;
    filter: drop-shadow(0 10px 15px rgba(0, 0, 0, 0.6));
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.left-title {
    left: 4%;
    transform: translateY(-50%) rotate(180deg);
    background: linear-gradient(to top, #9ca3af, #d97706, #eab308); 
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.right-title {
    right: 4%;
    transform: translateY(-50%); 
    background: linear-gradient(to bottom, #60a5fa, #c026d3, #f472b6); 
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.half-screen:hover .vertical-title { filter: drop-shadow(0 15px 25px rgba(0, 0, 0, 0.8)); }

.left-half:hover .left-title {
    transform: translateY(-50%) rotate(180deg) scale(1.1) translateZ(20px);
    filter: drop-shadow(0 0 15px rgba(234, 179, 8, 0.4));
}

.right-half:hover .right-title {
    transform: translateY(-50%) scale(1.1) translateZ(20px);
    filter: drop-shadow(0 0 15px rgba(192, 38, 211, 0.4));
}

/* --- Content Sections --- */
.content-section { min-height: 80vh; }

/* --- HERO & ABOUT STYLES --- */
.hero-title { font-size: 3.2rem; font-weight: 700; color: #fff; margin-bottom: 0.5rem; }
.hero-title .name { color: var(--primary-color); }
.hero-subtitle { font-size: 1.5rem; color: var(--text-color); opacity: 0.8; margin-bottom: 1.5rem; }

.hero-image-container { display: flex; justify-content: center; align-items: center; }
.hero-image {
    max-width: 350px; 
    width: 100%; 
    border-radius: 50% / 40%; 
    border: 6px solid var(--primary-color); 
    box-shadow: 0 0 35px rgba(37, 99, 235, 0.6), inset 0 0 20px rgba(37, 99, 235, 0.4);
}

.profile-photo { 
    max-width: 300px; 
    border-radius: 50%; 
    border: 5px solid var(--border-color); 
    box-shadow: 0 10px 20px rgba(0,0,0,0.5);
} 

/* ================= 3D LIQUID/GLASSMORPHISM BUTTONS ================= */
.liquid-btn-group { display: flex; flex-wrap: wrap; gap: 12px; }

.liquid-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 8px 18px;
    color: #a0aec0 !important;
    font-size: 0.85rem;
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    text-decoration: none !important;
    border-radius: 40px;
    cursor: pointer;
    outline: none;
    background: linear-gradient(145deg, rgba(255,255,255,0.05) 0%, rgba(0,0,0,0.6) 100%);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-top: 1px solid rgba(255, 255, 255, 0.2); 
    border-bottom: 1px solid rgba(0, 0, 0, 0.8); 
    box-shadow: 
        0 8px 15px rgba(0, 0, 0, 0.4), 
        inset 0 2px 4px rgba(255, 255, 255, 0.1), 
        inset 0 -2px 5px rgba(0, 0, 0, 0.5); 
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1;
}

.nav-liquid-btn { padding: 6px 14px; font-size: 0.8rem; }
.liquid-btn.btn-lg { padding: 12px 28px; font-size: 1.1rem; border-radius: 50px; }

/* Glow Colors */
.btn-github { --glow-color: #ffffff; }
.btn-demo   { --glow-color: #2ed573; } 
.btn-report { --glow-color: #1e90ff; } 
.btn-slide  { --glow-color: #ff4757; } 
.btn-cyan   { --glow-color: #00d2d3; }
.btn-purple { --glow-color: #a29bfe; }
.btn-yellow { --glow-color: #feca57; }

/* Hover & Active States */
.liquid-btn:hover {
    color: #ffffff !important;
    border-color: var(--glow-color);
    background: rgba(0, 0, 0, 0.8);
    transform: translateY(-3px);
    box-shadow: 
        0 8px 25px rgba(0, 0, 0, 0.6),
        0 0 15px var(--glow-color), 
        inset 0 0 15px var(--glow-color), 
        inset 0 2px 4px rgba(255, 255, 255, 0.3);
}

.liquid-btn:active {
    transform: translateY(2px);
    box-shadow: 
        0 2px 10px rgba(0, 0, 0, 0.8),
        0 0 8px var(--glow-color), 
        inset 0 0 8px var(--glow-color), 
        inset 0 2px 4px rgba(255, 255, 255, 0.1);
}

.liquid-btn i { transition: color 0.3s ease, text-shadow 0.3s ease; }
.liquid-btn:hover i { color: var(--glow-color); text-shadow: 0 0 8px var(--glow-color); }

/* --- Education --- */
.education-item {
    padding: 1.5rem; 
    border-left: 3px solid var(--primary-color); 
    margin-bottom: 1.5rem;
    position: relative; 
    background: rgba(30, 41, 59, 0.5); 
    border-radius: 0 8px 8px 0;
}

.education-item::before {
    content: ''; 
    position: absolute; 
    left: -9px; 
    top: 22px; 
    width: 15px; 
    height: 15px;
    border-radius: 50%; 
    background-color: var(--primary-color); 
    border: 2px solid var(--background-color);
}

.education-item .year { color: var(--text-color); opacity: 0.7; float: right; }

/* ================= FLOATING & RECTANGLE CARDS (Skills & Projects) ================= */
@keyframes floating {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-15px); }
    100% { transform: translateY(0px); }
}

.float-1 { animation: floating 4s ease-in-out infinite; }
.float-2 { animation: floating 5s ease-in-out infinite 1s; }
.float-3 { animation: floating 6s ease-in-out infinite 2s; }
.float-4 { animation: floating 4.5s ease-in-out infinite 0.5s; }

/* Unified Base Style for Skills and Projects */
.skill-card, .project-card, .academic-project-card {
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.05) 0%, rgba(0, 0, 0, 0.4) 100%);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 16px;
    height: 100%;
    overflow: hidden;
    transition: transform 0.4s ease, box-shadow 0.4s ease, border-color 0.4s ease;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.4), inset 0 2px 4px rgba(255, 255, 255, 0.1);
    position: relative;
    cursor: pointer;
}

.skill-card, .project-card .card-body, .academic-project-card .p-4 { padding: 2rem !important; }
.skill-card { text-align: center; }

/* Straight Rectangular Lift up */
.skill-card:hover, .project-card:hover, .academic-project-card:hover {
    border-color: var(--primary-color);
    transform: translateY(-12px); 
    box-shadow: 
        0 25px 45px rgba(0, 0, 0, 0.7),
        0 0 20px rgba(37, 99, 235, 0.2),
        inset 0 2px 4px rgba(255, 255, 255, 0.3);
}

.skill-icon { 
    font-size: 2.5rem; 
    color: var(--primary-color); 
    margin-bottom: 1rem; 
    filter: drop-shadow(0 0 8px rgba(37, 99, 235, 0.5)); 
    transition: transform 0.3s ease; 
}

/* Card Titles */
.skill-card .card-title, .project-card .card-title, .academic-project-card .card-title { 
    color: var(--primary-color); 
    font-weight: 700;
    margin-bottom: 1rem;
    transition: text-shadow 0.3s ease;
}

.skill-card:hover .card-title, .project-card:hover .card-title, .academic-project-card:hover .card-title {
    text-shadow: 0 0 10px rgba(37, 99, 235, 0.5);
}

.skill-card .card-text, .project-card .card-text, .academic-project-card .card-text { 
    color: #cbd5e1; 
    font-size: 0.95rem; 
    line-height: 1.6;
}

/* Project Image Styling */
.academic-project-card .project-img { 
    width: 100%; 
    height: 200px; 
    object-fit: cover; 
    border-bottom: 1px solid rgba(255, 255, 255, 0.1); 
    transition: transform 0.6s ease; 
}

.academic-project-card:hover .project-img { transform: scale(1.08); }
.project-card .liquid-btn-group, .academic-project-card .liquid-btn-group { margin-top: 1.5rem; }


/* --- Contact Section --- */
#contact { background-color: transparent; }
#contact .section-title.text-start::after { left: 0; transform: none; }
.contact-tiles-grid { display: flex; flex-wrap: wrap; justify-content: center; gap: 1.5rem; }
.contact-tile {
    display: flex; 
    align-items: center; 
    justify-content: center;
    width: 65px; 
    height: 65px; 
    border-radius: 12px; 
    color: #ffffff !important;
    text-decoration: none; 
    transition: transform 0.3s ease, box-shadow 0.3s ease; 
    font-size: 2rem; 
}

.contact-tile.linkedin { background: #0077B5; }
.contact-tile.github   { background: #333333; }
.contact-tile.facebook { background: #1877F2; }
.contact-tile.whatsapp { background: #25D366; }
.contact-tile.youtube  { background: #FF0000; }
.contact-tile.email    { background: #D44638; }
.contact-tile:hover { transform: translateY(-5px) scale(1.05); box-shadow: 0 10px 20px rgba(0,0,0,0.4); }

/* --- Footer --- */
footer { background-color: #0c1221; border-top: 1px solid var(--border-color); }


/* ================= MODAL GRID DESIGN ================= */
.custom-dark-modal .modal-content {
    background-color: #0F172A;
    border: 1px solid #334155;
    border-radius: 12px;
    color: #F8FAFC;
    box-shadow: 0 25px 50px rgba(0,0,0,0.8);
}

.custom-dark-modal .modal-header { border-bottom: 1px solid #1E293B; padding: 20px 25px; }
.custom-dark-modal .modal-title { color: #3b82f6; display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 1.5rem;}
.custom-dark-modal .modal-body { padding: 25px; }

.modal-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 15px;
}

.modal-grid-item {
    background: #161b22;
    border: 1px solid #2D3748;
    border-radius: 10px;
    padding: 15px 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    transition: all 0.3s ease;
    cursor: default;
}

.modal-grid-item:hover {
    background: #1E293B;
    border-color: #3b82f6;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.4);
}

.modal-grid-item i, .modal-grid-item .icon-text { font-size: 1.8rem; color: #3b82f6; width: 35px; text-align: center; }
.modal-grid-item span { font-weight: 500; font-size: 1.05rem; }


/* Animations & Responsive */
.fade-in { opacity: 0; transform: translateY(20px); transition: opacity 0.6s ease-out, transform 0.6s ease-out; }
.fade-in.visible { opacity: 1; transform: translateY(0); }

@media (max-width: 992px) {
    .hero-content { margin-top: 2rem; text-align: center; }
    .hero-title { font-size: 2.8rem; }
    .section-title.text-start { text-align: center !important; }
    .section-title.text-start::after { left: 50%; transform: translateX(-50%); }
    .nav-gap { gap: 15px; margin-bottom: 10px; }
}

@media (max-width: 768px) {
    .split-container { flex-direction: column; }
    .left-img { width: 100%; height: 200%; top: 0; left: 0; object-position: center top; }
    .right-img { width: 100%; height: 200%; bottom: 0; top: auto; right: 0; object-position: center bottom; }

    .vertical-title {
        writing-mode: horizontal-tb; 
        font-size: 3.5rem;
        top: 15%; 
        left: 50% !important;
        right: auto !important;
        transform: translateX(-50%) !important; 
    }

    .left-half:hover .left-title, .right-half:hover .right-title {
        transform: translateX(-50%) scale(1.05) !important;
    }
}