/**
 * Order Confirmation Page Styles
 * صفحه تایید سفارش - طراحی حرفه‌ای و کاملا ریسپانسیو
 */

/* ==================== Main Container ==================== */
.confirmation-main {
    min-height: 100vh;
    background: linear-gradient(135deg, #f5f7fa 0%, #e8ecf1 100%);
    padding: 40px 0;
}

.confirmation-section {
    padding: 20px 0;
}

/* ==================== Success Header ==================== */
.confirmation-header {
    text-align: center;
    padding: 60px 20px 40px;
    background: white;
    border-radius: 24px;
    margin-bottom: 30px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

/* Success Animation */
.success-animation {
    margin-bottom: 30px;
    display: inline-block;
}

.success-checkmark {
    width: 120px;
    height: 120px;
    margin: 0 auto;
    position: relative;
}

.check-icon {
    width: 120px;
    height: 120px;
    position: relative;
    border-radius: 50%;
    box-sizing: content-box;
    border: 4px solid #4CAF50;
    animation: scaleAnimation 0.5s ease-in-out;
}

.icon-line {
    height: 5px;
    background-color: #4CAF50;
    display: block;
    border-radius: 2px;
    position: absolute;
    z-index: 10;
}

.line-tip {
    top: 56px;
    left: 25px;
    width: 25px;
    transform: rotate(45deg);
    animation: tipAnimation 0.75s 0.3s ease-in-out;
}

.line-long {
    top: 50px;
    right: 15px;
    width: 47px;
    transform: rotate(-45deg);
    animation: longAnimation 0.75s 0.5s ease-in-out;
}

.icon-circle {
    top: -4px;
    left: -4px;
    z-index: 10;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    position: absolute;
    box-sizing: content-box;
    border: 4px solid rgba(76, 175, 80, 0.2);
}

.icon-fix {
    top: 12px;
    width: 10px;
    left: 32px;
    z-index: 1;
    height: 100px;
    position: absolute;
    transform: rotate(-45deg);
    background-color: white;
}

@keyframes scaleAnimation {
    0% {
        transform: scale(0);
    }
    100% {
        transform: scale(1);
    }
}

@keyframes tipAnimation {
    0% {
        width: 0;
        left: 1px;
        top: 19px;
    }
    54% {
        width: 0;
        left: 1px;
        top: 19px;
    }
    70% {
        width: 25px;
        left: -8px;
        top: 37px;
    }
    84% {
        width: 17px;
        left: 21px;
        top: 48px;
    }
    100% {
        width: 25px;
        left: 25px;
        top: 56px;
    }
}

@keyframes longAnimation {
    0% {
        width: 0;
        right: 46px;
        top: 54px;
    }
    65% {
        width: 0;
        right: 46px;
        top: 54px;
    }
    84% {
        width: 55px;
        right: 0;
        top: 35px;
    }
    100% {
        width: 47px;
        right: 15px;
        top: 50px;
    }
}

.confirmation-title {
    font-size: 32px;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 12px;
    line-height: 1.4;
}

.confirmation-subtitle {
    font-size: 16px;
    color: #7f8c8d;
    margin-bottom: 24px;
    line-height: 1.6;
}

.order-number-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 12px 24px;
    border-radius: 50px;
    font-size: 15px;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.badge-label {
    opacity: 0.9;
}

.badge-value {
    font-family: 'Courier New', monospace;
    letter-spacing: 1px;
}

/* ==================== Cards ==================== */
.order-items-card,
.order-info-card,
.shipping-info-card,
.order-summary-card,
.order-actions-card,
.support-card {
    background: white;
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    transition: all 0.3s ease;
}

.order-items-card:hover,
.order-info-card:hover,
.shipping-info-card:hover {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.card-header {
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 2px solid #f0f0f0;
}

.card-title {
    font-size: 20px;
    font-weight: 700;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
}

.card-title svg {
    color: #ef394e;
}

/* ==================== Order Items ==================== */
.order-items-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.order-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 12px;
    transition: all 0.3s ease;
}

.order-item:hover {
    background: #e9ecef;
    transform: translateX(-4px);
}

.item-image-wrapper {
    flex-shrink: 0;
    width: 100px;
    height: 100px;
    border-radius: 12px;
    overflow: hidden;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #e9ecef;
}

.item-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.item-image-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: #adb5bd;
    font-size: 12px;
    text-align: center;
    padding: 10px;
}

.item-image-placeholder svg {
    color: #dee2e6;
}

.item-details {
    flex: 1;
    min-width: 0;
}

.item-name {
    font-size: 16px;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 6px;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.item-sku {
    display: inline-block;
    font-size: 13px;
    color: #6c757d;
    background: white;
    padding: 4px 10px;
    border-radius: 6px;
    margin-bottom: 8px;
}

.item-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    font-size: 14px;
    color: #7f8c8d;
}

.item-quantity,
.item-unit-price {
    display: flex;
    align-items: center;
    gap: 4px;
}

.item-quantity svg {
    color: #ef394e;
}

.item-price-section {
    flex-shrink: 0;
    text-align: left;
}

.item-total-price {
    font-size: 18px;
    font-weight: 700;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 6px;
}

/* ==================== Order Info Grid ==================== */
.order-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
}

.info-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 12px;
}

.info-icon {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 10px;
    color: white;
}

.info-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.info-label {
    font-size: 13px;
    color: #7f8c8d;
}

.info-value {
    font-size: 15px;
    font-weight: 600;
    color: #2c3e50;
}

.status-badge,
.payment-badge {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
}

.status-badge.status-pending {
    background: #fff3cd;
    color: #856404;
}

.status-badge.status-paid,
.status-badge.status-processing {
    background: #d1ecf1;
    color: #0c5460;
}

.status-badge.status-shipped,
.status-badge.status-delivered {
    background: #d4edda;
    color: #155724;
}

.payment-badge.payment-paid {
    background: #d4edda;
    color: #155724;
}

.payment-badge.payment-pending {
    background: #fff3cd;
    color: #856404;
}

/* ==================== Shipping Info ==================== */
.shipping-details {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.receiver-info {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.receiver-name-row,
.receiver-phone-row {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 15px;
}

.receiver-name-row svg,
.receiver-phone-row svg {
    color: #ef394e;
}

.receiver-name {
    font-weight: 600;
    color: #2c3e50;
}

.receiver-phone {
    color: #495057;
    direction: ltr;
    text-align: right;
}

.receiver-address {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 10px;
}

.receiver-address svg {
    flex-shrink: 0;
    margin-top: 2px;
    color: #ef394e;
}

.receiver-address p {
    margin: 0;
    line-height: 1.7;
    color: #495057;
    font-size: 14px;
}

.postal-code {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: #e9ecef;
    border-radius: 8px;
    font-size: 14px;
}

.postal-label {
    color: #6c757d;
}

.postal-value {
    font-weight: 600;
    color: #2c3e50;
    font-family: 'Courier New', monospace;
    letter-spacing: 1px;
}

/* ==================== Order Summary ==================== */
.sticky-sidebar {
    position: sticky;
    top: 20px;
}

.summary-content {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
}

.summary-label {
    font-size: 15px;
    color: #6c757d;
    display: flex;
    align-items: center;
    gap: 6px;
}

.summary-value {
    font-size: 16px;
    font-weight: 600;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 6px;
}

.discount-row .summary-label {
    color: #28a745;
}

.discount-value {
    color: #28a745 !important;
}

.summary-divider {
    height: 2px;
    background: linear-gradient(90deg, transparent, #e9ecef, transparent);
    margin: 8px 0;
}

.total-row {
    padding: 16px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    margin-top: 8px;
}

.total-row .summary-label,
.total-row .summary-value {
    color: white;
    font-size: 18px;
}

.total-value {
    font-size: 24px !important;
    font-weight: 700 !important;
}

.free-shipping {
    color: #28a745;
    font-weight: 600;
}

/* ==================== Action Buttons ==================== */
.order-actions-card {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.action-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 20px;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.action-btn-primary {
    background: linear-gradient(135deg, #ef394e 0%, #d62839 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(239, 57, 78, 0.3);
}

.action-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(239, 57, 78, 0.4);
    color: white;
}

.action-btn-secondary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.action-btn-secondary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
    color: white;
}

.action-btn-outline {
    background: white;
    color: #495057;
    border: 2px solid #e9ecef;
}

.action-btn-outline:hover {
    background: #f8f9fa;
    border-color: #dee2e6;
    transform: translateY(-2px);
    color: #495057;
}

/* ==================== Action Button (Alternative Class Name) ==================== */
.action-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 20px;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    width: 100%;
    text-align: center;
}

.action-button svg,
.action-button .svg-icon {
    flex-shrink: 0;
}

.action-button.secondary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.action-button.secondary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
    color: white;
}

.action-button.danger {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(220, 53, 69, 0.3);
}

.action-button.danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(220, 53, 69, 0.4);
    color: white;
    background: linear-gradient(135deg, #c82333 0%, #bd2130 100%);
}

.action-button.outline {
    background: white;
    color: #495057;
    border: 2px solid #e9ecef;
}

.action-button.outline:hover {
    background: #f8f9fa;
    border-color: #dee2e6;
    transform: translateY(-2px);
    color: #495057;
}

/* ==================== Support Card ==================== */
.support-card {
    text-align: center;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.support-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: white;
    border-radius: 50%;
    color: #ef394e;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.support-title {
    font-size: 18px;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 8px;
}

.support-desc,
.support-text {
    font-size: 14px;
    color: #6c757d;
    margin-bottom: 16px;
    line-height: 1.6;
}

.support-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: white;
    color: #ef394e;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.support-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    color: #d62839;
}

.support-link svg,
.support-link .svg-icon {
    transition: transform 0.3s ease;
}

.support-link:hover svg,
.support-link:hover .svg-icon {
    transform: translateX(-4px);
}

.support-phone-help-box {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: white;
    color: #ef394e;
    border-radius: 50px;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    direction: ltr;
}

.support-phone-help-box:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    color: #ef394e;
}

/* ==================== Order Not Found ==================== */
.order-not-found {
    text-align: center;
    padding: 80px 20px;
    background: white;
    border-radius: 24px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.not-found-animation {
    margin-bottom: 30px;
}

.not-found-icon {
    width: 120px;
    height: 120px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 50%;
    color: #adb5bd;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.not-found-title {
    font-size: 28px;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 12px;
}

.not-found-desc {
    font-size: 16px;
    color: #7f8c8d;
    margin-bottom: 32px;
    line-height: 1.6;
}

.not-found-actions {
    display: flex;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
}

.site-button {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 28px;
    background: linear-gradient(135deg, #ef394e 0%, #d62839 100%);
    color: white;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    box-shadow: 0 4px 15px rgba(239, 57, 78, 0.3);
    transition: all 0.3s ease;
}

.site-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(239, 57, 78, 0.4);
    color: white;
}

/* ==================== Responsive Design ==================== */

/* Tablet */
@media (max-width: 991px) {
    .confirmation-header {
        padding: 40px 20px 30px;
    }
    
    .confirmation-title {
        font-size: 26px;
    }
    
    .order-number-badge {
        font-size: 14px;
        padding: 10px 20px;
    }
    
    .sticky-sidebar {
        position: relative;
        top: 0;
    }
    
    .order-info-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Mobile */
@media (max-width: 767px) {
    .confirmation-main {
        padding: 20px 0;
    }
    
    .confirmation-header {
        padding: 30px 15px 25px;
        border-radius: 16px;
        margin-bottom: 20px;
    }
    
    .success-checkmark,
    .check-icon {
        width: 80px;
        height: 80px;
    }
    
    .check-icon {
        border: 3px solid #4CAF50;
    }
    
    .line-tip {
        top: 38px;
        left: 17px;
        width: 17px;
    }
    
    .line-long {
        top: 34px;
        right: 10px;
        width: 32px;
    }
    
    .icon-circle {
        width: 80px;
        height: 80px;
        border: 3px solid rgba(76, 175, 80, 0.2);
    }
    
    .icon-fix {
        top: 8px;
        left: 22px;
        height: 68px;
    }
    
    .confirmation-title {
        font-size: 22px;
    }
    
    .confirmation-subtitle {
        font-size: 14px;
    }
    
    .order-number-badge {
        font-size: 13px;
        padding: 8px 16px;
        flex-wrap: wrap;
    }
    
    .order-items-card,
    .order-info-card,
    .shipping-info-card,
    .order-summary-card,
    .order-actions-card,
    .support-card {
        padding: 16px;
        border-radius: 12px;
        margin-bottom: 16px;
    }
    
    .action-button {
        padding: 12px 16px;
        font-size: 14px;
        gap: 8px;
    }
    
    .action-button svg,
    .action-button .svg-icon {
        width: 18px;
        height: 18px;
    }
    
    .card-title {
        font-size: 17px;
    }
    
    .order-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
        padding: 12px;
    }
    
    .item-image-wrapper {
        width: 100%;
        height: 180px;
    }
    
    .item-details {
        width: 100%;
    }
    
    .item-name {
        font-size: 15px;
    }
    
    .item-meta {
        flex-direction: column;
        gap: 8px;
    }
    
    .item-price-section {
        width: 100%;
        text-align: right;
    }
    
    .item-total-price {
        font-size: 16px;
        justify-content: flex-end;
    }
    
    .order-info-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .info-item {
        padding: 12px;
    }
    
    .info-icon {
        width: 36px;
        height: 36px;
    }
    
    .summary-row {
        padding: 10px 0;
    }
    
    .summary-label,
    .summary-value {
        font-size: 14px;
    }
    
    .total-row .summary-label,
    .total-row .summary-value {
        font-size: 16px;
    }
    
    .total-value {
        font-size: 20px !important;
    }
    
    .action-btn,
    .action-button {
        padding: 12px 16px;
        font-size: 14px;
        gap: 8px;
    }
    
    .action-button svg,
    .action-button .svg-icon {
        width: 18px;
        height: 18px;
    }
    
    .support-icon {
        width: 50px;
        height: 50px;
    }
    
    .support-title {
        font-size: 16px;
    }
    
    .support-desc {
        font-size: 13px;
    }
    
    .support-phone-help-box {
        font-size: 14px;
        padding: 10px 20px;
    }
    
    .order-not-found {
        padding: 50px 15px;
        border-radius: 16px;
    }
    
    .not-found-icon {
        width: 100px;
        height: 100px;
    }
    
    .not-found-title {
        font-size: 22px;
    }
    
    .not-found-desc {
        font-size: 14px;
    }
    
    .not-found-actions {
        flex-direction: column;
        align-items: stretch;
    }
    
    .site-button,
    .not-found-actions .action-btn {
        width: 100%;
        justify-content: center;
    }
}

/* Small Mobile */
@media (max-width: 480px) {
    .confirmation-title {
        font-size: 20px;
    }
    
    .order-number-badge {
        font-size: 12px;
        padding: 6px 12px;
    }
    
    .badge-value {
        font-size: 11px;
    }
    
    .item-image-wrapper {
        height: 150px;
    }
}
