:root {
    --primary-bg: #ffeeba;
    --primary-text: #333;
    --primary-border: #e6dbb9;
    --muted-text: #555;
    --border: #e0e0e0;
    --shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    --radius: 4px;
    --font-base: sans-serif;
}

.heatmap_data_output{
    display: none;
}

/* Shared Notice */
.notice-message,
.erm-review-notice {
    background: #f3e5f5;
    color: #6a1b9a;
    padding: 15px;
    border: 1px solid #ce93d8;
    border-radius: var(--radius);
    text-align: center;
    font-size: 16px;
    margin-bottom: 20px;
    font-weight: 600;
    font-family: var(--font-base);
}

.erm-review-notice {
    margin-top: 10px;
}

/* Leave Review Layout */
.review-task-container {
    max-width: 500px;
    margin: 0 auto;
    font-family: var(--font-base);
}

.timer-section {
    text-align: center;
    margin-bottom: 25px;
}

.timer-label {
    font-size: 12px;
    font-weight: bold;
    margin-bottom: 5px;
    color: #333;
}

.timer-display {
    display: flex;
    flex-direction: column;
    align-items: center;
    border: 1px solid #ccc;
    border-radius: 5px;
    background: #fff;
    letter-spacing: 1px;
}

.timer-display .timer-value {
    font-size: 32px;
    font-weight: 800;
    padding: 10px;
    letter-spacing: 2px;
}

.review-target-line {
    width: 100%;
    padding: 10px 0;
    font-size: 16px;
    color: #333;
    background: #f9f9f9;
    border-top: 1px solid #e0e0e0;
    font-weight: 500;
    text-align: center;
}

.review-target-line strong {
    font-weight: 700;
}

.step-card {
    background: #fff;
    border: 1px solid var(--border);
    padding: 30px 20px;
    margin-bottom: 20px;
    text-align: center;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.step-card h2 {
    font-size: 28px;
    font-weight: 800;
    margin: 0 0 5px 0;
    color: #000;
}

.step-sub {
    text-transform: uppercase;
    font-size: 14px;
    margin-bottom: 20px;
    color: #666;
}

.review-link-display {
    word-break: break-all;
    text-transform: none;
    font-size: 12px;
    color: #007bff;
    margin-bottom: 15px;
}

select,
.text-input {
    width: 100%;
    padding: 12px;
    margin-bottom: 15px;
    border: 1px solid #ccc;
    border-radius: var(--radius);
    font-size: 16px;
}

.review-content-box textarea {
    width: 100%;
    height: 120px;
    padding: 10px;
    border: 1px solid #eee;
    background: #f9f9f9;
    font-size: 14px;
    line-height: 1.5;
    resize: none;
    margin-bottom: 15px;
    color: #555;
}

.review-content-box textarea.loading {
    opacity: 0.75;
}

.input-label {
    display: block;
    text-align: left;
    font-size: 14px;
    font-weight: 600;
    margin-top: 15px;
    margin-bottom: 5px;
    color: #333;
}

.btn-copy,
.btn-primary,
.btn-secondary,
.btn-submit,
.btn-upload {
    display: inline-block;
    padding: 12px 20px;
    text-transform: uppercase;
    font-weight: 600;
    cursor: pointer;
    border: none;
    border-radius: var(--radius);
    transition: background 0.2s;
    font-size: 14px;
    text-decoration: none;
    white-space: nowrap;
    line-height: 1.5;
    box-sizing: border-box;
    vertical-align: middle;
}

.btn-copy {
    background: var(--primary-bg);
    color: #856404;
    width: 100%;
}

.btn-copy:hover {
    background: #ffe8a1;
}

.button-group {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    flex-wrap: nowrap;
    margin-bottom: 20px;
}

.button-group > * {
    flex-grow: 1;
    text-align: center;
}

.or-divider {
    font-weight: bold;
    color: #555;
    margin: 0 5px;
    font-size: 14px;
    flex-shrink: 0;
}

.btn-primary {
    background: var(--primary-bg);
    color: var(--primary-text);
    text-decoration: none;
    border: 1px solid var(--primary-border);
}

.btn-secondary {
    background: #f0f0f0;
    color: var(--primary-text);
    border: 1px solid #ccc;
}

.qr-code-container {
    text-align: center;
    padding: 15px;
    border: 1px solid #eee;
    background: #f9f9f9;
    border-radius: var(--radius);
}

.qr-label {
    font-size: 14px;
    font-weight: 600;
    color: #555;
    margin-bottom: 10px;
    text-transform: uppercase;
}

.qr-code-image {
    max-width: 150px;
    height: auto;
    border: 1px solid #ccc;
    padding: 5px;
    background: white;
}

.upload-wrapper {
    margin: 20px 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

input[type="file"] {
    display: none;
}

.btn-upload {
    background: var(--primary-bg);
    color: var(--primary-text);
    border: 1px solid var(--primary-border);
    width: 100%;
    display: block;
    text-align: center;
}

.btn-upload:hover {
    background: #ffe8a1;
}

#image-preview-container {
    margin-top: 10px;
    display: none;
    cursor: pointer;
    text-align: center;
    position: relative;
}

#image-preview {
    max-width: 300px;
    max-height: 300px;
    border: 1px solid #ccc;
    padding: 2px;
    border-radius: 4px;
    display: block; /* Ensures no extra space below image */
}

.preview-overlay-icon {
    position: absolute;
    top: -10px;
    right: -10px;
    width: 24px;
    height: 24px;
    background-color: #dc3232;
    color: white;
    border-radius: 50%;
    text-align: center;
    line-height: 24px;
    font-weight: bold;
    font-size: 14px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    cursor: pointer;
    z-index: 10;
}

.preview-overlay-icon:hover {
    background-color: #a00;
}

.btn-submit {
    background: var(--primary-bg);
    width: 100%;
    padding: 15px;
    font-size: 16px;
    letter-spacing: 1px;
    margin-top: 10px;
}

.timer-expired .timer-value {
    color: red;
}

.timer-expired {
    border-color: red;
    background: #fff0f0;
}

@media (max-width: 400px) {
    .btn-copy,
    .btn-primary,
    .btn-secondary,
    .btn-submit,
    .btn-upload {
        padding: 10px 15px;
        font-size: 12px;
    }
    .button-group {
        gap: 3px;
    }
    .or-divider {
        margin: 0 3px;
    }
}

/* List Reviews */
.erm-reviews-container {
    max-width: 800px;
    margin: 20px auto;
    padding: 10px;
    font-family: var(--font-base);
}

.erm-reviews-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 20px;
}

.erm-review-item {
    background: #fdfdfd;
    border: 1px solid #e1e1e1;
    border-radius: 8px;
    padding: 10px;
    text-align: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    transition: transform 0.2s, box-shadow 0.2s;
}

.erm-review-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.erm-review-date {
    font-size: 0.9em;
    color: #555;
    margin-bottom: 8px;
    display: block;
    font-weight: 600;
}

.erm-review-link img {
    max-width: 100%;
    height: 120px;
    width: 100%;
    object-fit: cover;
    border-radius: 4px;
    display: block;
    border: 1px solid #ddd;
}

.erm-no-image {
    height: 120px;
    background: #ecf0f1;
    border: 1px dashed #ccc;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8em;
    color: #999;
    border-radius: 4px;
}

.erm-heading {
    text-align: center;
    color: #2c3e50;
    margin-bottom: 25px;
    padding-bottom: 10px;
    border-bottom: 2px solid #3498db;
    font-family: var(--font-base);
}

/* Dashboard Heatmap */
.view-heatmap-box {
    background-color: #ffffff;
    padding: 8px;
    border-radius: var(--radius);
    position: relative;
    font-family: var(--font-base);
}

.recent-titlte {
    font-size: 16px;
    font-weight: 600;
    padding-bottom: 4px;
    margin: 0;
}

.title-view {
    display: flex;
    justify-content: space-between;
}

.view-screenshots {
    text-decoration: underline;
    font-size: 12px;
    font-weight: 600;
    padding: 0;
    margin: 0;
}

#cal-heatmap {
    display: block;
    width: 100%;
    max-width: 100%;
}

.view-heatmap-box-inner {
    width: 100%;
    display: flex;
    justify-content: center;
}

/* Dashboard summary */
.dashboard-section {
    max-width: 900px;
    margin: 0 auto 12px auto;
    font-family: var(--font-base);
}

.metric-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 12px;
    margin-bottom: 12px;
}

.metric-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 18px 16px;
    box-shadow: var(--shadow);
    text-align: center;
}

.metric-primary {
    background: #fffdfa;
    border-color: var(--primary-border);
}

.metric-label {
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--muted-text);
    margin: 0 0 8px 0;
    font-weight: 700;
}

.metric-value {
    font-size: 32px;
    font-weight: 800;
    margin: 0;
    color: var(--primary-text);
}

@media (max-width: 600px) {
    .metric-grid {
        grid-template-columns: 1fr;
    }
    .metric-card {
        display: flex;
        align-items: center;
        justify-content: space-between;
        text-align: left;
        padding: 15px;
    }
    .metric-label {
        margin: 0;
        text-align: left;
    }
    .metric-value {
        margin-left: 10px;
    }
}

.heatmap-card {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 12px;
}

/* Review Acknowledgement */
.review-acknowledgement {
    max-width: 500px;
    margin: 30px auto;
    padding: 40px 20px;
    text-align: center;
    border-radius: 8px;
    font-family: var(--font-base);
}

.review-acknowledgement.success {
    background-color: #e6ffe6;
    border: 2px solid #00c000;
    color: #008000;
}

.review-acknowledgement.failure {
    background-color: #ffe6e6;
    border: 2px solid #c00000;
    color: #c00000;
}

.review-acknowledgement h2 {
    margin-top: 0;
    font-size: 2em;
}

.review-acknowledgement p {
    font-size: 1.1em;
    margin-bottom: 30px;
}

.review-acknowledgement .button-group {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}
