/* ============================================
   NINAD KARKHANIS PORTFOLIO - STYLES
   Cyber Security Theme
   ============================================ */

/* Base Styles */
body {
    background-color: #0a0a0a;
    color: #ffffff;
    scroll-behavior: smooth;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

/* Selection Styling */
::selection {
    background-color: #00ff41;
    color: #0a0a0a;
}

::-moz-selection {
    background-color: #00ff41;
    color: #0a0a0a;
}

/* ============================================
   CUSTOM SCROLLBAR
   ============================================ */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #121212; 
}

::-webkit-scrollbar-thumb {
    background: #2d2d2d; 
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #00ff41; 
}

/* Hide scrollbar but keep functionality */
.no-scrollbar::-webkit-scrollbar {
    display: none;
}

.no-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* ============================================
   ANIMATIONS
   ============================================ */
@keyframes spin-slow {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.animate-spin-slow {
    animation: spin-slow 10s linear infinite;
}

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

.fade-in {
    animation: fadeIn 0.6s ease-out forwards;
}

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

.slide-in-left {
    animation: slideInLeft 0.5s ease-out forwards;
}

@keyframes pulse-glow {
    0%, 100% {
        box-shadow: 0 0 10px rgba(0, 255, 65, 0.3);
    }
    50% {
        box-shadow: 0 0 20px rgba(0, 255, 65, 0.6);
    }
}

.pulse-glow {
    animation: pulse-glow 2s ease-in-out infinite;
}

/* ============================================
   NAVIGATION
   ============================================ */
nav {
    transition: all 0.3s ease;
}

.nav-link {
    position: relative;
    padding-bottom: 2px;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: #00ff41;
    transition: width 0.3s ease;
}

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

/* Mobile menu transition */
#mobile-menu {
    transition: max-height 0.3s ease-out, opacity 0.3s ease-out;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
}

#mobile-menu.show {
    max-height: 300px;
    opacity: 1;
}

/* ============================================
   BLOG CARDS
   ============================================ */
.blog-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.blog-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 255, 65, 0.2);
}

/* Responsive Blog Cards - Mobile First */
#blog-container .blog-card,
#blog-container a {
    min-width: 85vw;
    width: 85vw;
}

/* Desktop Override */
@media (min-width: 640px) {
    #blog-container .blog-card,
    #blog-container a {
        min-width: 300px;
        width: 300px;
    }
}

/* ============================================
   TIMELINE (Experience/Education)
   ============================================ */
.timeline-line {
    position: relative;
}

.timeline-line > div {
    transition: all 0.3s ease;
}

.timeline-line > div:hover {
    transform: translateX(5px);
}

/* ============================================
   SKILLS BADGES
   ============================================ */
.skill-badge {
    transition: all 0.3s ease;
    cursor: default;
}

.skill-badge:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 255, 65, 0.3);
}

/* ============================================
   SHIELD PARTICLE EFFECT
   ============================================ */
#shield-container {
    position: relative;
}

#particle-canvas {
    pointer-events: none;
    z-index: 1;
}

#shield-svg {
    transition: all 0.3s ease;
    filter: drop-shadow(0 0 10px rgba(0, 255, 65, 0.3));
}

#shield-container:hover #shield-svg {
    transform: scale(1.1);
    filter: drop-shadow(0 0 20px rgba(0, 255, 65, 0.8));
}

/* Pulse animation for shield rings */
@keyframes shield-pulse {
    0%, 100% {
        opacity: 0.2;
        transform: scale(1);
    }
    50% {
        opacity: 0.4;
        transform: scale(1.05);
    }
}

#shield-container:hover .animate-pulse {
    animation: shield-pulse 1.5s ease-in-out infinite;
}

/* ============================================
   CONTACT FORM
   ============================================ */
#contact-form input,
#contact-form textarea {
    transition: all 0.3s ease;
}

#contact-form input:focus,
#contact-form textarea:focus {
    border-color: #00ff41;
    box-shadow: 0 0 0 3px rgba(0, 255, 65, 0.1);
}

#contact-form input::placeholder,
#contact-form textarea::placeholder {
    color: #4a5568;
}

#submit-btn {
    position: relative;
    overflow: hidden;
}

#submit-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

#submit-btn:active::before {
    width: 300px;
    height: 300px;
}

/* Status message animations */
#form-status {
    animation: slideDown 0.3s ease-out;
}

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

/* ============================================
   BUTTONS
   ============================================ */
button,
.btn {
    transition: all 0.3s ease;
    cursor: pointer;
}

button:hover,
.btn:hover {
    transform: translateY(-2px);
}

button:active,
.btn:active {
    transform: translateY(0);
}

/* ============================================
   TERMINAL WINDOW
   ============================================ */
#terminal-window {
    box-shadow: 0 -10px 50px rgba(0, 0, 0, 0.8);
}

#terminal-output {
    font-size: 13px;
    line-height: 1.5;
}

#terminal-input {
    caret-color: #00ff41;
}

#terminal-input:focus {
    outline: none;
}

/* Terminal text effects */
.terminal-error {
    color: #ff4444;
}

.terminal-success {
    color: #00ff41;
    font-weight: bold;
}

.terminal-warning {
    color: #ffaa00;
}

.terminal-info {
    color: #4af677;
}

/* ============================================
   CERTIFICATION CARDS
   ============================================ */
.cert-card {
    transition: all 0.3s ease;
}

.cert-card:hover {
    background-color: rgba(0, 255, 65, 0.05);
    border-color: #00ff41;
}

.cert-card:hover .cert-icon {
    background-color: rgba(0, 255, 65, 0.2);
}

/* ============================================
   LOADING STATES
   ============================================ */
.skeleton {
    background: linear-gradient(90deg, #121212 25%, #2d2d2d 50%, #121212 75%);
    background-size: 200% 100%;
    animation: loading 1.5s ease-in-out infinite;
}

@keyframes loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

/* Tablet (768px and up) */
@media (min-width: 768px) {
    #terminal-output {
        font-size: 14px;
    }
}

/* Desktop (1024px and up) */
@media (min-width: 1024px) {
    .timeline-line > div:hover {
        transform: translateX(10px);
    }
}

/* Large Desktop (1280px and up) */
@media (min-width: 1280px) {
    body {
        font-size: 16px;
    }
}

/* ============================================
   ACCESSIBILITY
   ============================================ */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* Focus styles for keyboard navigation */
a:focus,
button:focus,
input:focus {
    outline: 2px solid #00ff41;
    outline-offset: 2px;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* ============================================
   UTILITY CLASSES
   ============================================ */
.text-cyber-green {
    color: #00ff41;
}

.bg-cyber-dark {
    background-color: #121212;
}

.border-cyber-gray {
    border-color: #2d2d2d;
}

.hover-lift:hover {
    transform: translateY(-3px);
    transition: transform 0.3s ease;
}

/* ============================================
   PRINT STYLES
   ============================================ */
@media print {
    nav,
    #terminal-window,
    button {
        display: none !important;
    }
    
    body {
        background: white;
        color: black;
    }
    
    a {
        text-decoration: underline;
    }
}