﻿/* سیستم طراحی صفحات بازطراحی‌شده (صفحه اصلی، صفحه پرامپت و ...). پیشوند همه کلاس‌ها ph- است؛ ظرف صفحه کلاس ph می‌گیرد */
.ph {
    --ph-ink: #0f172b;
    --ph-ink-2: #1b2640;
    --ph-muted: #5a6880;
    --ph-paper: #f5f7fb;
    --ph-card: #fff;
    --ph-line: #e2e7f0;
    --ph-teal: #00ac94;
    --ph-teal-ink: #00806e;
    --ph-teal-soft: #e2f5f1;
    --ph-gold: #c9a14a;
    --ph-gold-soft: #f6eedb;
    --ph-blue: #2f6fe4;
    --ph-rose: #d6336c;
    --ph-orange: #db5a2a;
    --ph-r-lg: 26px;
    --ph-r-md: 18px;
    --ph-shadow: 0 1px 2px rgba(15, 23, 43, .05), 0 8px 24px -12px rgba(15, 23, 43, .18);
    color: var(--ph-ink);
    line-height: 1.8;
}

    .ph *, .ph *::before, .ph *::after {
        box-sizing: border-box;
    }

    .ph h1, .ph h2, .ph h3 {
        margin: 0;
        line-height: 1.4;
        text-wrap: pretty;
    }

    .ph a {
        color: inherit;
        text-decoration: none;
    }

    .ph img {
        max-width: 100%;
        display: block;
    }

    .ph a:focus-visible, .ph button:focus-visible, .ph input:focus-visible {
        outline: 3px solid rgba(0, 172, 148, .5);
        outline-offset: 2px;
    }

.ph-sprite {
    position: absolute;
}

.ph-ico {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
    flex: none;
}

.ph-ico--gold {
    color: var(--ph-gold);
    width: 26px;
    height: 26px;
}

.ph-sr {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

.ph-badge {
    display: inline-block;
    font-size: 10.5px;
    font-weight: bold;
    padding: 0 7px;
    border-radius: 99px;
    line-height: 1.9;
    vertical-align: middle;
}

.ph-badge--hot { background: #ffece4; color: var(--ph-orange); }
.ph-badge--new { background: var(--ph-gold-soft); color: #8a6a1f; }
.ph-badge--soon { background: #fde8ef; color: var(--ph-rose); }

.ph-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 14px;
    border-radius: 99px;
    background: var(--ph-card);
    border: 1px solid var(--ph-line);
    font-size: 13.5px;
    font-weight: 500;
    transition: border-color .15s, color .15s;
}

    .ph-chip:hover {
        border-color: var(--ph-teal);
        color: var(--ph-teal-ink);
    }

/* ---------- هیرو ---------- */
.ph-hero {
    display: grid;
    grid-template-columns: 1.08fr 1fr;
    gap: 40px;
    align-items: center;
    padding-block: 48px 32px;
}

.ph-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 5px 14px 5px 12px;
    border-radius: 99px;
    background: var(--ph-teal-soft);
    color: var(--ph-teal-ink);
    font-size: 13px;
    font-weight: bold;
}

.ph-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--ph-teal);
    box-shadow: 0 0 0 4px rgba(0, 172, 148, .18);
}

.ph-hero h1 {
    margin-top: 16px;
    font-size: 60px;
    font-weight: bold;
    line-height: 1.2;
}

.ph-accent {
    display: block;
    margin-top: 12px;
    font-size: 28px;
    color: var(--ph-teal-ink);
}

.ph-hero-desc {
    max-width: 56ch;
    margin: 16px 0 24px;
    color: var(--ph-muted);
    font-size: 16px;
    line-height: 2;
}

.ph-search {
    display: flex;
    align-items: center;
    gap: 10px;
    max-width: 600px;
    height: 62px;
    padding: 7px 18px 7px 7px;
    border-radius: 18px;
    background: var(--ph-card);
    border: 1px solid var(--ph-line);
    box-shadow: var(--ph-shadow);
}

    .ph-search .ph-ico {
        width: 22px;
        height: 22px;
        color: var(--ph-muted);
    }

    .ph-search input {
        flex: 1;
        min-width: 0;
        height: 100%;
        border: 0;
        outline: 0;
        background: transparent;
        font-family: inherit;
        font-size: 15.5px;
        color: var(--ph-ink);
    }

    .ph-search button {
        height: 48px;
        padding: 0 26px;
        border: 0;
        border-radius: 12px;
        background: var(--ph-ink);
        color: #fff;
        font-family: inherit;
        font-size: 14.5px;
        font-weight: bold;
        cursor: pointer;
    }

.ph-quick {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-top: 16px;
    font-size: 13.5px;
}

    .ph-quick > span {
        color: var(--ph-muted);
        margin-left: 2px;
    }

.ph-hero-ai {
    display: inline-block;
    margin-top: 20px;
    font-size: 14px;
    color: var(--ph-muted) !important;
}

    .ph-hero-ai b {
        color: var(--ph-ink);
        border-bottom: 2px solid var(--ph-teal);
    }

.ph-trust {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 18px;
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px dashed var(--ph-line);
    font-size: 13px;
    color: var(--ph-muted);
}

    .ph-trust span {
        display: flex;
        align-items: center;
        gap: 6px;
    }

    .ph-trust .ph-ico {
        width: 16px;
        height: 16px;
        color: var(--ph-teal);
    }

/* یک عکس، چند خروجی */
.ph-fan {
    position: relative;
    height: 460px;
}

.ph-fan-glow {
    position: absolute;
    inset: 40px 30px 30px;
    border-radius: 50%;
    background: radial-gradient(closest-side, rgba(0, 172, 148, .2), transparent 70%);
    filter: blur(10px);
}

.ph-fan-card {
    position: absolute;
    bottom: 90px;
    left: 50%;
    width: 196px;
    height: auto;
    aspect-ratio: 4 / 5;
    object-fit: cover;
    border-radius: 20px;
    border: 5px solid #fff;
    background: #e3e7ee;
    box-shadow: 0 24px 50px -20px rgba(15, 23, 43, .45);
    transform: translateX(calc(-50% + var(--x))) translateY(var(--y)) rotate(var(--r));
    transition: transform .35s cubic-bezier(.2, .8, .2, 1);
}

    .ph-fan-card:nth-child(2) { --x: 196px; --y: 26px; --r: 9deg; z-index: 1; }
    .ph-fan-card:nth-child(3) { --x: 102px; --y: -4px; --r: 4deg; z-index: 2; }
    .ph-fan-card:nth-child(4) { --x: 0px; --y: -22px; --r: 0deg; z-index: 5; width: 232px; }
    .ph-fan-card:nth-child(5) { --x: -102px; --y: -4px; --r: -4deg; z-index: 2; }
    .ph-fan-card:nth-child(6) { --x: -196px; --y: 26px; --r: -9deg; z-index: 1; }

.ph-fan:hover .ph-fan-card:nth-child(2) { --x: 214px; }
.ph-fan:hover .ph-fan-card:nth-child(3) { --x: 110px; }
.ph-fan:hover .ph-fan-card:nth-child(5) { --x: -110px; }
.ph-fan:hover .ph-fan-card:nth-child(6) { --x: -214px; }

.ph-source {
    position: absolute;
    bottom: 0;
    left: 50%;
    z-index: 10;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 18px 8px 8px;
    border-radius: 99px;
    background: var(--ph-card);
    border: 1px solid var(--ph-line);
    box-shadow: var(--ph-shadow);
    white-space: nowrap;
    font-size: 13px;
}

    .ph-source img {
        width: 44px;
        height: 44px;
        border-radius: 50%;
        object-fit: cover;
        object-position: 50% 18%;
        border: 2px solid var(--ph-teal);
    }

    .ph-source b {
        display: block;
        font-size: 14px;
    }

    .ph-source small {
        color: var(--ph-muted);
    }

/* ---------- نوار امکانات ---------- */
.ph-dock {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    overflow: hidden;
    border-radius: var(--ph-r-lg);
    background: var(--ph-card);
    border: 1px solid var(--ph-line);
    box-shadow: var(--ph-shadow);
}

.ph-dock--4 {
    grid-template-columns: repeat(4, 1fr);
}

.ph-dock-item {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
    padding: 22px;
    border-inline-start: 1px solid var(--ph-line);
    transition: background .2s;
}

    .ph-dock-item:first-child {
        border-inline-start: 0;
    }

    .ph-dock-item:hover {
        background: #fafbfd;
    }

    .ph-dock-item b {
        font-size: 15.5px;
        margin-top: 4px;
    }

    .ph-dock-item p {
        margin: 0;
        font-size: 13px;
        line-height: 1.8;
        color: var(--ph-muted);
    }

    .ph-dock-item.is-main {
        background: linear-gradient(180deg, var(--ph-teal-soft), #fff 70%);
    }

        .ph-dock-item.is-main::after {
            content: "";
            position: absolute;
            inset: auto 22px 0 22px;
            height: 3px;
            border-radius: 3px 3px 0 0;
            background: var(--ph-teal);
        }

.ph-dock-ico {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

    .ph-dock-ico .ph-ico {
        box-sizing: content-box;
        width: 22px;
        height: 22px;
        padding: 11px;
        border-radius: 13px;
        color: var(--c);
        background: color-mix(in srgb, var(--c) 12%, white);
    }

.ph-dock-item.is-soon .ph-dock-ico .ph-ico {
    background: repeating-linear-gradient(45deg, #fdf0f4 0 6px, #fbe4ec 6px 12px);
}

.ph-dock-thumbs {
    display: flex;
    margin-top: auto;
    padding-top: 6px;
}

    .ph-dock-thumbs img {
        width: 34px;
        height: 34px;
        object-fit: cover;
        border-radius: 10px;
        border: 2px solid #fff;
        margin-inline-start: -8px;
        box-shadow: 0 2px 6px rgba(15, 23, 43, .15);
    }

        .ph-dock-thumbs img:first-child {
            margin-inline-start: 0;
        }

.ph-dock-go {
    margin-top: auto;
    padding-top: 6px;
    font-size: 13px;
    font-weight: bold;
    color: var(--c);
}

/* ---------- بخش‌ها ---------- */
.ph-sec {
    padding-top: 52px;
}

.ph-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 20px;
}

    .ph-head h2 {
        display: flex;
        align-items: center;
        gap: 10px;
        font-size: 24px;
        font-weight: bold;
    }

        .ph-head h2 img {
            width: 28px;
            height: 28px;
            object-fit: contain;
        }

    .ph-head p {
        margin: 2px 0 0;
        font-size: 14px;
        color: var(--ph-muted);
    }

.ph-head-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.ph-more {
    flex: none;
    padding: 8px 14px;
    border-radius: 10px;
    background: var(--ph-teal-soft);
    color: var(--ph-teal-ink) !important;
    font-size: 13.5px;
    font-weight: bold;
    white-space: nowrap;
}

    .ph-more::after {
        content: " ←";
    }

.ph-rail-ctrls {
    display: flex;
    gap: 8px;
}

.ph-rail-btn {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    border-radius: 12px;
    border: 1px solid var(--ph-line);
    background: var(--ph-card);
    color: var(--ph-ink);
    cursor: pointer;
}

    .ph-rail-btn:hover {
        border-color: var(--ph-ink);
    }

.ph-genders {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
}

.ph-gender {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    border-radius: var(--ph-r-md);
    background: var(--ph-card);
    border: 1px solid var(--ph-line);
    transition: border-color .15s, transform .15s;
}

    .ph-gender:hover {
        border-color: var(--ph-teal);
        transform: translateY(-2px);
    }

    .ph-gender b {
        display: block;
        font-size: 15px;
        line-height: 1.6;
    }

    .ph-gender small {
        font-size: 12.5px;
        color: var(--ph-muted);
    }

.ph-gender-ico {
    flex: none;
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border-radius: 14px;
    background: var(--ph-paper);
}

    .ph-gender-ico img {
        width: 28px;
        height: 28px;
        object-fit: contain;
    }

.ph-topics {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
}

    .ph-topics .ph-chip {
        padding: 6px 15px;
        font-size: 14px;
    }

/* کارت پرامپت */
.ph-rail {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: calc((100% - 4 * 16px) / 5);
    gap: 16px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    padding-bottom: 4px;
}

    .ph-rail::-webkit-scrollbar {
        display: none;
    }

.ph-card {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    aspect-ratio: 4 / 5;
    border-radius: var(--ph-r-md);
    background: #dfe4ec;
    scroll-snap-align: start;
}

    .ph-card img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        transition: transform .5s cubic-bezier(.2, .8, .2, 1);
        object-position:top;
    }

    .ph-card:hover img {
        transform: scale(1.05);
    }

    .ph-card::after {
        content: "";
        position: absolute;
        inset: 0;
        z-index: 1;
        background: linear-gradient(180deg, transparent 45%, rgba(10, 16, 32, .86));
    }

.ph-card-body {
    position: absolute;
    inset: auto 0 0 0;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    padding: 14px;
    color: #fff;
}

    .ph-card-body h3 {
        font-size: 14.5px;
        font-weight: bold;
        line-height: 1.6;
    }

.ph-gen-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    border-radius: 99px;
    background: var(--ph-teal);
    color: #fff;
    font-size: 12.5px;
    font-weight: bold;
}

    .ph-gen-btn svg {
        width: 14px;
        height: 14px;
        fill: currentColor;
    }

/* ---------- ۱۰ پربازدید ---------- */
.ph-top {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 18px 16px;
    margin: 0;
    padding: 0;
    list-style: none;
    counter-reset: ph-rank;
}

    .ph-top li {
        counter-increment: ph-rank;
        min-width: 0;
    }

.ph-rank {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.ph-rank-img {
    overflow: hidden;
    aspect-ratio: 1;
    border-radius: var(--ph-r-md);
    background: #dfe4ec;
}

    .ph-rank-img img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        transition: transform .5s;
        object-position:top;
    }

.ph-rank:hover .ph-rank-img img {
    transform: scale(1.05);
}

.ph-rank-row {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.ph-rank-n::before {
    content: counter(ph-rank, persian);
    display: block;
    min-width: 34px;
    font-size: 36px;
    font-weight: bold;
    line-height: 1;
    color: #c3ccda;
}

.ph-top li:nth-child(-n+3) .ph-rank-n::before {
    color: var(--ph-teal);
}

.ph-rank-title {
    font-size: 14px;
    font-weight: bold;
    line-height: 1.7;
}

/* ---------- هوش مصنوعی و ابزارها ---------- */
.ph-bento {
    display: grid;
    grid-template-columns: 1.35fr 1fr 1fr;
    gap: 16px;
}

.ph-tile {
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;
    border-radius: var(--ph-r-lg);
    background: var(--ph-card);
    border: 1px solid var(--ph-line);
    transition: border-color .15s;
}

a.ph-tile:hover {
    border-color: var(--ph-teal);
}

.ph-tile-media {
    aspect-ratio: 16 / 11;
    overflow: hidden;
    background: #e8ecf2;
}

    .ph-tile-media img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        transition: transform .5s;
    }

.ph-tile-ph {
    display: grid;
    place-items: center;
    width: 100%;
    height: 100%;
    background: radial-gradient(260px 160px at 70% 20%, rgba(0, 172, 148, .18), transparent 70%), var(--ph-teal-soft);
    color: var(--ph-teal-ink);
}

    .ph-tile-ph .ph-ico {
        width: 40px;
        height: 40px;
    }

a.ph-tile:hover .ph-tile-media img {
    transform: scale(1.04);
}

.ph-tile-pad {
    padding: 18px 20px 20px;
}

    .ph-tile-pad h3 {
        font-size: 17px;
        font-weight: bold;
    }

    .ph-tile-pad p {
        margin: 6px 0 0;
        font-size: 13.5px;
        line-height: 1.9;
        color: var(--ph-muted);
    }

.ph-tile-ai {
    grid-row: span 2;
    background: linear-gradient(170deg, #eaf7f4 0%, #fff 55%);
}

.ph-chat {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 0 20px;
}

.ph-msg {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-width: 82%;
    padding: 10px;
    border-radius: 18px;
    font-size: 13.5px;
    line-height: 1.8;
}

    .ph-msg img {
        border-radius: 12px;
        object-fit: cover;
        aspect-ratio: 1;
    }

    .ph-msg span {
        margin: 0 4px;
    }

.ph-msg--user {
    align-self: flex-start;
    background: var(--ph-ink);
    color: #fff;
    border-start-start-radius: 6px;
}

    .ph-msg--user img {
        width: 110px;
    }

.ph-msg--bot {
    align-self: flex-end;
    background: var(--ph-card);
    border: 1px solid var(--ph-line);
    border-start-end-radius: 6px;
    box-shadow: var(--ph-shadow);
}

    .ph-msg--bot img {
        width: 210px;
    }

.ph-composer {
    display: flex;
    align-items: center;
    gap: 8px;
    height: 56px;
    margin: 18px 20px 20px;
    padding: 0 8px 0 16px;
    border-radius: 16px;
    background: var(--ph-card);
    border: 1.5px solid var(--ph-line);
    transition: border-color .15s, box-shadow .15s;
}

    .ph-composer:focus-within {
        border-color: var(--ph-teal);
        box-shadow: 0 0 0 4px rgba(0, 172, 148, .14);
    }

    .ph-composer input {
        flex: 1;
        min-width: 0;
        height: 100%;
        border: 0;
        outline: 0 !important;
        background: transparent;
        font-family: inherit;
        font-size: 14.5px;
        color: var(--ph-ink);
    }

    .ph-composer button {
        flex: none;
        width: 40px;
        height: 40px;
        display: grid;
        place-items: center;
        border: 0;
        border-radius: 12px;
        background: var(--ph-teal);
        color: #fff;
        cursor: pointer;
    }

        .ph-composer button .ph-ico {
            width: 18px;
            height: 18px;
        }

.ph-more-tools {
    grid-column: 2 / -1;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    padding: 14px 18px;
    border-radius: var(--ph-r-md);
    background: var(--ph-card);
    border: 1px solid var(--ph-line);
    font-size: 13.5px;
}

/* ---------- ویدیو ---------- */
.ph-video {
    display: grid;
    grid-template-columns: 280px 1fr auto;
    gap: 30px;
    align-items: center;
    margin-top: 52px;
    padding: 20px 20px 20px 30px;
    border-radius: var(--ph-r-lg);
    background: linear-gradient(100deg, #1a1030, #2a1430 55%, #3a1528);
    color: #e9eef7;
    overflow: hidden;
}

.ph-video-media {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 10;
    border-radius: 16px;
}

    .ph-video-media img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        animation: phKenBurns 9s ease-in-out infinite alternate;
    }

@keyframes phKenBurns {
    from { transform: scale(1.02); }
    to { transform: scale(1.18) translateX(-14px); }
}

.ph-video-play {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 52px;
    height: 52px;
    margin: -26px 0 0 -26px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, .92);
    color: var(--ph-rose);
    box-shadow: 0 0 0 10px rgba(255, 255, 255, .18);
}

    .ph-video-play svg {
        width: 22px;
        height: 22px;
        fill: currentColor;
        margin-right: -3px;
    }

.ph-video-bar {
    position: absolute;
    inset: auto 10px 10px 10px;
    height: 4px;
    border-radius: 4px;
    background: rgba(255, 255, 255, .3);
    overflow: hidden;
}

    .ph-video-bar::after {
        content: "";
        position: absolute;
        inset: 0 auto 0 0;
        background: #fff;
        animation: phBar 9s linear infinite;
    }

@keyframes phBar {
    from { width: 0; }
    to { width: 100%; }
}

.ph-video h2 {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 24px;
    font-weight: bold;
    color: #fff;
}

.ph-video p {
    max-width: 58ch;
    margin: 8px 0 0;
    color: #c9b8cf;
    font-size: 14.5px;
    line-height: 2;
}

.ph-video-btn {
    padding: 12px 20px;
    border-radius: 12px;
    background: #fff;
    color: #3a1528 !important;
    font-size: 14px;
    font-weight: bold;
    white-space: nowrap;
}

/* ---------- راهنما ---------- */
.ph-guide {
    display: grid;
    grid-template-columns: 1.25fr 1fr;
    gap: 24px;
    margin-top: 56px;
}

.ph-guide-main {
    padding: 34px;
    border-radius: var(--ph-r-lg);
    background: var(--ph-card);
    border: 1px solid var(--ph-line);
}

    .ph-guide-main h2 {
        margin-bottom: 14px;
        font-size: 22px;
        font-weight: bold;
    }

    .ph-guide-main p {
        max-width: 72ch;
        margin: 0 0 14px;
        color: #3b475c;
        font-size: 14.5px;
        line-height: 2.1;
    }

        .ph-guide-main p a {
            color: var(--ph-teal-ink);
            font-weight: bold;
            border-bottom: 1px solid currentColor;
        }

    .ph-guide-main h3 {
        margin: 22px 0 12px;
        font-size: 16px;
        font-weight: bold;
    }

.ph-guide-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
}

    .ph-guide-links a {
        display: inline-block;
        padding: 4px 13px;
        border-radius: 99px;
        background: var(--ph-paper);
        border: 1px solid var(--ph-line);
        font-size: 13px;
        color: var(--ph-ink-2);
    }

        .ph-guide-links a:hover {
            border-color: var(--ph-teal);
            color: var(--ph-teal-ink);
        }

.ph-guide-side {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.ph-steps {
    padding: 28px;
    border-radius: var(--ph-r-lg);
    background: var(--ph-ink);
    color: #e9eef7;
}

    .ph-steps h3 {
        margin-bottom: 16px;
        font-size: 17px;
        font-weight: bold;
        color: #fff;
    }

    .ph-steps ol {
        display: flex;
        flex-direction: column;
        gap: 16px;
        margin: 0;
        padding: 0;
        list-style: none;
        counter-reset: ph-step;
    }

    .ph-steps li {
        display: grid;
        grid-template-columns: 40px 1fr;
        column-gap: 14px;
        counter-increment: ph-step;
    }

        .ph-steps li::before {
            content: counter(ph-step, persian);
            grid-row: span 2;
            width: 40px;
            height: 40px;
            display: grid;
            place-items: center;
            border-radius: 12px;
            background: rgba(0, 172, 148, .18);
            color: var(--ph-teal);
            font-size: 17px;
            font-weight: bold;
        }

    .ph-steps b {
        color: #fff;
        font-size: 14.5px;
    }

    .ph-steps span {
        color: #9aa7bd;
        font-size: 13px;
        line-height: 1.9;
    }

.ph-why {
    padding: 26px 28px;
    border-radius: var(--ph-r-lg);
    background: var(--ph-card);
    border: 1px solid var(--ph-line);
}

    .ph-why h3 {
        margin-bottom: 12px;
        font-size: 17px;
        font-weight: bold;
    }

    .ph-why ul {
        display: flex;
        flex-direction: column;
        gap: 10px;
        margin: 0;
        padding: 0;
        list-style: none;
    }

    .ph-why li {
        display: flex;
        gap: 10px;
        font-size: 13.5px;
        line-height: 1.9;
        color: #3b475c;
    }

    .ph-why .ph-ico {
        width: 18px;
        height: 18px;
        margin-top: 4px;
        color: var(--ph-teal);
    }

@media (prefers-reduced-motion: reduce) {
    .ph *, .ph *::before, .ph *::after {
        animation: none !important;
        transition: none !important;
    }
}

/* ---------- تبلت ---------- */
@media (max-width: 1080px) {
    .ph-hero {
        grid-template-columns: 1fr;
        gap: 20px;
        padding-top: 28px;
    }

        .ph-hero h1 {
            font-size: 44px;
        }

    .ph-fan {
        height: 420px;
    }

    .ph-dock, .ph-dock--4 {
        grid-template-columns: 1fr 1fr;
    }

    .ph-dock-item {
        border-top: 1px solid var(--ph-line);
    }

    .ph-rail {
        grid-auto-columns: 30%;
    }

    .ph-top {
        grid-template-columns: repeat(3, 1fr);
    }

    .ph-bento {
        grid-template-columns: 1fr 1fr;
    }

    .ph-tile-ai {
        grid-column: 1 / -1;
        grid-row: auto;
    }

    .ph-more-tools {
        grid-column: 1 / -1;
    }

    .ph-video {
        grid-template-columns: 220px 1fr;
    }

    .ph-video-btn {
        grid-column: 1 / -1;
        justify-self: start;
    }

    .ph-guide {
        grid-template-columns: 1fr;
    }
}

/* ---------- موبایل ---------- */
@media (max-width: 600px) {
    .ph-hero h1 {
        font-size: 34px;
    }

    .ph-accent {
        font-size: 19px;
    }

    .ph-hero-desc {
        font-size: 14.5px;
    }

    .ph-search {
        height: 56px;
        padding-right: 14px;
    }

        .ph-search button {
            height: 42px;
            padding: 0 16px;
        }

    /* جستجو در هدر موبایل هست؛ اینجا فقط تیتر و عکس‌ها می‌مانند */
    .ph-hero .ph-search,
    .ph-hero .ph-quick,
    .ph-hero .ph-hero-ai,
    .ph-hero .ph-trust {
        display: none;
    }

    /* فاصله کم بین متن و عکس‌ها */
    .ph-hero {
        gap: 6px;
    }

    .ph-hero-desc {
        margin-bottom: 0;
    }

    .ph-fan {
        height: 292px;
        overflow: hidden;
    }

    .ph-fan-card {
        bottom: 86px;
        width: 128px;
    }

    /* با left:50% فقط نصف عرض در اختیار داشت و متن از کادر بیرون می‌زد */
    .ph-source {
        bottom: 12px;
        width: max-content;
        max-width: calc(100% - 24px);
        gap: 10px;
        padding: 6px 14px 6px 6px;
        font-size: 12px;
    }

        .ph-source img {
            width: 36px;
            height: 36px;
        }

        .ph-source b {
            font-size: 13px;
        }

        .ph-fan-card:nth-child(2) { --x: 124px; --y: 18px; }
        .ph-fan-card:nth-child(3) { --x: 64px; --y: -2px; }
        .ph-fan-card:nth-child(4) { width: 150px; --y: -14px; }
        .ph-fan-card:nth-child(5) { --x: -64px; --y: -2px; }
        .ph-fan-card:nth-child(6) { --x: -124px; --y: 18px; }

    .ph-dock, .ph-dock--4 {
        grid-template-columns: 1fr;
    }

    .ph-dock-item {
        display: grid;
        grid-template-columns: auto 1fr;
        column-gap: 14px;
        row-gap: 2px;
        padding: 16px;
        border-inline-start: 0;
    }

        .ph-dock-item .ph-dock-ico {
            grid-row: span 2;
            align-self: start;
        }

        .ph-dock-item b {
            margin: 0;
        }

        .ph-dock-thumbs, .ph-dock-go {
            display: none;
        }

        .ph-dock-item .ph-badge {
            display: none;
        }

    .ph-sec {
        padding-top: 38px;
    }

    .ph-head {
        flex-wrap: wrap;
        align-items: center;
    }

        .ph-head h2 {
            font-size: 19px;
        }

    .ph-rail-ctrls {
        display: none;
    }

    .ph-genders {
        grid-template-columns: 1fr 1fr;
    }

    .ph-gender {
        padding: 10px 12px;
        gap: 10px;
    }

    .ph-gender-ico {
        width: 40px;
        height: 40px;
    }

    .ph-rail {
        grid-auto-columns: 62%;
        gap: 12px;
    }

    .ph-top {
        grid-template-columns: 1fr 1fr;
        gap: 14px 12px;
    }

    .ph-rank-n::before {
        font-size: 28px;
        min-width: 24px;
    }

    .ph-bento {
        gap: 12px;
    }

    .ph-tile-pad {
        padding: 12px 14px 14px;
    }

        .ph-tile-pad h3 {
            font-size: 14.5px;
        }

        .ph-tile-pad p {
            display: none;
        }

    .ph-tile-ai .ph-tile-pad p {
        display: block;
    }

    .ph-msg--bot img {
        width: 170px;
    }

    .ph-video {
        grid-template-columns: 1fr;
        padding: 16px;
    }

    .ph-guide-main, .ph-steps, .ph-why {
        padding: 22px 18px;
    }
}

/* کارت اپلیکیشن در نوار امکانات */
.ph-badge--app { background: #e8f6ee; color: #23804a; }

.ph-dock-item--app {
    background: linear-gradient(180deg, #eef9f2, #fff 70%);
}

/* کادر چت کارت هوش مصنوعی (لینک به /ai) */
a.ph-composer {
    padding: 0 8px;
    cursor: text;
    color: var(--ph-muted);
}

    a.ph-composer:hover {
        border-color: var(--ph-teal);
        box-shadow: 0 0 0 4px rgba(0, 172, 148, .14);
    }

.ph-composer-clip {
    flex: none;
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border-radius: 12px;
    color: var(--ph-muted);
    transition: background .15s, color .15s;
}

a.ph-composer:hover .ph-composer-clip {
    background: var(--ph-paper);
    color: var(--ph-ink);
}

.ph-composer-text {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    font-size: 14px;
}

.ph-composer-send {
    flex: none;
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: var(--ph-teal);
    color: #fff;
}

    .ph-composer-send .ph-ico,
    .ph-composer-clip .ph-ico {
        width: 19px;
        height: 19px;
    }

/* ---------- کارت پرامپت ویدیویی ---------- */
.ph-vcard video {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top;
    background: #0f172b;
}

.ph-vcard-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 10px;
    border-radius: 99px;
    background: rgba(15, 23, 43, .72);
    color: #fff;
    font-size: 11.5px;
    font-weight: bold;
    backdrop-filter: blur(4px);
}

    .ph-vcard-badge svg {
        width: 11px;
        height: 11px;
        fill: currentColor;
    }

.ph-gen-btn--video {
    background: #4f46e5;
}

/* نوار امکانات صفحه اول: در دسکتاپ ستون‌ها هم‌عرض‌اند و اگر جا نشوند اسکرول افقی می‌شود */
@media (min-width: 1081px) {
    .ph-dock, .ph-dock--4 {
        grid-template-columns: none;
        grid-auto-flow: column;
        grid-auto-columns: minmax(180px, 1fr);
        overflow-x: auto;
        scrollbar-width: thin;
    }
}

.ph-dock-item--video {
    background: linear-gradient(180deg, #eef0ff, #fff 70%);
}
