/* styles.css */

/* Basic reset */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body.lp-body {
    font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    min-height: 100vh;
    color: #f7fafc;
    background: radial-gradient(circle at top, #1f2933 0, #050816 50%, #02010a 100%);
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Low-poly background shapes */
.lp-background {
    position: fixed;
    inset: 0;
    overflow: hidden;
    z-index: -1;
}

.lp-polygon {
    position: absolute;
    filter: blur(0.5px);
    opacity: 0.45;
    clip-path: polygon(0% 50%, 20% 0%, 60% 0%, 100% 40%, 80% 100%, 30% 100%);
    background: linear-gradient(135deg, #36cfc9, #4f46e5);
}

.poly-1 {
    width: 420px;
    height: 420px;
    top: -80px;
    left: -120px;
}

.poly-2 {
    width: 480px;
    height: 480px;
    bottom: -150px;
    right: -200px;
    background: linear-gradient(135deg, #ec4899, #8b5cf6);
}

.poly-3 {
    width: 320px;
    height: 320px;
    top: 40%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: linear-gradient(135deg, #22c55e, #0ea5e9);
    opacity: 0.25;
}

/* Layout */
.lp-container {
    width: 100%;
    max-width: 1000px;
    padding: 24px;
}

.lp-header {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.lp-header-profile {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
}

.lp-logo {
    font-size: 2.1rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #e5e7eb;
}

.lp-logo span {
    background: linear-gradient(135deg, #22c55e, #0ea5e9);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.lp-subtitle {
    color: #9ca3af;
    font-size: 0.95rem;
}

/* Alerts */
.lp-alert {
    margin-bottom: 1rem;
    padding: 0.75rem 1rem;
    border-radius: 0.75rem;
    font-size: 0.9rem;
}

.lp-alert-error {
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.5);
}

.lp-alert-success {
    background: rgba(34, 197, 94, 0.15);
    border: 1px solid rgba(34, 197, 94, 0.5);
}

/* Cards */
.lp-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.5rem;
}

.lp-card {
    background: rgba(15, 23, 42, 0.92);
    border-radius: 1.2rem;
    padding: 1.4rem 1.6rem;
    border: 1px solid rgba(148, 163, 184, 0.25);
    box-shadow:
        0 18px 40px rgba(15, 23, 42, 0.85),
        0 0 0 1px rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(12px);
}

.lp-card h2 {
    font-size: 1.1rem;
    margin-bottom: 1rem;
}

.lp-card-highlight {
    border-image: linear-gradient(135deg, #22c55e, #0ea5e9) 1;
}

/* Forms */
label {
    display: block;
    font-size: 0.82rem;
    color: #cbd5f5;
    margin-bottom: 0.6rem;
}

input,
textarea {
    margin-top: 0.25rem;
    width: 100%;
    padding: 0.55rem 0.65rem;
    border-radius: 0.6rem;
    border: 1px solid rgba(148, 163, 184, 0.7);
    background: rgba(15, 23, 42, 0.9);
    color: #e5e7eb;
    font-size: 0.9rem;
}

input:focus,
textarea:focus {
    outline: none;
    border-color: #22c55e;
    box-shadow: 0 0 0 1px rgba(34, 197, 94, 0.6);
}

/* Buttons */
.lp-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-top: 0.6rem;
    padding: 0.5rem 1.2rem;
    border-radius: 999px;
    border: none;
    background: linear-gradient(135deg, #22c55e, #0ea5e9);
    color: #0f172a;
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    cursor: pointer;
    transition: transform 0.08s ease, box-shadow 0.08s ease, filter 0.08s ease;
    box-shadow: 0 10px 25px rgba(15, 23, 42, 0.9);
}

.lp-btn:hover {
    transform: translateY(-1px) scale(1.01);
    filter: brightness(1.06);
}

.lp-btn:active {
    transform: translateY(1px) scale(0.99);
    box-shadow: 0 4px 10px rgba(15, 23, 42, 0.9);
}

.lp-btn-outline {
    background: transparent;
    color: #e5e7eb;
    border: 1px solid rgba(148, 163, 184, 0.75);
    box-shadow: 0 10px 25px rgba(15, 23, 42, 0.8);
}

.lp-btn-small {
    padding: 0.35rem 0.9rem;
    font-size: 0.8rem;
}

/* Bio text */
.lp-bio {
    margin-top: 0.3rem;
    font-size: 0.9rem;
    color: #e5e7eb;
    white-space: pre-line;
}

/* Profile header (avatar + banner) */
.lp-profile-header-card {
    padding: 0;
    overflow: hidden;
}

.lp-profile-banner {
    position: relative;
    width: 100%;
    height: 160px;
    background: radial-gradient(circle at top left, rgba(34, 197, 94, 0.4), rgba(15, 23, 42, 1));
    background-size: cover;
    background-position: center;
}

.lp-profile-banner-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(15, 23, 42, 0.1), rgba(15, 23, 42, 0.9));
}

.lp-profile-header-content {
    display: flex;
    gap: 1.2rem;
    padding: 1.2rem 1.4rem 1.4rem;
    align-items: flex-end;
    margin-top: -60px;
}

.lp-profile-avatar-wrap {
    flex-shrink: 0;
}

.lp-profile-avatar {
    width: 96px;
    height: 96px;
    border-radius: 999px;
    border: 3px solid rgba(15, 23, 42, 0.95);
    background-size: cover;
    background-position: center;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 2rem;
    color: #e5e7eb;
    background-color: rgba(15, 23, 42, 0.95);
}

.lp-profile-avatar-placeholder {
    background: radial-gradient(circle at top, #22c55e, #0ea5e9);
}

.lp-profile-text h2 {
    font-size: 1.3rem;
    margin-bottom: 0.1rem;
}

.lp-profile-title {
    font-size: 0.9rem;
    color: #9ca3af;
    margin-bottom: 0.4rem;
}

.lp-profile-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.3rem 0.7rem;
    font-size: 0.75rem;
    color: #9ca3af;
    margin-bottom: 0.4rem;
}

.lp-profile-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem 0.8rem;
    font-size: 0.8rem;
}

.lp-profile-links a,
.lp-profile-links span {
    text-decoration: none;
    color: #e5e7eb;
    padding: 0.15rem 0.55rem;
    border-radius: 999px;
    border: 1px solid rgba(148, 163, 184, 0.5);
    font-size: 0.78rem;
}

/* Field groups in edit form */
.lp-field-group {
    margin-bottom: 1rem;
    padding-bottom: 0.8rem;
    border-bottom: 1px dashed rgba(148, 163, 184, 0.3);
}

.lp-field-group:last-of-type {
    border-bottom: none;
    padding-bottom: 0;
}

.lp-field-group h3 {
    font-size: 0.85rem;
    font-weight: 600;
    color: #e5e7eb;
    margin-bottom: 0.5rem;
}

.lp-checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.82rem;
    color: #cbd5f5;
    margin-bottom: 0.5rem;
}

.lp-checkbox-label input[type="checkbox"] {
    width: 16px;
    height: 16px;
}




/* Message board */
.lp-card-message-board {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.lp-chat-messages {
    flex: 1;
    min-height: 260px;
    max-height: 420px;
    overflow-y: auto;
    padding: 0.6rem;
    margin-bottom: 0.8rem;
    background: radial-gradient(circle at top left, rgba(15, 23, 42, 0.9), rgba(15, 23, 42, 0.98));
    border-radius: 0.9rem;
    border: 1px solid rgba(148, 163, 184, 0.25);
}

.lp-chat-message {
    padding: 0.4rem 0.5rem;
    margin-bottom: 0.35rem;
    border-radius: 0.6rem;
    background: rgba(15, 23, 42, 0.95);
    border: 1px solid rgba(148, 163, 184, 0.2);
}

.lp-chat-meta {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    margin-bottom: 0.15rem;
    font-size: 0.75rem;
    color: #9ca3af;
}

.lp-chat-user {
    font-weight: 600;
    color: #e5e7eb;
}

.lp-chat-time {
    font-size: 0.7rem;
    opacity: 0.8;
}

.lp-chat-text {
    font-size: 0.88rem;
    color: #e5e7eb;
    word-wrap: break-word;
    white-space: pre-wrap;
}

/* Chat form */
.lp-chat-form {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.lp-chat-form textarea {
    resize: vertical;
}

.lp-chat-form .lp-btn {
    align-self: flex-end;
}

/* Notes list */
.lp-chat-notes {
    list-style: disc;
    padding-left: 1.2rem;
    font-size: 0.85rem;
    color: #d1d5db;
}

.lp-chat-notes li {
    margin-bottom: 0.25rem;
}

@media (max-width: 800px) {
    .lp-card-message-board {
        order: -1;
    }
}


@media (max-width: 700px) {
    .lp-profile-header-content {
        flex-direction: column;
        align-items: flex-start;
        margin-top: -50px;
    }

    .lp-profile-avatar {
        width: 80px;
        height: 80px;
    }
}


/* Responsive */
@media (max-width: 800px) {
    .lp-grid {
        grid-template-columns: 1fr;
    }

    .lp-header-profile {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
    }
}

@media (max-width: 500px) {
    .lp-container {
        padding: 16px;
    }
    
    .lp-logo {
        font-size: 1.7rem;
    }
}
