/* ============================================================
   SECRO EHITUSPORTAAL - PÕHISTIILID & KUJUNDUS
============================================================ */

:root {
    --secro-primary: #0284c7;
    --secro-primary-hover: #0369a1;
    --secro-success: #16a34a;
    --secro-bg-light: #f8fafc;
    --secro-border: #e2e8f0;
    --secro-text-main: #0f172a;
    --secro-text-muted: #64748b;
    --secro-radius: 8px;
}

/* --- KUULUTUSE LISEMISE VORM --- */
.secro-form-container {
    max-width: 820px;
    margin: 2.5rem auto;
    background: #ffffff;
    padding: 2.5rem;
    border: 1px solid var(--secro-border);
    border-radius: 12px;
    box-shadow: 0 4px 20px -2px rgba(0, 0, 0, 0.05);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: var(--secro-text-main);
}

.secro-form-section {
    margin-bottom: 2.5rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--secro-border);
}

.secro-form-section:last-of-type {
    border-bottom: none;
    padding-bottom: 0;
}

.secro-form-section h3 {
    margin: 0 0 1.5rem 0;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--secro-text-main);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Sisendväljad ja sildid */
.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.45rem;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--secro-text-main);
}

.input-field {
    width: 100%;
    padding: 0.75rem 1rem;
    font-size: 0.95rem;
    border: 1.5px solid var(--secro-border);
    border-radius: var(--secro-radius);
    background-color: #fff;
    color: var(--secro-text-main);
    box-sizing: border-box;
    transition: all 0.2s ease;
    outline: none;
    font-family: inherit;
}

.input-field:focus {
    border-color: var(--secro-primary);
    box-shadow: 0 0 0 4px rgba(2, 132, 199, 0.12);
}

select.input-field {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2364748b'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1.2rem;
    padding-right: 2.5rem;
}

textarea.input-field {
    resize: vertical;
    line-height: 1.6;
}

/* Interaktiivsed nupukestena valikud (Pill Checkboxes) */
.secro-checkbox-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    gap: 0.6rem;
    margin-top: 0.5rem;
}

.secro-checkbox-grid label {
    display: flex;
    align-items: center;
    padding: 0.6rem 0.8rem;
    background: var(--secro-bg-light);
    border: 1px solid var(--secro-border);
    border-radius: var(--secro-radius);
    cursor: pointer;
    font-size: 0.88rem;
    font-weight: 500;
    transition: all 0.15s ease;
    user-select: none;
}

.secro-checkbox-grid label:hover {
    background: #e2e8f0;
}

.secro-checkbox-grid input[type="checkbox"] {
    margin-right: 0.55rem;
    width: 16px;
    height: 16px;
    accent-color: var(--secro-primary);
}

/* Nupud */
.secro-btn {
    display: inline-block;
    width: 100%;
    padding: 0.85rem 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: var(--secro-radius);
    border: none;
    cursor: pointer;
    text-align: center;
    box-sizing: border-box;
    text-decoration: none;
    transition: background-color 0.2s ease, transform 0.1s ease;
}

.secro-btn-submit {
    background-color: var(--secro-primary);
    color: #ffffff;
}

.secro-btn-submit:hover {
    background-color: var(--secro-primary-hover);
}

.secro-btn-submit:active {
    transform: scale(0.99);
}

/* Teated */
.secro-alert {
    padding: 1.25rem;
    border-radius: var(--secro-radius);
    margin-bottom: 2rem;
    font-size: 0.95rem;
    line-height: 1.5;
}

.secro-alert h3 {
    margin: 0 0 0.5rem 0;
    font-size: 1.15rem;
}

.secro-alert-success {
    background: #f0fdf4;
    color: #166534;
    border: 1px solid #bbf7d0;
}

.secro-alert-error {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

/* --- VISIITKAARDI VAATE STIILID --- */
.secro-profile-container {
    max-width: 1140px;
    margin: 2.5rem auto;
    padding: 0 1rem 5rem 1rem;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: var(--secro-text-main);
}

.secro-profile-header {
    display: flex;
    gap: 1.5rem;
    align-items: center;
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--secro-border);
    padding-bottom: 1.5rem;
}

.secro-avatar img, .secro-avatar-placeholder {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    object-fit: cover;
    background: var(--secro-primary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    font-weight: 700;
}

.secro-verified-badge {
    color: var(--secro-success);
    font-size: 1.2rem;
}

.secro-tags .badge {
    display: inline-block;
    padding: 0.3rem 0.65rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
    margin-right: 0.4rem;
}

.badge-cat { background: #e0f2fe; color: #0369a1; }
.badge-reg { background: #f1f5f9; color: #475569; }

.secro-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
}

.secro-card {
    background: #fff;
    border: 1px solid var(--secro-border);
    border-radius: 12px;
    padding: 1.75rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.03);
}

.secro-btn-phone {
    background-color: var(--secro-success);
    color: #ffffff;
}

.secro-btn-phone:hover {
    background-color: #15803d;
}

.secro-mobile-bar { display: none; }

@media (max-width: 768px) {
    .secro-form-container {
        padding: 1.5rem;
        margin: 1rem auto;
    }
    .secro-grid { grid-template-columns: 1fr; }
    .secro-mobile-bar {
        display: flex;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        background: #fff;
        padding: 0.75rem 1rem;
        box-shadow: 0 -4px 15px rgba(0,0,0,0.08);
        gap: 0.75rem;
        z-index: 9999;
    }
    .mobile-btn { width: 50%; padding: 0.7rem 0.5rem; }
}
/* Peidab teema vaikimisi lehepealkirja ehitaja profiilil */
.single-builder_profile h1.wp-block-post-title,
.single-builder_profile .entry-title,
.single-builder_profile .post-title {
    display: none !important;
}

.secro-meta-list {
    list-style: none;
    padding: 0;
    margin: 0 0 1.25rem 0;
}

.secro-meta-list li {
    padding: 0.4rem 0;
    border-bottom: 1px solid var(--secro-border);
    font-size: 0.95rem;
}

.secro-meta-list li:last-child {
    border-bottom: none;
}
/* --- TEHTUD TÖÖDE GALERII --- */
.secro-portfolio-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.secro-gallery-item {
    display: block;
    border-radius: 8px;
    overflow: hidden;
    aspect-ratio: 4 / 3;
    border: 1px solid var(--secro-border);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.secro-gallery-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(0,0,0,0.1);
}

.secro-gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* --- ARVUSTUSTE SÜSTEEM --- */
.secro-header-rating {
    margin: 0.4rem 0 0.8rem 0;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.secro-stars-display {
    color: #eab308;
    font-weight: 700;
}

.secro-rating-count {
    color: var(--secro-text-muted);
}

.secro-reviews-list {
    margin-bottom: 2rem;
}

.secro-review-item {
    border-bottom: 1px solid var(--secro-border);
    padding: 1rem 0;
}

.secro-review-item:last-child {
    border-bottom: none;
}

.secro-review-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.4rem;
}

.secro-stars-gold {
    color: #eab308;
    letter-spacing: 2px;
}

.secro-review-date {
    font-size: 0.8rem;
    color: var(--secro-text-muted);
}

.secro-review-text {
    margin: 0;
    color: var(--secro-text-main);
    line-height: 1.5;
}

.secro-add-review-box {
    background: var(--secro-bg-light);
    border: 1px solid var(--secro-border);
    border-radius: 8px;
    padding: 1.5rem;
    margin-top: 1.5rem;
}

.secro-add-review-box h3 {
    margin-top: 0;
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

/* Interaktiivne tärnide valik (Star Rating Radio Buttons) */
.secro-star-rating {
    display: inline-flex;
    flex-direction: row-reverse;
    font-size: 1.75rem;
}

.secro-star-rating input {
    display: none;
}

.secro-star-rating label {
    color: #cbd5e1;
    cursor: pointer;
    padding: 0 0.15rem;
    transition: color 0.15s ease;
}

.secro-star-rating label:hover,
.secro-star-rating label:hover ~ label,
.secro-star-rating input:checked ~ label {
    color: #eab308;
}
/* Keelevahetaja päises */
.secro-title-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.secro-lang-switch {
    display: inline-flex;
    background: #f1f5f9;
    padding: 3px;
    border-radius: 6px;
    border: 1px solid var(--secro-border);
}

.secro-lang-switch a {
    padding: 4px 10px;
    font-size: 0.8rem;
    font-weight: 700;
    color: #64748b;
    text-decoration: none;
    border-radius: 4px;
    transition: all 0.15s ease;
}

.secro-lang-switch a:hover {
    color: var(--secro-primary);
}

.secro-lang-switch a.active {
    background: #ffffff;
    color: var(--secro-primary);
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}