@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');

@import url("https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.0/css/all.min.css");

/* Reset and Base Styles */
        button,
        html input[type="button"],
        input[type="reset"],
        input[type="submit"] {
            padding: 0px;
        }

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

        .wrapper {
            font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
            background: linear-gradient(135deg, #1e3c72 0%, #2a5298 50%, #1e3c72 100%);
            min-height: 100vh;
            line-height: 1.6;
            position: relative;
            overflow-x: hidden;
        }

        .wrapper::before {
            content: '';
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: 
                radial-gradient(circle at 20% 80%, rgba(59, 130, 246, 0.15) 0%, transparent 50%),
                radial-gradient(circle at 80% 20%, rgba(139, 92, 246, 0.15) 0%, transparent 50%),
                radial-gradient(circle at 40% 40%, rgba(16, 185, 129, 0.1) 0%, transparent 50%);
            pointer-events: none;
        }

        .main-contain {
            max-width: 1200px;
            margin: 0 auto;
            padding: 20px;
            position: relative;
            z-index: 1;
        }

        /* Professional Instagram Tool Wrapper */
        .ig-tool-wrapper {
            width: 100%;
            margin: 20px auto;
            padding: 40px;
            border-radius: 24px;
            background: rgba(255, 255, 255, 0.98);
            backdrop-filter: blur(20px);
            border: 2px solid rgba(59, 130, 246, 0.2);
            color: #1e293b;
            text-align: center;
            box-shadow: 
                0 25px 50px rgba(0, 0, 0, 0.15),
                0 0 0 1px rgba(59, 130, 246, 0.1);
            position: relative;
            overflow: hidden;
        }

        .ig-tool-wrapper::before {
            content: "";
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: linear-gradient(135deg, rgba(59, 130, 246, 0.05) 0%, rgba(139, 92, 246, 0.05) 100%);
            pointer-events: none;
        }


        .ig-header h3 {
            font-size: 42px;
            font-weight: 700;
            background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 50%, #ec4899 100%);
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            background-clip: text;
            margin-bottom: 20px;
            letter-spacing: -1px;
            text-shadow: none;
            position: relative;
            z-index: 2;
            display: inline-block;
        }

        .viewer-anonymous {
            background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 50%, #ec4899 100%);
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
            background-clip: text;
            position: relative;
            display: inline-block;
        }

        .viewer-anonymous::after {
            content: "";
            position: absolute;
            bottom: -8px;
            left: 0;
            width: 100%;
            height: 4px;
            background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 50%, #ec4899 100%);
            border-radius: 2px;
            animation: underlineGlow 2s ease-in-out infinite alternate;
        }

        @keyframes underlineGlow {
            0% {
                opacity: 0.7;
                transform: scaleX(0.95);
            }
            100% {
                opacity: 1;
                transform: scaleX(1.05);
            }
        }

        .ig-header p {
            font-size: 18px;
            margin: 20px 0 30px;
            line-height: 1.7;
            font-weight: 400;
            color: #4a5568;
            max-width: 700px;
            margin-left: auto;
            margin-right: auto;
            position: relative;
            z-index: 2;
        }

        /* Professional Input Area */
        .ig-input-area {
            display: flex;
            align-items: center;
            background: rgba(255, 255, 255, 0.9);
            backdrop-filter: blur(10px);
            padding: 30px 25px;
            border-radius: 20px;
            gap: 20px;
            margin: 0 auto;
            max-width: 100%;
            flex-wrap: wrap;
            box-shadow: 
                0 15px 35px rgba(0, 0, 0, 0.1),
                0 0 0 2px rgba(59, 130, 246, 0.1);
            position: relative;
            border: 2px solid rgba(59, 130, 246, 0.2);
        }

        .ig-icon {
            font-size: 16px;
            color: #4a5568;
            font-weight: 600;
            width: 100%;
            text-align: left;
            margin-bottom: 15px;
            position: relative;
            z-index: 2;
        }

        .ig-input-area input {
            flex-grow: 1;
            padding: 16px 20px;
            font-size: 16px;
            border: 2px solid #3b82f6;
            outline: none;
            min-width: 200px;
            background: transparent;
            border-radius: 12px;
            transition: all 0.3s ease;
            color: #1e293b;
            font-weight: 500;
            position: relative;
            z-index: 2;
        }

        .ig-input-area input:focus {
            background: rgba(59, 130, 246, 0.05);
            border-color: #1e40af;
            box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1);
            transform: translateY(-1px);
        }

        .error-container {
            margin-top: 25px;
            position: absolute;
            bottom: -60px;
            left: 20px;
            right: 20px;
        }

        #error-message {
            color: #e53935;
            margin-top: 25px;
            display: none;
            font-weight: 500;
        }

        .paste-btn,
        .view-btn {
            border: 2px solid transparent;
            border-radius: 12px;
            padding: 16px 24px;
            cursor: pointer;
            font-weight: 600;
            transition: all 0.3s ease;
            display: flex;
            align-items: center;
            gap: 10px;
            font-size: 15px;
            margin-bottom: 15px;
            position: relative;
            z-index: 2;
            text-transform: none;
            letter-spacing: 0.5px;
            background-clip: padding-box;
        }

        .paste-btn {
            background: linear-gradient(135deg, #3b82f6 0%, #1e40af 100%);
            color: white;
            box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
            border: 2px solid #3b82f6;
        }

        .paste-btn:hover {
            background: linear-gradient(135deg, #1e40af 0%, #1e3a8a 100%);
            border-color: #1e40af;
            transform: translateY(-2px);
            box-shadow: 0 8px 25px rgba(59, 130, 246, 0.4);
        }

        .view-btn {
            background: linear-gradient(135deg, #8b5cf6 0%, #7c3aed 100%);
            color: white;
            box-shadow: 0 4px 15px rgba(139, 92, 246, 0.3);
            border: 2px solid #8b5cf6;
        }

        .view-btn:hover {
            background: linear-gradient(135deg, #7c3aed 0%, #6d28d9 100%);
            border-color: #7c3aed;
            transform: translateY(-2px);
            box-shadow: 0 8px 25px rgba(139, 92, 246, 0.4);
        }

        .view-btn:disabled {
            opacity: 0.6;
            cursor: not-allowed;
            transform: none;
            background: #cbd5e1;
            border-color: #cbd5e1;
            box-shadow: none;
        }

        /* Ad Space */
        .ad-space {
            display: none;
            margin-top: 20px;
            text-align: center;
            position: relative;
            border-radius: 16px;
            overflow: hidden;
            padding: 6px;
            background: linear-gradient(135deg, #e53935, #1e88e5 35%, #8e24aa 70%, #ec407a);
            background-size: 300% 300%;
            animation: gradientBorder 6s ease infinite;
        }

        @keyframes gradientBorder {
            0% {
                background-position: 0% 50%;
            }

            50% {
                background-position: 100% 50%;
            }

            100% {
                background-position: 0% 50%;
            }
        }

        .ad-inner {
            border-radius: 12px;
            overflow: hidden;
            background-color: #fff;
            box-shadow: 0 10px 24px rgba(0, 0, 0, 0.1);
            transition: transform 0.3s ease;
            animation: floatAd 5s ease-in-out infinite;
        }

        @keyframes floatAd {

            0%,
            100% {
                transform: translateY(0px);
            }

            50% {
                transform: translateY(-5px);
            }
        }

        .ad-placeholder {
            display: block;
            position: relative;
            text-decoration: none;
            color: inherit;
        }

        .ad-placeholder::before {
            content: "Sponsored";
            position: absolute;
            top: 12px;
            left: 12px;
            background-color: #fff;
            color: #ec407a;
            font-size: 12px;
            font-weight: 600;
            padding: 3px 10px;
            border-radius: 5px;
            box-shadow: 0 1px 6px rgba(0, 0, 0, 0.15);
            animation: pulseTag 2s infinite;
            z-index: 2;
        }

        @keyframes pulseTag {
            0% {
                transform: scale(1);
                opacity: 1;
            }

            50% {
                transform: scale(1.05);
                opacity: 0.85;
            }

            100% {
                transform: scale(1);
                opacity: 1;
            }
        }

        .ad-image {
            width: 100%;
            height: auto;
            display: block;
            transition: transform 0.4s ease;
        }

        .ad-placeholder:hover .ad-image {
            animation: wiggle 0.4s ease;
            transform: scale(1.04);
        }

        @keyframes wiggle {
            0% {
                transform: rotate(0deg);
            }

            25% {
                transform: rotate(1.5deg);
            }

            50% {
                transform: rotate(-1.5deg);
            }

            75% {
                transform: rotate(1.5deg);
            }

            100% {
                transform: rotate(0deg);
            }
        }

        .note {
            font-size: 14px;
            color: rgba(255, 255, 255, 0.8);
            margin-top: 15px;
            font-style: italic;
        }

        /* Result Section */
        .tools-result {
            width: 100%;
            margin-top: 60px;
        }

        .ig-result {
            margin-top: 30px;
            background: white;
            border-radius: 20px;
            padding: 30px;
            color: #333;
            box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
            animation: fadeIn 0.5s ease-out;
        }

        /* Profile Header */
        .ig-profile-header {
            margin-bottom: 40px;
            position: relative;
            background: linear-gradient(to bottom, #f9fafb, #ffffff);
            border-radius: 16px;
            padding: 30px;
            box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
            border: 1px solid #f1f5f9;
        }

        .profile-header-content {
            display: flex;
            align-items: center;
            gap: 30px;
            flex-wrap: wrap;
        }

        .profile-image-container {
            position: relative;
            flex-shrink: 0;
        }

        .profile-image {
            width: 150px;
            height: 150px;
            border-radius: 50%;
            object-fit: cover;
            border: 4px solid white;
            box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
            transition: transform 0.3s;
            background: linear-gradient(to bottom right, #1e88e5, #ec407a);
            padding: 3px;
            min-height: 150px;
            min-width: 150px;
            display: flex;
            align-items: center;
            justify-content: center;
            color: #94a3b8;
            font-size: 60px;
        }

        .profile-image:hover {
            transform: scale(1.03);
        }

        .view-profile-img {
            position: absolute;
            bottom: 5px;
            right: 5px;
            background-color: #1e88e5;
            color: white;
            border: none;
            border-radius: 50%;
            width: 36px;
            height: 36px;
            display: flex;
            justify-content: center;
            align-items: center;
            cursor: pointer;
            transition: all 0.3s;
            box-shadow: 0 5px 15px rgba(30, 136, 229, 0.3);
            z-index: 5;
        }

        .view-profile-img:hover {
            transform: scale(1.1) rotate(15deg);
            background-color: #1a75c6;
        }

        .profile-info {
            flex: 1;
            text-align: left;
            min-width: 250px;
        }

        .profile-info h3 {
            font-size: 24px;
            margin: 0 0 5px;
            font-weight: 700;
            color: #1e293b;
        }

        .profile-info h4 {
            font-size: 18px;
            margin: 0 0 15px;
            font-weight: 600;
            color: #475569;
        }

        .stats {
            display: flex;
            gap: 25px;
            margin: 15px 0;
        }

        .stat-item {
            display: flex;
            flex-direction: column;
            align-items: center;
        }

        .stat-value {
            font-size: 20px;
            font-weight: 700;
            color: #1e293b;
        }

        .stat-label {
            font-size: 14px;
            color: #64748b;
            margin-top: 3px;
        }

        .profile-bio {
            margin-top: 25px;
            padding-top: 20px;
            border-top: 1px solid #e2e8f0;
            text-align: left;
            color: #475569;
            line-height: 1.6;
        }

        .profile-link {
            display: inline-flex;
            align-items: center;
            gap: 5px;
            color: #1e88e5;
            text-decoration: none;
            font-weight: 500;
            margin-top: 10px;
            transition: all 0.3s;
        }

        .profile-link:hover {
            color: #1a75c6;
            text-decoration: underline;
        }

        /* Tabs */
        .ig-tabs {
            display: flex;
            justify-content: center;
            margin: 30px 0;
            gap: 15px;
            flex-wrap: wrap;
        }

        .ig-tabs button {
            background: #f8fafc;
            color: #64748b;
            border: none;
            font-weight: 600;
            font-size: 15px;
            padding: 12px 24px;
            cursor: pointer;
            border-radius: 50px;
            transition: all 0.3s;
            display: flex;
            align-items: center;
            gap: 8px;
            box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
        }

        .ig-tabs button i {
            font-size: 16px;
        }

        .ig-tabs button.active {
            background: linear-gradient(135deg, #1e88e5, #ec407a);
            color: white;
            box-shadow: 0 5px 15px rgba(30, 136, 229, 0.3);
            transform: translateY(-2px);
        }

        .ig-tabs button:hover:not(.active) {
            background: #f1f5f9;
            color: #334155;
            transform: translateY(-2px);
        }

        /* Tab Content */
        .tab-content {
            padding: 20px;
            text-align: center;
            color: #666;
            display: none;
        }

        .tab-content.active {
            display: block;
        }

        .no-result {
            border: 1px dashed #cbd5e1;
            padding: 30px 20px;
            margin-top: 30px;
            text-align: center;
            font-size: 16px;
            font-weight: 500;
            border-radius: 12px;
            color: #64748b;
            background: #f8fafc;
        }

        .no-result i {
            font-size: 48px;
            color: #cbd5e1;
            margin-bottom: 15px;
            display: block;
        }

        /* Private Account Message */
        .private-account-message {
            background-color: rgba(229, 57, 53, 0.1);
            color: #e53935;
            padding: 20px;
            border-radius: 12px;
            margin-top: 20px;
            text-align: center;
            font-weight: 500;
            border: 1px solid rgba(229, 57, 53, 0.2);
            animation: fadeIn 0.5s ease-out;
        }

        .private-account-message i {
            margin-right: 8px;
            font-size: 18px;
        }

        /* Posts Grid */
        .posts-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
            gap: 25px;
            margin-top: 25px;
        }

        .post-card {
            border-radius: 16px;
            overflow: hidden;
            background: #fff;
            box-shadow: 0 5px 20px rgba(0, 0, 0, 0.06);
            transition: all 0.3s;
            border: 1px solid #f1f5f9;
            animation: slideUp 0.5s ease-out;
            animation-fill-mode: both;
        }

        .post-card:hover {
            transform: translateY(-8px);
            box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
        }

        .post-img-container {
            position: relative;
            overflow: hidden;
            aspect-ratio: 1 / 1;
        }

        .post-thumb {
            width: 100%;
            height: 100%;
            object-fit: cover;
            display: block;
            transition: transform 0.5s;
        }

        .post-overlay {
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: linear-gradient(to bottom, rgba(0, 0, 0, 0) 50%, rgba(0, 0, 0, 0.7) 100%);
            display: flex;
            align-items: center;
            justify-content: center;
            opacity: 1;
            transition: opacity 0.3s ease;
            z-index: 3;
        }

        .post-img-container:hover .post-overlay {
            opacity: 1;
        }

        .post-img-container:hover .post-thumb {
            transform: scale(1.08);
        }

        .post-download-btn,
        .post-view-btn {
            background: white;
            color: #ec407a;
            width: 45px;
            height: 45px;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            transition: all 0.3s;
            border: none;
            font-size: 16px;
            box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
        }

        .post-download-btn:hover,
        .post-view-btn:hover {
            transform: scale(1.1) translateY(-3px);
            box-shadow: 0 8px 20px rgba(30, 136, 229, 0.15);
        }

        .post-download-btn:hover {
            background: #1e88e5;
            color: white;
        }

        .post-view-btn {
            background: rgba(255, 255, 255, 0.9);
            color: #333;
            border: none;
            border-radius: 50%;
            width: 50px;
            height: 50px;
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            transition: all 0.3s ease;
            font-size: 20px;
        }

        .post-view-btn:hover {
            background: white;
            transform: scale(1.1);
        }

        .post-meta {
            padding: 20px;
        }

        .post-stats,
        .reel-stats {
            background: linear-gradient(135deg, rgba(30, 136, 229, 0.15), rgba(236, 64, 122, 0.15));
            padding: 8px 12px;
            border-radius: 12px;
            border: 1px solid rgba(30, 136, 229, 0.1);
            backdrop-filter: blur(10px);
            -webkit-backdrop-filter: blur(10px);
        }

        .post-stats span,
        .reel-stats span {
            color: #1e293b;
            font-weight: 600;
            font-size: 13px;
        }

        .post-stats span i,
        .reel-stats span i {
            color: #ec407a;
            margin-right: 4px;
        }

        .post-stats {
            display: flex;
            gap: 15px;
            margin-bottom: 10px;
        }

        .post-stats span {
            font-size: 14px;
            color: #64748b;
            display: flex;
            align-items: center;
            gap: 5px;
        }

        .post-stats span i {
            color: #ec407a;
        }

        .post-meta .caption {
            font-size: 15px;
            color: #334155;
            margin-bottom: 10px;
            line-height: 1.5;
            font-weight: 500;
            display: -webkit-box;
            -webkit-line-clamp: 2;
            -webkit-box-orient: vertical;
            overflow: hidden;
        }

        .post-meta .time {
            font-size: 13px;
            color: #94a3b8;
            display: block;
            font-weight: 400;
        }

        .post-stats-row {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 8px;
        }

        /* Stories Container */
        .stories-container {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
            gap: 20px;
            margin-top: 25px;
        }

        .story-card {
            border-radius: 16px;
            overflow: hidden;
            background: #fff;
            box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
            transition: all 0.3s;
            border: 1px solid #f1f5f9;
        }

        .story-card:hover {
            transform: translateY(-5px);
            box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
        }

        .story-img-container {
            position: relative;
            overflow: hidden;
            aspect-ratio: 9 / 16;
        }

        .story-thumb {
            width: 100%;
            height: 100%;
            object-fit: cover;
            display: block;
            transition: transform 0.5s;
        }

        .story-overlay {
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: rgba(0, 0, 0, 0.4);
            backdrop-filter: blur(2px);
            -webkit-backdrop-filter: blur(2px);
            display: flex;
            justify-content: center;
            align-items: center;
            opacity: 0;
            transition: all 0.3s;
            gap: 15px;
            flex-direction: column;
        }

        .story-img-container:hover .story-overlay {
            opacity: 1;
        }

        .story-img-container:hover .story-thumb {
            transform: scale(1.05);
        }

        .story-download-btn,
        .story-view-btn {
            background: white;
            color: #1e293b;
            width: 40px;
            height: 40px;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            transition: all 0.3s;
            border: none;
            font-size: 16px;
            box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
            padding: 0px;
        }

        .story-download-btn:hover,
        .story-view-btn:hover {
            transform: scale(1.1);
            box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
        }

        .story-download-btn:hover {
            background: #8e24aa;
            color: white;
        }

        .story-view-btn:hover {
            background: #f8bbd0;
            color: #8e24aa;
        }

        .story-meta {
            padding: 12px;
            text-align: center;
        }

        .story-meta .time {
            font-size: 13px;
            color: #94a3b8;
            font-weight: 400;
        }

        .story-stats-row {
            display: flex;
            justify-content: space-between;
            align-items: center;
            background: linear-gradient(135deg, rgba(236, 64, 122, 0.1), rgba(30, 136, 229, 0.1));
            padding: 6px 10px;
            border-radius: 8px;
            border: 1px solid rgba(236, 64, 122, 0.2);
        }

        .story-stats-row .time {
            color: #64748b;
            font-weight: 500;
        }

        .story-stats-row {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 8px;
        }

        /* Highlights Container */
        .highlights-container {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
            gap: 20px;
            margin-top: 25px;
        }

        .highlight-card {
            border-radius: 16px;
            overflow: hidden;
            background: #fff;
            box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
            transition: all 0.3s;
            border: 1px solid #f1f5f9;
            cursor: pointer;
            padding: 15px 10px;
            text-align: center;
        }

        .highlight-card:hover {
            transform: translateY(-5px) scale(1.02);
            box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
        }

        .highlight-img-container {
            position: relative;
            overflow: hidden;
            aspect-ratio: 1 / 1;
            border-radius: 50%;
            width: 120px;
            height: 120px;
            margin: 0 auto 10px;
            border: 3px solid #e53935;
            background: linear-gradient(to bottom right, #1e88e5, #ec407a);
            padding: 3px;
        }

        .highlight-thumb {
            width: 100%;
            height: 100%;
            object-fit: cover;
            display: block;
            transition: transform 0.5s;
            border-radius: 50%;
        }

        .highlight-meta {
            padding: 5px;
            text-align: center;
        }

        .highlight-title {
            font-size: 14px;
            color: #334155;
            font-weight: 600;
            margin: 0;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        .highlight-overlay {
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background-color: rgba(0, 0, 0, 0.5);
            opacity: 0;
            transition: opacity 0.3s;
            display: flex;
            justify-content: center;
            align-items: center;
        }

        .highlight-img-container:hover .highlight-overlay {
            opacity: 1;
        }

        .highlight-view-btn {
            background-color: white;
            color: #1e88e5;
            border: none;
            border-radius: 50%;
            width: 40px;
            height: 40px;
            display: flex;
            justify-content: center;
            align-items: center;
            cursor: pointer;
            transition: transform 0.2s;
        }

        .highlight-view-btn:hover {
            transform: scale(1.1);
        }

        /* Reels Grid */
        .reels-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
            gap: 25px;
            margin-top: 25px;
        }

        .reel-card {
            border-radius: 16px;
            overflow: hidden;
            background: #fff;
            box-shadow: 0 5px 20px rgba(0, 0, 0, 0.06);
            transition: all 0.3s;
            border: 1px solid #f1f5f9;
        }

        .reel-card:hover {
            transform: translateY(-8px);
            box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
        }

        .reel-img-container {
            position: relative;
            overflow: hidden;
            aspect-ratio: 9 / 16;
        }

        .reel-thumb {
            width: 100%;
            height: 100%;
            object-fit: cover;
            display: block;
            transition: transform 0.5s;
        }

        .reel-overlay {
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: rgba(0, 0, 0, 0.4);
            backdrop-filter: blur(2px);
            -webkit-backdrop-filter: blur(2px);
            display: flex;
            justify-content: center;
            align-items: center;
            opacity: 0;
            transition: all 0.3s;
            gap: 15px;
            flex-direction: column;
        }

        .reel-img-container:hover .reel-overlay {
            opacity: 1;
        }

        .reel-img-container:hover .reel-thumb {
            transform: scale(1.05);
        }

        .reel-download-btn,
        .reel-view-btn {
            background: white;
            color: #1e88e5;
            width: 45px;
            height: 45px;
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            transition: all 0.3s;
            border: none;
            font-size: 16px;
            box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
        }

        .reel-download-btn:hover {
            background: #1e88e5;
            color: white;
        }

        .reel-view-btn:hover {
            background: #ec407a;
            color: #fff;
        }

        .reel-meta {
            padding: 20px;
        }

        .reel-meta .caption {
            font-size: 15px;
            color: #334155;
            margin-bottom: 10px;
            line-height: 1.5;
            font-weight: 500;
            display: -webkit-box;
            -webkit-line-clamp: 2;
            -webkit-box-orient: vertical;
            overflow: hidden;
        }

        .reel-stats,
        .post-stats {
            background: linear-gradient(135deg, rgba(30, 136, 229, 0.15), rgba(236, 64, 122, 0.15));
            padding: 8px 12px;
            border-radius: 12px;
            border: 1px solid rgba(30, 136, 229, 0.1);
            backdrop-filter: blur(10px);
            -webkit-backdrop-filter: blur(10px);
        }

        .reel-stats span,
        .post-stats span {
            color: #1e293b;
            font-weight: 600;
            font-size: 13px;
        }

        .reel-stats span i,
        .post-stats span i {
            color: #ec407a;
            margin-right: 4px;
        }

        .reel-stats {
            display: flex;
            gap: 15px;
            margin-bottom: 8px;
        }

        .reel-stats span {
            font-size: 13px;
            color: #64748b;
            display: flex;
            align-items: center;
            gap: 5px;
        }

        .reel-stats span i {
            color: #8e24aa;
        }

        .reel-meta .time {
            font-size: 13px;
            color: #94a3b8;
            display: block;
            font-weight: 400;
        }

        .reel-stats-row {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 8px;
        }

        /* Video Elements */
        .post-video,
        .story-video,
        .reel-video {
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            object-fit: cover;
            z-index: 2;
        }

        .post-fullscreen-btn,
        .story-fullscreen-btn,
        .reel-fullscreen-btn {
            position: absolute;
            top: 10px;
            right: 10px;
            background: rgba(255, 255, 255, 0.9);
            color: #333;
            border: none;
            border-radius: 50%;
            width: 40px;
            height: 40px;
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            transition: all 0.3s ease;
            font-size: 16px;
            z-index: 4;
        }

        .post-fullscreen-btn:hover,
        .story-fullscreen-btn:hover,
        .reel-fullscreen-btn:hover {
            background: white;
            transform: scale(1.1);
        }

        /* Media Type Indicators */
        .media-type-indicator {
            position: absolute;
            top: 8px;
            left: 8px;
            background-color: rgba(0, 0, 0, 0.8);
            color: white;
            border-radius: 4px;
            padding: 4px 8px;
            font-size: 11px;
            font-weight: bold;
            z-index: 5;
            display: flex;
            align-items: center;
            gap: 4px;
            pointer-events: none;
        }

        .video-indicator {
            background-color: rgba(220, 53, 69, 0.9);
        }

        .image-indicator {
            background-color: rgba(13, 110, 253, 0.9);
        }

        /* Modal Styles */
        .ipgv-profile-img-modal {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            z-index: 10000;
            display: flex;
            justify-content: center;
            align-items: center;
            opacity: 0;
            visibility: hidden;
            transition: all 0.3s ease;
        }

        .ipgv-profile-img-modal.active {
            opacity: 1;
            visibility: visible;
        }

        .ipgv-modal-backdrop {
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background-color: rgba(0, 0, 0, 0.85);
            cursor: pointer;
        }

        .ipgv-modal-content {
            position: relative;
            max-width: 90vw;
            max-height: 90vh;
            background-color: white;
            border-radius: 12px;
            overflow: hidden;
            box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
            transform: scale(0.8);
            transition: transform 0.3s ease;
            z-index: 10001;
        }

        .ipgv-profile-img-modal.active .ipgv-modal-content {
            transform: scale(1);
        }

        .ipgv-modal-img {
            display: block;
            width: 100%;
            max-width: 500px;
            height: auto;
            max-height: 70vh;
            object-fit: contain;
        }

        .ipgv-modal-actions {
            display: flex;
            justify-content: center;
            padding: 20px;
            background-color: #f8f9fa;
        }

        .ipgv-modal-download-btn {
            background-color: #1e88e5;
            color: white;
            border: none;
            border-radius: 8px;
            padding: 12px 24px;
            font-weight: 600;
            font-size: 14px;
            cursor: pointer;
            transition: all 0.2s ease;
            display: flex;
            align-items: center;
            gap: 8px;
        }

        .ipgv-modal-download-btn:hover {
            background-color: #1a75c6;
            transform: translateY(-1px);
        }

        .ipgv-close-modal {
            position: absolute;
            top: 15px;
            right: 15px;
            background-color: rgba(0, 0, 0, 0.6);
            color: white;
            border: none;
            border-radius: 50%;
            width: 35px;
            height: 35px;
            display: flex;
            justify-content: center;
            align-items: center;
            cursor: pointer;
            transition: all 0.2s ease;
            z-index: 10002;
        }

        .ipgv-close-modal:hover {
            background-color: rgba(0, 0, 0, 0.8);
            transform: scale(1.1);
        }

        body.ipgv-modal-open {
            overflow: hidden;
        }

        /* abc */

        /* Fixed Reel Controls - Always Visible Play and Fullscreen */
        .reel-img-container .reel-overlay {
            opacity: 1;
        }

        .reel-img-container .reel-view-btn {
            opacity: 1;
            visibility: visible;
        }

        .reel-img-container .reel-fullscreen-btn {
            opacity: 1;
            visibility: visible;
            display: flex;
        }

        .reel-img-container:hover .reel-overlay {
            opacity: 1;
        }

        .reel-video.playing {
            display: block;
        }

        .reel-thumb.hidden {
            display: none;
        }


        /* abc */

        /* Skeleton Loaders */
        @keyframes shimmer {
            0% {
                background-position: -1000px 0;
            }

            100% {
                background-position: 1000px 0;
            }
        }

        .skeleton-profile {
            width: 100%;
            animation: fadeIn 0.5s ease-out;
        }

        .skeleton-profile-header {
            display: flex;
            gap: 30px;
            padding: 30px;
            background: #f9fafb;
            border-radius: 16px;
            margin-bottom: 20px;
            border: 1px solid #f1f5f9;
        }

        .skeleton-avatar {
            width: 150px;
            height: 150px;
            border-radius: 50%;
            background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
            background-size: 1000px 100%;
            animation: shimmer 2s infinite linear;
            flex-shrink: 0;
            border: 4px solid white;
            box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
        }

        .skeleton-profile-info {
            flex: 1;
            display: flex;
            flex-direction: column;
            gap: 15px;
        }

        .skeleton-username {
            height: 28px;
            width: 180px;
            background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
            background-size: 1000px 100%;
            animation: shimmer 2s infinite linear;
            border-radius: 6px;
        }

        .skeleton-fullname {
            height: 20px;
            width: 140px;
            background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
            background-size: 1000px 100%;
            animation: shimmer 2s infinite linear;
            border-radius: 6px;
        }

        .skeleton-stats {
            display: flex;
            gap: 25px;
            margin-top: 10px;
        }

        .skeleton-stat {
            height: 40px;
            width: 60px;
            background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
            background-size: 1000px 100%;
            animation: shimmer 2s infinite linear;
            border-radius: 6px;
        }

        .skeleton-bio {
            height: 60px;
            width: 100%;
            background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
            background-size: 1000px 100%;
            animation: shimmer 2s infinite linear;
            border-radius: 6px;
            margin-bottom: 30px;
        }

        .skeleton-tabs {
            display: flex;
            justify-content: center;
            gap: 15px;
            margin-bottom: 30px;
        }

        .skeleton-tab {
            height: 40px;
            width: 100px;
            background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
            background-size: 1000px 100%;
            animation: shimmer 2s infinite linear;
            border-radius: 50px;
        }

        /* Posts Skeleton */
        .skeleton-posts-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
            gap: 25px;
        }

        .skeleton-post {
            border-radius: 16px;
            overflow: hidden;
            background: #fff;
            box-shadow: 0 5px 20px rgba(0, 0, 0, 0.06);
            border: 1px solid #f1f5f9;
        }

        .skeleton-post-img {
            aspect-ratio: 1 / 1;
            background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
            background-size: 1000px 100%;
            animation: shimmer 2s infinite linear;
        }

        .skeleton-post-meta {
            padding: 20px;
        }

        .skeleton-post-stats {
            display: flex;
            gap: 15px;
            margin-bottom: 10px;
        }

        .skeleton-post-stat {
            height: 16px;
            width: 60px;
            background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
            background-size: 1000px 100%;
            animation: shimmer 2s infinite linear;
            border-radius: 4px;
        }

        .skeleton-post-caption {
            height: 16px;
            width: 100%;
            background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
            background-size: 1000px 100%;
            animation: shimmer 2s infinite linear;
            border-radius: 4px;
            margin-bottom: 8px;
        }

        .skeleton-post-caption-short {
            height: 16px;
            width: 70%;
            background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
            background-size: 1000px 100%;
            animation: shimmer 2s infinite linear;
            border-radius: 4px;
            margin-bottom: 10px;
        }

        .skeleton-post-time {
            height: 14px;
            width: 80px;
            background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
            background-size: 1000px 100%;
            animation: shimmer 2s infinite linear;
            border-radius: 4px;
        }

        /* Stories Skeleton */
        .skeleton-stories-container {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
            gap: 20px;
        }

        .skeleton-story {
            border-radius: 16px;
            overflow: hidden;
            background: #fff;
            box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
            border: 1px solid #f1f5f9;
        }

        .skeleton-story-img {
            aspect-ratio: 9 / 16;
            background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
            background-size: 1000px 100%;
            animation: shimmer 2s infinite linear;
        }

        .skeleton-story-meta {
            padding: 12px;
            text-align: center;
        }

        .skeleton-story-time {
            height: 14px;
            width: 80px;
            background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
            background-size: 1000px 100%;
            animation: shimmer 2s infinite linear;
            border-radius: 4px;
            margin: 0 auto;
        }

        /* Highlights Skeleton */
        .skeleton-highlights-container {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
            gap: 20px;
        }

        .skeleton-highlight {
            border-radius: 16px;
            overflow: hidden;
            background: #fff;
            box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
            border: 1px solid #f1f5f9;
            padding: 15px 10px;
            text-align: center;
        }

        .skeleton-highlight-img {
            width: 80px;
            height: 80px;
            border-radius: 50%;
            background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
            background-size: 1000px 100%;
            animation: shimmer 2s infinite linear;
            margin: 0 auto 10px;
            border: 3px solid #e53935;
        }

        .skeleton-highlight-title {
            height: 16px;
            width: 80px;
            background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
            background-size: 1000px 100%;
            animation: shimmer 2s infinite linear;
            border-radius: 4px;
            margin: 0 auto;
        }

        /* Reels Skeleton */
        .skeleton-reels-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
            gap: 25px;
        }

        .skeleton-reel {
            border-radius: 16px;
            overflow: hidden;
            background: #fff;
            box-shadow: 0 5px 20px rgba(0, 0, 0, 0.06);
            border: 1px solid #f1f5f9;
        }

        .skeleton-reel-img {
            aspect-ratio: 9 / 16;
            background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
            background-size: 1000px 100%;
            animation: shimmer 2s infinite linear;
        }

        .skeleton-reel-meta {
            padding: 20px;
        }

        .skeleton-reel-caption {
            height: 16px;
            width: 100%;
            background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
            background-size: 1000px 100%;
            animation: shimmer 2s infinite linear;
            border-radius: 4px;
            margin-bottom: 8px;
        }

        .skeleton-reel-caption-short {
            height: 16px;
            width: 70%;
            background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
            background-size: 1000px 100%;
            animation: shimmer 2s infinite linear;
            border-radius: 4px;
            margin-bottom: 10px;
        }

        .skeleton-reel-stats {
            display: flex;
            gap: 15px;
            margin-bottom: 8px;
        }

        .skeleton-reel-stat {
            height: 16px;
            width: 60px;
            background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
            background-size: 1000px 100%;
            animation: shimmer 2s infinite linear;
            border-radius: 4px;
        }

        .skeleton-reel-time {
            height: 14px;
            width: 80px;
            background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
            background-size: 1000px 100%;
            animation: shimmer 2s infinite linear;
            border-radius: 4px;
        }

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

            to {
                opacity: 1;
            }
        }

        @keyframes slideUp {
            from {
                transform: translateY(20px);
                opacity: 0;
            }

            to {
                transform: translateY(0);
                opacity: 1;
            }
        }

        @keyframes spin {
            0% {
                transform: rotate(0deg);
            }

            100% {
                transform: rotate(360deg);
            }
        }

        /* Professional Responsive Design */
        @media (max-width: 768px) {
            .wrapper {
                padding: 10px;
            }

            .main-contain {
                padding: 10px;
            }

            .ig-tool-wrapper {
                padding: 25px 20px;
                margin: 10px auto;
                border-radius: 20px;
            }

            .ig-header h1 {
                font-size: 28px;
                margin-bottom: 15px;
                background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 50%, #ec4899 100%);
                -webkit-background-clip: text;
                -webkit-text-fill-color: transparent;
                background-clip: text;
            }

            .viewer-anonymous {
                background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 50%, #ec4899 100%);
                -webkit-background-clip: text;
                -webkit-text-fill-color: transparent;
                background-clip: text;
            }

            .ig-header p {
                font-size: 16px;
                margin: 15px 0 25px;
            }

            .ig-input-area {
                padding: 20px 15px;
                flex-direction: column;
                gap: 15px;
                border-radius: 16px;
            }

            .ig-icon {
                width: 100%;
                text-align: left;
                margin-left: 0;
                margin-bottom: 10px;
            }

            .ig-input-area input {
                margin: 0 0 15px 0;
                width: 100%;
                min-width: 100%;
                padding: 14px 16px;
            }

            .paste-btn {
                display: none;
            }

            .view-btn {
                width: 100%;
                justify-content: center;
                padding: 14px 20px;
            }

            .profile-header-content {
                flex-direction: column;
                align-items: center;
                text-align: center;
            }

            .profile-info {
                text-align: center;
            }
					
					.ig-profile-header {
	margin-bottom: 40px;
	position: relative;
	background: linear-gradient(to bottom, #f9fafb, #ffffff);
	border-radius: 16px;
	padding: 30px;
	box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
	border: 1px solid #f1f5f9;
	display: flex;
	justify-content: center;
	align-items: center;
	flex-direction: column;
}

            .stats {
                justify-content: center;
            }

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

            .stories-container {
                grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
            }

            .highlights-container {
                grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
            }

            .reels-grid {
                grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
            }

            .post-meta .caption,
            .reel-meta .caption {
                font-size: 14px;
            }

            .ig-tabs button {
                padding: 10px 16px;
                font-size: 14px;
            }

            .ipgv-modal-content {
                max-width: 95vw;
                max-height: 85vh;
                margin: 20px;
            }

            .ipgv-modal-img {
                max-height: 60vh;
            }

            .ipgvmodal-actions {
                padding: 15px;
            }

            .ipgv-modal-download-btn {
                padding: 10px 20px;
                font-size: 13px;
            }

            .skeleton-profile-header {
                flex-direction: column;
                align-items: center;
            }

            .skeleton-avatar {
                margin-bottom: 20px;
            }

            .skeleton-username,
            .skeleton-fullname {
                margin: 0 auto;
            }

            .skeleton-stats {
                justify-content: center;
            }

            .skeleton-posts-grid {
                grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
            }

            .skeleton-stories-container {
                grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
            }

            .skeleton-highlights-container {
                grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
            }

            .skeleton-reels-grid {
                grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
            }
        }

        .ipgv-media-modal {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            z-index: 10000;
            display: flex;
            justify-content: center;
            align-items: center;
            opacity: 0;
            visibility: hidden;
            transition: all 0.3s ease;
        }

        .ipgv-media-modal.active {
            opacity: 1;
            visibility: visible;
        }

        .ipgv-modal-media {
            display: block;
            width: 100%;
            height: auto;
            border-radius: 8px;
        }

        /* Medium Device Responsive Design */
        @media (max-width: 1024px) and (min-width: 769px) {
            .wrapper {
                padding: 15px;
            }

            .main-contain {
                padding: 15px;
            }

            .ig-tool-wrapper {
                padding: 35px 30px;
                margin: 15px auto;
            }

            .ig-header h1 {
                font-size: 36px;
                background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 50%, #ec4899 100%);
                -webkit-background-clip: text;
                -webkit-text-fill-color: transparent;
                background-clip: text;
            }

            .viewer-anonymous {
                background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 50%, #ec4899 100%);
                -webkit-background-clip: text;
                -webkit-text-fill-color: transparent;
                background-clip: text;
            }

            .ig-header p {
                font-size: 17px;
            }

            .ig-input-area {
                padding: 25px 20px;
                gap: 18px;
            }

            .ig-input-area input {
                padding: 15px 18px;
            }

            .paste-btn,
            .view-btn {
                padding: 15px 22px;
            }
        }
			
			/* Responsive Design for Small and Medium Devices */

/* Max-width 992px */
@media (max-width: 992px) {
    .wrapper {
        padding: 15px;
    }

    .main-contain {
        padding: 15px;
    }

    .ig-tool-wrapper {
        padding: 30px;
        margin: 15px auto;
        border-radius: 20px;
    }

    .ig-header h3 {
        font-size: 38px;
        margin-bottom: 18px;
    }

    .ig-header p {
        font-size: 17px;
        margin: 18px 0 28px;
    }

    .ig-input-area {
        padding: 25px;
        gap: 15px;
        border-radius: 16px;
        flex-wrap: wrap;
    }

    .ig-icon {
        width: 100%;
        text-align: left;
        margin-bottom: 10px;
    }

    .ig-input-area input {
        flex-grow: 1;
        width: calc(100% - 150px); /* Adjust based on button width */
        min-width: unset;
        padding: 15px 18px;
    }

    .paste-btn,
    .view-btn {
        padding: 14px 20px;
        font-size: 14px;
        margin-bottom: 0;
    }

    .paste-btn {
        flex-basis: auto;
    }

    .view-btn {
        flex-basis: auto;
    }

    .profile-header-content {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .profile-info {
        text-align: center;
    }

    .profile-image-container {
        margin-bottom: 20px;
    }

    .stats {
        justify-content: center;
        flex-wrap: wrap;
        gap: 20px;
    }

    .profile-bio {
        margin-top: 20px;
        padding-top: 15px;
        font-size: 15px;
    }

    .ig-tabs {
        gap: 10px;
        margin: 25px 0;
    }

    .ig-tabs button {
        padding: 10px 20px;
        font-size: 14px;
        gap: 6px;
    }

    .posts-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
        gap: 20px;
    }

    .stories-container {
        grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
        gap: 15px;
    }

    .highlights-container {
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
        gap: 15px;
    }

    .reel-card {
        max-width: unset;
    }

    .reels-grid {
        grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
        gap: 20px;
    }

    .post-meta .caption,
    .reel-meta .caption {
        font-size: 14px;
    }

    .post-stats span,
    .reel-stats span {
        font-size: 12px;
    }

    .ipgv-modal-content {
        max-width: 90vw;
        max-height: 85vh;
    }
}

/* Max-width 768px */
@media (max-width: 768px) {
    .wrapper {
        padding: 10px;
    }

    .main-contain {
        padding: 10px;
    }

    .ig-tool-wrapper {
        padding: 25px 20px;
        margin: 10px auto;
        border-radius: 20px;
    }

    .ig-header h1 {
        font-size: 32px;
        margin-bottom: 15px;
    }

    .ig-header p {
        font-size: 16px;
        margin: 15px 0 25px;
    }

    .ig-input-area {
        padding: 20px 15px;
        flex-direction: column;
        gap: 15px;
        border-radius: 16px;
    }

    .ig-icon {
        width: 100%;
        text-align: left;
        margin-left: 0;
        margin-bottom: 10px;
    }

    .ig-input-area input {
        width: 100%;
        min-width: 100%;
        padding: 14px 16px;
        margin-bottom: 0; /* No margin bottom for the input */
    }

    .paste-btn {
        display: none; /* Hide paste button on smaller screens */
    }

    .view-btn {
        width: 100%;
        justify-content: center;
        padding: 14px 20px;
    }

    .profile-image {
        width: 120px;
        height: 120px;
        min-width: 120px;
        min-height: 120px;
        font-size: 50px;
    }

    .view-profile-img {
        width: 30px;
        height: 30px;
        font-size: 14px;
    }

    .profile-info h3 {
        font-size: 22px;
    }

    .profile-info h4 {
        font-size: 16px;
    }

    .stat-value {
        font-size: 18px;
    }

    .stat-label {
        font-size: 13px;
    }

    .profile-bio {
        font-size: 14px;
    }

    .ig-tabs button {
        padding: 9px 15px;
        font-size: 13px;
        gap: 5px;
    }

    .posts-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 15px;
    }

    .stories-container {
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
        gap: 10px;
    }

    .highlights-container {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
        gap: 10px;
    }

    .highlight-img-container {
        width: 90px;
        height: 90px;
        border: 2px solid #e53935;
        padding: 2px;
    }

    .highlight-title {
        font-size: 13px;
    }

    .reels-grid {
        grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
        gap: 15px;
    }

    .post-download-btn,
    .post-view-btn,
    .reel-download-btn,
    .reel-view-btn {
        width: 40px;
        height: 40px;
        font-size: 14px;
    }

    .reel-view-btn {
        width: 45px;
        height: 45px;
        font-size: 18px;
    }

    .story-download-btn,
    .story-view-btn {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }

    .ipgv-modal-content {
        max-width: 95vw;
        max-height: 80vh;
        margin: 15px;
    }

    .ipgv-modal-img {
        max-height: 55vh;
    }

    .ipgv-modal-actions {
        padding: 15px;
    }

    .ipgv-modal-download-btn {
        padding: 10px 20px;
        font-size: 13px;
    }

    .ipgv-close-modal {
        width: 30px;
        height: 30px;
        font-size: 14px;
        top: 10px;
        right: 10px;
    }

    /* Skeleton Loaders Responsive */
    .skeleton-profile-header {
        flex-direction: column;
        align-items: center;
        padding: 25px;
    }

    .skeleton-avatar {
        width: 120px;
        height: 120px;
        margin-bottom: 15px;
    }

    .skeleton-username {
        width: 150px;
        height: 25px;
    }

    .skeleton-fullname {
        width: 120px;
        height: 18px;
    }

    .skeleton-stats {
        justify-content: center;
        gap: 20px;
    }

    .skeleton-stat {
        width: 50px;
        height: 35px;
    }

    .skeleton-bio {
        height: 50px;
        margin-bottom: 25px;
    }

    .skeleton-tabs {
        gap: 10px;
    }

    .skeleton-tab {
        width: 90px;
        height: 38px;
    }

    .skeleton-posts-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }

    .skeleton-post-img {
        aspect-ratio: 1 / 1;
    }

    .skeleton-stories-container {
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    }

    .skeleton-story-img {
        aspect-ratio: 9 / 16;
    }

    .skeleton-highlights-container {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    }

    .skeleton-highlight-img {
        width: 90px;
        height: 90px;
    }

    .skeleton-reels-grid {
        grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    }

    .skeleton-reel-img {
        aspect-ratio: 9 / 16;
    }
}


/* Max-width 600px */
@media (max-width: 600px) {
    .ig-tool-wrapper {
        padding: 20px 15px;
        margin: 10px auto;
        border-radius: 16px;
    }

    .ig-header h1 {
        font-size: 28px;
        margin-bottom: 12px;
    }

    .ig-header p {
        font-size: 15px;
        margin: 12px 0 20px;
    }

    .ig-input-area {
        padding: 15px 10px;
        gap: 10px;
        border-radius: 12px;
    }

    .ig-input-area input {
        padding: 12px 14px;
        font-size: 14px;
    }

    .view-btn {
        padding: 12px 18px;
        font-size: 14px;
    }

    .profile-image {
        width: 100px;
        height: 100px;
        min-width: 100px;
        min-height: 100px;
        font-size: 40px;
    }

    .profile-info h3 {
        font-size: 20px;
    }

    .profile-info h4 {
        font-size: 15px;
    }

    .stat-value {
        font-size: 16px;
    }

    .stat-label {
        font-size: 12px;
    }

    .profile-bio {
        font-size: 13px;
    }

    .ig-tabs button {
        padding: 8px 12px;
        font-size: 12px;
        gap: 4px;
    }

    .posts-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
        gap: 10px;
    }

    .stories-container {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
        gap: 8px;
    }

    .highlights-container {
        grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
        gap: 8px;
    }

    .highlight-img-container {
        width: 70px;
        height: 70px;
        border: 2px solid #e53935;
        padding: 1px;
    }

    .highlight-title {
        font-size: 12px;
    }

    .reels-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 10px;
    }

    .post-meta .caption,
    .reel-meta .caption {
        font-size: 13px;
        -webkit-line-clamp: 1; /* Shorter captions on small screens */
    }

    .post-stats span,
    .reel-stats span {
        font-size: 11px;
    }

    .post-download-btn,
    .post-view-btn,
    .reel-download-btn,
    .reel-view-btn {
        width: 35px;
        height: 35px;
        font-size: 13px;
    }

    .reel-view-btn {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }

    .story-download-btn,
    .story-view-btn {
        width: 32px;
        height: 32px;
        font-size: 13px;
    }

    .ipgv-modal-download-btn {
        padding: 8px 16px;
        font-size: 12px;
    }

    /* Skeleton Loaders Responsive */
    .skeleton-avatar {
        width: 100px;
        height: 100px;
    }

    .skeleton-username {
        width: 120px;
        height: 22px;
    }

    .skeleton-fullname {
        width: 100px;
        height: 16px;
    }

    .skeleton-stat {
        width: 45px;
        height: 30px;
    }

    .skeleton-bio {
        height: 40px;
    }

    .skeleton-tab {
        width: 70px;
        height: 35px;
    }

    .skeleton-posts-grid {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    }

    .skeleton-stories-container {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    }

    .skeleton-highlights-container {
        grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    }

    .skeleton-highlight-img {
        width: 70px;
        height: 70px;
    }

    .skeleton-reels-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }
}

/* Max-width 400px */
@media (max-width: 400px) {
    .ig-tool-wrapper {
        padding: 15px 10px;
    }

    .ig-header h1 {
        font-size: 24px;
    }

    .ig-header p {
        font-size: 14px;
        margin: 10px 0 15px;
    }

    .ig-input-area {
        padding: 10px;
    }

    .ig-input-area input {
        padding: 10px 12px;
        font-size: 13px;
    }

    .view-btn {
        padding: 10px 15px;
        font-size: 13px;
    }

    .profile-image {
        width: 80px;
        height: 80px;
        min-width: 80px;
        min-height: 80px;
        font-size: 30px;
    }

    .profile-info h3 {
        font-size: 18px;
    }

    .profile-info h4 {
        font-size: 14px;
    }

    .stat-value {
        font-size: 14px;
    }

    .stat-label {
        font-size: 11px;
    }

    .ig-tabs button {
        padding: 7px 10px;
        font-size: 11px;
    }

    .posts-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 8px;
    }

    .stories-container {
        grid-template-columns: repeat(auto-fill, minmax(90px, 1fr));
        gap: 6px;
    }

    .highlights-container {
        grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
        gap: 6px;
    }

    .highlight-img-container {
        width: 60px;
        height: 60px;
    }

    .highlight-title {
        font-size: 11px;
    }

    .reels-grid {
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
        gap: 8px;
    }

    .post-meta .caption,
    .reel-meta .caption {
        font-size: 12px;
    }

    .post-stats span,
    .reel-stats span {
        font-size: 10px;
    }

    .post-download-btn,
    .post-view-btn,
    .reel-download-btn,
    .reel-view-btn {
        width: 30px;
        height: 30px;
        font-size: 12px;
    }

    .reel-view-btn {
        width: 35px;
        height: 35px;
        font-size: 14px;
    }

    .story-download-btn,
    .story-view-btn {
        width: 28px;
        height: 28px;
        font-size: 12px;
    }

    /* Skeleton Loaders Responsive */
    .skeleton-avatar {
        width: 80px;
        height: 80px;
    }

    .skeleton-username {
        width: 100px;
        height: 20px;
    }

    .skeleton-fullname {
        width: 80px;
        height: 14px;
    }

    .skeleton-stat {
        width: 40px;
        height: 25px;
    }

    .skeleton-bio {
        height: 35px;
    }

    .skeleton-tab {
        width: 60px;
        height: 30px;
    }

    .skeleton-posts-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    }

    .skeleton-stories-container {
        grid-template-columns: repeat(auto-fill, minmax(90px, 1fr));
    }

    .skeleton-highlights-container {
        grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
    }

    .skeleton-highlight-img {
        width: 60px;
        height: 60px;
    }

    .skeleton-reels-grid {
        grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    }
}

/* Max-width 375px (iPhone SE/older smaller phones) */
@media (max-width: 375px) {
    .ig-tool-wrapper {
        padding: 12px 8px;
    }

    .ig-header h1 {
        font-size: 22px;
    }

    .ig-header p {
        font-size: 13px;
        margin: 8px 0 12px;
    }

    .ig-input-area input {
        padding: 9px 10px;
        font-size: 12px;
    }

    .view-btn {
        padding: 9px 12px;
        font-size: 12px;
    }

    .profile-image {
        width: 70px;
        height: 70px;
        min-width: 70px;
        min-height: 70px;
        font-size: 26px;
    }

    .profile-info h3 {
        font-size: 16px;
    }

    .profile-info h4 {
        font-size: 13px;
    }

    .stat-value {
        font-size: 13px;
    }

    .stat-label {
        font-size: 10px;
    }

    .ig-tabs button {
        padding: 6px 8px;
        font-size: 10px;
    }

    .posts-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: 6px;
    }

    .stories-container {
        grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
        gap: 5px;
    }

    .highlights-container {
        grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
        gap: 5px;
    }

    .highlight-img-container {
        width: 50px;
        height: 50px;
    }

    .highlight-title {
        font-size: 10px;
    }

    .reels-grid {
        grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
        gap: 6px;
    }

    .post-meta .caption,
    .reel-meta .caption {
        font-size: 11px;
    }

    .post-stats span,
    .reel-stats span {
        font-size: 9px;
    }

    .post-download-btn,
    .post-view-btn,
    .reel-download-btn,
    .reel-view-btn {
        width: 28px;
        height: 28px;
        font-size: 11px;
    }

    .reel-view-btn {
        width: 32px;
        height: 32px;
        font-size: 12px;
    }

    .story-download-btn,
    .story-view-btn {
        width: 26px;
        height: 26px;
        font-size: 11px;
    }

    /* Skeleton Loaders Responsive */
    .skeleton-avatar {
        width: 70px;
        height: 70px;
    }

    .skeleton-username {
        width: 90px;
        height: 18px;
    }

    .skeleton-fullname {
        width: 70px;
        height: 12px;
    }

    .skeleton-stat {
        width: 35px;
        height: 22px;
    }

    .skeleton-bio {
        height: 30px;
    }

    .skeleton-tab {
        width: 50px;
        height: 28px;
    }

    .skeleton-posts-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    }

    .skeleton-stories-container {
        grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    }

    .skeleton-highlights-container {
        grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
    }

    .skeleton-highlight-img {
        width: 50px;
        height: 50px;
    }

    .skeleton-reels-grid {
        grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    }
}

        /* Enhanced Video Controls */

' +
                            '@keyframes slideInRight {' +
                            'from { transform: translateX(100%); opacity: 0; }' +
                            'to { transform: translateX(0); opacity: 1; }' +
                            '}' +
                            '@keyframes slideOutRight {' +
                            'from { transform: translateX(0); opacity: 1; }' +
                            'to { transform: translateX(100%); opacity: 0; }' +
                            '}' +
                            '@keyframes shimmer {' +
                            '0% { transform: translateX(-100%); }' +
                            '100% { transform: translateX(100%); }' +
                            '}' +
                            '.cancel-download:hover {' +
                            'background: #dc2626;' +
                            'transform: scale(1.05);' +
                            '}' +
                            '.download-toast.success {' +
                            'border-left-color: #10b981;' +
                            '}' +
                            '.download-toast.error {' +
                            'border-left-color: #ef4444;' +
                            '}' +
                            '

/* --- Codex CSS updates --- */
button,
html input[type="button"],
input[type="reset"],
input[type="submit"] {
    padding: 0;
}

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

.wrapper {
    --ig-bg-1: #0f172a;
    --ig-bg-2: #312e81;
    --ig-bg-3: #be185d;
    --ig-primary: #2563eb;
    --ig-primary-dark: #1d4ed8;
    --ig-accent: #db2777;
    --ig-purple: #7c3aed;
    --ig-success: #10b981;
    --ig-error: #ef4444;
    --ig-warning: #f59e0b;
    --ig-text: #111827;
    --ig-muted: #64748b;
    --ig-soft: #f8fafc;
    --ig-border: rgba(148, 163, 184, 0.24);
    --ig-card: rgba(255, 255, 255, 0.96);
    --ig-shadow: 0 22px 60px rgba(15, 23, 42, 0.16);
    --ig-radius-lg: 24px;
    --ig-radius-md: 16px;
    --ig-radius-sm: 12px;
    font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background:
        radial-gradient(circle at 12% 18%, rgba(219, 39, 119, 0.22), transparent 34%),
        radial-gradient(circle at 88% 16%, rgba(37, 99, 235, 0.24), transparent 32%),
        linear-gradient(135deg, var(--ig-bg-1) 0%, var(--ig-bg-2) 48%, var(--ig-bg-3) 100%);
    min-height: 100vh;
    line-height: 1.6;
    position: relative;
    overflow-x: hidden;
    color: var(--ig-text);
}

.wrapper::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(rgba(255, 255, 255, 0.055) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
    background-size: 44px 44px;
    pointer-events: none;
    opacity: 0.45;
}

.main-contain,
.offcontents {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: 24px;
    position: relative;
    z-index: 1;
}

.ig-tool-wrapper {
    width: 100%;
    margin: 20px auto;
    padding: 42px;
    border-radius: var(--ig-radius-lg);
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.98), rgba(248, 250, 252, 0.92));
    backdrop-filter: blur(22px);
    -webkit-backdrop-filter: blur(22px);
    border: 1px solid rgba(255, 255, 255, 0.72);
    color: var(--ig-text);
    text-align: center;
    box-shadow: var(--ig-shadow), inset 0 1px 0 rgba(255, 255, 255, 0.78);
    position: relative;
    overflow: hidden;
}

.ig-tool-wrapper::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, rgba(37, 99, 235, 0.08), rgba(219, 39, 119, 0.08)),
        radial-gradient(circle at 50% 0%, rgba(124, 58, 237, 0.13), transparent 40%);
    pointer-events: none;
}

.ig-header {
    position: relative;
    z-index: 2;
}

.ig-header h1,
.ig-header h3 {
    display: inline-block;
    max-width: 980px;
    margin: 0 auto 16px;
    font-size: clamp(28px, 4vw, 44px);
    line-height: 1.16;
    font-weight: 800;
    letter-spacing: 0;
    text-transform: capitalize !important;
    color: transparent;
    background: linear-gradient(135deg, #2563eb 0%, #7c3aed 46%, #db2777 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.viewer-anonymous {
    display: inline-block;
    position: relative;
    background: linear-gradient(135deg, #2563eb 0%, #7c3aed 50%, #db2777 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.viewer-anonymous::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -7px;
    width: 100%;
    height: 3px;
    border-radius: 999px;
    background: linear-gradient(90deg, #2563eb, #db2777);
    animation: underlineGlow 2.2s ease-in-out infinite alternate;
}

@keyframes underlineGlow {
    0% {
        opacity: 0.65;
        transform: scaleX(0.94);
    }
    100% {
        opacity: 1;
        transform: scaleX(1);
    }
}

.ig-header p {
    max-width: 760px;
    margin: 14px auto 30px;
    color: #475569;
    font-size: clamp(15px, 1.8vw, 18px);
    line-height: 1.72;
    font-weight: 450;
}

.ig-input-area {
    display: flex;
    align-items: stretch;
    gap: 14px;
    width: 100%;
    max-width: 940px;
    margin: 0 auto;
    padding: 22px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.78);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border: 1px solid var(--ig-border);
    box-shadow: 0 18px 42px rgba(15, 23, 42, 0.1);
}

.ig-icon {
    width: 100%;
    flex: 0 0 100%;
    text-align: left;
    color: #334155;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0;
    text-transform: capitalize !important;
    position: relative;
    z-index: 2;
}

.ig-input-area input {
    flex: 1 1 360px;
    width: 100%;
    max-width: 100%;
    min-width: 220px;
    height: 54px;
    min-height: 54px;
    max-height: 60px;
    padding: 0 18px;
    border: 1px solid rgba(37, 99, 235, 0.28);
    outline: none;
    border-radius: 14px;
    background: #fff;
    color: var(--ig-text);
    font-size: 16px;
    font-weight: 550;
    line-height: 54px;
    box-shadow: inset 0 1px 0 rgba(15, 23, 42, 0.03);
    transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease, background 0.25s ease;
    position: relative;
    z-index: 2;
    resize: none;
}

.ig-input-area input::placeholder {
    color: #94a3b8;
    font-weight: 500;
}

.ig-input-area input:focus {
    background: #fff;
    border-color: var(--ig-primary);
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.14), 0 10px 24px rgba(37, 99, 235, 0.12);
    transform: translateY(-1px);
}

.error-container {
    margin-top: 20px;
    position: absolute;
    left: 20px;
    right: 20px;
    bottom: -54px;
}

#error-message {
    display: none;
    margin-top: 16px;
    color: #dc2626;
    font-size: 14px;
    font-weight: 650;
}

.paste-btn,
.view-btn,
.download-btn,
.ipgv-modal-download-btn {
    min-height: 54px;
    border: 0;
    border-radius: 14px;
    padding: 0 22px;
    cursor: pointer;
    font-weight: 750;
    font-size: 15px;
    line-height: 1;
    letter-spacing: 0;
    text-transform: capitalize !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    position: relative;
    z-index: 2;
    white-space: nowrap;
    transition: transform 0.22s ease, box-shadow 0.22s ease, filter 0.22s ease, background 0.22s ease;
}

.paste-btn {
    color: #fff;
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    box-shadow: 0 12px 24px rgba(37, 99, 235, 0.26);
}

.view-btn,
.download-btn {
    color: #fff;
    background: linear-gradient(135deg, #7c3aed 0%, #db2777 100%);
    box-shadow: 0 12px 28px rgba(219, 39, 119, 0.25);
}

.paste-btn:hover,
.view-btn:hover,
.download-btn:hover,
.ipgv-modal-download-btn:hover {
    transform: translateY(-2px);
    filter: saturate(1.08);
    box-shadow: 0 18px 34px rgba(15, 23, 42, 0.18);
}

.paste-btn:active,
.view-btn:active,
.download-btn:active,
.ipgv-modal-download-btn:active {
    transform: translateY(0);
}

.paste-btn:focus-visible,
.view-btn:focus-visible,
.download-btn:focus-visible,
.ipgv-modal-download-btn:focus-visible,
.tab-btn:focus-visible,
.ig-tabs button:focus-visible {
    outline: 3px solid rgba(37, 99, 235, 0.28);
    outline-offset: 3px;
}

.view-btn:disabled {
    opacity: 0.62;
    cursor: not-allowed;
    transform: none;
    background: #cbd5e1;
    box-shadow: none;
}

.ad-space {
    display: none;
    margin-top: 22px;
    text-align: center;
    position: relative;
    border-radius: 18px;
    overflow: hidden;
    padding: 5px;
    background: linear-gradient(135deg, #2563eb, #7c3aed 45%, #db2777);
    background-size: 300% 300%;
    animation: gradientBorder 6s ease infinite;
}

@keyframes gradientBorder {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.ad-inner {
    border-radius: 14px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 14px 32px rgba(15, 23, 42, 0.14);
    transition: transform 0.3s ease;
    animation: floatAd 5s ease-in-out infinite;
}

@keyframes floatAd {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-4px); }
}

.ad-placeholder {
    display: block;
    position: relative;
    color: inherit;
    text-decoration: none;
}

.ad-placeholder::before {
    content: "Sponsored";
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 2;
    padding: 4px 10px;
    border-radius: 999px;
    background: #fff;
    color: var(--ig-accent);
    font-size: 12px;
    font-weight: 700;
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.14);
    animation: pulseTag 2s infinite;
}

@keyframes pulseTag {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.04); opacity: 0.86; }
}

.ad-image {
    width: 100%;
    height: auto;
    display: block;
    transition: transform 0.4s ease;
}

.ad-placeholder:hover .ad-image {
    transform: scale(1.035);
}

@keyframes wiggle {
    0%, 100% { transform: rotate(0deg); }
    25%, 75% { transform: rotate(1.2deg); }
    50% { transform: rotate(-1.2deg); }
}

.note {
    margin-top: 16px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 14px;
    font-style: italic;
}

.tools-result {
    width: 100%;
    margin-top: 34px;
}

.ig-result {
    margin-top: 28px;
    padding: 30px;
    border-radius: 22px;
    background: var(--ig-card);
    color: var(--ig-text);
    box-shadow: var(--ig-shadow);
    border: 1px solid rgba(255, 255, 255, 0.72);
    animation: fadeIn 0.5s ease-out;
}

.ig-profile-header {
    margin-bottom: 34px;
    padding: 30px;
    border-radius: 20px;
    background:
        linear-gradient(145deg, rgba(248, 250, 252, 0.96), rgba(255, 255, 255, 0.98)),
        radial-gradient(circle at top left, rgba(37, 99, 235, 0.12), transparent 40%);
    box-shadow: 0 14px 34px rgba(15, 23, 42, 0.08);
    border: 1px solid var(--ig-border);
    position: relative;
}

.profile-header-content {
    display: flex;
    align-items: center;
    gap: 30px;
    flex-wrap: wrap;
}

.profile-image-container {
    position: relative;
    flex-shrink: 0;
}

.profile-image {
    width: 146px;
    height: 146px;
    min-width: 146px;
    min-height: 146px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid #fff;
    background: linear-gradient(135deg, #2563eb, #db2777);
    padding: 3px;
    box-shadow: 0 18px 38px rgba(15, 23, 42, 0.15);
    color: #94a3b8;
    font-size: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.profile-image:hover {
    transform: scale(1.03);
    box-shadow: 0 22px 44px rgba(15, 23, 42, 0.18);
}

.view-profile-img {
    position: absolute;
    right: 5px;
    bottom: 5px;
    width: 38px;
    height: 38px;
    border: 0;
    border-radius: 50%;
    background: linear-gradient(135deg, #2563eb, #7c3aed);
    color: #fff;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    box-shadow: 0 10px 20px rgba(37, 99, 235, 0.32);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    z-index: 5;
}

.view-profile-img:hover {
    transform: scale(1.08) rotate(8deg);
    box-shadow: 0 14px 28px rgba(37, 99, 235, 0.38);
}

.profile-info {
    flex: 1;
    min-width: 250px;
    text-align: left;
}

.profile-info h3 {
    margin: 0 0 5px;
    color: #0f172a;
    font-size: 24px;
    line-height: 1.25;
    font-weight: 800;
}

.profile-info h4 {
    margin: 0 0 14px;
    color: #475569;
    font-size: 17px;
    line-height: 1.35;
    font-weight: 650;
}

.stats {
    display: flex;
    gap: 18px;
    margin: 16px 0;
    flex-wrap: wrap;
}

.stat-item {
    min-width: 86px;
    padding: 10px 14px;
    border-radius: 14px;
    background: #fff;
    border: 1px solid var(--ig-border);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat-value {
    color: #0f172a;
    font-size: 20px;
    font-weight: 800;
    line-height: 1.15;
}

.stat-label {
    margin-top: 3px;
    color: var(--ig-muted);
    font-size: 13px;
    font-weight: 600;
}

.profile-bio {
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid #e2e8f0;
    text-align: left;
    color: #475569;
    line-height: 1.65;
}

.profile-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 10px;
    color: var(--ig-primary);
    text-decoration: none;
    font-weight: 650;
    transition: color 0.2s ease;
}

.profile-link:hover {
    color: var(--ig-primary-dark);
    text-decoration: underline;
}

.ig-tabs {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin: 28px 0;
    flex-wrap: wrap;
}

.ig-tabs button,
.tab-btn {
    min-height: 44px;
    padding: 0 20px;
    border: 1px solid var(--ig-border);
    border-radius: 999px;
    background: #fff;
    color: #475569;
    font-weight: 750;
    font-size: 14px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
    transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease, color 0.22s ease;
}

.ig-tabs button i,
.tab-btn i {
    font-size: 15px;
}

.ig-tabs button.active,
.tab-btn.active {
    color: #fff;
    background: linear-gradient(135deg, #2563eb 0%, #7c3aed 48%, #db2777 100%);
    border-color: transparent;
    box-shadow: 0 14px 28px rgba(124, 58, 237, 0.24);
    transform: translateY(-2px);
}

.ig-tabs button:hover:not(.active),
.tab-btn:hover:not(.active) {
    color: #0f172a;
    background: #f8fafc;
    transform: translateY(-2px);
}

.tab-content,
.ig-tab-content {
    display: none;
    padding: 18px 0 0;
    text-align: center;
    color: #475569;
}

.tab-content.active,
.ig-tab-content.active {
    display: block;
}

.no-result {
    margin-top: 20px;
    padding: 34px 24px;
    border: 1px dashed #cbd5e1;
    border-radius: 18px;
    background: linear-gradient(145deg, #f8fafc, #fff);
    color: #64748b;
    text-align: center;
    font-size: 16px;
    font-weight: 550;
}

.no-result i {
    display: block;
    margin-bottom: 14px;
    color: #cbd5e1;
    font-size: 46px;
}

.private-account-message {
    margin-top: 20px;
    padding: 18px;
    border-radius: 14px;
    background: rgba(239, 68, 68, 0.1);
    color: #dc2626;
    text-align: center;
    font-weight: 650;
    border: 1px solid rgba(239, 68, 68, 0.2);
    animation: fadeIn 0.5s ease-out;
}

.private-account-message i {
    margin-right: 8px;
    font-size: 18px;
}

.posts-grid,
.skeleton-posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 22px;
    margin-top: 24px;
}

.stories-container,
.skeleton-stories-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 18px;
    margin-top: 24px;
}

.highlights-container,
.skeleton-highlights-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(145px, 1fr));
    gap: 18px;
    margin-top: 24px;
}

.reels-grid,
.skeleton-reels-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
    gap: 22px;
    margin-top: 24px;
}

.post-card,
.story-card,
.highlight-card,
.reel-card,
.skeleton-post,
.skeleton-story,
.skeleton-highlight,
.skeleton-reel {
    overflow: hidden;
    border-radius: 18px;
    background: #fff;
    border: 1px solid var(--ig-border);
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.post-card:hover,
.story-card:hover,
.highlight-card:hover,
.reel-card:hover {
    transform: translateY(-6px);
    border-color: rgba(37, 99, 235, 0.22);
    box-shadow: 0 20px 42px rgba(15, 23, 42, 0.14);
}

.post-img-container,
.story-img-container,
.reel-img-container {
    position: relative;
    overflow: hidden;
}

.post-img-container {
    aspect-ratio: 1 / 1;
}

.story-img-container,
.reel-img-container {
    aspect-ratio: 9 / 16;
}

.post-thumb,
.story-thumb,
.reel-thumb,
.highlight-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.45s ease;
}

.post-img-container:hover .post-thumb,
.story-img-container:hover .story-thumb,
.reel-img-container:hover .reel-thumb {
    transform: scale(1.06);
}

.post-overlay,
.story-overlay,
.reel-overlay,
.highlight-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 14px;
    background: linear-gradient(to bottom, rgba(15, 23, 42, 0.08), rgba(15, 23, 42, 0.68));
    opacity: 0;
    transition: opacity 0.25s ease;
    z-index: 3;
}

.story-overlay,
.reel-overlay {
    flex-direction: column;
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
}

.post-img-container:hover .post-overlay,
.story-img-container:hover .story-overlay,
.reel-img-container:hover .reel-overlay,
.highlight-img-container:hover .highlight-overlay {
    opacity: 1;
}

.reel-img-container .reel-overlay,
.reel-img-container .reel-view-btn,
.reel-img-container .reel-fullscreen-btn {
    opacity: 1;
    visibility: visible;
}

.reel-img-container .reel-fullscreen-btn {
    display: flex;
}

.reel-video.playing {
    display: block;
}

.reel-thumb.hidden {
    display: none;
}

.post-download-btn,
.post-view-btn,
.story-download-btn,
.story-view-btn,
.reel-download-btn,
.reel-view-btn,
.highlight-view-btn,
.post-fullscreen-btn,
.story-fullscreen-btn,
.reel-fullscreen-btn {
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.94);
    color: #0f172a;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.18);
    transition: transform 0.22s ease, background 0.22s ease, color 0.22s ease, box-shadow 0.22s ease;
}

.post-download-btn,
.post-view-btn,
.reel-download-btn,
.reel-view-btn {
    width: 44px;
    height: 44px;
    font-size: 16px;
}

.story-download-btn,
.story-view-btn,
.highlight-view-btn {
    width: 40px;
    height: 40px;
    font-size: 15px;
}

.post-fullscreen-btn,
.story-fullscreen-btn,
.reel-fullscreen-btn {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 38px;
    height: 38px;
    font-size: 15px;
    z-index: 4;
}

.post-download-btn:hover,
.story-download-btn:hover,
.reel-download-btn:hover,
.highlight-view-btn:hover {
    background: linear-gradient(135deg, #2563eb, #7c3aed);
    color: #fff;
    transform: scale(1.08) translateY(-2px);
}

.post-view-btn:hover,
.story-view-btn:hover,
.reel-view-btn:hover,
.post-fullscreen-btn:hover,
.story-fullscreen-btn:hover,
.reel-fullscreen-btn:hover {
    background: linear-gradient(135deg, #7c3aed, #db2777);
    color: #fff;
    transform: scale(1.08);
}

.post-meta,
.reel-meta {
    padding: 18px;
}

.story-meta {
    padding: 12px;
    text-align: center;
}

.post-stats,
.reel-stats,
.story-stats-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
    padding: 8px 11px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.12), rgba(219, 39, 119, 0.1));
    border: 1px solid rgba(37, 99, 235, 0.12);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.post-stats-row,
.reel-stats-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.post-stats span,
.reel-stats span {
    display: flex;
    align-items: center;
    gap: 5px;
    color: #334155;
    font-size: 13px;
    font-weight: 700;
}

.post-stats span i,
.reel-stats span i {
    color: var(--ig-accent);
}

.post-meta .caption,
.reel-meta .caption {
    margin-bottom: 10px;
    color: #334155;
    font-size: 15px;
    line-height: 1.5;
    font-weight: 550;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.post-meta .time,
.story-meta .time,
.reel-meta .time,
.story-stats-row .time {
    color: #64748b;
    font-size: 13px;
    font-weight: 550;
}

.highlight-card {
    cursor: pointer;
    padding: 15px 10px;
    text-align: center;
}

.highlight-img-container {
    position: relative;
    overflow: hidden;
    width: 112px;
    height: 112px;
    aspect-ratio: 1 / 1;
    margin: 0 auto 10px;
    border-radius: 50%;
    padding: 3px;
    background: linear-gradient(135deg, #2563eb, #db2777);
}

.highlight-meta {
    padding: 5px;
    text-align: center;
}

.highlight-title,
.highlight-username {
    margin: 0;
    color: #334155;
    font-size: 14px;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.highlight-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-top: 5px;
    padding: 3px 8px;
    border-radius: 999px;
    background: rgba(37, 99, 235, 0.1);
    color: #2563eb;
    font-size: 12px;
    font-weight: 750;
}

.highlight-items {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 16px;
}

.highlight-item {
    overflow: hidden;
    border-radius: 16px;
    background: #fff;
    border: 1px solid var(--ig-border);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

.post-video,
.story-video,
.reel-video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 2;
}

.media-type-indicator {
    position: absolute;
    top: 8px;
    left: 8px;
    z-index: 5;
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    border-radius: 999px;
    background: rgba(15, 23, 42, 0.82);
    color: #fff;
    font-size: 11px;
    font-weight: 800;
    pointer-events: none;
}

.video-indicator {
    background: rgba(220, 38, 38, 0.9);
}

.image-indicator {
    background: rgba(37, 99, 235, 0.9);
}

.ipgv-profile-img-modal,
.ipgv-media-modal {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.ipgv-profile-img-modal.active,
.ipgv-media-modal.active {
    opacity: 1;
    visibility: visible;
}

.ipgv-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(2, 6, 23, 0.86);
    cursor: pointer;
}

.ipgv-modal-content {
    position: relative;
    z-index: 10001;
    max-width: 90vw;
    max-height: 90vh;
    overflow: hidden;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.36);
    transform: scale(0.92);
    transition: transform 0.25s ease;
}

.ipgv-profile-img-modal.active .ipgv-modal-content,
.ipgv-media-modal.active .ipgv-modal-content {
    transform: scale(1);
}

.ipgv-modal-img,
.modal-img,
.profile-img-modal {
    display: block;
    width: 100%;
    max-width: 560px;
    height: auto;
    max-height: 72vh;
    object-fit: contain;
}

.ipgv-modal-media {
    display: block;
    width: 100%;
    height: auto;
    max-height: 72vh;
    border-radius: 12px;
    object-fit: contain;
}

.ipgv-modal-actions {
    display: flex;
    justify-content: center;
    padding: 18px;
    background: #f8fafc;
}

.ipgv-modal-download-btn {
    color: #fff;
    background: linear-gradient(135deg, #2563eb, #7c3aed);
}

.ipgv-close-modal {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 10002;
    width: 36px;
    height: 36px;
    border: 0;
    border-radius: 50%;
    background: rgba(15, 23, 42, 0.74);
    color: #fff;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: transform 0.2s ease, background 0.2s ease;
}

.ipgv-close-modal:hover {
    background: rgba(15, 23, 42, 0.94);
    transform: scale(1.08);
}

body.ipgv-modal-open {
    overflow: hidden;
}

.skeleton-profile {
    width: 100%;
    animation: fadeIn 0.5s ease-out;
}

.skeleton-profile-header {
    display: flex;
    gap: 30px;
    padding: 30px;
    background: #f9fafb;
    border-radius: 18px;
    margin-bottom: 20px;
    border: 1px solid #f1f5f9;
}

.skeleton-avatar,
.skeleton-username,
.skeleton-fullname,
.skeleton-stat,
.skeleton-bio,
.skeleton-tab,
.skeleton-post-img,
.skeleton-post-stat,
.skeleton-post-caption,
.skeleton-post-caption-short,
.skeleton-post-time,
.skeleton-story-img,
.skeleton-story-time,
.skeleton-highlight-img,
.skeleton-highlight-title,
.skeleton-reel-img,
.skeleton-reel-caption,
.skeleton-reel-caption-short,
.skeleton-reel-stat,
.skeleton-reel-time {
    background: linear-gradient(90deg, #eef2f7 25%, #e2e8f0 50%, #eef2f7 75%);
    background-size: 1000px 100%;
    animation: shimmer 2s infinite linear;
}

.skeleton-avatar {
    width: 146px;
    height: 146px;
    border-radius: 50%;
    flex-shrink: 0;
    border: 4px solid #fff;
    box-shadow: 0 12px 26px rgba(15, 23, 42, 0.1);
}

.skeleton-profile-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.skeleton-username {
    height: 28px;
    width: 180px;
    border-radius: 8px;
}

.skeleton-fullname {
    height: 20px;
    width: 140px;
    border-radius: 8px;
}

.skeleton-stats {
    display: flex;
    gap: 20px;
    margin-top: 10px;
}

.skeleton-stat {
    height: 40px;
    width: 64px;
    border-radius: 8px;
}

.skeleton-bio {
    height: 60px;
    width: 100%;
    border-radius: 8px;
    margin-bottom: 30px;
}

.skeleton-tabs {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-bottom: 30px;
}

.skeleton-tab {
    height: 40px;
    width: 100px;
    border-radius: 999px;
}

.skeleton-post-img {
    aspect-ratio: 1 / 1;
}

.skeleton-story-img,
.skeleton-reel-img {
    aspect-ratio: 9 / 16;
}

.skeleton-post-meta,
.skeleton-reel-meta {
    padding: 18px;
}

.skeleton-story-meta {
    padding: 12px;
    text-align: center;
}

.skeleton-post-stats,
.skeleton-reel-stats {
    display: flex;
    gap: 12px;
    margin-bottom: 10px;
}

.skeleton-post-stat,
.skeleton-reel-stat {
    height: 16px;
    width: 60px;
    border-radius: 5px;
}

.skeleton-post-caption,
.skeleton-post-caption-short,
.skeleton-reel-caption,
.skeleton-reel-caption-short {
    height: 16px;
    border-radius: 5px;
    margin-bottom: 8px;
}

.skeleton-post-caption,
.skeleton-reel-caption {
    width: 100%;
}

.skeleton-post-caption-short,
.skeleton-reel-caption-short {
    width: 70%;
}

.skeleton-post-time,
.skeleton-story-time,
.skeleton-reel-time {
    height: 14px;
    width: 80px;
    border-radius: 5px;
}

.skeleton-story-time {
    margin: 0 auto;
}

.skeleton-highlight {
    padding: 15px 10px;
    text-align: center;
}

.skeleton-highlight-img {
    width: 82px;
    height: 82px;
    border-radius: 50%;
    margin: 0 auto 10px;
}

.skeleton-highlight-title {
    height: 16px;
    width: 80px;
    border-radius: 5px;
    margin: 0 auto;
}

.download-status {
    position: fixed;
    right: 18px;
    bottom: 18px;
    z-index: 10003;
    width: min(360px, calc(100vw - 36px));
    pointer-events: none;
}

.download-toast {
    padding: 14px 16px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.96);
    border-left: 4px solid var(--ig-primary);
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.18);
}

.download-toast.success {
    border-left-color: var(--ig-success);
}

.download-toast.error {
    border-left-color: var(--ig-error);
}

.download-percentage {
    font-size: 13px;
    font-weight: 800;
    color: #334155;
}

.progress-container {
    width: 100%;
    height: 8px;
    margin-top: 8px;
    overflow: hidden;
    border-radius: 999px;
    background: #e2e8f0;
}

.progress-bar {
    width: 0%;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, #2563eb, #db2777);
    transition: width 0.25s ease;
}

.cancel-download:hover {
    background: #dc2626;
    transform: scale(1.05);
}

.fa-solid,
.fa-user,
.fa-paste,
.fa-unlock,
.fa-expand,
.fa-grid-2,
.fa-circle,
.fa-star,
.fa-video,
.fa-images,
.fa-circle-play,
.fa-bookmark,
.fa-clapperboard,
.fa-download,
.fa-eye,
.fa-film,
.fa-heart,
.fa-comment,
.fa-link,
.fa-lock,
.fa-pause,
.fa-play,
.fa-photo-film,
.fa-image,
.fa-xmark,
.fa-badge-check,
.fa-\$\{isVideo,
.\? {
    display: inline-block;
    font-style: normal;
    line-height: 1;
    text-rendering: auto;
}

.fa-solid {
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
}

.fa-grid-2::before {
    content: "\f00a";
}

.fa-badge-check::before {
    content: "\f058";
}

@keyframes shimmer {
    0% { background-position: -1000px 0; }
    100% { background-position: 1000px 0; }
}

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

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

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

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

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

@media (max-width: 1024px) {
    .main-contain,
    .offcontents {
        padding: 18px;
    }

    .ig-tool-wrapper {
        padding: 34px 28px;
    }

    .ig-input-area {
        padding: 20px;
        gap: 12px;
    }

    .posts-grid,
    .skeleton-posts-grid {
        grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
    }

    .stories-container,
    .skeleton-stories-container {
        grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    }

    .reels-grid,
    .skeleton-reels-grid {
        grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
    }
}

@media (max-width: 768px) {
    .wrapper {
        padding: 0;
    }

    .main-contain,
    .offcontents {
        padding: 12px;
    }

    .ig-tool-wrapper {
        margin: 10px auto;
        padding: 24px 16px;
        border-radius: 20px;
    }

    .ig-header h1,
    .ig-header h3 {
        font-size: clamp(24px, 7vw, 32px);
        line-height: 1.2;
        margin-bottom: 12px;
    }

    .ig-header p {
        margin: 12px auto 22px;
        font-size: 15px;
        line-height: 1.6;
    }

    .ig-header p br {
        display: none;
    }

    .ig-input-area {
        flex-direction: column;
        align-items: stretch;
        padding: 16px;
        gap: 12px;
        border-radius: 16px;
    }

    .ig-icon {
        margin-bottom: 0;
        font-size: 13px;
    }

    .ig-input-area input {
        flex: 0 0 auto;
        width: 100%;
        min-width: 0;
        max-width: 100%;
        height: 52px;
        min-height: 52px;
        max-height: 52px;
        padding: 0 16px;
        line-height: 52px;
        font-size: 15px;
    }

    .paste-btn,
    .view-btn {
        width: 100%;
        min-height: 52px;
        margin: 0;
        padding: 0 18px;
        font-size: 14px;
    }

    .profile-header-content {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 20px;
    }

    .ig-profile-header {
        padding: 22px 16px;
        margin-bottom: 26px;
    }

    .profile-info {
        min-width: 0;
        width: 100%;
        text-align: center;
    }

    .profile-image {
        width: 116px;
        height: 116px;
        min-width: 116px;
        min-height: 116px;
        font-size: 46px;
    }

    .view-profile-img {
        width: 34px;
        height: 34px;
    }

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

    .stat-item {
        min-width: 82px;
        padding: 9px 10px;
    }

    .ig-result {
        padding: 18px 14px;
        border-radius: 18px;
    }

    .ig-tabs {
        gap: 8px;
        margin: 22px 0;
    }

    .ig-tabs button,
    .tab-btn {
        flex: 1 1 calc(50% - 8px);
        min-width: 130px;
        padding: 0 12px;
        font-size: 13px;
    }

    .posts-grid,
    .stories-container,
    .highlights-container,
    .reels-grid,
    .skeleton-posts-grid,
    .skeleton-stories-container,
    .skeleton-highlights-container,
    .skeleton-reels-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .story-card,
    .reel-card,
    .skeleton-story,
    .skeleton-reel {
        max-width: 360px;
        width: 100%;
        margin: 0 auto;
    }

    .highlight-img-container {
        width: 88px;
        height: 88px;
    }

    .ipgv-modal-content {
        max-width: 94vw;
        max-height: 84vh;
        margin: 14px;
    }

    .ipgv-modal-img,
    .modal-img,
    .profile-img-modal,
    .ipgv-modal-media {
        max-height: 58vh;
    }

    .ipgv-modal-actions {
        padding: 14px;
    }

    .skeleton-profile-header {
        flex-direction: column;
        align-items: center;
        padding: 22px;
    }

    .skeleton-avatar {
        width: 116px;
        height: 116px;
    }

    .skeleton-profile-info {
        width: 100%;
        align-items: center;
    }

    .skeleton-stats {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .main-contain,
    .offcontents {
        padding: 10px;
    }

    .ig-tool-wrapper {
        padding: 20px 12px;
        border-radius: 18px;
    }

    .ig-header h1,
    .ig-header h3 {
        font-size: clamp(22px, 7.2vw, 28px);
    }

    .ig-header p {
        font-size: 14px;
    }

    .ig-input-area {
        padding: 12px;
        gap: 10px;
    }

    .ig-input-area input {
        height: 50px;
        min-height: 50px;
        max-height: 50px;
        line-height: 50px;
        font-size: 14px;
    }

    .paste-btn,
    .view-btn {
        min-height: 50px;
        font-size: 14px;
    }

    .profile-image {
        width: 96px;
        height: 96px;
        min-width: 96px;
        min-height: 96px;
        font-size: 38px;
    }

    .profile-info h3 {
        font-size: 20px;
    }

    .profile-info h4 {
        font-size: 15px;
    }

    .stat-value {
        font-size: 17px;
    }

    .stat-label {
        font-size: 12px;
    }

    .ig-tabs button,
    .tab-btn {
        min-width: 100%;
        min-height: 42px;
    }

    .post-meta,
    .reel-meta {
        padding: 14px;
    }

    .post-download-btn,
    .post-view-btn,
    .story-download-btn,
    .story-view-btn,
    .reel-download-btn,
    .reel-view-btn,
    .highlight-view-btn {
        width: 38px;
        height: 38px;
        font-size: 14px;
    }

    .no-result {
        padding: 26px 16px;
        font-size: 14px;
    }

    .download-status {
        right: 10px;
        bottom: 10px;
        width: calc(100vw - 20px);
    }
}