/**
 * MEATIOWA Bulk Meat Store Styles
 */

/* ============================================
   HERO SECTION
   ============================================ */
.bulk-hero {
    background: linear-gradient(135deg, #1e3a2f 0%, #2d5a45 100%);
    color: white;
    padding: 80px 20px;
    text-align: center;
}

.bulk-hero .hero-title {
    font-family: 'Bitter', serif;
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.bulk-hero .hero-subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto 2rem;
}

.hero-benefits {
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

.benefit {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    font-size: 0.95rem;
}

.benefit i {
    color: #B8860B;
}

/* ============================================
   HOW IT WORKS
   ============================================ */
.how-it-works {
    background: #f8f9fa;
    padding: 60px 20px;
}

.how-it-works .section-title {
    text-align: center;
    font-family: 'Bitter', serif;
    font-size: 1.8rem;
    margin-bottom: 3rem;
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    max-width: 1000px;
    margin: 0 auto;
}

.step {
    text-align: center;
    padding: 1.5rem;
}

.step-number {
    width: 50px;
    height: 50px;
    background: #B8860B;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 auto 1rem;
}

.step h3 {
    font-family: 'Bitter', serif;
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    color: #1e3a2f;
}

.step p {
    font-size: 0.9rem;
    color: #666;
    line-height: 1.5;
}

@media (max-width: 768px) {
    .steps-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 480px) {
    .steps-grid {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   LISTINGS SECTION
   ============================================ */
.listings-section {
    padding: 60px 20px;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.section-title {
    font-family: 'Bitter', serif;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.section-title i {
    color: #B8860B;
}

.filters {
    display: flex;
    gap: 1rem;
}

.filters select {
    padding: 0.5rem 1rem;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 0.9rem;
    background: white;
    cursor: pointer;
}

.listings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
}

/* ============================================
   LISTING CARD
   ============================================ */
.listing-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.listing-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
}

.listing-image {
    height: 140px;
    background: linear-gradient(135deg, #2d5a45 0%, #1e3a2f 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.listing-image i {
    font-size: 4rem;
    color: rgba(255,255,255,0.3);
}

.listing-content {
    padding: 1.25rem;
}

.listing-title {
    font-family: 'Bitter', serif;
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    color: #1e3a2f;
}

.listing-meta {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    margin-bottom: 1rem;
    font-size: 0.85rem;
    color: #666;
}

.listing-meta i {
    width: 20px;
    color: #999;
}

.listing-details {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    margin-bottom: 1rem;
    padding: 0.75rem;
    background: #f8f9fa;
    border-radius: 8px;
}

.listing-details .detail {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    font-size: 0.8rem;
}

.listing-details .detail i {
    color: #B8860B;
    margin-bottom: 0.25rem;
}

.listing-availability {
    margin-bottom: 1rem;
}

.portions-bar {
    height: 8px;
    background: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.5rem;
}

.portions-sold {
    height: 100%;
    background: linear-gradient(90deg, #B8860B, #d4a84b);
    transition: width 0.3s;
}

.portions-text {
    font-size: 0.8rem;
    color: #666;
}

.listing-price {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1e3a2f;
    text-align: right;
}

/* ============================================
   LISTING DETAIL MODAL
   ============================================ */
.modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    z-index: 1000;
    overflow-y: auto;
}

.modal.open {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: 16px;
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
}

.modal-content.modal-lg {
    max-width: 800px;
}

.modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #666;
    z-index: 10;
    min-width: 44px;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-header {
    padding: 1.5rem;
    border-bottom: 1px solid #eee;
}

.modal-header h3 {
    margin: 0;
    font-family: 'Bitter', serif;
}

.modal-body {
    padding: 1.5rem;
}

.modal-footer {
    padding: 1rem 1.5rem;
    border-top: 1px solid #eee;
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
}

/* Listing Detail */
.listing-detail-header {
    display: flex;
    gap: 1.5rem;
    padding: 2rem;
    background: linear-gradient(135deg, #2d5a45 0%, #1e3a2f 100%);
    color: white;
}

.listing-detail-image {
    width: 100px;
    height: 100px;
    background: rgba(255,255,255,0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.listing-detail-image i {
    font-size: 3rem;
    opacity: 0.5;
}

.listing-detail-info h2 {
    font-family: 'Bitter', serif;
    margin-bottom: 0.5rem;
}

.listing-detail-info .farm-link,
.listing-detail-info .location {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    opacity: 0.9;
    font-size: 0.95rem;
    margin: 0.25rem 0;
}

.listing-detail-info .farm-link a {
    color: white;
    text-decoration: underline;
}

.listing-detail-body {
    padding: 1.5rem;
}

.detail-section {
    margin-bottom: 2rem;
}

.detail-section h3 {
    font-family: 'Bitter', serif;
    font-size: 1.1rem;
    color: #1e3a2f;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #B8860B;
}

.specs-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.spec {
    display: flex;
    flex-direction: column;
}

.spec-label {
    font-size: 0.8rem;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.spec-value {
    font-size: 1.1rem;
    font-weight: 600;
    color: #1e3a2f;
}

/* Timeline */
.timeline {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.timeline-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.timeline-item i {
    width: 40px;
    height: 40px;
    background: #f0f4f2;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #B8860B;
    flex-shrink: 0;
}

.timeline-item strong {
    display: block;
    color: #1e3a2f;
}

.timeline-item span {
    color: #666;
    font-size: 0.9rem;
}

/* Portions Grid */
.portions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
}

.portion-option {
    border: 2px solid #e9ecef;
    border-radius: 12px;
    padding: 1rem;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
}

.portion-option:hover {
    border-color: #B8860B;
    background: #fffbf0;
}

.portion-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.portion-name {
    font-weight: 600;
    color: #1e3a2f;
}

.portion-status {
    font-size: 0.75rem;
    padding: 0.25rem 0.75rem;
    border-radius: 50px;
    text-transform: uppercase;
}

.portion-status.available {
    background: #d4edda;
    color: #155724;
}

.portion-details {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
    color: #666;
    font-size: 0.9rem;
}

.portion-price {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1e3a2f;
}

.sold-out-message {
    text-align: center;
    padding: 2rem;
    background: #f8f9fa;
    border-radius: 12px;
    color: #666;
}

.sold-out-message i {
    font-size: 3rem;
    color: #dc3545;
    margin-bottom: 1rem;
}

.pricing-info {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 12px;
}

.pricing-info ul {
    margin: 1rem 0 0;
    padding-left: 1.5rem;
}

.pricing-info li {
    margin: 0.5rem 0;
    color: #666;
}

/* ============================================
   MY PURCHASES
   ============================================ */
.my-purchases-section {
    background: #f8f9fa;
    padding: 60px 20px;
}

.purchases-list {
    display: grid;
    gap: 1rem;
}

.purchase-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.purchase-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.purchase-header h4 {
    font-family: 'Bitter', serif;
    margin: 0;
    color: #1e3a2f;
}

.status-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 600;
}

.status-primary { background: #cce5ff; color: #004085; }
.status-success { background: #d4edda; color: #155724; }
.status-warning { background: #fff3cd; color: #856404; }
.status-info { background: #d1ecf1; color: #0c5460; }
.status-secondary { background: #e2e3e5; color: #383d41; }

.purchase-details {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin-bottom: 1rem;
}

.purchase-details .detail {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: #666;
}

.purchase-details .detail i {
    color: #B8860B;
}

.purchase-actions {
    display: flex;
    gap: 1rem;
}

/* ============================================
   CUT SHEET MODAL
   ============================================ */
.cut-sheet-intro {
    margin-bottom: 1.5rem;
    color: #666;
}

.cut-options h4 {
    font-family: 'Bitter', serif;
    font-size: 1rem;
    color: #1e3a2f;
    margin: 1.5rem 0 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #eee;
}

.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #333;
}

.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 0.95rem;
}

.form-group textarea {
    resize: vertical;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
}

.btn:hover {
    transform: translateY(-1px);
}

.btn-primary {
    background: #B8860B;
    color: white;
}

.btn-primary:hover {
    background: #a0750a;
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-success {
    background: #28a745;
    color: white;
}

.btn-block {
    width: 100%;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
}

/* ============================================
   TOAST NOTIFICATIONS
   ============================================ */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
}

.toast {
    background: white;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    margin-bottom: 1rem;
    display: flex;
    flex-direction: column;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.toast.success { border-left: 4px solid #28a745; }
.toast.error { border-left: 4px solid #dc3545; }
.toast.info { border-left: 4px solid #17a2b8; }
.toast.warning { border-left: 4px solid #ffc107; }

/* ============================================
   EMPTY & LOADING STATES
   ============================================ */
.loading-state,
.empty-state {
    text-align: center;
    padding: 3rem;
    color: #666;
}

.loading-state i,
.empty-state i {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: #ccc;
}

.empty-state h3 {
    color: #333;
    margin-bottom: 0.5rem;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
    .bulk-hero .hero-title {
        font-size: 1.8rem;
    }

    .hero-benefits {
        flex-direction: column;
        align-items: center;
    }

    .section-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .filters {
        width: 100%;
    }

    .filters select {
        flex: 1;
    }

    .listing-detail-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .specs-grid {
        grid-template-columns: 1fr;
    }

    .portions-grid {
        grid-template-columns: 1fr;
    }

    .form-row {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   CONTAINER
   ============================================ */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}
