:root {
    --primary-color: #833ab4;
    /* Instagram Purple */
    --accent-color: #e1306c;
    /* Instagram Pink/Red */
    --vibrant-orange: #f56040;
    --bg-color: #ffffff;
    --text-color: #333333;
    --secondary-bg: #f8f8f8;
    --terminal-bg: #1a1a1a;
    --terminal-text: #27ae60;
    --card-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --border-radius: 12px;
    --neon-pink: #ff1867;
}

#ig-viewer-app-root {
    background: linear-gradient(135deg, #020C1F 0%, #061F4D 100%);
    background-attachment: fixed;
    color: #ffffff;
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
    font-family: 'Lexend', sans-serif;
    margin: 0;
    box-sizing: border-box;
    width: 100%;
}

#ig-viewer-app-root *,
#ig-viewer-app-root *::before,
#ig-viewer-app-root *::after {
    box-sizing: inherit;
}

.app-container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    padding: 22vh 20px 60px 20px;
    box-sizing: border-box;
    width: 100%;
}

/* --- UNLOCKED STATS BADGE (PILL DESIGN) --- */
.unlocked-stats-badge {
    background: #000000;
    /* Super dark/black as in pic */
    padding: 6px 20px 6px 6px;
    /* Less padding on icon side to match pill look */
    border-radius: 50px;
    /* Perfect Pill Shape */
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 2.5rem;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.08);
    /* Subtle border for definition */
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.unlocked-stats-badge:hover {
    transform: scale(1.03);
}

.badge-icon-check {
    background: linear-gradient(135deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #1a1a1a;
    /* Dark checkmark on gradient */
    font-size: 16px;
    position: relative;
    box-shadow: 0 0 15px rgba(220, 39, 67, 0.5);
    /* Glow matching gradient */
}

.badge-icon-check::after {
    content: '';
    position: absolute;
    inset: -2px;
    border-radius: 50%;
    background: inherit;
    filter: blur(8px);
    opacity: 0.4;
    z-index: -1;
}

.badge-text-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
}

.badge-label-text {
    color: #ffffff;
    font-size: 14px;
    font-weight: 500;
    font-family: 'Lexend', sans-serif;
    letter-spacing: 0.2px;
}

.badge-number-value {
    color: #ffffff;
    font-size: 16px;
    font-weight: 700;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.8), 0 0 20px rgba(255, 220, 128, 0.3);
    font-family: 'Lexend', sans-serif;
}

.main-header {
    margin-top: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
}

#ig-viewer-app-root.results-mode {
    background: radial-gradient(circle at top right, #fff9f9 0%, #f7f4f2 100%);
    background-attachment: fixed;
}

#ig-viewer-app-root.results-mode .app-container {
    justify-content: flex-start;
    padding-top: 1.5rem;
}

#ig-viewer-app-root.results-mode .main-header {
    margin-top: 0;
}

.title-monda {
    font-family: 'Roboto', sans-serif;
    font-weight: 800;
    font-size: 2.8rem;
    letter-spacing: -1px;
    color: #ffffff;
    margin: 0 auto 3.5rem auto;
    text-transform: uppercase;
    display: flex;
    flex-direction: column;
    align-items: center;
    line-height: 1.1;
    text-align: center;
    text-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.title-monda .line-1 {
    font-size: 3rem;
    letter-spacing: 2px;
    font-weight: 800;
}

.title-monda .line-2 {
    font-size: 3.4rem;
    margin-top: 0.3rem;
    letter-spacing: 4px;
    font-weight: 800;
}


#lock-shackle {
    transform-origin: left bottom;
    transition: transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.button-group {
    display: flex;
    justify-content: center;
    gap: 4rem;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.mode-selection,
.search-section {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.results-section {
    padding: 2rem 1rem;
    animation: fadeIn 0.8s cubic-bezier(0.23, 1, 0.32, 1);
    background: #fdfdfd;
    border-radius: 24px;
    max-width: 650px;
    width: 95%;
    margin: 2rem auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(0, 0, 0, 0.05);
    box-sizing: border-box;
}

/* Arcade Style Buttons */
.btn-arcade {
    text-transform: uppercase;
    letter-spacing: 0.15rem;
    padding: 18px 55px;
    /* Bigger buttons as requested */
    transition: all 0.4s ease;
    position: relative;
    font-size: 17px;
    background: #ffffff;
    border: none;
    color: #061F4D;
    cursor: pointer;
    border-radius: 50px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.btn-arcade:hover {
    letter-spacing: 0.15em;
    background: #f0f0f0;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 255, 255, 0.3);
}

.btn-arcade .btn-content {
    display: flex;
    align-items: center;
    gap: 12px;
}

.btn-arcade .btn-icon {
    font-size: 18px;
}

.btn-arcade::before {
    display: none;
}

.btn-arcade i {
    display: none;
}

.navbar-container {
    display: flex;
    justify-content: center;
    padding: 0.5rem;
    margin-top: 1rem;
}

.search-bar {
    display: flex;
    align-items: center;
    width: 100%;
    max-width: 650px;
    /* Shorter width for a cleaner look */
    background-color: #12141d;
    padding: 0.6rem 0.6rem 0.6rem 2rem;
    border-radius: 50px;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.4);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    border: 2px solid transparent;
    background-clip: padding-box;
}

/* Instagram Gradient Border on Hover/Focus */
.search-bar::after {
    content: '';
    position: absolute;
    inset: -2px;
    z-index: -1;
    background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
    border-radius: 42px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.search-bar:hover::after,
.search-bar:focus-within::after {
    opacity: 1;
}

.search-bar:focus-within {
    background-color: #0c0e15;
    box-shadow: 0 0 25px rgba(220, 39, 67, 0.2);
}

/* Hide Trigger until typing */
#search-go-wrap {
    opacity: 0;
    transform: scale(0.8);
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    /* Ensure it stays flex when shown */
}

#search-go-wrap.show-trigger {
    opacity: 1;
    transform: scale(1);
    pointer-events: auto;
}

.border-v {
    width: 1px;
    height: 24px;
    background-color: #3a3b43;
    margin: 0 0.5rem 0 1rem;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.show-trigger+.border-v,
.search-bar:has(.show-trigger) .border-v {
    opacity: 1;
}

.InputContainer {
    display: flex;
    align-items: center;
    flex-grow: 1;
    gap: 1rem;
}

.input {
    flex: 1;
    border: none;
    outline: none;
    font-size: 1.1rem;
    background: none;
    color: #f0f0f0;
    padding: 0.5rem 0;
    font-family: 'Monda', sans-serif;
}

.input::placeholder {
    color: #8a8a8a;
    opacity: 1;
    transition: opacity 0.2s ease;
}



#lock-icon-container {
    display: flex;
    align-items: center;
    transition: all 0.5s ease;
}

.search-bar:focus-within #lock-icon path,
.search-bar:focus-within #lock-icon rect {
    stroke: #833ab4;
}

/* Custom Search Checkbox (Search Trigger) */
.container {
    display: block;
    position: relative;
    cursor: pointer;
    font-size: 20px;
    user-select: none;
}

.container input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.checkmark {
    position: relative;
    top: 0;
    left: 0;
    height: 2.6em;
    width: 2.6em;
    background: #000;
    border-radius: 50%;
    transition: all 0.7s;
    --spread: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #333;
}

.container input:checked~.checkmark {
    background: #000;
    box-shadow:
        -10px -10px var(--spread) 0px #5B51D8,
        0 -10px var(--spread) 0px #833AB4,
        10px -10px var(--spread) 0px #E1306C,
        10px 0 var(--spread) 0px #FD1D1D,
        10px 10px var(--spread) 0px #F77737,
        0 10px var(--spread) 0px #FCAF45,
        -10px 10px var(--spread) 0px #FFDC80;
}

.checkmark:after {
    content: "";
    position: absolute;
    display: none;
}

.container input:checked~.checkmark:after {
    display: block;
}

.container .checkmark:after {
    left: 50%;
    top: 45%;
    width: 0.25em;
    height: 0.6em;
    border: solid #ffffff;
    border-width: 0 0.15em 0.15em 0;
    transform: translate(-50%, -50%) rotate(45deg);
}

.search-btn-icon {
    transition: opacity 0.3s ease;
    width: 22px;
    height: 22px;
}

.container input:checked~.checkmark .search-btn-icon {
    opacity: 0;
}


.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    color: white;
    border: none;
    padding: 0.8rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    transform: scale(1.03);
    box-shadow: 0 4px 12px rgba(155, 89, 182, 0.3);
}

.btn-secondary {
    background-color: #eee;
    color: #333;
    border: none;
    padding: 0.8rem 2rem;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 2rem;
}

/* Cyber Terminal Full-Screen Overhaul */
.terminal-section {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: #0a0a0f !important;
    z-index: 5000;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Share Tech Mono', monospace;
    overflow: hidden;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
}

#matrix-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.2;
    z-index: 1;
}

.grid-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(rgba(0, 255, 65, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 255, 65, 0.03) 1px, transparent 1px);
    background-size: 40px 40px;
    z-index: 2;
    pointer-events: none;
}

.scanlines {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(0deg,
            transparent,
            transparent 2px,
            rgba(0, 0, 0, 0.15) 2px,
            rgba(0, 0, 0, 0.15) 4px);
    z-index: 3;
    animation: scanMove 8s linear infinite;
}

@keyframes scanMove {
    0% {
        background-position: 0 0;
    }

    100% {
        background-position: 0 100px;
    }
}

.terminal-wrapper {
    position: relative;
    z-index: 10;
    width: 720px;
    max-width: 95vw;
}

.terminal-header {
    background: linear-gradient(90deg, #0d1117, #0f2027);
    border: 1px solid #00ff41;
    border-bottom: none;
    padding: 12px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
}

.header-dots {
    display: flex;
    gap: 8px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.dot.red {
    background: #ff5f57;
    box-shadow: 0 0 6px #ff5f57;
}

.dot.yellow {
    background: #ffbd2e;
    box-shadow: 0 0 6px #ffbd2e;
}

.dot.green {
    background: #28ca41;
    box-shadow: 0 0 6px #28ca41;
}

.header-title {
    font-family: 'Orbitron', sans-serif;
    font-size: 12px;
    font-weight: 700;
    color: #00ff41;
    letter-spacing: 3px;
    text-transform: uppercase;
}

.terminal-body {
    background: rgba(10, 12, 16, 0.98);
    border: 1px solid #00ff41;
    border-top: none;
    padding: 30px;
    min-height: 420px;
    max-height: 80vh;
    overflow-y: auto;
    position: relative;
    box-shadow: 0 0 50px rgba(0, 255, 65, 0.1);
}

.log-line {
    display: flex;
    gap: 12px;
    margin-bottom: 12px;
    opacity: 0;
    transform: translateX(-15px);
    transition: all 0.3s;
    font-size: 14px;
    color: #00ff41;
}

.log-line.visible {
    opacity: 1;
    transform: translateX(0);
}

.prefix {
    color: #00d4ff;
    font-weight: bold;
    text-shadow: 0 0 5px #00d4ff;
}

.prefix.success {
    color: #00ff41;
    text-shadow: 0 0 5px #00ff41;
}

.progress-container {
    margin: 10px 0 10px 40px;
    opacity: 0;
    transition: 0.3s;
}

.progress-container.visible {
    opacity: 1;
}

.progress-bar {
    width: 100%;
    height: 5px;
    background: rgba(0, 255, 65, 0.1);
    border-radius: 3px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #00ff41, #00d4ff);
    width: 0%;
    transition: width 0.1s linear;
}

.progress-text {
    font-size: 11px;
    color: rgba(0, 255, 65, 0.6);
    margin-top: 5px;
    text-align: right;
}

.ip-display {
    position: absolute;
    top: 30px;
    right: 30px;
    color: rgba(0, 255, 65, 0.4);
    font-size: 11px;
    text-align: right;
    z-index: 100;
}

.stats-bar {
    position: absolute;
    left: 30px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 25px;
    z-index: 100;
}

.cyber-stat-item {
    font-size: 11px;
    color: rgba(0, 255, 65, 0.3);
    writing-mode: vertical-rl;
    letter-spacing: 2px;
}

.final-banner {
    margin-top: 25px;
    padding: 15px;
    border: 1px solid #00ff41;
    background: rgba(0, 255, 65, 0.05);
    opacity: 0;
    transform: scaleX(0);
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    font-family: 'Orbitron', sans-serif;
    font-size: 13px;
    color: #00ff41;
    text-align: center;
    box-shadow: 0 0 20px rgba(0, 255, 65, 0.2);
}

.final-banner.visible {
    opacity: 1;
    transform: scaleX(1);
}

.cursor {
    display: inline-block;
    width: 8px;
    height: 16px;
    background: #00ff41;
    margin-left: 5px;
    animation: blink 1s step-end infinite;
}

@keyframes blink {
    50% {
        opacity: 0;
    }
}

@keyframes fadeOutTerminal {
    from {
        opacity: 1;
        transform: scale(1);
    }

    to {
        opacity: 0;
        transform: scale(1.1);
        filter: blur(20px);
    }
}

.terminal-closing {
    animation: fadeOutTerminal 0.8s forwards;
}

/* Results Section */
.profile-card {
    margin-top: 3rem;
    background-color: rgba(155, 89, 182, 0.05);
    /* Soft purple tint */
    border-radius: var(--border-radius);
    padding: 2.5rem;
    box-shadow: var(--card-shadow);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

#profile-pic-container {
    width: 150px;
    height: 150px;
    margin: 0 auto 2rem;
    /* Fixed syntax error */
    border-radius: 50%;
    padding: 5px;
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

#profile-pic {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid white;
    display: block;
}

/* Profile Card Authentic White Look */
.premium-card {
    background: #ffffff;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    position: relative;
    overflow: hidden;
    border: 1px solid #efefef;
    margin-bottom: 2rem;
    width: 100%;
    box-sizing: border-box;
    font-family: 'Lexend', sans-serif;
}

.premium-card::before {
    display: none;
}

.card-header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    margin-bottom: 5px;
}

.header-username {
    font-weight: 700;
    font-size: 1.1rem;
    color: #262626;
}

.back-arrow,
.header-options {
    font-size: 1.2rem;
    color: #262626;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
}

.back-arrow:hover {
    background: #fafafa;
    transform: translateX(-5px);
    color: #0095f6;
}

.header-options:hover {
    background: #fafafa;
    transform: scale(1.1);
}

@keyframes arrowPulse {
    0% {
        transform: translateX(0);
    }

    50% {
        transform: translateX(-3px);
    }

    100% {
        transform: translateX(0);
    }
}

.back-arrow i {
    animation: arrowPulse 2s infinite ease-in-out;
}

.back-arrow:hover i {
    animation: none;
}

.card-header-sub {
    display: flex;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.time-badge {
    background: #fafafa;
    color: #8e8e8e;
    padding: 4px 12px;
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 500;
    border: 1px solid #efefef;
}

.profile-main {
    text-align: center;
    margin-bottom: 3rem;
}

.profile-name {
    font-size: 2rem;
    font-weight: 800;
    color: #1a1a1a;
    margin-top: 1.5rem;
    letter-spacing: -0.5px;
}

.profile-username {
    color: #8e8e8e;
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    font-weight: 500;
}

.profile-bio {
    font-size: 1rem;
    color: #4a4a4a;
    max-width: 450px;
    margin: 0 auto;
    line-height: 1.5;
    font-weight: 400;
}

.stats-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-bottom: 3.5rem;
}

.stat-box {
    text-align: center;
    padding: 1rem;
}

.stat-box span {
    display: block;
    font-size: 1.6rem;
    font-weight: 800;
    color: #1a1a1a;
}

.stat-box label {
    font-size: 0.85rem;
    color: #8e8e8e;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

.modern-insights {
    background: #fafafa;
    border-radius: 20px;
    padding: 2rem;
    margin-top: 1.5rem;
}

.insight-title {
    font-size: 0.9rem;
    font-weight: 700;
    color: #1a1a1a;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1.5rem;
    text-align: left;
}

.insight-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.insight-card {
    background: #fff;
    padding: 1.2rem;
    border-radius: 15px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
    border: 1px solid rgba(0, 0, 0, 0.02);
}

.insight-label {
    display: block;
    font-size: 0.75rem;
    color: #8e8e8e;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.insight-value {
    display: block;
    font-size: 1.1rem;
    font-weight: 700;
    color: #cc2366;
}

.feature-pills {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-top: 2.5rem;
}

.pill {
    background: #fff;
    border: 1px solid #efefef;
    padding: 8px 18px;
    border-radius: 100px;
    font-size: 0.85rem;
    color: #262626;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* --- LOCKED CONTENT STYLES --- */
.locked-content {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding-top: 1rem;
    animation: fadeIn 0.5s ease;
}

.locked-info-header {
    text-align: center;
    margin-bottom: 0.5rem;
}

.locked-title {
    font-size: 1rem;
    font-weight: 700;
    color: #262626;
    margin-bottom: 5px;
}

.locked-text {
    font-size: 0.85rem;
    color: #8e8e8e;
    line-height: 1.4;
    padding: 0 1rem;
}

.locked-section {
    border-top: 1px solid #efefef;
    padding-top: 10px;
}

.locked-label {
    font-size: 0.85rem;
    font-weight: 700;
    color: #262626;
    margin-bottom: 10px;
    letter-spacing: 0.3px;
}

.locked-stories-row {
    display: flex;
    gap: 15px;
    overflow-x: auto;
    padding: 5px 0 10px;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.locked-stories-row::-webkit-scrollbar {
    display: none;
}

.blurred-story {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: #f0f0f0;
    border: 2px solid #dbdbdb;
    flex-shrink: 0;
    filter: blur(5px);
    background-size: cover;
    background-position: center;
}

/* Variety in story colors */
.locked-stories-row .blurred-story:nth-child(1) {
    background-image: url('../images/p1.png');
    filter: blur(4px);
}

.locked-stories-row .blurred-story:nth-child(2) {
    background-image: url('../images/p2.png');
    filter: blur(5px);
}

.locked-stories-row .blurred-story:nth-child(3) {
    background-image: url('../images/p3.png');
    filter: blur(6px);
}

.locked-stories-row .blurred-story:nth-child(4) {
    background-image: url('../images/p4.png');
    filter: blur(5px);
}

.locked-stories-row .blurred-story:nth-child(5) {
    background-image: url('../images/p5.png');
    filter: blur(4px);
}

.locked-stories-row .blurred-story:nth-child(6) {
    background-image: url('../images/p6.png');
    filter: blur(5px);
}

.blurred-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3px;
}

.blurred-post {
    aspect-ratio: 1/1;
    filter: blur(18px);
    /* Softer, more realistic IG blur */
    border-radius: 0;
    position: relative;
    overflow: hidden;
    background-color: #f0f0f0;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
}

.blurred-post i {
    color: white;
    font-size: 1.5rem;
    opacity: 0.6;
    filter: blur(2px);
    /* Softer icon for the 'private' look */
}

/* Simulate blurred content colors from image */
.blurred-post.p1 {
    background-image: url('../images/p1.png');
}

.blurred-post.p2 {
    background-image: url('../images/p2.png');
}

.blurred-post.p3 {
    background-image: url('../images/p3.png');
}

.blurred-post.p4 {
    background-image: url('../images/p4.png');
}

.blurred-post.p5 {
    background-image: url('../images/p5.png');
}

.blurred-post.p6 {
    background-image: url('../images/p6.png');
}

.locked-action {
    display: flex;
    justify-content: center;
    margin-top: 1.5rem;
    border-bottom: 2px solid #efefef;
    padding-bottom: 1.5rem;
}

.btn-primary-ig {
    background-color: #0095f6;
    color: white;
    border: none;
    padding: 10px 24px;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s;
}

.btn-primary-ig:hover {
    background-color: #1877f2;
}

.btn-primary-ig:active {
    transform: scale(0.98);
}

.blurred-post.unlocked {
    filter: none;
}

.blurred-post.unlocked::after {
    display: none;
}

/* Verification Puzzle */
.verification-section {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.98);
    z-index: 1000;
    display: flex;
    justify-content: center;
    align-items: center;
    backdrop-filter: blur(10px);
}

.puzzle-container {
    background: white;
    padding: 3rem;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    max-width: 500px;
    width: 90%;
    text-align: center;
}

.puzzle-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin: 1.5rem 0;
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
}

.puzzle-tile {
    aspect-ratio: 1/1;
    background-color: #f0f0f0;
    border: 1px solid #ddd;
    border-radius: 4px;
    cursor: grab;
    user-select: none;
    transition: transform 0.2s, box-shadow 0.2s;
    background-size: 400% 400%;
    /* Total grid size since it's 4x4 */
}

.puzzle-tile:hover {
    transform: scale(1.02);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    z-index: 10;
}

.puzzle-tile.dragging {
    opacity: 0.5;
    transform: scale(1.05);
}

.reference-image {
    width: 100px;
    height: 100px;
    background-image: url('https://upload.wikimedia.org/wikipedia/commons/a/a5/Instagram_icon.png');
    background-size: cover;
    margin: 1rem auto;
    border-radius: 12px;
    opacity: 0.6;
    border: 1px dashed #ccc;
}

.timer-container {
    font-size: 1.2rem;
    margin-top: 1rem;
    font-weight: 600;
}

#timer-display {
    color: #e74c3c;
    font-size: 1.5rem;
}

/* Helper Classes */
.hidden {
    display: none !important;
}

.error-text {
    color: #e74c3c;
    margin-top: 1rem;
    font-size: 0.9rem;
}

/* Loading State */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.8);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 5px solid #f3f3f3;
    border-top: 5px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1rem;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

@media (max-width: 600px) {
    #ig-viewer-app-root .app-container {
        padding: 1rem;
    }

    /* Only make it full-screen when results are showing */
    #ig-viewer-app-root.results-mode .app-container {
        padding: 10px 0 !important;
        width: 100% !important;
    }

    .main-header h1 {
        font-size: 1.8rem;
    }

    .search-container {
        flex-direction: column;
        width: 100%;
        padding: 1rem;
    }

    .search-container input {
        width: 100%;
    }

    .results-section {
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 !important;
        border-radius: 0 !important;
        padding: 0 !important;
        box-shadow: none !important;
        border: none !important;
    }

    .premium-card {
        padding: 1.5rem 12px !important;
        margin-bottom: 0 !important;
        border-radius: 0 !important;
        box-shadow: none !important;
        border-left: none !important;
        border-right: none !important;
    }

    .profile-header-top {
        gap: 1rem !important;
    }

    .avatar-wrap {
        width: 75px !important;
        height: 75px !important;
    }

    #profile-pic {
        width: 65px !important;
        height: 65px !important;
    }

    .stat-value {
        font-size: 1.1rem !important;
    }

    .stat-label {
        font-size: 0.7rem !important;
    }

    .action-buttons {
        gap: 5px !important;
    }

    .btn-action {
        font-size: 0.8rem !important;
        padding: 8px 0 !important;
    }

    .insights-grid {
        grid-template-columns: repeat(3, 1fr) !important;
        gap: 5px !important;
    }

    .insight-box {
        padding: 10px 5px !important;
    }

    .insight-value {
        font-size: 0.9rem !important;
    }

    .puzzle-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 6px;
    }

    #btn-back {
        width: 90% !important;
        margin: 20px auto !important;
        display: block !important;
    }
}


/* --- AUTHENTIC INSTAGRAM LAYOUT --- */
.profile-main-info {
    text-align: left;
}

.profile-header-top {
    display: flex;
    align-items: center;
    gap: 2rem;
    margin-bottom: 1.5rem;
}

.avatar-wrap {
    position: relative;
    width: 85px;
    /* Slightly larger for better detail */
    height: 85px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

#profile-pic {
    width: 75px;
    height: 75px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #fff;
    display: block;
    z-index: 2;
    position: relative;
}

.story-ring {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    padding: 3px;
    /* Space for the gradient ring */
    background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
    -webkit-mask:
        linear-gradient(#fff 0 0) content-box,
        linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask:
        linear-gradient(#fff 0 0) content-box,
        linear-gradient(#fff 0 0);
    mask-composite: exclude;
    pointer-events: none;
    z-index: 1;
}

.stats-grid {
    display: flex;
    justify-content: space-around;
    flex-grow: 1;
    background: none;
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat-value {
    font-size: 1.25rem;
    font-weight: 800;
    color: #262626;
    letter-spacing: -0.3px;
}

.stat-label {
    font-size: 0.8rem;
    color: #737373;
    font-weight: 500;
    margin-top: 2px;
}

.highlights-container {
    display: flex;
    gap: 15px;
    overflow-x: auto;
    padding: 10px 1rem 20px;
    margin-bottom: 0.5rem;
    scrollbar-width: none;
}

.highlights-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 65px;
}

.highlight-cover {
    width: 55px;
    height: 55px;
    border-radius: 50%;
    border: 1px solid #dbdbdb;
    padding: 3px;
    margin-bottom: 5px;
    object-fit: cover;
    background: #fff;
}

.highlight-title {
    font-size: 0.7rem;
    color: #262626;
    text-align: center;
    width: 65px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.profile-bio-section {
    margin-bottom: 1.5rem;
}

.name-row {
    display: flex;
    align-items: center;
    gap: 5px;
}

#full-name-display {
    font-size: 1.05rem;
    font-weight: 800;
    margin: 0;
    color: #262626;
}

.profile-category {
    font-size: 0.85rem;
    color: #737373;
    margin: 2px 0;
    font-weight: 600;
}

.bio-text {
    font-size: 0.95rem;
    line-height: 1.6;
    white-space: pre-wrap;
    margin: 10px 0;
    color: #262626;
    font-weight: 600;
}

.external-link {
    font-size: 0.9rem;
    color: #4a6fa5;
    text-decoration: none;
    font-weight: 500;
    font-family: 'Lexend', sans-serif;
}

.action-buttons {
    display: flex;
    gap: 8px;
    margin-bottom: 2rem;
}

.btn-action {
    flex: 1;
    border: none;
    border-radius: 8px;
    padding: 8px 0;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    background: #efefef;
    color: #262626;
    transition: background 0.2s;
}

.btn-action.follow {
    background: #0095f6;
    color: #ffffff;
}

.btn-action.follow:hover {
    background: #1877f2;
}

/* Insights */
.insights-divider {
    height: 1px;
    background: #efefef;
    margin: 20px 0;
}

.insights-title {
    font-size: 0.8rem;
    font-weight: 700;
    color: #8e8e8e;
    text-align: center;
    margin-bottom: 15px;
}

.insights-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 20px;
}

.insight-box {
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(5px);
    padding: 12px;
    border-radius: 12px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.8);
    transition: transform 0.3s ease;
}

.insight-box:hover {
    transform: translateY(-3px);
    background: rgba(255, 255, 255, 0.8);
}

.insight-label {
    display: block;
    font-size: 0.7rem;
    color: #555;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.insight-value {
    display: block;
    font-size: 1rem;
    font-weight: 700;
    color: #1a1a1a;
    margin-top: 4px;
}

.btn-action:hover {
    background: #dbdbdb;
}

.btn-action.small-add {
    flex: 0 0 32px;
}

/* Tabs */
.profile-tabs {
    display: flex;
    border-top: 1px solid #efefef;
    margin-bottom: 1rem;
}

.tab-item {
    flex: 1;
    display: flex;
    justify-content: center;
    padding: 12px 0;
    color: #8e8e8e;
    cursor: pointer;
}

.tab-item.active {
    color: #262626;
    border-top: 1px solid #262626;
    margin-top: -1px;
}

/* Posts */
.posts-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 3px;
    width: 100%;
    margin-top: 10px;
}

.post-card {
    aspect-ratio: 1/1;
    position: relative;
    cursor: pointer;
    background: #efefef;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.post-card img,
.post-card video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.video-overlay {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 5;
    color: white;
    font-size: 1rem;
    pointer-events: none;
    text-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
    opacity: 0.9;
}

.post-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.3);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.2s;
    pointer-events: none;
    gap: 10px;
}

.post-card:hover .post-overlay {
    opacity: 1;
}

.overlay-info {
    display: flex;
    gap: 15px;
    color: white;
    font-weight: 700;
    font-size: 1rem;
}

.overlay-info span {
    display: flex;
    align-items: center;
    gap: 5px;
}

.btn-view-likes {
    background: rgba(255, 255, 255, 0.9);
    border: none;
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 700;
    color: #262626;
    cursor: pointer;
    pointer-events: auto;
    transition: background 0.2s, transform 0.1s;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.btn-view-likes:hover {
    background: #ffffff;
    transform: scale(1.05);
}

.btn-view-likes:active {
    transform: scale(0.95);
}

/* Likes Modal */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 10000;
    display: flex;
    justify-content: center;
    align-items: center;
}

.modal-content {
    background: white;
    width: 90%;
    max-width: 400px;
    border-radius: 12px;
    overflow: hidden;
    animation: zoomIn 0.3s ease-out;
}

.modal-header {
    border-bottom: 1px solid #efefef;
    padding: 12px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-title {
    font-weight: 700;
    margin: 0;
}

.modal-body {
    padding: 15px;
    max-height: 300px;
    overflow-y: auto;
}

.like-item {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}

.like-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #efefef;
}

.like-name {
    font-weight: 600;
    font-size: 0.9rem;
}

@keyframes zoomIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* ===== MOBILE RESPONSIVE: Title & Description Fix ===== */
@media screen and (max-width: 768px) {
    .title-monda {
        max-width: 100%;
        padding: 0 20px;
        box-sizing: border-box;
        word-wrap: break-word;
        overflow-wrap: break-word;
        text-align: center;
        align-items: center;
    }

    .title-monda .line-1 {
        font-size: 1.5rem;
        letter-spacing: 1px;
        line-height: 1.3;
        max-width: 100%;
        word-wrap: break-word;
        overflow-wrap: break-word;
        text-align: center;
    }

    .title-monda .line-2 {
        font-size: 2rem;
        letter-spacing: 2px;
        text-align: center;
    }

    .description-lines {
        max-width: 100%;
        padding: 0 20px;
        box-sizing: border-box;
    }

    /* ALL description lines same size - no inconsistency */
    .desc-line-1,
    .desc-line-2,
    .desc-line-3 {
        max-width: 100%;
        word-wrap: break-word;
        overflow-wrap: break-word;
        hyphens: auto;
        line-height: 1.7;
        font-size: 0.95rem;
        text-align: center;
        padding: 0 4px;
    }

    .button-group {
        gap: 1.5rem;
    }
}

@media screen and (max-width: 480px) {
    .title-monda .line-1 {
        font-size: 1.25rem;
        letter-spacing: 0.5px;
    }

    .title-monda .line-2 {
        font-size: 1.7rem;
        letter-spacing: 1.5px;
    }

    .description-lines {
        padding: 0 16px;
    }

    /* ALL description lines same size on small screens too */
    .desc-line-1,
    .desc-line-2,
    .desc-line-3 {
        font-size: 0.88rem;
        line-height: 1.7;
        padding: 0 2px;
    }
}

.error-text {
    background: rgba(231, 76, 60, 0.1);
    color: #e74c3c;
    padding: 12px 20px;
    border-radius: 12px;
    margin-top: 1.5rem;
    font-size: 0.9rem;
    font-weight: 600;
    border: 1px solid rgba(231, 76, 60, 0.2);
    display: flex;
    align-items: center;
    gap: 10px;
    animation: slideInUp 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    max-width: 400px;
    text-align: center;
}

.error-text::before {
    content: '\f071';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

 