/* ==========================================================================
   Natalis Connect – Public Styles
   Namespaced to .natalis-* to prevent theme bleeding.
   ========================================================================== */

/* --- Base / Reset --- */
.natalis-wrap {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, sans-serif;
    color: #2d3436;
    line-height: 1.6;
    box-sizing: border-box;
}

.natalis-wrap *, .natalis-wrap *::before, .natalis-wrap *::after {
    box-sizing: inherit;
}

/* --- Buttons --- */
.natalis-btn {
    display: inline-block;
    padding: 10px 24px;
    border-radius: 6px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    border: 2px solid transparent;
    transition: all 0.2s ease;
    text-align: center;
}

.natalis-btn-primary {
    background: #6c5ce7;
    color: #fff;
    border-color: #6c5ce7;
}

.natalis-btn-primary:hover {
    background: #5a4bd1;
    border-color: #5a4bd1;
    color: #fff;
}

.natalis-btn-outline {
    background: transparent;
    color: #6c5ce7;
    border-color: #6c5ce7;
}

.natalis-btn-outline:hover {
    background: #6c5ce7;
    color: #fff;
}

.natalis-btn-danger {
    background: #d63031;
    color: #fff;
    border-color: #d63031;
}

.natalis-btn-danger:hover {
    background: #c0392b;
    border-color: #c0392b;
}

.natalis-btn-sm {
    padding: 6px 16px;
    font-size: 13px;
}

.natalis-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* --- Cards --- */
.natalis-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    overflow: hidden;
    transition: box-shadow 0.2s ease;
}

.natalis-card:hover {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.natalis-card-featured {
    border-color: #6c5ce7;
    position: relative;
}

.natalis-card-badge {
    position: absolute;
    top: 0;
    right: 20px;
    background: #6c5ce7;
    color: #fff;
    padding: 4px 12px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    border-radius: 0 0 6px 6px;
}

.natalis-card-header {
    padding: 24px 24px 16px;
}

.natalis-card-header h3 {
    margin: 0 0 8px;
    font-size: 20px;
    color: #2d3436;
}

.natalis-card-price {
    font-size: 36px;
    font-weight: 700;
    color: #6c5ce7;
}

.natalis-card-price small {
    font-size: 14px;
    font-weight: 400;
    color: #636e72;
}

.natalis-card-features {
    list-style: none;
    margin: 0;
    padding: 0 24px 16px;
}

.natalis-card-features li {
    padding: 6px 0;
    border-bottom: 1px solid #f5f5f5;
    font-size: 14px;
    color: #636e72;
}

.natalis-card-features li::before {
    content: "\2713";
    color: #00b894;
    font-weight: 700;
    margin-right: 8px;
}

.natalis-card-features li:last-child {
    border-bottom: none;
}

.natalis-card-action {
    padding: 16px 24px 24px;
    text-align: center;
}

/* --- Pricing Layout --- */
.natalis-pricing-title {
    text-align: center;
    font-size: 28px;
    margin-bottom: 32px;
    color: #2d3436;
}

.natalis-pricing-grid .natalis-pricing-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px;
    max-width: 900px;
    margin: 0 auto;
}

/* --- Login Prompt --- */
.natalis-login-prompt {
    text-align: center;
    padding: 60px 20px;
}

.natalis-login-prompt p {
    font-size: 18px;
    color: #636e72;
    margin-bottom: 20px;
}

/* --- Dashboard States --- */
.natalis-dashboard {
    max-width: 700px;
    margin: 0 auto;
    padding: 20px 0;
}

.natalis-state-header {
    text-align: center;
    margin-bottom: 32px;
}

.natalis-state-header h2 {
    font-size: 24px;
    margin-bottom: 8px;
}

.natalis-state-header p {
    color: #636e72;
    font-size: 15px;
}

/* Match card */
.natalis-match-card {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
}

.natalis-match-card .natalis-match-type {
    display: inline-block;
    background: #dfe6e9;
    padding: 2px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    color: #636e72;
    margin-bottom: 12px;
}

.natalis-match-card .natalis-match-type-twin {
    background: #ffeaa7;
    color: #d35400;
}

.natalis-match-card .natalis-match-type-month {
    background: #81ecec;
    color: #00897b;
}

.natalis-match-info {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
}

.natalis-match-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: #dfe6e9;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: #6c5ce7;
    font-weight: 700;
    flex-shrink: 0;
}

.natalis-match-details h3 {
    margin: 0 0 4px;
    font-size: 18px;
}

.natalis-match-details p {
    margin: 0;
    color: #636e72;
    font-size: 14px;
}

.natalis-match-actions {
    display: flex;
    gap: 12px;
    margin-top: 16px;
}

/* Countdown */
.natalis-countdown {
    text-align: center;
    padding: 12px;
    background: #ffeaa7;
    border-radius: 8px;
    margin-bottom: 16px;
    font-size: 14px;
    font-weight: 600;
    color: #d35400;
}

/* --- Video Room --- */
.natalis-video-wrap {
    position: relative;
    width: 100%;
    border-radius: 12px;
    overflow: hidden;
    background: #000;
    margin-bottom: 24px;
}

.natalis-video-wrap iframe {
    width: 100%;
    height: 500px;
    border: none;
}

.natalis-icebreakers {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 16px 20px;
    margin-bottom: 24px;
}

.natalis-icebreakers h4 {
    margin: 0 0 12px;
    font-size: 15px;
    color: #6c5ce7;
}

.natalis-icebreakers ol {
    margin: 0;
    padding-left: 20px;
}

.natalis-icebreakers li {
    margin-bottom: 8px;
    font-size: 14px;
    color: #636e72;
}

/* Report button */
.natalis-report-wrap {
    text-align: center;
    margin-top: 16px;
}

/* --- Profile Form --- */
.natalis-profile-form {
    max-width: 500px;
    margin: 0 auto;
}

.natalis-field {
    margin-bottom: 20px;
}

.natalis-field label {
    display: block;
    font-weight: 600;
    margin-bottom: 6px;
    font-size: 14px;
}

.natalis-field input,
.natalis-field select,
.natalis-field textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #dfe6e9;
    border-radius: 6px;
    font-size: 15px;
    transition: border-color 0.2s;
}

.natalis-field input:focus,
.natalis-field select:focus,
.natalis-field textarea:focus {
    border-color: #6c5ce7;
    outline: none;
    box-shadow: 0 0 0 3px rgba(108, 92, 231, 0.1);
}

.natalis-field textarea {
    min-height: 100px;
    resize: vertical;
}

.natalis-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
}

.natalis-toggle input[type="checkbox"] {
    width: auto;
}

/* --- Status badges --- */
.natalis-status {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
}

.natalis-status-pending { background: #ffeaa7; color: #d35400; }
.natalis-status-accepted { background: #55efc4; color: #00695c; }
.natalis-status-completed { background: #dfe6e9; color: #636e72; }
.natalis-status-expired { background: #fab1a0; color: #c0392b; }
.natalis-status-reported { background: #ff7675; color: #fff; }
.natalis-status-open { background: #ff7675; color: #fff; }
.natalis-status-resolved { background: #55efc4; color: #00695c; }

/* --- Spinner --- */
.natalis-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #dfe6e9;
    border-top-color: #6c5ce7;
    border-radius: 50%;
    animation: natalisSpin 0.6s linear infinite;
}

@keyframes natalisSpin {
    to { transform: rotate(360deg); }
}

@media (prefers-reduced-motion: reduce) {
    .natalis-spinner {
        animation: none;
        border-top-color: #6c5ce7;
        opacity: 0.7;
    }
}

/* --- Screen reader only --- */
.natalis-sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* --- Toast notification --- */
.natalis-toast {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    background: #2d3436;
    color: #fff;
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    animation: natalisSlideIn 0.3s ease;
    max-width: 360px;
}

.natalis-toast-error {
    background: #d63031;
}

@keyframes natalisSlideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

/* --- Focus styles (accessibility) --- */
.natalis-btn:focus-visible,
.natalis-field input:focus-visible,
.natalis-field select:focus-visible,
.natalis-field textarea:focus-visible {
    outline: 3px solid #6c5ce7;
    outline-offset: 2px;
}

/* --- Auth Forms --- */
.natalis-auth-wrap {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 40px 20px;
}

.natalis-auth-form {
    width: 100%;
    max-width: 420px;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 32px;
}

.natalis-auth-header {
    text-align: center;
    margin-bottom: 24px;
}

.natalis-auth-header h2 {
    font-size: 24px;
    margin: 0 0 6px;
    color: #2d3436;
}

.natalis-auth-header p {
    color: #636e72;
    font-size: 14px;
    margin: 0;
}

.natalis-auth-error {
    background: #ffeaea;
    color: #d63031;
    padding: 10px 14px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 16px;
}

.natalis-auth-success {
    background: #e6fff5;
    color: #00695c;
    padding: 10px 14px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 16px;
}

.natalis-auth-divider {
    display: flex;
    align-items: center;
    margin: 20px 0;
}

.natalis-auth-divider::before,
.natalis-auth-divider::after {
    content: "";
    flex: 1;
    border-bottom: 1px solid #e0e0e0;
}

.natalis-auth-divider span {
    padding: 0 12px;
    color: #b2bec3;
    font-size: 13px;
    text-transform: uppercase;
    font-weight: 600;
}

.natalis-auth-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.natalis-btn-full {
    width: 100%;
    margin-top: 8px;
}

.natalis-auth-links {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    margin-top: 20px;
}

.natalis-auth-links a {
    color: #6c5ce7;
    font-size: 14px;
    text-decoration: none;
    font-weight: 500;
}

.natalis-auth-links a:hover {
    text-decoration: underline;
}

.natalis-field-hint {
    display: block;
    font-size: 12px;
    color: #b2bec3;
    margin-top: 4px;
}

.natalis-google-btn-wrap {
    display: flex;
    justify-content: center;
}

.natalis-google-btn-wrap > div {
    width: 100%;
}

/* --- Responsive --- */
@media (max-width: 600px) {
    .natalis-pricing-cards {
        grid-template-columns: 1fr !important;
    }

    .natalis-match-actions {
        flex-direction: column;
    }

    .natalis-btn {
        min-height: 44px;
        min-width: 44px;
    }

    .natalis-video-wrap iframe,
    .natalis-video-wrap > div {
        height: 56vw;
        min-height: 260px;
    }

    .natalis-auth-form {
        padding: 24px 18px;
    }

    .natalis-auth-row {
        grid-template-columns: 1fr;
    }

    .natalis-auth-wrap {
        padding: 20px 12px;
    }
}
