/*product_details.css*/
.product-page-wrapper {
    background-color: var(--color-bg);
    padding: 0 0 60px 0;
    min-height: 100vh;
    font-family: var(--font-family);
    width: 100%;
}

.product-main-card {
    display: grid;
    grid-template-columns: 0.8fr 1.2fr;
    background: #ffffff;
    border: 1px solid #edf1ed;
    border-radius: 16px;
    overflow: hidden;
    transition: all 0.3s ease;
    height: 350;
}

.product-image-area {
    padding: 15px;
    background: #fafafa;
    display: flex;
    align-items: center;
    justify-content: center;
    border-right: 1px solid #edf1ed;
}

.product-image-area img {
    width: 85%;
    max-height: 350px;
    object-fit: contain;
    border-radius: 10px;
}

.product-info-area {
    padding: 30px 40px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    justify-content: center;
}

.category-label {
    color: #c5a059;
    font-weight: 700;
    font-size: 0.75rem;
    letter-spacing: 1px;
}

.product-title {
    color: #1a1a1a;
    font-size: 1.6rem;
    margin: 0;
    line-height: 1.2;
}

.price-display {
    font-size: 1.4rem;
    color: var(--color-secondary);
    font-weight: 700;
}

.accent-line-left {
    width: 30px;
    height: 2px;
    background-color: #c5a059;
    margin: 5px 0 15px 0;
}

.qty-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 15px 0;
}

.qty-label {
    font-weight: 600;
    color: #444;
    font-size: 0.9rem;
}

.quantity-control {
    display: inline-flex;
    align-items: stretch;
    border: 1px solid var(--color-border);
    border-radius: 4px;
    overflow: hidden;
    background: white;
    margin: 0 auto; 
    transform: translateX(-25px); 
}

.qty-btn {
    width: 35px;
    height: 32px;
    border: none;
    background: white;
    color: #666;
    cursor: pointer;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.quantity-control input {
    width: 45px;
    border: none;
    border-left: 1px solid #f0f0f0;
    border-right: 1px solid #f0f0f0;
    text-align: center;
    font-size: 0.95rem;
    font-weight: bold;
    color: var(--color-secondary);
    outline: none;
    margin: 0;
}

.quantity-control input::-webkit-outer-spin-button,
.quantity-control input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.purchase-actions {
    display: flex;
    gap: 10px;
    margin-top: 10px;
}



.product-description-section,
.product-reviews-section {
    background: #ffffff;
    border: 1px solid #edf1ed;
    border-radius: 16px;
    padding: 35px;
    transition: all 0.3s ease;
}

.product-reviews-section:hover {
    border-color: #2d5a27;
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
}

.subsection-label {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 4px 0;
}

.description-text {
    color: #555;
    line-height: 1.8;
    font-size: 1.1rem;
}

.review-upload-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
    background: #f9fbf9;
    padding: 20px;
    border-radius: 12px;
}

.form-row-compact {
    display: flex;
    gap: 15px;
    align-items: center;
}

.review-upload-form textarea {
    width: 100%;
    padding: 12px;
    border-radius: 8px;
    border: 1px solid var(--color-border);
    min-height: 45px;
    height: 45px;
    resize: vertical;
    font-family: inherit;
}

input[type="file"]::file-selector-button {
    background: #ffffff;
    border: 1px solid var(--color-primary);
    color: var(--color-primary);
    padding: 8px 12px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 600;
    transition: 0.2s;
}

input[type="file"]::file-selector-button:hover {
    background: var(--color-primary);
    color: #ffffff;
}

.btn-submit-review {
    background: var(--color-secondary);
    color: white;
    max-width: 200px;
    align-self: flex-end;
}

.reviews-list { margin-top: 25px; }

.review-item {
    padding: 20px 0;
    border-bottom: 1px solid #eee;
}

.review-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
    margin-bottom: 5px;
}

.comment-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

.comment-actions form {
    margin: 0;
    display: flex;
    align-items: center;
}

.btn-action-link {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 600;
    padding: 0;
    line-height: 1;
}

.edit-link { color: var(--color-secondary); }
.delete-link { color: #d32f2f; }

.reviewer-name { font-weight: 700; color: var(--color-secondary); }

.review-image img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    margin-top: 10px;
    border-radius: 8px;
    border: 1px solid #eee;
}

.no-reviews-msg {
    text-align: center;
    padding: 40px;
    color: #888;
    background: #fcfcfc;
    border: 1px dashed #ccc;
    border-radius: 12px;
}

@media (max-width: 1100px) {
    .product-info-area { padding: 24px 28px; }
}

@media (max-width: 768px) {
    .product-main-card { grid-template-columns: 1fr; }
    .product-image-area { border-right: none; border-bottom: 1px solid #edf1ed; }
    .form-row-compact { flex-direction: column; align-items: flex-start; }
    .purchase-actions { flex-direction: column; }
    .qty-wrapper { flex-direction: row; align-items: center; justify-content: flex-start; }
    .quantity-control { margin-left: auto; transform: none;}
    .btn-submit-review { max-width: 100%; width: 100%; align-self: stretch; }
}

@media (max-width: 480px) {
    .product-info-area, .product-description-section, .product-reviews-section { padding: 20px 16px; }
    .product-title { font-size: 1.35rem; }
    .price-display { font-size: 1.2rem; }
}

#cartToast {
    position: fixed;
    top: 80px;
    right: 24px;
    z-index: 9999;
    animation: toastSlideIn 0.35s ease forwards;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

#cartToast.toast-hiding {
    animation: toastSlideOut 0.4s ease forwards;
}

.toast-inner {
    background: #ffffff;
    border-radius: 14px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.13);
    width: 300px;
    overflow: hidden;
    border: 1px solid #e8f0e9;
}

.toast-header {
    background: var(--color-secondary);
    color: white;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
}

.toast-check { font-size: 1rem; font-weight: 700; }

.toast-title {
    flex: 1;
    font-size: 0.9rem;
    font-weight: 600;
}

.toast-close {
    background: none;
    border: none;
    color: rgba(255,255,255,0.8);
    cursor: pointer;
    font-size: 0.85rem;
    padding: 0;
    line-height: 1;
    transition: color 0.2s;
}

.toast-close:hover { color: white; }

.toast-body {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px;
}

.toast-body img {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid #eee;
    background: #fafafa;
}

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

.toast-product-name {
    font-size: 0.9rem;
    font-weight: 600;
    color: #1a1a1a;
}

@keyframes toastSlideIn {
    from { opacity: 0; transform: translateX(60px); }
    to   { opacity: 1; transform: translateX(0); }
}

@keyframes toastSlideOut {
    from { opacity: 1; transform: translateX(0); }
    to   { opacity: 0; transform: translateX(60px); }
}
