/* =========================================================
   Tekino — حساب کاربری من (هر کادر یک رنگ نئونی)
   فقط در صفحه حساب کاربری لود می‌شود
========================================================= */

/* ---------- چیدمان دو ستونه ---------- */
body.woocommerce-account .woocommerce-notices-wrapper { grid-column: 1 / -1; }

/* پاک‌کننده‌های float ووکامرس در گرید یک خانه می‌گیرند و چیدمان را به‌هم می‌ریزند */
body.woocommerce-account .woocommerce::before,
body.woocommerce-account .woocommerce::after { display: none !important; content: none !important; }

body.woocommerce-account .woocommerce-MyAccount-navigation,
body.woocommerce-account .woocommerce-MyAccount-content { min-width: 0; max-width: 100%; box-sizing: border-box; }

body.logged-in.woocommerce-account .woocommerce {
    display: grid;
    grid-template-columns: 290px minmax(0, 1fr);
    gap: 22px;
    align-items: start;
}

body.woocommerce-account .woocommerce-MyAccount-navigation,
body.woocommerce-account .woocommerce-MyAccount-content { float: none !important; width: auto !important; margin: 0; }

/* ---------- منوی حساب ---------- */
body.woocommerce-account .woocommerce-MyAccount-navigation {
    position: sticky;
    top: 90px;
    padding: 16px;
    background: #fff;
    border: 2px solid #00eaff;
    border-radius: 22px;
    box-shadow: 0 0 18px rgba(0, 234, 255, .38), inset 0 0 16px rgba(0, 234, 255, .06);
}

.woocommerce-MyAccount-navigation ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }

.woocommerce-MyAccount-navigation li {
    --nc: #00eaff;
    margin: 0; padding: 0; list-style: none;
}
.woocommerce-MyAccount-navigation li.woocommerce-MyAccount-navigation-link--orders          { --nc: #ff2d95; }
.woocommerce-MyAccount-navigation li.woocommerce-MyAccount-navigation-link--edit-address    { --nc: #ffb703; }
.woocommerce-MyAccount-navigation li.woocommerce-MyAccount-navigation-link--edit-account    { --nc: #39ff88; }
.woocommerce-MyAccount-navigation li.woocommerce-MyAccount-navigation-link--customer-logout { --nc: #ff8a1f; }

.woocommerce-MyAccount-navigation li a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    background: #fff;
    border: 2px solid var(--nc);
    border-radius: 14px;
    box-shadow: 0 0 9px color-mix(in srgb, var(--nc) 38%, transparent);
    color: #1e293b;
    font-size: 14px;
    font-weight: 800;
    text-decoration: none;
    transition: box-shadow .2s, background .2s;
}

.woocommerce-MyAccount-navigation li a::before {
    flex: 0 0 auto;
    width: 34px; height: 34px;
    display: grid; place-items: center;
    border-radius: 10px;
    background: color-mix(in srgb, var(--nc) 16%, #fff);
    font-size: 17px;
    content: "🏠";
}
.woocommerce-MyAccount-navigation li.woocommerce-MyAccount-navigation-link--orders a::before          { content: "📦"; }
.woocommerce-MyAccount-navigation li.woocommerce-MyAccount-navigation-link--edit-address a::before    { content: "📍"; }
.woocommerce-MyAccount-navigation li.woocommerce-MyAccount-navigation-link--edit-account a::before    { content: "👤"; }
.woocommerce-MyAccount-navigation li.woocommerce-MyAccount-navigation-link--customer-logout a::before { content: "🚪"; }

.woocommerce-MyAccount-navigation li a:hover,
.woocommerce-MyAccount-navigation li.is-active a {
    background: color-mix(in srgb, var(--nc) 9%, #fff);
    box-shadow: 0 0 16px color-mix(in srgb, var(--nc) 62%, transparent);
}

/* ---------- محتوای هر صفحه ---------- */
body.woocommerce-account .woocommerce-MyAccount-content {
    padding: 22px;
    background: #fff;
    border: 2px solid #a855f7;
    border-radius: 22px;
    box-shadow: 0 0 18px rgba(168, 85, 247, .38), inset 0 0 16px rgba(168, 85, 247, .05);
    font-size: 14px;
    line-height: 2;
    color: #334155;
}
.woocommerce-MyAccount-content h2,
.woocommerce-MyAccount-content h3 { margin: 0 0 14px; font-size: 18px; font-weight: 900; color: #1e293b; }

/* ---------- پیشخوان ---------- */
.woocommerce-MyAccount-content:has(.tk-dash) > p { display: none; }
.woocommerce-MyAccount-content:has(.tk-dash) { padding: 16px; }

.tk-dash { display: flex; flex-direction: column; gap: 16px; }

.tk-dash-hero {
    display: flex; align-items: center; gap: 16px; padding: 18px 20px;
    border: 2px solid #a855f7; border-radius: 20px; color: #fff;
    background:
        radial-gradient(120% 90% at 100% 0%, rgba(249, 115, 22, .25), transparent 60%),
        radial-gradient(100% 80% at 0% 100%, rgba(236, 72, 153, .2), transparent 60%),
        linear-gradient(135deg, #211b2d, #17121f);
    box-shadow: 0 0 18px rgba(168, 85, 247, .5);
}
.tk-dash-avatar img {
    display: block; width: 68px; height: 68px; border-radius: 50%; object-fit: cover;
    border: 3px solid #00eaff; box-shadow: 0 0 14px rgba(0, 234, 255, .65);
}
.tk-dash-hello { display: flex; flex-direction: column; min-width: 0; line-height: 1.7; }
.tk-dash-hello small { font-size: 12px; font-weight: 700; color: #c4b5fd; }
.tk-dash-hello strong { font-size: 19px; font-weight: 900; }
.tk-dash-hello span { font-size: 12px; color: #cbd5e1; overflow-wrap: anywhere; }

.tk-dash-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.tk-ds {
    --dc: #00eaff;
    padding: 14px; text-align: center; background: #fff;
    border: 2px solid var(--dc); border-radius: 16px;
    box-shadow: 0 0 12px color-mix(in srgb, var(--dc) 45%, transparent), inset 0 0 12px color-mix(in srgb, var(--dc) 7%, transparent);
}
.tk-ds-pink  { --dc: #ff2d95; }
.tk-ds-green { --dc: #39ff88; }
.tk-ds b { display: block; font-size: 20px; font-weight: 900; color: #1e293b; line-height: 1.6; }
.tk-ds b .woocommerce-Price-amount { font-size: 15px; }
.tk-ds span { font-size: 12px; font-weight: 800; color: #64748b; }

.tk-dash-tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.tk-dt {
    --tc: #00eaff;
    display: flex; flex-direction: column; align-items: center; gap: 4px;
    padding: 16px 10px; text-align: center; text-decoration: none; background: #fff;
    border: 2px solid var(--tc); border-radius: 18px;
    box-shadow: 0 0 12px color-mix(in srgb, var(--tc) 45%, transparent);
    transition: transform .2s, box-shadow .2s;
}
.tk-dt:hover { transform: translateY(-2px); box-shadow: 0 0 20px color-mix(in srgb, var(--tc) 70%, transparent); }
.tk-dt-pink   { --tc: #ff2d95; }
.tk-dt-green  { --tc: #39ff88; }
.tk-dt-yellow { --tc: #ffb703; }
.tk-dt-ico {
    width: 46px; height: 46px; display: grid; place-items: center; border-radius: 14px; font-size: 23px;
    background: color-mix(in srgb, var(--tc) 16%, #fff);
}
.tk-dt strong { font-size: 14px; font-weight: 900; color: #1e293b; }
.tk-dt small { font-size: 11px; font-weight: 700; color: #64748b; line-height: 1.7; }

.tk-dash-last {
    padding: 16px 18px; background: #fff; border: 2px solid #ff8a1f; border-radius: 18px;
    box-shadow: 0 0 14px rgba(255, 138, 31, .42);
}
.tk-dl-head { margin-bottom: 8px; font-size: 15px; font-weight: 900; color: #1e293b; }
.tk-dl-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 6px 14px; font-size: 13px; color: #64748b; font-weight: 700; }
.tk-dl-row strong { color: #1e293b; font-weight: 900; }
.tk-dl-status { color: #0d9488 !important; }
.tk-dl-empty { margin: 0 0 8px; font-size: 13px; color: #64748b; }
.tk-dl-btn {
    display: inline-block; margin-top: 12px; padding: 10px 18px; border: 2px solid #39ff88; border-radius: 12px;
    background: linear-gradient(135deg, #4f46e5, #7c3aed); color: #fff !important; font-size: 13px; font-weight: 900;
    text-decoration: none; box-shadow: 0 0 12px rgba(57, 255, 136, .5);
}

/* ---------- سفارش‌ها (کارت‌های رنگی) ---------- */
body.woocommerce-account table.woocommerce-orders-table,
body.woocommerce-account table.woocommerce-orders-table tbody { display: block; width: 100%; border: 0 !important; }
body.woocommerce-account table.woocommerce-orders-table thead { display: none; }

body.woocommerce-account tr.woocommerce-orders-table__row {
    --oc: #00eaff;
    display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 8px 14px;
    margin: 0 0 14px; padding: 14px; background: #fff;
    border: 2px solid var(--oc); border-radius: 18px;
    box-shadow: 0 0 13px color-mix(in srgb, var(--oc) 42%, transparent);
}
body.woocommerce-account tr.woocommerce-orders-table__row:nth-child(4n+2) { --oc: #ff2d95; }
body.woocommerce-account tr.woocommerce-orders-table__row:nth-child(4n+3) { --oc: #39ff88; }
body.woocommerce-account tr.woocommerce-orders-table__row:nth-child(4n+4) { --oc: #ffb703; }

body.woocommerce-account tr.woocommerce-orders-table__row td {
    display: block !important; padding: 0 !important; border: 0 !important; text-align: right !important;
    font-size: 13px; font-weight: 800; color: #1e293b;
}
body.woocommerce-account tr.woocommerce-orders-table__row td::before {
    content: attr(data-title); display: block !important; float: none !important;
    margin-bottom: 2px; font-size: 11px; font-weight: 800; color: #94a3b8;
}
body.woocommerce-account td.woocommerce-orders-table__cell-order-actions { grid-column: 1 / -1; display: flex !important; flex-wrap: wrap; gap: 8px; }
body.woocommerce-account td.woocommerce-orders-table__cell-order-actions::before { display: none !important; }
body.woocommerce-account td.woocommerce-orders-table__cell-order-number a { color: #4f46e5; font-weight: 900; text-decoration: none; }

/* ---------- آدرس‌ها ---------- */
body.woocommerce-account .woocommerce-Addresses { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
body.woocommerce-account .woocommerce-Addresses::before,
body.woocommerce-account .woocommerce-Addresses::after { display: none; }
body.woocommerce-account .woocommerce-Address {
    --ac: #00eaff;
    float: none !important; width: auto !important; padding: 16px;
    background: #fff; border: 2px solid var(--ac); border-radius: 18px;
    box-shadow: 0 0 14px color-mix(in srgb, var(--ac) 45%, transparent);
}
body.woocommerce-account .woocommerce-Addresses > .woocommerce-Address:nth-child(2) { --ac: #ff2d95; }
body.woocommerce-account .woocommerce-Address-title { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
body.woocommerce-account .woocommerce-Address-title h3 { margin: 0; font-size: 16px; }
body.woocommerce-account .woocommerce-Address-title a.edit {
    padding: 5px 12px; border: 1.5px solid var(--ac); border-radius: 10px; font-size: 12px; font-weight: 800;
    color: #1e293b; text-decoration: none; box-shadow: 0 0 8px color-mix(in srgb, var(--ac) 40%, transparent);
}
body.woocommerce-account .woocommerce-Address address { font-style: normal; font-size: 13px; font-weight: 700; line-height: 2; }

/* ---------- فرم‌ها ---------- */
body.woocommerce-account .woocommerce form .form-row label { font-size: 13px; font-weight: 800; color: #475569; }

body.woocommerce-account :is(input.input-text, input[type="text"], input[type="email"], input[type="password"], input[type="tel"], textarea, select) {
    width: 100%; box-sizing: border-box; padding: 11px 13px;
    background: #fff; border: 2px solid #818cf8; border-radius: 12px;
    font-weight: 700; color: #1e293b;
    box-shadow: 0 0 8px rgba(129, 140, 248, .32);
    transition: box-shadow .2s;
}
body.woocommerce-account :is(input, textarea, select):focus { outline: 0; box-shadow: 0 0 15px #818cf8; }

body.woocommerce-account .select2-container--default .select2-selection--single {
    height: 46px; border: 2px solid #818cf8; border-radius: 12px; box-shadow: 0 0 8px rgba(129, 140, 248, .32);
}
body.woocommerce-account .select2-container--default .select2-selection--single .select2-selection__rendered { line-height: 42px; font-weight: 700; }
body.woocommerce-account .select2-container--default .select2-selection--single .select2-selection__arrow { height: 42px; }

/* فرم تغییر رمز عبور: کادر نارنجی */
body.woocommerce-account .woocommerce-EditAccountForm fieldset {
    margin: 18px 0 0; padding: 16px; border: 2px solid #ff8a1f; border-radius: 16px;
    box-shadow: 0 0 12px rgba(255, 138, 31, .38);
}
body.woocommerce-account .woocommerce-EditAccountForm fieldset legend { padding: 0 8px; font-size: 14px; font-weight: 900; color: #1e293b; }

/* دکمه‌ها */
body.woocommerce-account :is(button.button, a.button, .woocommerce-Button, button[type="submit"]) {
    display: inline-flex; align-items: center; justify-content: center;
    padding: 10px 20px; min-height: 42px;
    background: linear-gradient(135deg, #4f46e5, #7c3aed) !important; color: #fff !important;
    border: 2px solid #39ff88 !important; border-radius: 13px !important;
    font-size: 13.5px; font-weight: 900; text-decoration: none; cursor: pointer;
    box-shadow: 0 0 13px rgba(57, 255, 136, .45);
}
body.woocommerce-account .woocommerce-orders-table a.button { padding: 7px 14px; min-height: 36px; font-size: 12.5px; }

/* ---------- ورود / ثبت‌نام (کاربر مهمان) ---------- */
body.woocommerce-account .u-columns.col2-set { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
body.woocommerce-account .u-columns.col2-set::before,
body.woocommerce-account .u-columns.col2-set::after { display: none; }
body.woocommerce-account .u-columns .u-column1,
body.woocommerce-account .u-columns .u-column2 {
    float: none !important; width: auto !important; padding: 22px; background: #fff;
    border: 2px solid #00eaff; border-radius: 22px;
    box-shadow: 0 0 18px rgba(0, 234, 255, .4), inset 0 0 16px rgba(0, 234, 255, .06);
}
body.woocommerce-account .u-columns .u-column2 { border-color: #ff2d95; box-shadow: 0 0 18px rgba(255, 45, 149, .4), inset 0 0 16px rgba(255, 45, 149, .06); }
body.woocommerce-account .u-columns :is(form.login, form.register) { margin: 0; padding: 0; border: 0; box-shadow: none; }

body.woocommerce-account .woocommerce > :is(form.login, form.woocommerce-ResetPassword, form.lost_reset_password) {
    max-width: 520px; margin: 0 auto; padding: 22px; background: #fff;
    border: 2px solid #00eaff; border-radius: 22px; box-shadow: 0 0 18px rgba(0, 234, 255, .4);
}
body.woocommerce-account h2 { font-size: 19px; font-weight: 900; color: #1e293b; }
body.woocommerce-account .woocommerce-form-login__rememberme { font-size: 13px; font-weight: 700; color: #475569; }
body.woocommerce-account .lost_password a { color: #4f46e5; font-weight: 800; }

/* ---------- پیام‌ها ---------- */
body.woocommerce-account :is(.woocommerce-message, .woocommerce-info, .woocommerce-error) {
    --mc: #00eaff;
    margin: 0 0 16px; background: #fff; list-style: none;
    border: 2px solid var(--mc) !important; border-radius: 16px;
    box-shadow: 0 0 12px color-mix(in srgb, var(--mc) 45%, transparent);
    font-weight: 700; color: #1e293b;
}
body.woocommerce-account .woocommerce-message { --mc: #39ff88; }
body.woocommerce-account .woocommerce-error   { --mc: #ff2d95; }

/* ---------- موبایل ---------- */
@media (max-width: 768px) {

    body.logged-in.woocommerce-account .woocommerce { grid-template-columns: minmax(0, 1fr); gap: 14px; }

    /* منو: نوار افقی قابل کشیدن */
    body.woocommerce-account .woocommerce-MyAccount-navigation { position: static; padding: 10px; border-radius: 18px; }
    .woocommerce-MyAccount-navigation ul {
        flex-direction: row; gap: 8px; overflow-x: auto; padding: 2px 2px 6px;
        scrollbar-width: none; -webkit-overflow-scrolling: touch;
    }
    .woocommerce-MyAccount-navigation ul::-webkit-scrollbar { display: none; }
    .woocommerce-MyAccount-navigation li { flex: 0 0 auto; }
    .woocommerce-MyAccount-navigation li a { padding: 8px 12px; gap: 8px; font-size: 12.5px; white-space: nowrap; }
    .woocommerce-MyAccount-navigation li a::before { width: 26px; height: 26px; font-size: 14px; border-radius: 8px; }

    body.woocommerce-account .woocommerce-MyAccount-content { padding: 14px; border-radius: 18px; }
    .woocommerce-MyAccount-content:has(.tk-dash) { padding: 10px; }

    .tk-dash { gap: 12px; }
    .tk-dash-hero { padding: 14px; gap: 12px; border-radius: 16px; }
    .tk-dash-avatar img { width: 56px; height: 56px; }
    .tk-dash-hello strong { font-size: 16px; }

    .tk-dash-stats { grid-template-columns: 1fr 1fr; gap: 8px; }
    .tk-dash-stats .tk-ds-green { grid-column: 1 / -1; }
    .tk-ds { padding: 10px; border-radius: 14px; }
    .tk-ds b { font-size: 18px; }

    .tk-dash-tiles { grid-template-columns: 1fr 1fr; gap: 8px; }
    .tk-dt { padding: 12px 8px; border-radius: 15px; }
    .tk-dt-ico { width: 40px; height: 40px; font-size: 20px; }

    body.woocommerce-account .woocommerce-Addresses { grid-template-columns: 1fr; gap: 12px; }
    body.woocommerce-account .u-columns.col2-set { grid-template-columns: 1fr; gap: 14px; }
    body.woocommerce-account .u-columns .u-column1,
    body.woocommerce-account .u-columns .u-column2 { padding: 16px; border-radius: 18px; }

    body.woocommerce-account tr.woocommerce-orders-table__row { grid-template-columns: 1fr 1fr; padding: 12px; }
}


/* =========================================================
   هم‌عرض شدن کادرهای منو و محتوا با کادر عنوان «حساب کاربری من»
   (قبلاً عرض div.woocommerce یک بار دیگر ۴۰ پیکسل کم می‌شد)
========================================================= */
body.woocommerce-account .tk-page-content div.woocommerce,
body.woocommerce-account div.woocommerce {
    width: 100% !important;
    max-width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    box-sizing: border-box;
}
