/*
Theme Name: Alirezax5 Portfolio v2
Theme URI: https://alirezax5.ir
Author: Alirezax5 (theme by Super Z)
Author URI: https://alirezax5.ir
Description: قالب پورتفولیو مدرن با تم تیره، شامل ۸ بخش قابل ویرایش: معرفی، محصولات، گیت‌هاب، نمونه‌کارها، بلاگ، تعرفه، همکاران و تماس. پشتیبانی کامل از Customizer وردپرس و ۶ پست تایپ اختصاصی. بر اساس قالب HTML اصلی Alirezax5.
Version: 2.0.0
Requires at least: 6.0
Tested up to: 7.1
Requires PHP: 8.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: alirezax5
Tags: portfolio, dark, rtl-language-support, custom-colors, custom-logo, custom-menu, featured-images, threaded-comments, translation-ready, block-styles, wide-blocks
*/

/* ============================================================
   Color System (CSS variables)
   قابل تغییر از Customizer: رنگ‌های اصلی و ثانویه
   ============================================================ */
:root {
    --a5-ink: #07111f;        /* پس‌زمینه اصلی */
    --a5-panel: #0c1a2b;      /* پس‌زمینه کارت‌ها */
    --a5-electric: #1687ff;   /* رنگ اصلی */
    --a5-cyan: #54d2ff;       /* رنگ تأکید */
    --a5-slate: #94a3b8;      /* متن خاکستری */
    --a5-text: #e2e8f0;       /* متن روشن */
    color-scheme: dark;
}

* { box-sizing: border-box; }

body {
    min-height: 100vh;
    overflow-x: hidden;
    background: var(--a5-ink);
    color: var(--a5-text);
    font-family: 'Vazirmatn', 'Inter', ui-sans-serif, system-ui, sans-serif;
}

/* ============================================================
   Noise / texture overlay (subtle)
   ============================================================ */
.noise {
    pointer-events: none;
    position: fixed;
    inset: 0;
    z-index: 99;
    opacity: .025;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.7'/%3E%3C/svg%3E");
}

/* ============================================================
   Hero glow effect
   ============================================================ */
.hero-glow {
    position: absolute;
    width: 45rem;
    height: 45rem;
    top: -18rem;
    right: -12rem;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(22, 135, 255, .2), transparent 67%);
    filter: blur(4px);
    pointer-events: none;
}
html[dir="ltr"] .hero-glow { right: auto; left: -12rem; }

/* ============================================================
   Gradient text
   ============================================================ */
.gradient-text {
    background: linear-gradient(100deg, #fff 8%, var(--a5-cyan) 52%, var(--a5-electric));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

/* ============================================================
   Navigation links
   ============================================================ */
.nav-link { transition: .2s; color: var(--a5-slate); }
.nav-link:hover { color: #fff; }
.mobile-link {
    border-bottom: 1px solid rgba(255, 255, 255, .06);
    padding: .75rem 0;
    color: var(--a5-text);
}

/* ============================================================
   Buttons
   ============================================================ */
.btn-primary,
.btn-secondary {
    display: inline-flex;
    min-height: 3rem;
    align-items: center;
    gap: .6rem;
    border-radius: .8rem;
    padding: .75rem 1.1rem;
    font-size: .875rem;
    font-weight: 700;
    transition: .2s;
    text-decoration: none;
    cursor: pointer;
}
.btn-primary {
    background: var(--a5-electric);
    color: #fff;
    box-shadow: 0 12px 32px rgba(22, 135, 255, .25);
}
.btn-primary:hover {
    background: #3095ff;
    transform: translateY(-2px);
    color: #fff;
}
.btn-secondary {
    border: 1px solid rgba(255, 255, 255, .12);
    background: rgba(255, 255, 255, .04);
    color: var(--a5-text);
}
.btn-secondary:hover {
    border-color: rgba(84, 210, 255, .35);
    background: rgba(84, 210, 255, .06);
    color: #fff;
}

/* ============================================================
   Code window (decorative element in hero)
   ============================================================ */
.code-window {
    border: 1px solid rgba(255, 255, 255, .11);
    border-radius: 1.4rem;
    background: linear-gradient(145deg, rgba(16, 36, 59, .92), rgba(7, 17, 31, .92));
    box-shadow: 0 28px 90px rgba(0, 0, 0, .38), inset 0 1px rgba(255, 255, 255, .05);
    padding: 1.5rem;
    overflow: hidden;
}
.rotate-card {
    transform: perspective(1000px) rotateY(-4deg) rotateX(2deg);
}
html[dir="ltr"] .rotate-card {
    transform: perspective(1000px) rotateY(4deg) rotateX(2deg);
}

/* ============================================================
   Tech pills / mini stats
   ============================================================ */
.tech-pill,
.mini-stat {
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: .6rem;
    background: rgba(255, 255, 255, .035);
    padding: .5rem .65rem;
    font-size: .7rem;
    color: var(--a5-slate);
    display: inline-block;
}

/* ============================================================
   Section shell
   ============================================================ */
.section-shell {
    max-width: 80rem;
    margin: auto;
    padding: 5rem 1.25rem;
}
.section-head {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 2.25rem;
}
.section-head h2 {
    margin-top: .75rem;
    font-size: 1.8rem;
    line-height: 1.25;
    font-weight: 800;
    letter-spacing: -.025em;
    color: #fff;
}
.section-head > p {
    max-width: 32rem;
    color: var(--a5-slate);
    line-height: 1.9;
}
.eyebrow {
    font-size: .7rem;
    font-weight: 800;
    letter-spacing: .18em;
    color: var(--a5-cyan);
    text-transform: uppercase;
    display: inline-block;
}

/* ============================================================
   Cards: feature, repo, article, price, person
   ============================================================ */
.feature-card,
.repo-card,
.article-card,
.price-card,
.person-card {
    border: 1px solid rgba(255, 255, 255, .08);
    background: linear-gradient(145deg, rgba(12, 26, 43, .9), rgba(9, 21, 36, .86));
    transition: .25s;
}

.feature-card {
    min-height: 17rem;
    border-radius: 1.25rem;
    padding: 1.5rem;
    overflow: hidden;
    position: relative;
}
.feature-card::before {
    content: "";
    position: absolute;
    width: 10rem;
    height: 10rem;
    top: -5rem;
    left: -5rem;
    background: var(--a5-electric);
    border-radius: 50%;
    opacity: .08;
    filter: blur(30px);
    pointer-events: none;
}
.feature-card:hover,
.repo-card:hover,
.article-card:hover {
    border-color: rgba(84, 210, 255, .3);
    transform: translateY(-3px);
}

.card-icon,
.price-icon {
    display: grid;
    height: 2.8rem;
    width: 2.8rem;
    place-items: center;
    border-radius: .8rem;
    background: rgba(22, 135, 255, .12);
    color: var(--a5-cyan);
}
.card-icon svg,
.price-icon svg {
    width: 1.2rem;
    height: 1.2rem;
}

.feature-card h3,
.repo-card h3,
.article-card h3,
.price-card h3 {
    margin-top: .65rem;
    font-size: 1.25rem;
    font-weight: 750;
    color: #fff;
}
.feature-card p,
.repo-card p,
.article-card p,
.price-card > p {
    margin-top: .75rem;
    color: var(--a5-slate);
    line-height: 1.85;
    font-size: .9rem;
}

.tag {
    display: inline-block;
    font-size: .65rem;
    font-weight: 700;
    letter-spacing: .08em;
    color: var(--a5-cyan);
    margin-bottom: .4rem;
}

.text-link {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    color: var(--a5-cyan);
    font-size: .8rem;
    font-weight: 700;
    text-decoration: none;
    transition: .2s;
}
.text-link:hover { color: #fff; }
.text-link svg { width: 1rem; height: 1rem; }

/* ============================================================
   GitHub repo cards
   ============================================================ */
.repo-card {
    border-radius: 1.15rem;
    padding: 1.4rem;
    text-decoration: none;
    color: inherit;
    display: block;
}
.repo-card > div > svg {
    color: #cbd5e1;
    width: 1.35rem;
    height: 1.35rem;
}
.repo-status {
    display: flex;
    align-items: center;
    gap: .35rem;
    font-size: .65rem;
    color: #64748b;
}
.repo-status span {
    width: .35rem;
    height: .35rem;
    border-radius: 50%;
    background: #34d399;
}
.repo-meta {
    display: flex;
    justify-content: space-between;
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, .07);
    font-size: .7rem;
    color: #64748b;
}
.repo-meta span {
    display: flex;
    align-items: center;
    gap: .4rem;
}
.repo-meta b {
    width: .5rem;
    height: .5rem;
    border-radius: 50%;
}
.repo-meta svg {
    width: .8rem;
    height: .8rem;
}

/* ============================================================
   Portfolio work rows
   ============================================================ */
.work-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 1.15rem;
    background: rgba(12, 26, 43, .64);
    padding: 1rem;
    transition: .25s;
    text-decoration: none;
    color: inherit;
}
.work-row:hover {
    border-color: rgba(22, 135, 255, .3);
    background: rgba(12, 26, 43, .9);
}
.work-number {
    display: none;
    font-size: .7rem;
    color: #475569;
    font-weight: 700;
}
.work-visual {
    display: grid;
    height: 4rem;
    width: 4rem;
    flex: none;
    place-items: center;
    border-radius: 1rem;
}
.work-visual svg { width: 1.5rem; height: 1.5rem; color: #fff; }
.visual-blue   { background: linear-gradient(135deg, #123c70, #1687ff); }
.visual-cyan   { background: linear-gradient(135deg, #0c4254, #20a7ce); }
.visual-indigo { background: linear-gradient(135deg, #27245b, #625ee8); }
.visual-purple { background: linear-gradient(135deg, #3b1b58, #9333ea); }
.visual-green  { background: linear-gradient(135deg, #14532d, #16a34a); }
.visual-orange { background: linear-gradient(135deg, #5b2a0c, #ea580c); }

.work-row h3 {
    margin-top: .2rem;
    font-size: 1.05rem;
    font-weight: 750;
    color: #fff;
}
.work-row p:not(.text-xs) {
    margin-top: .4rem;
    color: #8493a8;
    font-size: .8rem;
    line-height: 1.6;
}
.work-row .text-xs {
    color: var(--a5-cyan);
    font-size: .75rem;
    margin: 0;
}

/* ============================================================
   Article cards (blog)
   ============================================================ */
.article-card {
    position: relative;
    border-radius: 1.15rem;
    padding: 1.5rem;
    text-decoration: none;
    color: inherit;
    display: block;
}
.article-mark {
    position: absolute;
    top: 1rem;
    left: 1rem;
    color: rgba(84, 210, 255, .12);
    font-size: 2.8rem;
    font-weight: 900;
}
html[dir="ltr"] .article-mark { left: auto; right: 1rem; }
.article-date {
    font-size: .7rem;
    color: #64748b;
}
.article-card h3 {
    position: relative;
    min-height: 3.5rem;
    margin-top: 1.2rem;
}
.article-card > a {
    display: inline-block;
    margin-top: 1.4rem;
    color: var(--a5-cyan);
    font-size: .75rem;
    font-weight: 700;
}

/* ============================================================
   Pricing cards
   ============================================================ */
.price-card {
    position: relative;
    border-radius: 1.4rem;
    padding: 1.5rem;
    text-decoration: none;
    color: inherit;
    display: block;
}
.price-card.featured {
    border-color: rgba(22, 135, 255, .55);
    box-shadow: 0 20px 70px rgba(22, 135, 255, .12);
}
.popular {
    position: absolute;
    top: 1rem;
    left: 1rem;
    border-radius: 999px;
    background: var(--a5-electric);
    padding: .35rem .6rem;
    font-size: .6rem;
    font-weight: 800;
    color: #fff;
}
html[dir="ltr"] .popular { left: auto; right: 1rem; }
.price {
    display: flex;
    align-items: baseline;
    gap: .35rem;
    margin-top: 1.7rem;
}
.price strong { font-size: 1.5rem; color: #fff; }
.price small { font-size: .68rem; color: #64748b; }
.price-card ul {
    margin: 1.4rem 0;
    display: grid;
    gap: .8rem;
    color: #cbd5e1;
    font-size: .82rem;
    list-style: none;
    padding: 0;
}
.price-card li {
    position: relative;
    padding-inline-start: 1.35rem;
}
.price-card li::before {
    content: "✓";
    position: absolute;
    inset-inline-start: 0;
    color: var(--a5-cyan);
    font-weight: 800;
}
.price-card > a {
    width: 100%;
}

/* ============================================================
   Person cards (team)
   ============================================================ */
.person-card {
    border-radius: 1.1rem;
    padding: 1.3rem;
    text-align: center;
}
.avatar {
    display: grid;
    height: 3.2rem;
    width: 3.2rem;
    place-items: center;
    border-radius: 999px;
    border: 1px solid rgba(84, 210, 255, .25);
    background: rgba(22, 135, 255, .09);
    color: var(--a5-cyan);
    font-size: .7rem;
    font-weight: 800;
    margin: 0 auto;
}
.avatar svg { width: 1rem; height: 1rem; }
.person-card h3 {
    margin-top: 1rem;
    font-size: .92rem;
    font-weight: 750;
    color: #fff;
}
.person-card p {
    margin-top: .3rem;
    font-size: .7rem;
    color: #64748b;
}
.join-card {
    border-style: dashed;
    text-decoration: none;
    color: inherit;
    display: block;
}
.join-card:hover { border-color: rgba(84, 210, 255, .4); }

/* ============================================================
   Social section (CTA)
   ============================================================ */
.social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .6rem;
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: .85rem;
    background: rgba(255, 255, 255, .035);
    padding: .8rem;
    font-size: .78rem;
    color: #cbd5e1;
    transition: .2s;
    text-decoration: none;
}
.social-link:hover {
    border-color: rgba(84, 210, 255, .35);
    color: #fff;
}
.social-link svg { width: 1rem; height: 1rem; }

/* ============================================================
   RTL/LTR icon direction toggle
   ============================================================ */
.dir-icon { transition: transform .2s; }
html[dir="ltr"] .dir-icon { transform: scaleX(-1); }

/* ============================================================
   Header / Nav
   ============================================================ */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 50;
    backdrop-filter: blur(14px);
    background: rgba(7, 17, 31, .72);
    border-bottom: 1px solid rgba(255, 255, 255, .06);
}

/* ============================================================
   Footer
   ============================================================ */
.site-footer {
    border-top: 1px solid rgba(255, 255, 255, .06);
    background: rgba(7, 17, 31, .5);
    padding: 3rem 1.25rem 2rem;
}

/* ============================================================
   WordPress Core Styles
   ============================================================ */
.alignnone { margin: 5px 20px 20px 0; }
.aligncenter, div.aligncenter { display: block; margin: 5px auto 5px auto; }
.alignright { float: right; margin: 5px 0 20px 20px; }
.alignleft { float: left; margin: 5px 20px 20px 0; }
a img.alignright { float: right; margin: 5px 0 20px 20px; }
a img.alignnone { margin: 5px 20px 20px 0; }
a img.alignleft { float: left; margin: 5px 20px 20px 0; }
a img.aligncenter { display: block; margin-left: auto; margin-right: auto; }
.wp-caption { max-width: 100%; }
.wp-caption .wp-caption-text { font-size: 14px; margin: 5px 0; padding: 0 5px; color: var(--a5-slate); }

.screen-reader-text {
    border: 0; clip: rect(1px, 1px, 1px, 1px); clip-path: inset(50%);
    height: 1px; margin: -1px; overflow: hidden; padding: 0;
    position: absolute !important; width: 1px; word-wrap: normal !important;
}
.screen-reader-text:focus {
    background-color: var(--a5-electric); border-radius: 3px;
    box-shadow: 0 0 2px 2px rgba(0, 0, 0, .6);
    clip: auto !important; clip-path: none; color: #fff;
    display: block; font-size: 14px; font-weight: bold; height: auto;
    left: 5px; line-height: normal; padding: 15px 23px 14px;
    text-decoration: none; top: 5px; width: auto; z-index: 100000;
}

/* Sticky posts */
.sticky { display: block; }

/* Bypostauthor */
.bypostauthor { display: block; }

/* Single post / page content */
.entry-content { color: var(--a5-text); line-height: 1.9; }
.entry-content a { color: var(--a5-cyan); text-decoration: none; border-bottom: 1px dotted currentColor; }
.entry-content a:hover { color: #fff; border-bottom-style: solid; }
.entry-content h2, .entry-content h3, .entry-content h4 { color: #fff; margin-top: 1.5em; }
.entry-content blockquote {
    border-inline-start: 4px solid var(--a5-electric);
    padding-inline-start: 1.5rem;
    color: var(--a5-slate);
    font-style: italic;
    margin: 1.5rem 0;
}
.entry-content pre {
    background: rgba(7, 17, 31, .8);
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: .8rem;
    padding: 1rem;
    overflow-x: auto;
    direction: ltr;
    text-align: left;
}
.entry-content code {
    background: rgba(22, 135, 255, .12);
    color: var(--a5-cyan);
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.9em;
    direction: ltr;
    display: inline-block;
}
.entry-content img { max-width: 100%; height: auto; border-radius: .8rem; }

/* Comments */
.comments-area { color: var(--a5-text); }
.comment-list { list-style: none; padding: 0; }
.comment-list .comment { padding: 1rem; border: 1px solid rgba(255, 255, 255, .08); border-radius: .8rem; margin-bottom: 1rem; background: rgba(12, 26, 43, .5); }
.comment-form input,
.comment-form textarea {
    background: rgba(7, 17, 31, .8);
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: .5rem;
    padding: .5rem .75rem;
    color: var(--a5-text);
    width: 100%;
}
.comment-form .submit {
    background: var(--a5-electric);
    color: #fff;
    border: none;
    padding: .75rem 1.5rem;
    border-radius: .5rem;
    font-weight: 700;
    cursor: pointer;
    width: auto;
}

/* Pagination */
.pagination, .nav-links {
    display: flex;
    gap: .5rem;
    justify-content: center;
    margin-top: 2rem;
}
.pagination .page-numbers, .nav-links .page-numbers {
    padding: .5rem 1rem;
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: .5rem;
    color: var(--a5-text);
    text-decoration: none;
    background: rgba(12, 26, 43, .5);
    transition: .2s;
}
.pagination .page-numbers:hover, .nav-links .page-numbers:hover,
.pagination .current, .nav-links .current {
    background: var(--a5-electric);
    color: #fff;
    border-color: var(--a5-electric);
}

/* Search form */
.search-form input[type="search"] {
    background: rgba(7, 17, 31, .8);
    border: 1px solid rgba(255, 255, 255, .08);
    color: var(--a5-text);
    padding: .5rem .75rem;
    border-radius: .5rem;
}

/* ============================================================
   Responsive
   ============================================================ */
@media (min-width: 640px) {
    .section-head {
        flex-direction: row;
        align-items: end;
        justify-content: space-between;
    }
    .section-head h2 { font-size: 2.3rem; }
    .work-number { display: block; }
    .work-row { gap: 1.4rem; padding: 1.15rem 1.4rem; }
    .work-visual { height: 5rem; width: 6.5rem; }
    .price-card { padding: 1.8rem; }
}

@media (min-width: 1024px) {
    .section-shell { padding: 6.5rem 2rem; }
    .section-head h2 { font-size: 2.65rem; }
}

@media (max-width: 640px) {
    .rotate-card { transform: none !important; }
    .feature-card { min-height: 15rem; }
    .section-shell { padding-top: 4.5rem; padding-bottom: 4.5rem; }
}

@media (prefers-reduced-motion: reduce) {
    * { scroll-behavior: auto !important; transition: none !important; }
}
