/* =========================================
   CSS Reset & Variables
   ========================================= */
:root {
    --bg-color: #000000; /* Black background */
    --text-primary: #ffffff;
    --text-secondary: #a0a0a0;
    --card-bg: rgba(255, 255, 255, 0.08); /* Dark glass */
    --card-hover: rgba(255, 255, 255, 0.12);
    
    /* Social Brand Colors */
    --color-whatsapp: #25D366;
    --color-linkedin: #0077b5;
    --color-facebook: #1877F2;
    --color-instagram: #E1306C;
    --color-twitter: #ffffff; /* White for black background */
    --color-youtube: #FF0000;
    --color-tiktok: #ffffff; /* White for black background */
    --color-email: #ea4335;
    --color-phone: #34d399;
}

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

body {
    font-family: 'Open Sans', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-primary);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    overflow-x: hidden;
}

/* =========================================
   Layout & Container
   ========================================= */
.container {
    width: 100%;
    max-width: 680px;
    padding: 3rem 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

/* =========================================
   Profile Card
   ========================================= */
.profile-card {
    background: var(--card-bg);
    border-radius: 30px;
    padding: 2.5rem 1.5rem 1.5rem 1.5rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: flex;
    flex-direction: column;
    align-items: center;
    border: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 0.5rem;
    position: relative;
    min-height: 280px;
    transition: all 0.6s cubic-bezier(0.25, 1, 0.5, 1);
}

.profile-card.avatar-expanded {
    min-height: 520px;
}

/* =========================================
   Top Right Action Buttons
   ========================================= */
.action-buttons-container {
    position: absolute;
    top: 20px;
    right: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 10;
}

.action-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 50%;
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
}

.share-btn:hover {
    background: #ffffff;
    transform: scale(1.05);
}

/* =========================================
   Profile Header
   ========================================= */
.profile-header {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
    width: 100%;
    margin-top: 120px; /* Space for the absolute avatar (110px + 10px gap) */
    transition: all 0.6s cubic-bezier(0.25, 1, 0.5, 1);
}

.avatar-container {
    position: absolute;
    top: 2.5rem;
    left: 50%;
    margin-left: -55px; /* Center 110px width */
    width: 110px;
    height: 110px;
    border-radius: 50%;
    overflow: hidden;
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
    /* Profile Picture Animation */
    animation: profileFloat 4s ease-in-out infinite;
    cursor: pointer;
    transition: all 0.6s cubic-bezier(0.25, 1, 0.5, 1);
    z-index: 0;
}

.avatar-container:hover {
    animation-play-state: paused;
}

.avatar {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    transition: all 0.6s cubic-bezier(0.25, 1, 0.5, 1);
}

.avatar-container:hover .avatar {
    transform: scale(1.15);
}

.avatar-overlay {
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: all 0.6s cubic-bezier(0.25, 1, 0.5, 1);
}

.avatar-container:hover .avatar-overlay {
    opacity: 1;
}

.overlay-title {
    font-weight: 700;
    font-size: 1rem;
    color: #000;
    transform: translateY(15px);
    transition: all 0.6s ease;
}

.overlay-subtitle {
    font-size: 0.75rem;
    font-weight: 500;
    color: #333;
    transform: translateY(15px);
    transition: all 0.6s ease;
    transition-delay: 0.05s;
}

.avatar-container:hover .overlay-title,
.avatar-container:hover .overlay-subtitle {
    transform: translateY(0);
}

@keyframes profileFloat {
    0% { transform: translateY(0px); box-shadow: 0 8px 20px rgba(0,0,0,0.15); }
    50% { transform: translateY(-8px); box-shadow: 0 16px 25px rgba(0,0,0,0.2); }
    100% { transform: translateY(0px); box-shadow: 0 8px 20px rgba(0,0,0,0.15); }
}

.name {
    font-size: 1.6rem;
    font-weight: 500;
    letter-spacing: -0.3px;
    transition: all 0.6s ease;
    position: relative;
    z-index: 3;
    margin-bottom: 0.2rem;
}

.tagline {
    font-size: 0.95rem;
    color: var(--text-primary);
    font-weight: 400;
    letter-spacing: 0.2px;
    transition: all 0.6s ease;
    overflow: hidden;
    position: relative;
    z-index: 3;
}

.separator {
    margin: 0 0.5rem;
    opacity: 0.8;
}

/* =========================================
   Expanded Avatar Hero Mode
   ========================================= */

/* The header drops down to the bottom */
.profile-card.avatar-expanded .profile-header {
    margin-top: auto;
    margin-bottom: 0.5rem;
}

/* The image expands to cover the entire card behind the content */
.profile-card.avatar-expanded .avatar-container {
    top: 0;
    left: 0;
    margin-left: 0;
    width: 100%;
    height: 100%;
    border-radius: 30px; /* Match the card's border-radius */
    animation: none;
    box-shadow: none;
}

.profile-card.avatar-expanded .avatar {
    border-radius: 30px;
    transform: scale(1); /* remove hover scale if any */
}

/* Glassmorphism dark gradient over the expanded image */
.profile-card.avatar-expanded .avatar-overlay {
    opacity: 1;
    background: linear-gradient(to bottom, rgba(0,0,0,0) 40%, rgba(0,0,0,0.85) 100%);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    border: none;
    border-radius: 30px;
}

/* Hide the click-hint when expanded */
.profile-card.avatar-expanded .click-hint,
.profile-card.avatar-expanded .avatar-overlay {
    opacity: 0;
    visibility: hidden;
}

/* Name changes color to contrast against the dark gradient */
.profile-card.avatar-expanded .name {
    color: #fff;
    text-shadow: 0 2px 10px rgba(0,0,0,0.6);
}

/* Tagline is hidden softly */
.profile-card.avatar-expanded .tagline {
    opacity: 0;
    height: 0;
    margin: 0;
    transform: translateY(10px);
}

/* =========================================
   Social Media Icons (Original Colors)
   ========================================= */
.social-container {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
    margin-bottom: 2rem;
    position: relative;
    z-index: 3;
}

.social-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.05);
    font-size: 1.2rem;
    transition: all 0.3s ease;
    border: 1px solid;
}

/* Original Brand Colors */
.social-icon.phone { color: #4CAF50; border-color: rgba(76, 175, 80, 0.3); }
.social-icon.whatsapp { color: #25D366; border-color: rgba(37, 211, 102, 0.3); }
.social-icon.linkedin { color: #0a66c2; border-color: rgba(10, 102, 194, 0.3); }
.social-icon.xing { color: #026466; border-color: rgba(2, 100, 102, 0.3); }
.social-icon.facebook { color: #1877F2; border-color: rgba(24, 119, 242, 0.3); }
.social-icon.instagram { 
    color: #E1306C;
    border-color: rgba(225, 48, 108, 0.3);
}
.social-icon.youtube { color: #FF0000; border-color: rgba(255, 0, 0, 0.3); }
.social-icon.teams { color: #6264A7; border-color: rgba(98, 100, 167, 0.3); }
.social-icon.email { color: #EA4335; border-color: rgba(234, 67, 53, 0.3); }
.social-icon.website { color: #00f2fe; border-color: rgba(0, 242, 254, 0.3); }
.social-icon.map { color: #ff3b30; border-color: rgba(255, 59, 48, 0.3); }
.social-icon.provenexpert { color: #c1a660; border-color: rgba(193, 166, 96, 0.3); }

/* Glow & Fill on Hover */
.social-icon:hover {
    color: #ffffff;
    text-shadow: none;
    transform: translateY(-3px);
}

.social-icon.phone:hover { 
    background-color: #4CAF50; 
    border-color: #4CAF50;
    box-shadow: 0 0 15px rgba(76, 175, 80, 0.5); 
}
.social-icon.whatsapp:hover { 
    background-color: #25D366; 
    border-color: #25D366;
    box-shadow: 0 0 15px rgba(37, 211, 102, 0.5); 
}
.social-icon.linkedin:hover { 
    background-color: #0a66c2; 
    border-color: #0a66c2;
    box-shadow: 0 0 15px rgba(10, 102, 194, 0.5); 
}
.social-icon.xing:hover {
    background-color: #026466;
    border-color: #026466;
    box-shadow: 0 0 15px rgba(2, 100, 102, 0.5);
}
.social-icon.facebook:hover { 
    background-color: #1877F2; 
    border-color: #1877F2;
    box-shadow: 0 0 15px rgba(24, 119, 242, 0.5); 
}
.social-icon.instagram:hover { 
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    border-color: transparent;
    box-shadow: 0 0 15px rgba(225, 48, 108, 0.5); 
}
.social-icon.youtube:hover { 
    background-color: #FF0000; 
    border-color: #FF0000;
    box-shadow: 0 0 15px rgba(255, 0, 0, 0.5); 
}
.social-icon.teams:hover {
    background-color: #6264A7;
    border-color: #6264A7;
    box-shadow: 0 0 15px rgba(98, 100, 167, 0.5);
}
.social-icon.email:hover { 
    background-color: #EA4335; 
    border-color: #EA4335;
    box-shadow: 0 0 15px rgba(234, 67, 53, 0.5); 
}
.social-icon.website:hover { 
    background-color: #00f2fe; 
    border-color: #00f2fe;
    box-shadow: 0 0 15px rgba(0, 242, 254, 0.5); 
}
.social-icon.map:hover { 
    background-color: #ff3b30; 
    border-color: #ff3b30;
    box-shadow: 0 0 15px rgba(255, 59, 48, 0.5); 
}
.social-icon.provenexpert:hover { 
    background-color: #c1a660; 
    border-color: #c1a660;
    box-shadow: 0 0 15px rgba(193, 166, 96, 0.5); 
}

/* =========================================
   Bento Grid Layout
   ========================================= */
.bento-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.8rem;
    width: 100%;
}

.bento-item {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 18px;
    padding: 1.2rem;
    color: var(--text-primary);
    text-decoration: none;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.25, 1, 0.5, 1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

.bento-item:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 10px 20px rgba(0,0,0,0.2), inset 0 0 0 1px rgba(255,255,255,0.15);
}

.bento-icon {
    font-size: 1.6rem;
    margin-bottom: 0.8rem;
    opacity: 0.9;
    color: #ffffff;
}

.bento-item .btn-text {
    font-size: 1rem;
    font-weight: 400; /* Identical, lighter font weight */
    line-height: 1.3;
}

/* Span Classes */
.bento-item.quarter {
    grid-column: span 1;
    aspect-ratio: 1 / 1;
    padding: 0.5rem;
    gap: 0.3rem;
}
.bento-item.quarter .bento-icon {
    font-size: 1.4rem;
    margin-bottom: 0;
    transition: all 0.3s ease;
}
.bento-item.quarter .btn-text {
    font-size: 0.65rem;
    line-height: 1.1;
    word-break: break-word;
    hyphens: auto;
    transition: all 0.3s ease;
}

.bento-item.square {
    grid-column: span 2;
    aspect-ratio: 1 / 1;
}

.bento-item.wide {
    grid-column: span 4;
    flex-direction: row;
    justify-content: flex-start;
    padding: 1.2rem;
    aspect-ratio: auto;
    text-align: left;
}

.bento-item.wide .bento-icon {
    margin-bottom: 0;
    margin-right: 1.2rem;
    font-size: 1.4rem;
}

/* Small portals on mobile: span 1, but smaller padding */
.bento-item.portal {
    padding: 1rem;
    aspect-ratio: 1 / 1;
}

.bento-item.portal .bento-icon {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}
.bento-item.portal .btn-text {
    font-size: 0.85rem;
}

/* Herrlich AI Feature */
.feature-herrlichai {
    background: linear-gradient(135deg, rgba(138, 43, 226, 0.1), rgba(0, 242, 254, 0.1));
    border-color: rgba(138, 43, 226, 0.3);
}
.feature-herrlichai:hover {
    background: linear-gradient(135deg, rgba(138, 43, 226, 0.2), rgba(0, 242, 254, 0.2));
    border-color: #8a2be2;
    box-shadow: 0 0 15px rgba(138, 43, 226, 0.4);
    transform: translateY(-3px) scale(1.02);
}
.feature-herrlichai .bento-icon {
    color: #8a2be2;
    text-shadow: 0 0 10px rgba(138, 43, 226, 0.5);
}

/* Custom Background Utilities */
.custom-bg {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    overflow: hidden;
    z-index: 0;
    pointer-events: none;
    transition: all 0.5s ease;
}
.bento-item .btn-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 1.5rem;
    width: 100%;
    text-align: left;
}
.bento-item.wide .text-group {
    display: flex;
    flex-direction: column;
    justify-content: center;
}
.bento-item.wide .btn-subtext {
    font-size: 0.75rem;
    opacity: 0.7;
    margin-top: 0.2rem;
    font-weight: 400;
    line-height: 1.3;
}
.bento-item.wide .bento-icon {
    margin-bottom: 0;
    font-size: 2rem;
}
@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.15); filter: drop-shadow(0 0 10px rgba(10, 132, 255, 0.8)); }
    100% { transform: scale(1); }
}
.pulse-icon {
    animation: pulse 2.5s infinite ease-in-out;
}
.watermark {
    position: absolute;
    right: -20px;
    bottom: -40px;
    font-size: 10rem;
    opacity: 0.03;
    transform: rotate(-15deg);
    transition: all 0.5s ease;
}

/* ProvenExpert Profile */
.feature-provenexpert {
    position: relative;
    overflow: hidden;
    background: #111;
    border-color: rgba(193, 166, 96, 0.3);
}
.feature-provenexpert .provenexpert-bg {
    background: radial-gradient(circle at bottom right, rgba(193, 166, 96, 0.15) 0%, transparent 70%);
}
.feature-provenexpert:hover {
    border-color: #c1a660;
    box-shadow: 0 0 15px rgba(193, 166, 96, 0.3);
    transform: translateY(-3px) scale(1.02);
}
.feature-provenexpert:hover .provenexpert-bg {
    transform: scale(1.05);
}
.feature-provenexpert:hover .watermark {
    transform: rotate(0deg) scale(1.1);
    opacity: 0.08;
    color: #c1a660;
}
.feature-provenexpert .bento-icon {
    color: #c1a660;
    text-shadow: 0 0 10px rgba(193, 166, 96, 0.5);
    margin-bottom: 0.5rem;
}

/* Location / Map Feature */
.feature-location {
    position: relative;
    overflow: hidden;
    background: #111;
    border-color: rgba(255, 255, 255, 0.1);
    align-items: flex-start;
    padding: 1.5rem;
}

.feature-location .location-bg {
    position: absolute;
    top: -10px; left: -10px; right: -10px; bottom: -10px;
    z-index: 0;
    opacity: 0.6;
    transition: all 0.5s ease;
    pointer-events: none; /* Lets clicks pass through to the button */
    filter: grayscale(100%) invert(90%) contrast(1.2); /* Turns the map into a beautiful dark mode UI map */
}

.feature-location::after {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: radial-gradient(circle at center, transparent 0%, #111 90%);
    z-index: 1;
    pointer-events: none;
}

.feature-location .bento-icon {
    color: #ff3b30;
    font-size: 1.8rem;
    margin-bottom: 0.8rem;
    text-shadow: 0 0 15px rgba(255, 59, 48, 0.5);
    transition: all 0.3s ease;
}



.feature-location .btn-subtext {
    font-size: 0.75rem;
    opacity: 0.6;
}

.feature-location:hover .location-bg {
    transform: scale(1.1);
    opacity: 0.8;
}
.feature-location:hover {
    border-color: rgba(255, 59, 48, 0.4);
    box-shadow: 0 0 20px rgba(255, 59, 48, 0.2);
    transform: translateY(-3px) scale(1.02);
}
.feature-location:hover .bento-icon {
    transform: translateY(-5px);
    text-shadow: 0 5px 15px rgba(255, 59, 48, 0.8);
}

/* Save Contact Feature */
.feature-vcard {
    position: relative;
    overflow: hidden;
    background: #111;
    border-color: rgba(10, 132, 255, 0.3);
}
.feature-vcard .vcard-bg {
    background: radial-gradient(circle at top left, rgba(10, 132, 255, 0.15) 0%, transparent 70%),
                repeating-radial-gradient(circle at center, transparent 0, transparent 20px, rgba(10, 132, 255, 0.03) 21px, rgba(10, 132, 255, 0.03) 22px);
}
.feature-vcard:hover {
    border-color: #0A84FF;
    box-shadow: 0 0 15px rgba(10, 132, 255, 0.3);
    transform: translateY(-3px) scale(1.02);
}
.feature-vcard:hover .vcard-bg {
    transform: scale(1.05);
}
.feature-vcard:hover .watermark {
    transform: rotate(0deg) scale(1.1);
    opacity: 0.08;
    color: #0A84FF;
}
.feature-vcard .bento-icon {
    color: #0A84FF;
    text-shadow: 0 0 10px rgba(10, 132, 255, 0.5);
    margin-bottom: 0.5rem;
}

/* Colored Square Features */
/* About Me Feature */
.feature-aboutme {
    background: linear-gradient(135deg, rgba(0, 242, 254, 0.1), rgba(0, 242, 254, 0.05));
    border-color: rgba(0, 242, 254, 0.3);
}
.feature-aboutme:hover {
    background: linear-gradient(135deg, rgba(0, 242, 254, 0.2), rgba(0, 242, 254, 0.1));
    border-color: #00f2fe;
    box-shadow: 0 0 15px rgba(0, 242, 254, 0.4);
    transform: translateY(-3px) scale(1.02);
}
.feature-aboutme .bento-icon {
    color: #00f2fe;
    text-shadow: 0 0 10px rgba(0, 242, 254, 0.5);
}

/* Timeslot Feature */
.feature-timeslot {
    background: linear-gradient(135deg, rgba(76, 175, 80, 0.1), rgba(76, 175, 80, 0.05));
    border-color: rgba(76, 175, 80, 0.3);
}
.feature-timeslot:hover {
    background: linear-gradient(135deg, rgba(76, 175, 80, 0.2), rgba(76, 175, 80, 0.1));
    border-color: #4CAF50;
    box-shadow: 0 0 15px rgba(76, 175, 80, 0.4);
    transform: translateY(-3px) scale(1.02);
}
.feature-timeslot .bento-icon {
    color: #4CAF50;
    text-shadow: 0 0 10px rgba(76, 175, 80, 0.5);
}

/* Application Feature */
.feature-application {
    background: linear-gradient(135deg, rgba(225, 48, 108, 0.1), rgba(225, 48, 108, 0.05));
    border-color: rgba(225, 48, 108, 0.3);
}
.feature-application:hover {
    background: linear-gradient(135deg, rgba(225, 48, 108, 0.2), rgba(225, 48, 108, 0.1));
    border-color: #E1306C;
    box-shadow: 0 0 15px rgba(225, 48, 108, 0.4);
    transform: translateY(-3px) scale(1.02);
}
.feature-application .bento-icon {
    color: #E1306C;
    text-shadow: 0 0 10px rgba(225, 48, 108, 0.5);
}

.highlight-timeslot {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
}
.highlight-timeslot:hover {
    background: rgba(255, 255, 255, 0.15);
}

.feature-redugyzer {
    background: linear-gradient(135deg, rgba(255,255,255,0.05), rgba(0, 255, 200, 0.05));
}

.highlight-article {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.05), rgba(255, 100, 100, 0.05));
    flex-direction: column;
    align-items: flex-start;
    padding: 2rem;
}
.highlight-article .hero-icon {
    margin-bottom: 1rem;
    font-size: 2.5rem;
    color: #ffb74d; /* lightning yellow */
    margin-right: 0;
}
.highlight-article .btn-text {
    font-size: 1.2rem;
    font-weight: 600;
    line-height: 1.4;
}

/* Desktop Grid Adjustments */
@media (min-width: 768px) {
    .bento-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    .bento-item.square, .bento-item.portal {
        grid-column: span 1;
    }
    .bento-item.wide {
        grid-column: span 4;
    }
    .bento-item.hero {
        grid-column: span 4;
        flex-direction: row;
        align-items: center;
    }
    .bento-item.hero .hero-icon {
        margin-bottom: 0;
        margin-right: 2rem;
        font-size: 3rem;
    }
}

/* =========================================
   Footer
   ========================================= */
.footer {
    text-align: center;
    margin-top: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.join-link {
    display: inline-block;
    padding: 1rem 2rem;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    align-self: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.5);
    backdrop-filter: blur(5px);
}

.join-link:hover {
    transform: scale(1.05);
}

.footer-meta {
    font-size: 0.75rem;
    color: var(--text-primary);
    opacity: 0.7;
    line-height: 1.8;
}

.footer-meta a {
    color: var(--text-primary);
    text-decoration: none;
    transition: opacity 0.3s ease;
}

.footer-meta a:hover {
    opacity: 1;
    text-decoration: underline;
}

/* =========================================
   Share Modal
   ========================================= */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    z-index: 1000;
    display: flex;
    justify-content: center;
    align-items: flex-end; /* Bottom sheet on mobile */
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.share-modal {
    background: #111111;
    color: #ffffff;
    width: 100%;
    max-width: 500px;
    border-radius: 24px 24px 0 0;
    padding: 1.5rem 1.5rem 2rem 1.5rem;
    transform: translateY(100%);
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    box-shadow: 0 -10px 40px rgba(0,0,0,0.5);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

@media (min-width: 600px) {
    .modal-overlay {
        align-items: center;
    }
    .share-modal {
        border-radius: 24px;
        transform: translateY(50px) scale(0.95);
    }
}

.modal-overlay.active .share-modal {
    transform: translateY(0) scale(1);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.modal-header h2 {
    font-size: 1.2rem;
    font-weight: 700;
    margin: 0 auto;
    padding-left: 24px; /* balance the close button */
}

.close-btn {
    background: transparent;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    color: #aaaaaa;
    width: 32px;
    height: 32px;
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
    transition: background 0.2s, color 0.2s;
}

.close-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

.modal-profile-preview {
    background: #1a2a29; /* dark green/grey like the screenshot */
    border-radius: 16px;
    padding: 2rem 1rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #ffffff;
    margin-bottom: 1.5rem;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,0.1);
}

.modal-profile-preview img {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 1rem;
    border: 2px solid rgba(255,255,255,0.2);
}

.modal-profile-preview h3 {
    font-size: 1.4rem;
    font-weight: 500;
    margin-bottom: 0.3rem;
    letter-spacing: -0.3px;
}

.modal-profile-preview p {
    font-size: 0.85rem;
    font-weight: 400;
    opacity: 0.9;
    letter-spacing: 0.2px;
}

.modal-share-options {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
    padding-top: 0.8rem; /* Prevents top clipping on hover */
    padding-bottom: 0.8rem;
    scrollbar-width: none; /* Firefox */
}

.modal-share-options::-webkit-scrollbar {
    display: none; /* Chrome/Safari */
}

.share-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    background: transparent;
    border: none;
    text-decoration: none;
    color: #ffffff;
    cursor: pointer;
    min-width: 65px;
}

.share-icon-circle {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.2rem;
    color: #fff;
    transition: transform 0.2s;
}

.share-option:hover .share-icon-circle {
    transform: scale(1.05);
}

.share-icon-circle.copy { background: #333333; color: #ffffff; font-size: 1rem; }
.share-icon-circle.twitter { background: #000000; border: 1px solid rgba(255, 255, 255, 0.2); }
.share-icon-circle.facebook { background: #1877F2; }
.share-icon-circle.whatsapp { background: #25D366; }
.share-icon-circle.linkedin { background: #0077b5; }
.share-icon-circle.email { background: #ea4335; }

.share-option span {
    font-size: 0.75rem;
    font-weight: 500;
}

/* =========================================
   Toast Notification
   ========================================= */
.toast {
    position: fixed;
    bottom: -80px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(255, 255, 255, 0.95);
    color: #000;
    padding: 0.8rem 1.8rem;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 500;
    z-index: 2000;
    pointer-events: none;
    transition: bottom 0.4s cubic-bezier(0.25, 1, 0.5, 1), opacity 0.4s ease;
    opacity: 0;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(10px);
}
.toast.active {
    bottom: 40px;
    opacity: 1;
}

/* =========================================
   QR Code Modal
   ========================================= */
.qr-modal {
    background: #111111;
    color: #ffffff;
    width: 100%;
    max-width: 380px;
    border-radius: 24px;
    padding: 1.5rem;
    transform: translateY(50px) scale(0.95);
    transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
}
.modal-overlay.active .qr-modal {
    transform: translateY(0) scale(1);
}
.qr-container {
    background: #ffffff;
    border-radius: 16px;
    padding: 1.5rem;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 1rem 0;
}
.qr-container svg {
    width: 100%;
    max-width: 220px;
    height: auto;
}
.qr-hint {
    font-size: 0.8rem;
    opacity: 0.6;
    margin-top: 0.5rem;
}

/* =========================================
   Footer
   ========================================= */
.footer {
    text-align: center;
    margin-top: 1rem;
    padding-bottom: 1rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.2rem;
}
.footer-logo {
    display: flex;
    justify-content: center;
}
.logo-img {
    max-width: 180px;
    height: auto;
    opacity: 0.35;
    filter: invert(1);
    transition: opacity 0.3s ease;
}
.logo-img:hover {
    opacity: 0.6;
}
.footer-actions {
    display: flex;
    gap: 1rem;
}
.qr-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.4rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: rgba(255, 255, 255, 0.7);
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 400;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}
.qr-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.25);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}
.qr-btn i {
    font-size: 1rem;
}
.footer-meta {
    font-size: 0.7rem;
    color: var(--text-primary);
    opacity: 0.4;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.footer-meta a {
    color: var(--text-primary);
    text-decoration: none;
    transition: opacity 0.3s ease;
}
.footer-meta a:hover {
    opacity: 1;
    text-decoration: underline;
}
.footer-divider {
    opacity: 0.5;
}
