/* CSS Variables for Light and Dark Themes */
:root {
  --bg-primary: linear-gradient(135deg, #5aa0ff 0%, #8cd8ff 100%);
  --bg-secondary: rgba(255, 255, 255, 0.12);
  --bg-card: rgba(255, 255, 255, 0.97);
  --bg-glass: rgba(255, 255, 255, 0.28);

  --text-primary: #1f2937;   /* slate-800 */
  --text-secondary: #475569; /* slate-600 */
  --text-muted: #64748b;     /* slate-500 */

  --accent-primary: #2d81f7;   /* friendly blue */
  --accent-secondary: #8ec5ff; /* soft sky */
  --accent-hover: #1e6fe3;
  --accent-gradient: linear-gradient(135deg, #2d81f7 0%, #8ec5ff 100%);

  --border-color: rgba(0, 0, 0, 0.08);

  --shadow-light: rgba(0, 0, 0, 0.08);
  --shadow-medium: rgba(0, 0, 0, 0.18);
  --shadow-glow: rgba(45, 129, 247, 0.28);

  --gradient-bg: linear-gradient(135deg, #5aa0ff 0%, #8cd8ff 100%);
  --gradient-card: linear-gradient(145deg, rgba(255, 255, 255, 0.97) 0%, rgba(255, 255, 255, 0.85) 100%);

  --transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  --bounce: cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

[data-theme="dark"] {
  --bg-primary: linear-gradient(135deg, #0b1220 0%, #0e2437 100%);
  --bg-secondary: rgba(255, 255, 255, 0.05);
  --bg-card: rgba(15, 23, 42, 0.92);  /* slate-900 */
  --bg-glass: rgba(255, 255, 255, 0.06);

  --text-primary: #e6eef7;
  --text-secondary: #b7c4d1;
  --text-muted: #8aa0b6;

  --accent-primary: #8ec5ff;
  --accent-secondary: #2d81f7;
  --accent-hover: #a6d7ff;
  --accent-gradient: linear-gradient(135deg, #8ec5ff 0%, #2d81f7 100%);

  --border-color: rgba(255, 255, 255, 0.10);

  --shadow-light: rgba(0, 0, 0, 0.35);
  --shadow-medium: rgba(0, 0, 0, 0.55);
  --shadow-glow: rgba(45, 129, 247, 0.35);

  --gradient-bg: linear-gradient(135deg, #0b1220 0%, #0e2437 100%);
  --gradient-card: linear-gradient(145deg, rgba(15, 23, 42, 0.94) 0%, rgba(14, 36, 55, 0.88) 100%);
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    background: var(--bg-primary);
    color: var(--text-primary);
    transition: var(--transition);
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--bg-primary);
    z-index: -2;
}

body::after {
    content: '';
    position: fixed;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: 
        radial-gradient(circle at 20% 80%, rgba(108, 92, 231, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(162, 155, 254, 0.15) 0%, transparent 50%);
    animation: float 20s ease-in-out infinite;
    pointer-events: none;
    z-index: -1;
}

@keyframes float {
    0%, 100% { transform: translate(0px, 0px); }
    33% { transform: translate(7px, -4px); }
    66% { transform: translate(-5px, 7px); }
}

/* Theme Toggle */
.theme-toggle {
    position: fixed;
    top: 25px;
    right: 25px;
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 1000;
    background: var(--bg-glass);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 12px 18px;
    border-radius: 50px;
    border: 1px solid var(--border-color);
    box-shadow: 0 8px 32px var(--shadow-light), 0 0 0 1px rgba(255, 255, 255, 0.1);
    transition: var(--transition);
}

.theme-toggle:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 12px 40px var(--shadow-medium), 0 0 0 1px rgba(255, 255, 255, 0.2);
    background: var(--bg-card);
}

.theme-toggle i {
    color: var(--text-secondary);
    font-size: 14px;
    transition: var(--transition);
}

.toggle-switch {
    position: relative;
    width: 50px;
    height: 24px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--border-color);
    transition: var(--transition);
    border-radius: 24px;
    overflow: hidden;
}

.slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background: linear-gradient(145deg, #ffffff, #f0f0f0);
    transition: var(--bounce);
    border-radius: 50%;
    box-shadow: 0 4px 8px var(--shadow-light), inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

input:checked + .slider {
    background: var(--accent-gradient);
    box-shadow: 0 0 20px var(--shadow-glow);
}

input:checked + .slider:before {
    transform: translateX(26px) rotate(180deg);
}

/* Main Container */
.container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
}

/* V-Card */
.vcard {
    background: var(--gradient-card);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 32px;
    border: 1px solid var(--border-color);
    box-shadow: 
        0 25px 80px var(--shadow-light),
        0 0 0 1px rgba(255, 255, 255, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    padding: 50px;
    max-width: 650px;
    width: 100%;
    position: relative;
    overflow: hidden;
    transition: var(--transition);
    animation: slideUp 1s var(--bounce);
}

.vcard::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--accent-gradient);
    border-radius: 32px 32px 0 0;
}

.vcard::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(108, 92, 231, 0.03) 0%, transparent 70%);
    animation: rotate 30s linear infinite;
    pointer-events: none;
}

.vcard:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 
        0 35px 100px var(--shadow-medium),
        0 0 0 1px rgba(255, 255, 255, 0.2),
        0 0 50px var(--shadow-glow);
}

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

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

/* Profile Section */
.profile-section {
    text-align: center;
    margin-bottom: 50px;
    animation: fadeIn 1.2s ease-out 0.3s both;
    position: relative;
    z-index: 2;
}

.profile-image-container {
    position: relative;
    display: inline-block;
    margin-bottom: 25px;
}

.profile-image-container::before {
    content: '';
    position: absolute;
    top: -10px;
    left: -10px;
    right: -10px;
    bottom: -10px;
    background: var(--accent-gradient);
    border-radius: 50%;
    opacity: 0.3;
    animation: pulse 3s ease-in-out infinite;
    z-index: -1;
}

.profile-image {
    width: 160px;
    height: 160px;
    border-radius: 50%;
    object-fit: cover;
    border: 5px solid rgba(255, 255, 255, 0.3);
    transition: var(--transition);
    animation: float 6s ease-in-out infinite;
    box-shadow: 
        0 15px 35px var(--shadow-light),
        0 5px 15px rgba(108, 92, 231, 0.2);
}

.profile-image:hover {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 
        0 20px 60px var(--shadow-medium),
        0 0 50px var(--shadow-glow);
    border-color: rgba(255, 255, 255, 0.6);
}

.name {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 15px;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: slideInLeft 1s var(--bounce) 0.5s both;
    letter-spacing: -0.02em;
    text-shadow: 0 0 30px rgba(108, 92, 231, 0.3);
    position: relative;
}

.name::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: var(--accent-gradient);
    border-radius: 2px;
    animation: expandWidth 1s ease-out 1s both;
}

@keyframes expandWidth {
    from { width: 0; }
    to { width: 60px; }
}

.title {
    font-size: 1.3rem;
    color: var(--text-secondary);
    font-weight: 500;
    animation: slideInRight 1s var(--bounce) 0.7s both;
    margin-bottom: 20px;
    opacity: 0.9;
}

/* Contact Section */
.contact-section {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 50px;
    animation: fadeIn 1.5s ease-out 0.9s both;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 18px;
    padding: 20px 25px;
    background: var(--bg-glass);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 20px;
    transition: var(--transition);
    border: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
}

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

.contact-item:hover::before {
    left: 0;
}

.contact-item:hover {
    transform: translateX(8px) scale(1.03);
    border-color: rgba(255, 255, 255, 0.3);
    box-shadow: 0 10px 40px var(--shadow-glow);
}

.contact-item i {
    color: var(--accent-primary);
    font-size: 1.4rem;
    width: 24px;
    text-align: center;
    transition: var(--transition);
    z-index: 1;
    position: relative;
}

.contact-item:hover i {
    color: white;
    transform: scale(1.2) rotate(10deg);
}

.contact-item a {
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    z-index: 1;
    position: relative;
    font-size: 1.05rem;
}

.contact-item:hover a {
    color: white;
    transform: translateX(3px);
}

/* Info Sections */
.info-section {
    margin-bottom: 40px;
    padding: 30px;
    background: var(--bg-glass);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-radius: 24px;
    border: 1px solid var(--border-color);
    transition: var(--transition);
    animation: slideInUp 1s var(--bounce) both;
    position: relative;
    overflow: hidden;
}

.info-section::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, var(--accent-primary)05, transparent 70%);
    animation: rotate 20s linear infinite reverse;
    pointer-events: none;
    opacity: 0;
    transition: var(--transition);
}

.info-section:hover::before {
    opacity: 1;
}

.info-section:nth-child(odd) {
    animation-delay: 0.2s;
}

.info-section:nth-child(even) {
    animation-delay: 0.4s;
}

.info-section:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 
        0 15px 50px var(--shadow-light),
        0 0 0 1px rgba(255, 255, 255, 0.2),
        0 0 30px var(--shadow-glow);
    border-color: var(--accent-primary);
}

.info-section h2 {
    color: var(--accent-primary);
    font-size: 1.5rem;
    margin-bottom: 25px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 700;
    position: relative;
    z-index: 1;
}

.info-section h2::after {
    content: '';
    flex: 1;
    height: 2px;
    background: linear-gradient(to right, var(--accent-primary), transparent);
    border-radius: 1px;
    margin-left: 15px;
}

.info-section h2 i {
    font-size: 1.3rem;
    padding: 8px;
    background: var(--accent-gradient);
    color: white;
    border-radius: 12px;
    box-shadow: 0 4px 15px var(--shadow-glow);
}

.info-content h3 {
    color: var(--text-primary);
    font-size: 1.2rem;
    margin-bottom: 8px;
    font-weight: 600;
}

.company {
    color: var(--accent-secondary);
    font-weight: 500;
    margin-bottom: 10px;
    font-size: 1rem;
}

.description {
    color: var(--text-secondary);
    line-height: 1.7;
    font-size: 0.95rem;
}

/* Tags Container */
.tags-container {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 15px;
}

.tag {
    background: var(--accent-gradient);
    color: white;
    padding: 10px 18px;
    border-radius: 25px;
    font-size: 0.9rem;
    font-weight: 600;
    transition: var(--transition);
    cursor: default;
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 4px 15px rgba(108, 92, 231, 0.3);
}

.tag::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: var(--transition);
}

.tag:hover::before {
    left: 100%;
}

.tag:hover {
    transform: translateY(-3px) scale(1.08);
    box-shadow: 0 8px 25px rgba(108, 92, 231, 0.5);
    border-color: rgba(255, 255, 255, 0.4);
}

/* Passion Section */
.passion-section {
    background: var(--bg-glass);
    border: 2px solid var(--accent-primary);
    position: relative;
    overflow: hidden;
}

.passion-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--accent-gradient);
    opacity: 0.05;
    pointer-events: none;
}

.passion-section::after {
    content: '❤️';
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 1.5rem;
    animation: heartbeat 2s ease-in-out infinite;
}

@keyframes heartbeat {
    0%, 50%, 100% { transform: scale(1); }
    25%, 75% { transform: scale(1.2); }
}

.passion-text {
    color: var(--text-secondary);
    line-height: 1.8;
    margin-bottom: 20px;
    font-size: 1.05rem;
    position: relative;
    z-index: 1;
}

.passion-text:last-child {
    margin-bottom: 0;
}

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

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(50px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

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

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

@keyframes pulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(108, 92, 231, 0.4);
        opacity: 1;
    }
    50% {
        box-shadow: 0 0 0 20px rgba(108, 92, 231, 0);
        opacity: 0.8;
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 20px;
    }

    .vcard {
        padding: 40px 30px;
        border-radius: 28px;
        margin: 10px;
    }

    .name {
        font-size: 2.5rem;
    }

    .title {
        font-size: 1.2rem;
    }

    .profile-image {
        width: 140px;
        height: 140px;
    }

    .info-section {
        padding: 25px;
        margin-bottom: 30px;
    }

    .contact-section {
        gap: 15px;
    }

    .contact-item {
        padding: 18px 20px;
    }

    .theme-toggle {
        top: 20px;
        right: 20px;
        padding: 10px 15px;
    }

    .tags-container {
        gap: 10px;
        justify-content: center;
    }

    .tag {
        padding: 8px 15px;
        font-size: 0.85rem;
    }

    .info-section h2 {
        font-size: 1.3rem;
        flex-direction: column;
        align-items: flex-start;
    }

    .info-section h2::after {
        display: none;
    }
}

@media (max-width: 480px) {
    .vcard {
        padding: 30px 25px;
        border-radius: 24px;
        margin: 5px;
    }

    .name {
        font-size: 2.2rem;
    }

    .title {
        font-size: 1.1rem;
    }

    .profile-image {
        width: 120px;
        height: 120px;
    }

    .info-section h2 {
        font-size: 1.2rem;
    }

    .contact-item {
        flex-direction: column;
        text-align: center;
        gap: 12px;
        padding: 20px 15px;
    }

    .theme-toggle {
        top: 15px;
        right: 15px;
        padding: 8px 12px;
    }

    .tag {
        padding: 6px 12px;
        font-size: 0.8rem;
    }
}

/* Ultra-wide screens optimization */
@media (min-width: 1400px) {
    .vcard {
        max-width: 750px;
        padding: 60px;
    }
    
    .name {
        font-size: 3.5rem;
    }
    
    .profile-image {
        width: 180px;
        height: 180px;
    }
}
