/* AVT WP Manage - Admin Styles */

/* ==========================================================================
   Dashboard Grid Layout
   ========================================================================== */

.avt-dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

/* ==========================================================================
   Card Styles
   ========================================================================== */

.avt-card {
    background: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.avt-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.avt-card h2 {
    margin: 0 0 15px 0;
    font-size: 18px;
    color: #23282d;
    border-bottom: 2px solid #f0f0f0;
    padding-bottom: 10px;
}

/* Color variants */
.avt-card-blue { border-left: 4px solid #0073aa; }
.avt-card-green { border-left: 4px solid #46b450; }
.avt-card-red { border-left: 4px solid #dc3232; }
.avt-card-orange { border-left: 4px solid #ff922b; }
.avt-card-purple { border-left: 4px solid #826eb4; }
.avt-card-teal { border-left: 4px solid #00a0d2; }
.avt-card-gray { border-left: 4px solid #82878c; }

/* ==========================================================================
   Statistics Display
   ========================================================================== */

.avt-stats {
    margin-bottom: 15px;
}

.avt-stats p {
    margin: 8px 0;
    font-size: 14px;
    line-height: 1.4;
}

.avt-stats strong {
    color: #23282d;
    font-weight: 600;
}

/* Status indicators */
.avt-success { color: #46b450; font-weight: bold; }
.avt-warning { color: #ff922b; font-weight: bold; }
.avt-danger { color: #dc3232; font-weight: bold; }
.avt-info { color: #0073aa; font-weight: bold; }

/* ==========================================================================
   Quick Actions
   ========================================================================== */

.avt-quick-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 15px;
}

.avt-quick-actions .button {
    flex: 1;
    min-width: auto;
    text-align: center;
    white-space: nowrap;
}

.avt-actions {
    display: flex;
    gap: 10px;
    margin-top: 15px;
    flex-wrap: wrap;
}

.avt-actions .button {
    flex: 1;
    text-align: center;
}

/* ==========================================================================
   Progress Bars
   ========================================================================== */

.avt-progress-bar {
    width: 100%;
    height: 20px;
    background-color: #f0f0f0;
    border-radius: 10px;
    overflow: hidden;
    margin: 10px 0;
    position: relative;
}

.avt-progress-fill {
    height: 100%;
    background: linear-gradient(45deg, #0073aa, #00a0d2);
    border-radius: 10px;
    transition: width 0.3s ease;
    position: relative;
}

.avt-progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    background-image: linear-gradient(
        -45deg,
        rgba(255, 255, 255, .2) 25%,
        transparent 25%,
        transparent 50%,
        rgba(255, 255, 255, .2) 50%,
        rgba(255, 255, 255, .2) 75%,
        transparent 75%,
        transparent
    );
    background-size: 20px 20px;
    animation: move-stripes 1s linear infinite;
}

@keyframes move-stripes {
    0% { background-position: 0 0; }
    100% { background-position: 20px 0; }
}

.avt-progress-text {
    margin: 5px 0;
    font-size: 14px;
    color: #666;
    text-align: center;
}

/* ==========================================================================
   Tab Navigation
   ========================================================================== */

.nav-tab-wrapper {
    margin-bottom: 20px;
}

.nav-tab {
    border-radius: 6px 6px 0 0;
    transition: all 0.2s ease;
}

.nav-tab:hover {
    background-color: #f8f9fa;
}

.nav-tab-active {
    background-color: #ffffff;
    border-bottom: 1px solid #ffffff;
}

/* ==========================================================================
   Form Elements
   ========================================================================== */

.avt-form-section {
    margin-bottom: 30px;
}

.avt-form-section h3 {
    margin-bottom: 15px;
    color: #23282d;
    font-size: 16px;
}

.avt-settings-section {
    margin-bottom: 40px;
    padding-bottom: 30px;
    border-bottom: 1px solid #e0e0e0;
}

.avt-settings-section:last-child {
    border-bottom: none;
    margin-bottom: 20px;
}

/* ==========================================================================
   Loading States
   ========================================================================== */

.avt-loading {
    text-align: center;
    padding: 20px;
    color: #666;
    font-style: italic;
}

.avt-loading::before {
    content: "⏳ ";
    animation: spin 2s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ==========================================================================
   Tables and Lists
   ========================================================================== */

.avt-data-table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
}

.avt-data-table th,
.avt-data-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #e0e0e0;
}

.avt-data-table th {
    background-color: #f8f9fa;
    font-weight: 600;
    color: #23282d;
}

.avt-data-table tr:hover {
    background-color: #f8f9fa;
}

.avt-activity-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.avt-activity-list li {
    padding: 10px 0;
    border-bottom: 1px solid #f0f0f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.avt-activity-list li:last-child {
    border-bottom: none;
}

.avt-activity-time {
    font-size: 12px;
    color: #666;
    min-width: 100px;
}

.avt-activity-desc {
    flex: 1;
    margin-left: 15px;
    color: #23282d;
}

/* ==========================================================================
   Information Grids
   ========================================================================== */

.avt-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.avt-info-item {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.avt-info-item strong {
    color: #23282d;
    font-size: 14px;
}

.avt-info-item span {
    color: #666;
    font-size: 13px;
    font-family: monospace;
    background: #f8f9fa;
    padding: 4px 8px;
    border-radius: 4px;
}

/* ==========================================================================
   Sitemap Specific Styles
   ========================================================================== */

.avt-sitemap-preview {
    max-height: 400px;
    overflow-y: auto;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #f9f9f9;
}

.avt-sitemap-preview pre {
    margin: 0;
    padding: 15px;
    font-size: 12px;
    line-height: 1.4;
    color: #333;
}

.avt-generator-section {
    margin-bottom: 30px;
}

.avt-generator-actions {
    margin: 20px 0;
}

.avt-generator-info {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 4px;
    margin-top: 20px;
}

.avt-generator-info h4 {
    margin: 0 0 10px 0;
    color: #23282d;
}

.avt-generator-info ul {
    margin: 0;
    padding-left: 20px;
}

.avt-generator-info li {
    margin: 5px 0;
    color: #666;
}

/* ==========================================================================
   About Section
   ========================================================================== */

.avt-about {
    margin-bottom: 20px;
}

.avt-about p {
    margin-bottom: 15px;
    line-height: 1.5;
    color: #666;
}

.avt-about ul {
    margin: 0;
    padding-left: 20px;
}

.avt-about li {
    margin: 8px 0;
    color: #666;
    line-height: 1.4;
}

/* ==========================================================================
   Security Features
   ========================================================================== */

.avt-security-warning {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    color: #856404;
    padding: 12px;
    border-radius: 4px;
    margin: 15px 0;
}

.avt-security-success {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
    padding: 12px;
    border-radius: 4px;
    margin: 15px 0;
}

.avt-captcha-container {
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    margin: 20px 0;
}

.avt-captcha-question {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 10px;
    color: #23282d;
}

.avt-captcha-input {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    width: 100px;
    text-align: center;
}

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

@media (max-width: 768px) {
    .avt-dashboard-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .avt-quick-actions {
        flex-direction: column;
    }
    
    .avt-quick-actions .button {
        width: 100%;
        margin-bottom: 8px;
    }
    
    .avt-actions {
        flex-direction: column;
    }
    
    .avt-actions .button {
        width: 100%;
        margin-bottom: 8px;
    }
    
    .avt-info-grid {
        grid-template-columns: 1fr;
    }
    
    .avt-activity-list li {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .avt-activity-time {
        min-width: auto;
        margin-bottom: 5px;
    }
    
    .avt-activity-desc {
        margin-left: 0;
    }
}

/* ==========================================================================
   Dark Mode Support
   ========================================================================== */

@media (prefers-color-scheme: dark) {
    .avt-card {
        background: #1e1e1e;
        border-color: #3c3c3c;
        color: #e0e0e0;
    }
    
    .avt-card h2 {
        color: #ffffff;
        border-bottom-color: #3c3c3c;
    }
    
    .avt-stats strong {
        color: #ffffff;
    }
    
    .avt-info-item span {
        background: #2c2c2c;
        color: #e0e0e0;
    }
    
    .avt-generator-info {
        background: #2c2c2c;
        color: #e0e0e0;
    }
    
    .avt-generator-info h4 {
        color: #ffffff;
    }
}

/* ==========================================================================
   Animations and Transitions
   ========================================================================== */

.avt-card,
.button,
.nav-tab {
    transition: all 0.2s ease;
}

.avt-card:hover {
    transform: translateY(-2px);
}

/* Fade in animation for dashboard cards */
.avt-dashboard-grid .avt-card {
    animation: fadeInUp 0.5s ease forwards;
    opacity: 0;
    transform: translateY(20px);
}

.avt-dashboard-grid .avt-card:nth-child(1) { animation-delay: 0.1s; }
.avt-dashboard-grid .avt-card:nth-child(2) { animation-delay: 0.2s; }
.avt-dashboard-grid .avt-card:nth-child(3) { animation-delay: 0.3s; }
.avt-dashboard-grid .avt-card:nth-child(4) { animation-delay: 0.4s; }
.avt-dashboard-grid .avt-card:nth-child(5) { animation-delay: 0.5s; }
.avt-dashboard-grid .avt-card:nth-child(6) { animation-delay: 0.6s; }

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ==========================================================================
   Print Styles
   ========================================================================== */

@media print {
    .avt-quick-actions,
    .avt-actions,
    .button {
        display: none;
    }
    
    .avt-card {
        box-shadow: none;
        border: 1px solid #000;
        margin-bottom: 20px;
        page-break-inside: avoid;
    }
    
    .avt-dashboard-grid {
        display: block;
    }
}