/* ==========================================================================
   FRYNZY ACCOUNTS & ASSOCIATION (INSTAGRAM & YOUTUBE)
   Pure Apple iOS Design System (Cupertino frosted glass, smooth physics)
   ========================================================================== */

/* --- Page plein écran iOS (Comptes, Instagram, YouTube, Watch Later) --- */
.frynzy-acc-page {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #F2F2F7;
    z-index: 100010;
    display: none;
    flex-direction: column;
    overflow: hidden;
    transform: translate3d(100%, 0, 0);
    transition: transform 0.32s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.25s ease;
    opacity: 0;
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
}

.frynzy-acc-page.active {
    display: flex;
    transform: translate3d(0, 0, 0);
    opacity: 1;
}

.frynzy-acc-page.closing {
    transform: translate3d(100%, 0, 0);
    opacity: 0;
}

/* Thème Sombre */
body.dark-theme .frynzy-acc-page,
[data-theme="dark"] .frynzy-acc-page {
    background-color: #000000;
    color: #F5F5F7;
}

/* --- Barre de navigation iOS supérieure --- */
.frynzy-acc-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: calc(50px + max(var(--sat, 44px), env(safe-area-inset-top, 44px)));
    height: calc(50px + max(var(--sat, 44px), env(safe-area-inset-top, 44px)));
    padding: max(var(--sat, 44px), env(safe-area-inset-top, 44px)) 12px 0 12px;
    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(25px) saturate(180%);
    -webkit-backdrop-filter: blur(25px) saturate(180%);
    border-bottom: 0.5px solid rgba(0, 0, 0, 0.12);
    box-sizing: border-box;
    position: relative;
    z-index: 50;
    flex-shrink: 0;
}

body.dark-theme .frynzy-acc-nav,
[data-theme="dark"] .frynzy-acc-nav {
    background: rgba(28, 28, 30, 0.88);
    border-bottom: 0.5px solid rgba(255, 255, 255, 0.12);
}

.frynzy-acc-nav-left {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
    min-width: 0;
}

.frynzy-acc-nav-btn {
    background: none;
    border: none;
    padding: 8px 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #000000 !important;
    font-size: 1.15rem;
    cursor: pointer;
    border-radius: 8px;
    transition: opacity 0.15s ease, transform 0.1s ease;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
    flex-shrink: 0;
}

body.dark-theme .frynzy-acc-nav-btn,
[data-theme="dark"] .frynzy-acc-nav-btn {
    color: #FFFFFF !important;
}

.frynzy-acc-nav-btn:active {
    opacity: 0.55;
    transform: scale(0.95);
}

.frynzy-acc-nav-btn i {
    font-size: 1.25rem;
}

.frynzy-acc-nav-title {
    font-size: 1.18rem;
    font-weight: 700;
    letter-spacing: -0.35px;
    color: #000000;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: left;
    margin: 0;
    padding: 0;
}

body.dark-theme .frynzy-acc-nav-title,
[data-theme="dark"] .frynzy-acc-nav-title {
    color: #FFFFFF;
}

.frynzy-acc-nav-right {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    flex-shrink: 0;
}

.frynzy-acc-info-btn {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.05);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #000000 !important;
    font-size: 0.95rem;
    cursor: pointer;
    transition: background 0.15s ease, transform 0.1s ease;
}

body.dark-theme .frynzy-acc-info-btn,
[data-theme="dark"] .frynzy-acc-info-btn {
    background: rgba(255, 255, 255, 0.12);
    color: #FFFFFF !important;
}

.frynzy-acc-info-btn:active {
    transform: scale(0.92);
    background: rgba(0, 0, 0, 0.1);
}

/* --- Contenu de page défilable style iOS --- */
.frynzy-acc-body {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
    padding: 20px 16px calc(max(var(--sab, 24px), env(safe-area-inset-bottom, 24px)) + 30px) 16px;
    box-sizing: border-box;
    will-change: scroll-position;
}

/* --- Section Groupée iOS Inset (Liste des comptes) --- */
.frynzy-ios-group {
    background: #FFFFFF;
    border-radius: 16px;
    overflow: hidden;
    margin-bottom: 24px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04), 0 4px 12px rgba(0, 0, 0, 0.03);
    border: 0.5px solid rgba(0, 0, 0, 0.06);
}

body.dark-theme .frynzy-ios-group,
[data-theme="dark"] .frynzy-ios-group {
    background: #1C1C1E;
    border: 0.5px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
}

.frynzy-ios-group-title {
    font-size: 0.78rem;
    font-weight: 600;
    text-transform: uppercase;
    color: #6E6E73;
    letter-spacing: 0.5px;
    margin: 0 0 8px 12px;
}

.frynzy-ios-row-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 13px 16px;
    cursor: pointer;
    background: transparent;
    transition: background 0.15s ease;
    position: relative;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.frynzy-ios-row-item:active {
    background: rgba(0, 0, 0, 0.05);
}

body.dark-theme .frynzy-ios-row-item:active,
[data-theme="dark"] .frynzy-ios-row-item:active {
    background: rgba(255, 255, 255, 0.08);
}

.frynzy-ios-row-item:not(:last-child)::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    left: 64px;
    height: 0.5px;
    background: rgba(0, 0, 0, 0.08);
}

body.dark-theme .frynzy-ios-row-item:not(:last-child)::after,
[data-theme="dark"] .frynzy-ios-row-item:not(:last-child)::after {
    background: rgba(255, 255, 255, 0.1);
}

.frynzy-ios-row-leading {
    display: flex;
    align-items: center;
    gap: 14px;
}

.frynzy-acc-badge-icon {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
    position: relative;
}

.instagram-bg {
    background: radial-gradient(circle at 30% 107%, #fdf497 0%, #fdf497 5%, #fd5949 45%, #d6249f 60%, #285AEB 90%) !important;
}

.youtube-bg {
    background: #FF0000 !important;
}

.frynzy-ios-row-text {
    display: flex;
    flex-direction: column;
}

.frynzy-ios-row-name {
    font-size: 1.02rem;
    font-weight: 600;
    color: #000000;
    letter-spacing: -0.2px;
}

body.dark-theme .frynzy-ios-row-name,
[data-theme="dark"] .frynzy-ios-row-name {
    color: #FFFFFF;
}

.frynzy-ios-row-desc {
    font-size: 0.8rem;
    color: #8E8E93;
    margin-top: 1px;
}

.frynzy-ios-row-trailing {
    display: flex;
    align-items: center;
    gap: 8px;
}

.frynzy-ios-chevron {
    color: #C7C7CC;
    font-size: 0.85rem;
    margin-left: 2px;
}

/* --- Hero Association Frynzy <-> Plateforme --- */
/* --- Hero Association Frynzy <-> Plateforme & 3D Orbital Scene --- */
.frynzy-assoc-hero {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 24px 16px 20px 16px;
    margin-bottom: 20px;
    position: relative;
    overflow: visible;
}

.frynzy-assoc-logos-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    margin-bottom: 20px;
    position: relative;
    width: 100%;
    max-width: 330px;
    min-height: 90px;
    perspective: 1000px;
    -webkit-perspective: 1000px;
}

.frynzy-hero-logo-box {
    width: 68px;
    height: 68px;
    border-radius: 20px;
    background: #FFFFFF;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08), 0 1px 3px rgba(0, 0, 0, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px;
    box-sizing: border-box;
    position: relative;
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 10;
}

body.dark-theme .frynzy-hero-logo-box,
[data-theme="dark"] .frynzy-hero-logo-box {
    background: #2C2C2E;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
}

.frynzy-hero-logo-box img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.frynzy-hero-bridge {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.05);
    color: #8E8E93;
    font-size: 1rem;
    animation: frynzyPulseBridge 2.2s infinite ease-in-out;
    transition: all 0.4s ease;
    z-index: 5;
}

body.dark-theme .frynzy-hero-bridge,
[data-theme="dark"] .frynzy-hero-bridge {
    background: rgba(255, 255, 255, 0.1);
    color: #AEAEB2;
}

@keyframes frynzyPulseBridge {
    0%, 100% { transform: scale(1); opacity: 0.85; }
    50% { transform: scale(1.08); opacity: 1; }
}

/* --- YOUTUBE 3D ORBITAL ARENA & DOCKED SYSTEM --- */
/* Mode Connecté & Animé : Le logo YouTube se positionne au centre parfait */
.frynzy-assoc-logos-row.is-yt-connected #frynzyYtInitialFrynzy,
.frynzy-assoc-logos-row.is-yt-connected #frynzyYtInitialArrow,
.frynzy-assoc-logos-row.is-yt-animating #frynzyYtInitialFrynzy,
.frynzy-assoc-logos-row.is-yt-animating #frynzyYtInitialArrow {
    opacity: 0 !important;
    transform: scale(0.3) !important;
    pointer-events: none !important;
    display: none !important;
}

.frynzy-assoc-logos-row.is-yt-connected #frynzyYtCentralBox,
.frynzy-assoc-logos-row.is-yt-animating #frynzyYtCentralBox {
    position: relative !important;
    margin: 0 auto !important;
    transform: scale(1.12) !important;
    box-shadow: 0 14px 40px rgba(255, 0, 0, 0.35), 0 0 20px rgba(255, 0, 0, 0.2) !important;
    z-index: 10 !important;
    overflow: visible !important;
}

/* Badge Frynzy arrimé en bas à droite sur le logo YouTube */
.frynzy-hero-dock-badge {
    position: absolute;
    bottom: -8px;
    right: -8px;
    width: 32px;
    height: 32px;
    border-radius: 10px;
    background: #ffffff;
    border: 2px solid #ffffff;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.28);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 30;
    padding: 3px;
    box-sizing: border-box;
    animation: frynzyPopBadge 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.frynzy-hero-dock-badge img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 6px;
}

@keyframes frynzyPopBadge {
    0% { transform: scale(0) rotate(-45deg); opacity: 0; }
    100% { transform: scale(1) rotate(0deg); opacity: 1; }
}

/* Avatar utilisateur arrimé en haut à droite (hors du logo YouTube) */
.frynzy-hero-dock-avatar {
    position: absolute;
    top: -2px;
    right: 14px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #ffffff;
    border: 2.5px solid #ffffff;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.16), 0 0 0 1px rgba(0,0,0,0.06);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    z-index: 25;
    animation: frynzyPopAvatar 0.45s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.frynzy-hero-dock-avatar img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    border-radius: 50%;
    display: block;
}

.frynzy-hero-dock-avatar-fallback {
    width: 100%;
    height: 100%;
    background: #eff6ff;
    color: #2563eb;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
}

@keyframes frynzyPopAvatar {
    0% { transform: scale(0) translate3d(20px, -20px, 0); opacity: 0; }
    100% { transform: scale(1) translate3d(0, 0, 0); opacity: 1; }
}

/* Icônes Vidéo & Playlist arrimées sur le bord gauche (hors du logo YouTube) */
.frynzy-hero-dock-left {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    left: 14px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    z-index: 25;
    animation: frynzyPopLeft 0.45s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

@keyframes frynzyPopLeft {
    0% { transform: translateY(-50%) scale(0) translateX(-20px); opacity: 0; }
    100% { transform: translateY(-50%) scale(1) translateX(0); opacity: 1; }
}

.frynzy-hero-dock-pill {
    width: 36px;
    height: 36px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.95);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
}

.frynzy-hero-dock-pill.video {
    color: #ef4444;
}

.frynzy-hero-dock-pill.playlist {
    color: #3b82f6;
}

body.dark-theme .frynzy-hero-dock-pill,
[data-theme="dark"] .frynzy-hero-dock-pill {
    background: rgba(44, 44, 46, 0.92);
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
}

/* Scène Orbitale 3D (pendant la rotation) */
.frynzy-orbit-stage {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    perspective: 800px;
    -webkit-perspective: 800px;
    transform-style: preserve-3d;
}

.frynzy-orbit-satellite {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 36px;
    height: 36px;
    margin-top: -18px;
    margin-left: -18px;
    border-radius: 11px;
    background: #ffffff;
    border: 1.5px solid rgba(255, 255, 255, 0.95);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18);
    display: flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    will-change: transform, opacity, z-index;
}

.frynzy-orbit-satellite.satellite-avatar {
    border-radius: 50% !important;
    overflow: hidden;
}

.frynzy-orbit-satellite.satellite-avatar img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    border-radius: 50%;
    display: block;
}

.frynzy-orbit-satellite.satellite-frynzy img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 3px;
    box-sizing: border-box;
}

.frynzy-orbit-satellite.satellite-video {
    color: #ef4444;
    font-size: 0.95rem;
}

.frynzy-orbit-satellite.satellite-playlist {
    color: #3b82f6;
    font-size: 0.95rem;
}

/* Keyframes de Révolution Orbitale 3D "Couchée" (de Droite vers la Gauche)
   L'axe horizontal X varie de +110px à -110px.
   L'axe vertical Y varie de -24px (arrière) à +24px (devant).
   L'axe de profondeur Z varie de -80px (derrière le logo, scale 0.76, z-index 4)
   à +80px (devant le logo, scale 1.08, z-index 25).
*/
@keyframes frynzyOrbitSat1 {
    /* Avatar : Démarre à Droite (0%), va vers l'arrière gauche, puis devant droite, puis s'arrime en haut à droite */
    0% {
        transform: translate3d(112px, 0px, 0px) scale(0.95);
        z-index: 15;
        opacity: 1;
    }
    25% {
        transform: translate3d(0px, -24px, -80px) scale(0.76);
        z-index: 4;
        opacity: 0.85;
    }
    50% {
        transform: translate3d(-112px, 0px, 0px) scale(0.95);
        z-index: 15;
        opacity: 1;
    }
    75% {
        transform: translate3d(0px, 24px, 80px) scale(1.08);
        z-index: 25;
        opacity: 1;
    }
    90% {
        transform: translate3d(112px, 0px, 0px) scale(1);
        z-index: 25;
        opacity: 1;
    }
    100% {
        transform: translate3d(114px, -32px, 0px) scale(1.15);
        z-index: 25;
        opacity: 1;
    }
}

@keyframes frynzyOrbitSat2 {
    /* Frynzy : Démarre en Arrière (25% d'angle), passe à gauche, devant, puis s'arrime en bas à droite sur YouTube */
    0% {
        transform: translate3d(0px, -24px, -80px) scale(0.76);
        z-index: 4;
        opacity: 0.85;
    }
    25% {
        transform: translate3d(-112px, 0px, 0px) scale(0.95);
        z-index: 15;
        opacity: 1;
    }
    50% {
        transform: translate3d(0px, 24px, 80px) scale(1.08);
        z-index: 25;
        opacity: 1;
    }
    75% {
        transform: translate3d(112px, 0px, 0px) scale(1);
        z-index: 25;
        opacity: 1;
    }
    90% {
        transform: translate3d(60px, 16px, 40px) scale(0.98);
        z-index: 25;
        opacity: 1;
    }
    100% {
        transform: translate3d(26px, 26px, 0px) scale(0.9);
        z-index: 30;
        opacity: 1;
    }
}

@keyframes frynzyOrbitSat3 {
    /* Vidéo : Démarre à Gauche (50% d'angle), passe devant, droite, arrière, puis s'arrime sur le bord gauche haut */
    0% {
        transform: translate3d(-112px, 0px, 0px) scale(0.95);
        z-index: 15;
        opacity: 1;
    }
    25% {
        transform: translate3d(0px, 24px, 80px) scale(1.08);
        z-index: 25;
        opacity: 1;
    }
    50% {
        transform: translate3d(112px, 0px, 0px) scale(1);
        z-index: 25;
        opacity: 1;
    }
    75% {
        transform: translate3d(0px, -24px, -80px) scale(0.76);
        z-index: 4;
        opacity: 0.85;
    }
    90% {
        transform: translate3d(-112px, 0px, 0px) scale(0.95);
        z-index: 15;
        opacity: 1;
    }
    100% {
        transform: translate3d(-118px, -18px, 0px) scale(1);
        z-index: 25;
        opacity: 1;
    }
}

@keyframes frynzyOrbitSat4 {
    /* Playlist : Démarre Devant (75% d'angle), passe à droite, arrière, gauche, puis s'arrime sur le bord gauche bas */
    0% {
        transform: translate3d(0px, 24px, 80px) scale(1.08);
        z-index: 25;
        opacity: 1;
    }
    25% {
        transform: translate3d(112px, 0px, 0px) scale(1);
        z-index: 25;
        opacity: 1;
    }
    50% {
        transform: translate3d(0px, -24px, -80px) scale(0.76);
        z-index: 4;
        opacity: 0.85;
    }
    75% {
        transform: translate3d(-112px, 0px, 0px) scale(0.95);
        z-index: 15;
        opacity: 1;
    }
    90% {
        transform: translate3d(-112px, 12px, 0px) scale(0.98);
        z-index: 20;
        opacity: 1;
    }
    100% {
        transform: translate3d(-118px, 24px, 0px) scale(1);
        z-index: 25;
        opacity: 1;
    }
}

.is-yt-animating #frynzyOrbitSatAvatar {
    animation: frynzyOrbitSat1 2.4s cubic-bezier(0.25, 1, 0.5, 1) forwards !important;
}

.is-yt-animating #frynzyOrbitSatFrynzy {
    animation: frynzyOrbitSat2 2.4s cubic-bezier(0.25, 1, 0.5, 1) forwards !important;
}

.is-yt-animating #frynzyOrbitSatVideo {
    animation: frynzyOrbitSat3 2.4s cubic-bezier(0.25, 1, 0.5, 1) forwards !important;
}

.is-yt-animating #frynzyOrbitSatPlaylist {
    animation: frynzyOrbitSat4 2.4s cubic-bezier(0.25, 1, 0.5, 1) forwards !important;
}

.frynzy-assoc-headline {
    font-size: 1.35rem;
    font-weight: 800;
    color: #000000;
    letter-spacing: -0.4px;
    margin: 0 0 10px 0;
    line-height: 1.25;
}

body.dark-theme .frynzy-assoc-headline,
[data-theme="dark"] .frynzy-assoc-headline {
    color: #FFFFFF;
}

.frynzy-assoc-subtitle {
    font-size: 0.92rem;
    color: #6E6E73;
    line-height: 1.45;
    margin: 0;
    max-width: 90%;
}

body.dark-theme .frynzy-assoc-subtitle,
[data-theme="dark"] .frynzy-assoc-subtitle {
    color: #A1A1A6;
}

/* --- Cartes des avantages (Benefits) --- */
.frynzy-benefits-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 24px;
}

.frynzy-benefit-card {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    background: #FFFFFF;
    border-radius: 16px;
    padding: 14px 16px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
    border: 0.5px solid rgba(0, 0, 0, 0.05);
}

body.dark-theme .frynzy-benefit-card,
[data-theme="dark"] .frynzy-benefit-card {
    background: #1C1C1E;
    border: 0.5px solid rgba(255, 255, 255, 0.08);
}

.frynzy-benefit-icon-wrap {
    width: 38px;
    height: 38px;
    border-radius: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
    flex-shrink: 0;
    margin-top: 1px;
    color: #636366 !important;
    background: rgba(0, 0, 0, 0.04) !important;
    backdrop-filter: blur(14px) !important;
    -webkit-backdrop-filter: blur(14px) !important;
    border: 1px solid rgba(0, 0, 0, 0.06) !important;
    box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.8), 0 2px 6px rgba(0, 0, 0, 0.03) !important;
}

body.dark-theme .frynzy-benefit-icon-wrap,
[data-theme="dark"] .frynzy-benefit-icon-wrap {
    color: #AEAEB2 !important;
    background: rgba(255, 255, 255, 0.08) !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.15) !important;
}

.frynzy-benefit-content {
    flex: 1;
}

.frynzy-benefit-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #1C1C1E;
    margin-bottom: 3px;
    letter-spacing: -0.2px;
}

body.dark-theme .frynzy-benefit-title,
[data-theme="dark"] .frynzy-benefit-title {
    color: #F5F5F7;
}

.frynzy-benefit-desc {
    font-size: 0.82rem;
    color: #6E6E73;
    line-height: 1.4;
}

body.dark-theme .frynzy-benefit-desc,
[data-theme="dark"] .frynzy-benefit-desc {
    color: #8E8E93;
}

/* --- Zone d'action Connexion / État vérifié --- */
.frynzy-action-box {
    margin-top: 10px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Boutons principaux iOS */
.frynzy-btn-ig-connect {
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    color: #FFFFFF;
    border: none;
    border-radius: 14px;
    padding: 16px 20px;
    font-size: 1.02rem;
    font-weight: 700;
    letter-spacing: -0.2px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    cursor: pointer;
    box-shadow: 0 4px 18px rgba(220, 39, 67, 0.35);
    transition: transform 0.15s ease, filter 0.15s ease;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.frynzy-btn-ig-connect:active {
    transform: scale(0.97);
    filter: brightness(0.92);
}

.frynzy-btn-yt-connect {
    background: #FF0000;
    color: #FFFFFF;
    border: none;
    border-radius: 14px;
    padding: 16px 20px;
    font-size: 1.02rem;
    font-weight: 700;
    letter-spacing: -0.2px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    cursor: pointer;
    box-shadow: 0 4px 18px rgba(255, 0, 0, 0.32);
    transition: transform 0.15s ease, filter 0.15s ease;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.frynzy-btn-yt-connect:active {
    transform: scale(0.97);
    filter: brightness(0.92);
}

.frynzy-btn-watchlater {
    background: #007AFF;
    color: #FFFFFF;
    border: none;
    border-radius: 14px;
    padding: 15px 20px;
    font-size: 0.98rem;
    font-weight: 700;
    letter-spacing: -0.2px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(0, 122, 255, 0.28);
    transition: transform 0.15s ease;
    user-select: none;
}

.frynzy-btn-watchlater:active {
    transform: scale(0.97);
}

/* Carte Vérifiée iOS (quand connecté) */
.frynzy-verified-badge-card {
    background: #FFFFFF;
    border-radius: 16px;
    padding: 18px 16px;
    display: flex;
    align-items: center;
    gap: 14px;
    border: 1.5px solid rgba(52, 199, 89, 0.4);
    box-shadow: 0 4px 16px rgba(52, 199, 89, 0.12);
}

body.dark-theme .frynzy-verified-badge-card,
[data-theme="dark"] .frynzy-verified-badge-card {
    background: #1C1C1E;
    border: 1.5px solid rgba(48, 209, 88, 0.45);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

.frynzy-verified-icon {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #34C759;
    color: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(52, 199, 89, 0.4);
}

.frynzy-verified-info {
    flex: 1;
}

.frynzy-verified-title {
    font-size: 0.98rem;
    font-weight: 700;
    color: #1C1C1E;
    display: flex;
    align-items: center;
    gap: 6px;
}

body.dark-theme .frynzy-verified-title,
[data-theme="dark"] .frynzy-verified-title {
    color: #FFFFFF;
}

.frynzy-verified-user {
    font-size: 0.85rem;
    color: #007AFF;
    font-weight: 600;
    margin-top: 2px;
}

.frynzy-verified-sub {
    font-size: 0.75rem;
    color: #8E8E93;
    margin-top: 1px;
}

/* --- Modale Info / Options Bottom Sheet iOS --- */
.frynzy-acc-modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 100050;
    display: none;
    align-items: flex-end;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.25s ease;
}

.frynzy-acc-modal-backdrop.active {
    display: flex;
    opacity: 1;
}

.frynzy-acc-sheet {
    background: #FFFFFF;
    width: 100%;
    max-width: 500px;
    border-radius: 24px 24px 0 0;
    padding: 12px 20px calc(max(var(--sab, 20px), env(safe-area-inset-bottom, 20px)) + 16px) 20px;
    box-sizing: border-box;
    transform: translateY(100%);
    transition: transform 0.32s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.15);
}

body.dark-theme .frynzy-acc-sheet,
[data-theme="dark"] .frynzy-acc-sheet {
    background: #1C1C1E;
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.6);
}

.frynzy-acc-modal-backdrop.active .frynzy-acc-sheet {
    transform: translateY(0);
}

.frynzy-sheet-handle {
    width: 40px;
    height: 5px;
    background: #C7C7CC;
    border-radius: 3px;
    margin: 4px auto 18px auto;
}

body.dark-theme .frynzy-sheet-handle,
[data-theme="dark"] .frynzy-sheet-handle {
    background: #48484A;
}

.frynzy-sheet-header-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
}

.frynzy-sheet-title {
    font-size: 1.15rem;
    font-weight: 700;
    color: #000000;
    letter-spacing: -0.3px;
}

body.dark-theme .frynzy-sheet-title,
[data-theme="dark"] .frynzy-sheet-title {
    color: #FFFFFF;
}

.frynzy-sheet-close-btn {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.06);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #000000 !important;
    font-size: 0.9rem;
    cursor: pointer;
}

body.dark-theme .frynzy-sheet-close-btn,
[data-theme="dark"] .frynzy-sheet-close-btn {
    background: rgba(255, 255, 255, 0.12);
    color: #FFFFFF !important;
}

.frynzy-sheet-info-group {
    background: #F2F2F7;
    border-radius: 14px;
    padding: 12px 16px;
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

body.dark-theme .frynzy-sheet-info-group,
[data-theme="dark"] .frynzy-sheet-info-group {
    background: #2C2C2E;
}

.frynzy-sheet-info-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.88rem;
}

.frynzy-sheet-info-label {
    color: #8E8E93;
}

.frynzy-sheet-info-val {
    color: #000000;
    font-weight: 600;
}

body.dark-theme .frynzy-sheet-info-val,
[data-theme="dark"] .frynzy-sheet-info-val {
    color: #FFFFFF;
}

.frynzy-btn-destructive {
    width: 100%;
    background: rgba(255, 59, 48, 0.1);
    color: #FF3B30;
    border: 1px solid rgba(255, 59, 48, 0.25);
    border-radius: 14px;
    padding: 15px;
    font-size: 0.98rem;
    font-weight: 700;
    letter-spacing: -0.2px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    transition: background 0.15s ease, transform 0.1s ease;
    user-select: none;
}

.frynzy-btn-destructive:active {
    background: rgba(255, 59, 48, 0.2);
    transform: scale(0.98);
}

/* --- Page "À regarder plus tard" (Watch Later) --- */
.frynzy-wl-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.frynzy-wl-card {
    background: #FFFFFF;
    border-radius: 16px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04), 0 4px 12px rgba(0, 0, 0, 0.03);
    border: 0.5px solid rgba(0, 0, 0, 0.06);
    transition: transform 0.15s ease;
}

body.dark-theme .frynzy-wl-card,
[data-theme="dark"] .frynzy-wl-card {
    background: #1C1C1E;
    border: 0.5px solid rgba(255, 255, 255, 0.08);
}

.frynzy-wl-thumb-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000000;
    overflow: hidden;
}

.frynzy-wl-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.frynzy-wl-duration {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.82);
    color: #FFFFFF;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 3px 6px;
    border-radius: 6px;
    backdrop-filter: blur(4px);
    letter-spacing: 0.3px;
}

.frynzy-wl-body {
    padding: 12px 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.frynzy-wl-meta {
    flex: 1;
    min-width: 0;
}

.frynzy-wl-title {
    font-size: 0.92rem;
    font-weight: 700;
    color: #1C1C1E;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    letter-spacing: -0.2px;
}

body.dark-theme .frynzy-wl-title,
[data-theme="dark"] .frynzy-wl-title {
    color: #F5F5F7;
}

.frynzy-wl-channel {
    font-size: 0.78rem;
    color: #8E8E93;
    margin-top: 3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.frynzy-wl-dl-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #007AFF;
    color: #FFFFFF;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    cursor: pointer;
    flex-shrink: 0;
    box-shadow: 0 3px 10px rgba(0, 122, 255, 0.3);
    transition: transform 0.12s ease, background 0.15s ease;
}

.frynzy-wl-dl-btn:active {
    transform: scale(0.92);
    background: #0056B3;
}

/* --- Shimmer Skeleton Animation iOS --- */
.frynzy-shimmer {
    background: linear-gradient(90deg, #E5E5EA 25%, #F2F2F7 50%, #E5E5EA 75%);
    background-size: 200% 100%;
    animation: frynzyShimmerAnim 1.6s infinite ease-in-out;
    border-radius: 8px;
}

body.dark-theme .frynzy-shimmer,
[data-theme="dark"] .frynzy-shimmer {
    background: linear-gradient(90deg, #2C2C2E 25%, #3A3A3C 50%, #2C2C2E 75%);
    background-size: 200% 100%;
}

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

.frynzy-skeleton-card {
    background: #FFFFFF;
    border-radius: 16px;
    overflow: hidden;
    padding: 0;
    border: 0.5px solid rgba(0, 0, 0, 0.06);
    display: flex;
    flex-direction: column;
}

body.dark-theme .frynzy-skeleton-card,
[data-theme="dark"] .frynzy-skeleton-card {
    background: #1C1C1E;
    border: 0.5px solid rgba(255, 255, 255, 0.08);
}

.frynzy-skel-thumb {
    width: 100%;
    aspect-ratio: 16 / 9;
}

.frynzy-skel-body {
    padding: 12px 14px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.frynzy-skel-text-col {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.frynzy-skel-line-1 {
    width: 85%;
    height: 14px;
}

.frynzy-skel-line-2 {
    width: 50%;
    height: 11px;
}

.frynzy-skel-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
}
