/* =============================================================================
   owner.css — HIỆU ỨNG RIÊNG CHO ROLE "OWNER"
   -----------------------------------------------------------------------------
   Áp dụng cho khung profile của thành viên có role Owner:
     • Viền gradient vàng kim + hiệu ứng glow nhấp nháy (pulse)
     • Vệt sáng (shimmer) chạy ngang tên + khung
     • Badge "OWNER" nổi bật với icon vương miện
     • Khung ưu đãi (owner-perks) sang trọng
   Màu sắc lấy từ biến --owner-c1 / --owner-c2 (do PHP set theo setting admin).
   ============================================================================= */

:root {
    --owner-c1: #f6d365;
    --owner-c2: #fda085;
    --owner-c3: #f9d423;
}

/* ---------------------------------------------------------------------------
   Khung profile Owner: viền gradient + glow
   --------------------------------------------------------------------------- */
.owner-profile-card {
    position: relative;
    border-radius: 16px;
    background: linear-gradient(135deg, rgba(246, 211, 101, 0.18), rgba(253, 160, 133, 0.18));
    box-shadow: 0 0 0 2px rgba(246, 211, 101, 0.55),
                0 0 18px rgba(253, 160, 133, 0.55),
                0 10px 30px rgba(0, 0, 0, 0.25);
    animation: ownerGlow 2.6s ease-in-out infinite;
    overflow: hidden;
}

.owner-profile-card::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 16px;
    padding: 2px;
    background: linear-gradient(120deg, var(--owner-c1), var(--owner-c2), var(--owner-c3), var(--owner-c1));
    background-size: 300% 300%;
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    animation: ownerBorderShift 4s linear infinite;
    pointer-events: none;
}

@keyframes ownerGlow {
    0%, 100% {
        box-shadow: 0 0 0 2px rgba(246, 211, 101, 0.55),
                    0 0 14px rgba(253, 160, 133, 0.45),
                    0 10px 30px rgba(0, 0, 0, 0.25);
    }
    50% {
        box-shadow: 0 0 0 2px rgba(246, 211, 101, 0.9),
                    0 0 28px rgba(253, 160, 133, 0.85),
                    0 10px 34px rgba(0, 0, 0, 0.3);
    }
}

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

/* Vệt sáng shimmer chạy ngang khung */
.owner-profile-card::after {
    content: "";
    position: absolute;
    top: 0;
    left: -60%;
    width: 45%;
    height: 100%;
    background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.45), transparent);
    transform: skewX(-20deg);
    animation: ownerShimmer 3.4s ease-in-out infinite;
    pointer-events: none;
}

@keyframes ownerShimmer {
    0%   { left: -60%; }
    55%  { left: 120%; }
    100% { left: 120%; }
}

/* ---------------------------------------------------------------------------
   Tên Owner: chữ gradient vàng kim + shimmer
   --------------------------------------------------------------------------- */
.owner-username {
    background: linear-gradient(90deg, var(--owner-c1), var(--owner-c2), var(--owner-c1));
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    font-weight: 800;
    letter-spacing: 0.5px;
    animation: ownerTextShift 3s linear infinite;
    text-shadow: 0 0 18px rgba(246, 211, 101, 0.35);
}

@keyframes ownerTextShift {
    to { background-position: 200% center; }
}

/* ---------------------------------------------------------------------------
   Badge OWNER (vương miện)
   --------------------------------------------------------------------------- */
.owner-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 14px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: #5a3b00;
    background: linear-gradient(135deg, var(--owner-c1), var(--owner-c2));
    box-shadow: 0 0 12px rgba(246, 211, 101, 0.7), inset 0 0 6px rgba(255, 255, 255, 0.6);
    animation: ownerBadgePulse 2s ease-in-out infinite;
    position: relative;
    z-index: 2;
}

.owner-badge i {
    font-size: 13px;
}

.owner-badge-sm {
    padding: 2px 9px;
    font-size: 10px;
    letter-spacing: 0.6px;
}

@keyframes ownerBadgePulse {
    0%, 100% { transform: translateY(0) scale(1); }
    50%      { transform: translateY(-1px) scale(1.04); }
}

/* Avatar Owner: vòng sáng xoay */
.owner-avatar-ring {
    position: relative;
    display: inline-block;
    border-radius: 50%;
    padding: 3px;
    background: conic-gradient(var(--owner-c1), var(--owner-c2), var(--owner-c3), var(--owner-c1));
    animation: ownerRingSpin 6s linear infinite;
}

.owner-avatar-ring img {
    border-radius: 50%;
    display: block;
    border: 3px solid #1b1b2f;
}

@keyframes ownerRingSpin {
    to { transform: rotate(360deg); }
}

/* ---------------------------------------------------------------------------
   Khung ưu đãi Owner (owner-perks)
   --------------------------------------------------------------------------- */
.owner-perks {
    border-radius: 14px;
    padding: 14px 16px;
    background: linear-gradient(135deg, rgba(246, 211, 101, 0.14), rgba(253, 160, 133, 0.14));
    border: 1px solid rgba(246, 211, 101, 0.5);
    box-shadow: inset 0 0 18px rgba(253, 160, 133, 0.15);
}

.owner-perks-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 800;
    color: #8a5a00;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    font-size: 13px;
}

.owner-perks-title i {
    color: #e8a200;
}

.owner-perk-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.55);
    margin-bottom: 8px;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.owner-perk-item:last-child {
    margin-bottom: 0;
}

.owner-perk-item:hover {
    transform: translateX(3px);
    box-shadow: 0 4px 14px rgba(246, 211, 101, 0.35);
}

.owner-perk-icon {
    width: 34px;
    height: 34px;
    flex: 0 0 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #5a3b00;
    background: linear-gradient(135deg, var(--owner-c1), var(--owner-c2));
    box-shadow: 0 0 10px rgba(246, 211, 101, 0.6);
}

.owner-perk-label {
    font-size: 13px;
    color: #555;
    line-height: 1.1;
}

.owner-perk-value {
    font-weight: 800;
    color: #b8730a;
    font-size: 14px;
}

/* ---------------------------------------------------------------------------
   Thẻ nhiệm vụ: nhãn "+Xu ưu đãi Owner"
   --------------------------------------------------------------------------- */
.owner-task-bonus {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: 4px;
    padding: 2px 9px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 800;
    color: #5a3b00;
    background: linear-gradient(135deg, var(--owner-c1), var(--owner-c2));
    box-shadow: 0 0 8px rgba(246, 211, 101, 0.55);
    animation: ownerBadgePulse 2.4s ease-in-out infinite;
}

.owner-task-bonus i {
    font-size: 10px;
}

/* Nhãn "giảm X%" khi đổi thưởng / rút tiền */
.owner-discount-tag {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 9px;
    border-radius: 999px;
    font-size: 11px;
    font-weight: 800;
    color: #fff;
    background: linear-gradient(135deg, #e53935, #ff7043);
    box-shadow: 0 0 8px rgba(229, 57, 53, 0.5);
}

.owner-price-original {
    text-decoration: line-through;
    color: #999;
    font-size: 12px;
    margin-right: 4px;
}

.owner-price-final {
    color: #b8730a;
    font-weight: 800;
}

/* ---------------------------------------------------------------------------
   Print-friendly: tắt animation, giữ viền vàng
   --------------------------------------------------------------------------- */
@media print {
    .owner-profile-card,
    .owner-profile-card::before,
    .owner-profile-card::after,
    .owner-badge,
    .owner-task-bonus,
    .owner-avatar-ring {
        animation: none !important;
    }
    .owner-profile-card {
        box-shadow: 0 0 0 2px #d4a017;
    }
    .owner-username {
        -webkit-text-fill-color: #b8730a;
        color: #b8730a;
    }
}
