/* Wine Business Pro - Supplier Dashboard Frontend Styles */

/* === CSS VARIABLES - TEMA VINÍCOLA === */
:root {
    /* Colores principales del tema vinícola */
    --wbp-primary: #722f37;        /* Borgoña principal */
    --wbp-secondary: #8b3a42;      /* Borgoña claro */
    --wbp-accent: #d4af37;         /* Dorado elegante */
    --wbp-dark: #4a1e23;           /* Borgoña oscuro */
    --wbp-light: #f8f5f1;          /* Crema suave */
    
    /* Estados del sistema */
    --wbp-success: #4a7c59;        /* Verde esmeralda suave que armoniza con el borgoña */
    --wbp-success-bg: #f0f7f1;     /* Fondo verde muy suave */
    --wbp-warning: #b8860b;        /* Oro viejo */
    --wbp-danger: #8b0000;         /* Rojo oscuro */
    --wbp-info: #6b4423;           /* Marrón información */
    
    /* Colores de texto */
    --wbp-text-primary: #333;
    --wbp-text-secondary: #666;
    --wbp-text-muted: #999;
    
    /* Sombras y bordes */
    --wbp-shadow-light: 0 2px 10px rgba(0, 0, 0, 0.08);
    --wbp-shadow-medium: 0 4px 20px rgba(0, 0, 0, 0.1);
    --wbp-border-radius: 12px;
    --wbp-border-radius-small: 6px;
}

/* === LOGIN FORM === */
.wbp-supplier-login-wrapper {
    max-width: 400px;
    margin: 40px auto;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    padding: 40px;
    border-top: 4px solid #722f37;
}

.wbp-login-form h3 {
    color: #722f37;
    text-align: center;
    margin-bottom: 10px;
    font-size: 24px;
}

.wbp-login-form p {
    text-align: center;
    color: #666;
    margin-bottom: 30px;
}

.wbp-login-form form {
    margin-bottom: 20px;
}

.wbp-login-form label {
    display: block;
    margin-bottom: 5px;
    color: #333;
    font-weight: 500;
}

.wbp-login-form input[type="text"],
.wbp-login-form input[type="password"] {
    width: 100%;
    padding: 12px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    margin-bottom: 15px;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

.wbp-login-form input[type="text"]:focus,
.wbp-login-form input[type="password"]:focus {
    outline: none;
    border-color: #722f37;
    box-shadow: 0 0 0 3px rgba(114, 47, 55, 0.1);
}

.wbp-login-form input[type="submit"] {
    background: #722f37;
    color: white;
    padding: 12px 24px;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    width: 100%;
    transition: background-color 0.3s ease;
}

.wbp-login-form input[type="submit"]:hover {
    background: #8b3a42;
}

.wbp-login-links {
    text-align: center;
    margin-top: 15px;
}

.wbp-login-links a {
    color: #722f37;
    text-decoration: none;
}

.wbp-login-links a:hover {
    text-decoration: underline;
}

/* === NO SUPPLIER PROFILE === */
.wbp-no-supplier-profile {
    max-width: 600px;
    margin: 40px auto;
}

.wbp-notice {
    background: #fff;
    border-radius: 8px;
    padding: 30px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.wbp-notice-warning {
    border-left: 4px solid #f57c00;
}

.wbp-notice h3 {
    color: #f57c00;
    margin-top: 0;
}

/* === DASHBOARD WRAPPER === */
.wbp-supplier-dashboard-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* === HEADER SECTION === */
.wbp-dashboard-header {
    background: linear-gradient(135deg, #722f37 0%, #8b3a42 100%);
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 30px;
    color: white;
}

.wbp-header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.wbp-supplier-welcome h1 {
    margin: 0 0 10px 0;
    font-size: 32px;
    font-weight: 700;
}

.wbp-supplier-status {
    margin: 0;
    opacity: 0.9;
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.status-badge {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-active {
    background: var(--wbp-success);
    color: white;
}

.status-pending {
    background: var(--wbp-warning);
    color: white;
}

.status-inactive {
    background: var(--wbp-danger);
    color: white;
}

.wbp-header-actions {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

/* === BUTTONS === */
.wbp-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.wbp-btn-primary {
    background: #fff;
    color: #722f37;
}

.wbp-btn-primary:hover {
    background: #f5f5f5;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.wbp-btn-secondary {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.wbp-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: rgba(255, 255, 255, 0.5);
}

.wbp-btn-small {
    padding: 6px 12px;
    font-size: 12px;
}

.wbp-btn-text {
    background: none;
    color: #722f37;
    padding: 8px 0;
    border-bottom: 2px solid transparent;
}

.wbp-btn-text:hover {
    border-bottom-color: #722f37;
}

/* === STATISTICS GRID === */
.wbp-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.wbp-stat-card {
    background: #fff;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    display: flex;
    align-items: center;
    gap: 20px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.wbp-stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
}

.wbp-stat-card.highlight {
    background: linear-gradient(135deg, #722f37 0%, #8b3a42 100%);
    color: white;
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(114, 47, 55, 0.1);
    flex-shrink: 0;
}

.wbp-stat-card.highlight .stat-icon {
    background: rgba(255, 255, 255, 0.2);
}

.stat-icon .dashicons {
    font-size: 24px;
    color: #722f37;
}

.wbp-stat-card.highlight .stat-icon .dashicons {
    color: white;
}

.stat-content {
    flex: 1;
}

.stat-number {
    font-size: 28px;
    font-weight: 700;
    line-height: 1;
    margin-bottom: 5px;
    color: #333;
}

.wbp-stat-card.highlight .stat-number {
    color: white;
}

.stat-label {
    font-size: 14px;
    color: #666;
    margin-bottom: 5px;
    font-weight: 500;
}

.wbp-stat-card.highlight .stat-label {
    color: rgba(255, 255, 255, 0.9);
}

.stat-detail {
    font-size: 12px;
    color: #999;
}

.wbp-stat-card.highlight .stat-detail {
    color: rgba(255, 255, 255, 0.7);
}

/* === CONTENT SECTIONS === */
.wbp-content-section {
    background: #fff;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
}

.wbp-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px solid #f0f0f0;
}

.wbp-section-header h2 {
    margin: 0;
    color: #333;
    font-size: 24px;
    font-weight: 700;
}

/* === PRODUCTS GRID === */
.wbp-products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.wbp-product-card {
    border: 2px solid #f0f0f0;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.wbp-product-card:hover {
    border-color: #722f37;
    box-shadow: 0 8px 25px rgba(114, 47, 55, 0.1);
    transform: translateY(-5px);
}

.product-image {
    position: relative;
    height: 200px;
    overflow: hidden;
    background: #f9f9f9;
}

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

.no-image {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ccc;
    font-size: 48px;
}

.product-status {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.status-publish {
    background: var(--wbp-success-bg);
    color: var(--wbp-success);
}

.status-draft {
    background: var(--wbp-warning);
    color: white;
}

.status-private {
    background: var(--wbp-info);
    color: white;
}

.product-info {
    padding: 20px;
}

.product-title {
    margin: 0 0 10px 0;
    font-size: 18px;
    font-weight: 600;
}

.product-title a {
    color: #333;
    text-decoration: none;
}

.product-title a:hover {
    color: #722f37;
}

.product-price {
    font-size: 20px;
    font-weight: 700;
    color: #722f37;
    margin-bottom: 10px;
}

.product-meta {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 15px;
}

.product-meta span {
    display: block;
    padding: 6px 10px;
    background: #f8f8f8;
    border-left: 3px solid #722f37;
    border-radius: 4px;
    font-size: 13px;
    color: #555;
    line-height: 1.4;
}

.product-meta span strong {
    color: #722f37;
    font-weight: 600;
    margin-right: 6px;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

/* Individual taxonomy/meta styles */
.wine-type {
    border-left-color: #8b3a42;
}

.wine-vintage {
    border-left-color: #d4af37;
}

.wine-region {
    border-left-color: #4a7c59;
}

.grape-variety {
    border-left-color: #6b4423;
}

.product-actions {
    display: flex;
    gap: 10px;
    padding: 15px 20px;
    background: #f9f9f9;
    border-top: 1px solid #f0f0f0;
}

/* === EMPTY STATE === */
.wbp-empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #666;
}

.empty-icon {
    font-size: 72px;
    color: #ddd;
    margin-bottom: 20px;
}

.wbp-empty-state h3 {
    color: #333;
    margin-bottom: 10px;
}

/* === QUICK ACTIONS === */
.wbp-quick-actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.wbp-action-card {
    border: 2px solid #f0f0f0;
    border-radius: 12px;
    padding: 25px;
    text-align: center;
    transition: all 0.3s ease;
}

.wbp-action-card:hover {
    border-color: #722f37;
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(114, 47, 55, 0.1);
}

.action-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(114, 47, 55, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
}

.action-icon .dashicons {
    font-size: 32px;
    color: #722f37;
}

.action-content h4 {
    margin: 0 0 10px 0;
    color: #333;
    font-size: 18px;
}

.action-content p {
    color: #666;
    margin-bottom: 20px;
    line-height: 1.5;
}

/* === FOOTER === */
.wbp-dashboard-footer {
    background: #f9f9f9;
    border-radius: 12px;
    padding: 30px;
    text-align: center;
}

.wbp-help-section h3 {
    color: #333;
    margin-bottom: 10px;
}

.wbp-help-section p {
    color: #666;
    margin-bottom: 20px;
}

.wbp-help-links {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
}

.wbp-help-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #722f37;
    text-decoration: none;
    transition: transform 0.3s ease;
}

.wbp-help-link:hover {
    transform: translateY(-3px);
}

.wbp-help-link .dashicons {
    font-size: 24px;
    margin-bottom: 8px;
}

/* === RESPONSIVE DESIGN === */
@media (max-width: 768px) {
    .wbp-supplier-dashboard-wrapper {
        padding: 15px;
    }

    .wbp-dashboard-header {
        padding: 20px;
    }

    .wbp-header-content {
        flex-direction: column;
        align-items: flex-start;
        text-align: center;
    }

    .wbp-supplier-welcome h1 {
        font-size: 24px;
    }

    .wbp-header-actions {
        width: 100%;
        justify-content: center;
    }

    .wbp-stats-grid {
        grid-template-columns: 1fr;
    }

    .wbp-stat-card {
        flex-direction: column;
        text-align: center;
    }

    .wbp-products-grid {
        grid-template-columns: 1fr;
    }

    .wbp-quick-actions-grid {
        grid-template-columns: 1fr;
    }

    .wbp-section-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }

    .wbp-help-links {
        flex-direction: column;
        gap: 15px;
    }

    .product-actions {
        flex-direction: column;
    }

    .product-actions .wbp-btn {
        text-align: center;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .wbp-supplier-login-wrapper {
        margin: 20px auto;
        padding: 30px 20px;
    }

    .wbp-dashboard-header {
        padding: 15px;
    }

    .wbp-content-section {
        padding: 20px 15px;
    }

    .wbp-supplier-welcome h1 {
        font-size: 20px;
    }

    .stat-number {
        font-size: 24px;
    }

    .wbp-btn {
        padding: 10px 16px;
        font-size: 13px;
    }
}