/*
 * WP Mediation Manager - Main Stylesheet 
 * Version: 5.4 (Final Suite)
 */

/* --- 1. GENERAL CONTAINER & RESET --- */
.wmm-wizard-container, 
.wmm-dashboard {
    max-width: 1000px;
    margin: 30px auto;
    background: #fff;
    padding: 30px;
    border: 1px solid #ccd0d4;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
    border-radius: 6px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    color: #3c434a;
    box-sizing: border-box;
}

.wmm-wizard-container *, 
.wmm-dashboard * {
    box-sizing: border-box;
}

/* Header (Title & Back Link) */
.wmm-wizard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.wmm-wizard-header h2 {
    font-size: 1.5em;
    color: #23282d;
    margin: 0;
}

.wmm-wizard-header a {
    text-decoration: none;
    font-size: 14px;
    color: #0073aa;
    font-weight: 500;
}
.wmm-wizard-header a:hover {
    text-decoration: underline;
}

/* --- 2. WIZARD STEPS INDICATOR --- */
ul.wmm-steps {
    list-style: none;
    padding: 0;
    margin: 0 0 30px 0;
    display: flex;
    border-bottom: 2px solid #f0f0f1;
}

ul.wmm-steps li {
    flex: 1;
    text-align: center;
    padding: 15px;
    background: #fcfcfc;
    color: #a7aaad;
    font-weight: 600;
    font-size: 14px;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: all 0.3s ease;
    cursor: default;
}

ul.wmm-steps li.active {
    background: #fff;
    color: #0073aa;
    border-bottom: 2px solid #0073aa;
    border-top: 3px solid #0073aa;
}

/* --- 3. FORM ELEMENTS & GRID --- */
.wmm-step {
    display: none;
}
.wmm-step.active {
    display: block;
    animation: fadeIn 0.4s ease-in-out;
}

.wmm-row {
    display: flex;
    gap: 20px;
    margin-bottom: 15px;
}

.wmm-col {
    flex: 1;
}

.wmm-form-group {
    margin-bottom: 20px;
}

label {
    display: block;
    font-weight: 600;
    font-size: 13px;
    margin-bottom: 6px;
    color: #2c3338;
}

input[type="text"],
input[type="email"],
input[type="number"],
input[type="date"],
input[type="datetime-local"],
input[type="url"],
select,
textarea {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #8c8f94;
    border-radius: 4px;
    font-size: 14px;
    line-height: 1.5;
    color: #2c3338;
    background-color: #fff;
}

input:focus, select:focus, textarea:focus {
    border-color: #0073aa;
    box-shadow: 0 0 0 1px #0073aa;
    outline: none;
}

/* --- 4. REPEATER FIELDS (PARTIES) --- */
.wmm-party-box {
    border: 1px solid #dcdcde;
    background: #f6f7f7;
    padding: 20px;
    margin-bottom: 25px;
    border-radius: 5px;
    position: relative;
    border-left: 4px solid #0073aa;
}

.wmm-party-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #e0e0e0;
}

.wmm-party-header strong {
    font-size: 1.1em;
    color: #0073aa;
}

/* --- 5. ATTENDANCE & CHECKBOXES --- */
.attendance-check {
    background: #f0fcf2;
    border: 1px solid #46b450;
    padding: 15px;
    margin-top: 15px;
    border-radius: 4px;
}

.attendance-check label {
    cursor: pointer;
    margin-bottom: 5px;
    display: block;
    font-weight: normal;
}

.attendance-check input[type="text"] {
    margin-top: 5px;
    border: 1px dashed #46b450;
}

/* --- 6. BUTTONS --- */
.wmm-btn {
    display: inline-block;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
    border-radius: 4px;
    border: none;
    transition: background 0.2s, transform 0.1s;
    line-height: normal;
}

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

.wmm-btn-primary {
    background: #0073aa;
    color: #fff;
}
.wmm-btn-primary:hover { background: #005177; color: #fff; }
.wmm-btn-primary:disabled { background: #a7aaad; cursor: not-allowed; }

.wmm-btn-secondary {
    background: #f0f0f1;
    color: #2c3338;
    border: 1px solid #8c8f94;
}
.wmm-btn-secondary:hover { background: #dcdcde; color: #2c3338; }

.wmm-btn-remove {
    background: #fff;
    color: #d63638;
    border: 1px solid #d63638;
    padding: 4px 10px;
    font-size: 12px;
    border-radius: 3px;
    cursor: pointer;
}
.wmm-btn-remove:hover {
    background: #d63638;
    color: #fff;
}

.wmm-btn-add {
    background: #fff;
    color: #0073aa;
    border: 1px dashed #0073aa;
    width: 100%;
    padding: 12px;
    text-align: center;
    font-weight: bold;
    cursor: pointer;
    border-radius: 4px;
    transition: all 0.2s;
}
.wmm-btn-add:hover {
    background: #f0f6fc;
    border-color: #005177;
}

.nav-btns {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #eee;
    display: flex;
    justify-content: space-between;
}

/* --- 7. ACTION CARDS (STEP 3 & SETTINGS) --- */
.wmm-doc-grid {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.wmm-doc-card {
    flex: 1;
    min-width: 280px;
    background: #fff;
    border: 1px solid #ccd0d4;
    border-radius: 5px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.02);
}

.wmm-doc-card h4 {
    margin-top: 0;
    padding-bottom: 10px;
    border-bottom: 1px solid #f0f0f1;
    font-size: 1.1em;
    color: #23282d;
}

.wmm-doc-card button {
    display: block;
    width: 100%;
    text-align: left;
    margin-bottom: 8px;
    padding: 10px;
    background: #f6f7f7;
    border: 1px solid #dcdcde;
    border-radius: 3px;
    cursor: pointer;
    color: #0073aa;
    font-weight: 500;
}
.wmm-doc-card button:hover {
    border-color: #0073aa;
    background: #fff;
}

/* Email List styling */
#email-buttons-list button {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 13px;
}
#email-buttons-list button:hover {
    background: #e5f5fa;
    border-color: #0073aa;
}

/* Signature Preview */
#sig-preview-box img {
    max-width: 100%;
    height: auto;
    border-radius: 3px;
    padding: 5px;
    background: #fff;
}

/* --- 8. DASHBOARD TABLE STYLES --- */
.wmm-dashboard table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border: 1px solid #ccd0d4;
    margin-top: 10px;
    border-radius: 3px;
    overflow: hidden;
}

.wmm-dashboard th {
    background: #f8f9fa;
    text-align: left;
    padding: 15px;
    font-weight: 600;
    border-bottom: 2px solid #ddd;
    color: #32373c;
}

.wmm-dashboard td {
    padding: 15px;
    border-bottom: 1px solid #eee;
    vertical-align: middle;
    color: #50575e;
}

.wmm-dashboard tr:last-child td {
    border-bottom: none;
}

.wmm-dashboard tr:hover {
    background: #fafafa;
}

/* --- 9. ANIMATIONS --- */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(5px); }
    to { opacity: 1; transform: translateY(0); }
}

/* --- 10. RESPONSIVE --- */
@media (max-width: 768px) {
    .wmm-wizard-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .wmm-row {
        flex-direction: column;
        gap: 10px;
    }
    
    ul.wmm-steps li {
        font-size: 12px;
        padding: 10px 5px;
    }
    
    .wmm-doc-grid {
        flex-direction: column;
    }

    /* Responsive Dashboard Table */
    .wmm-dashboard table, 
    .wmm-dashboard thead, 
    .wmm-dashboard tbody, 
    .wmm-dashboard th, 
    .wmm-dashboard td, 
    .wmm-dashboard tr { 
        display: block; 
    }
    
    .wmm-dashboard thead tr { 
        position: absolute;
        top: -9999px;
        left: -9999px;
    }
    
    .wmm-dashboard tr { 
        border: 1px solid #ccc; 
        margin-bottom: 15px; 
        border-radius: 4px;
        background: #fff;
        box-shadow: 0 1px 3px rgba(0,0,0,0.05);
    }
    
    .wmm-dashboard td { 
        border: none;
        border-bottom: 1px solid #eee; 
        position: relative;
        padding-left: 40%; 
        padding-top: 10px;
        padding-bottom: 10px;
    }
    
    .wmm-dashboard td:before { 
        position: absolute;
        top: 10px;
        left: 10px;
        width: 35%; 
        padding-right: 10px; 
        white-space: nowrap;
        font-weight: bold;
        color: #555;
    }

    /* Labels for mobile table */
    .wmm-dashboard td:nth-of-type(1):before { content: "Τίτλος"; }
    .wmm-dashboard td:nth-of-type(2):before { content: "Περιγραφή"; }
    .wmm-dashboard td:nth-of-type(3):before { content: "Ημ/νία ΥΑΣ"; }
    .wmm-dashboard td:nth-of-type(4):before { content: "Ενέργειες"; }

    /* Dashboard Actions on Mobile */
    .wmm-dashboard td:nth-of-type(4) {
        text-align: right;
        padding-left: 10px; /* Reset padding for actions row */
    }
    .wmm-dashboard td:nth-of-type(4):before {
        display: none; /* Hide label for actions */
    }
}
