/* ============================================
   PERFIL (PUBLIC PROFILE) - MODERN STYLES
   Public user profile page - Read-only
   ============================================ */

:root {
    --primary-color: #2061a8;
    --primary-hover: #1a4f8a;
    --border-radius: 8px;
    --transition-speed: 0.3s;
    --box-shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.1);
    --box-shadow-md: 0 4px 16px rgba(0, 0, 0, 0.15);
    --box-shadow-hover: 0 8px 24px rgba(0, 0, 0, 0.2);
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 1.5rem;
    --spacing-lg: 2rem;
}

/* ============================================
   PROFILE HEADER
   ============================================ */
.profile-header {
    text-align: center;
    margin-bottom: var(--spacing-lg);
}

.profile-title {
    padding-bottom: 0.75rem;
    border-bottom: 3px solid var(--primary-color);
    position: relative;
    display: inline-block;
}

.profile-title::after {
    content: '';
    position: absolute;
    bottom: -3px;
    left: 0;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-hover));
    transition: width var(--transition-speed) ease;
}

.profile-title:hover::after {
    width: 100%;
}

.profile-link {
    color: #333;
    text-decoration: none;
    transition: color var(--transition-speed) ease;
}

.profile-link:hover {
    color: var(--primary-color);
    text-decoration: none;
}

/* ============================================
   INFO CARD (READ-ONLY)
   ============================================ */
.info-card {
    background: white;
    padding: var(--spacing-md);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow-sm);
    margin-bottom: var(--spacing-md);
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: var(--spacing-md);
    text-align: center;
}

.info-column {
    padding: var(--spacing-sm);
}

.info-label {
    font-weight: 600;
    color: #555;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
}

.info-value {
    color: #333;
    font-size: 1rem;
}

/* ============================================
   TABS
   ============================================ */
.tabs-container {
    background: white;
    padding: var(--spacing-lg);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow-sm);
    margin-bottom: var(--spacing-lg);
}

.tabs-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    border-bottom: 2px solid #e9ecef;
    margin-bottom: var(--spacing-lg);
}

.tab-button {
    padding: 0.75rem 1.5rem;
    background: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    font-weight: 600;
    text-transform: uppercase;
    cursor: pointer;
    transition: all var(--transition-speed) ease;
    color: #666;
    font-size: 0.875rem;
}

.tab-button:hover {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

.tab-button.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* ============================================
   ITEMS GRID (READ-ONLY)
   ============================================ */
.items-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: var(--spacing-md);
}

.item-card {
    background: white;
    padding: var(--spacing-sm);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow-sm);
    text-align: center;
    transition: all var(--transition-speed) ease;
}

.item-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--box-shadow-md);
}

.item-image-container {
    position: relative;
    width: 150px;
    height: 75px;
    margin: 0 auto var(--spacing-sm);
    overflow: hidden;
    border-radius: calc(var(--border-radius) - 2px);
}

.item-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-speed) ease;
}

.item-card:hover .item-image {
    transform: scale(1.1);
}

.item-link {
    color: #333;
    text-decoration: none;
    font-size: 0.875rem;
    display: block;
}

.item-link:hover {
    color: var(--primary-color);
    text-decoration: none;
}

/* ============================================
   FORUM ITEMS
   ============================================ */
.forum-list {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.forum-item {
    padding: var(--spacing-sm);
    border: 1px dotted #e9ecef;
    border-radius: var(--border-radius);
    transition: all var(--transition-speed) ease;
}

.forum-item:hover {
    background: #f8f9fa;
    border-style: solid;
}

.forum-link {
    color: #333;
    text-decoration: none;
    font-weight: 600;
    transition: color var(--transition-speed) ease;
}

.forum-link:hover {
    color: var(--primary-color);
    text-decoration: none;
}

.forum-preview {
    color: #666;
    font-size: 0.875rem;
    margin-top: 0.5rem;
    line-height: 1.6;
}

/* ============================================
   IMPORTANT MESSAGE
   ============================================ */
.important-message {
    background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
    border-left: 4px solid #ffc107;
    padding: var(--spacing-md);
    border-radius: var(--border-radius);
    margin-bottom: var(--spacing-md);
    line-height: 1.8;
}

.important-message strong {
    color: #856404;
    font-weight: 700;
}

/* ============================================
   LAYOUT
   ============================================ */
.profile-layout {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: var(--spacing-md);
}

.profile-sidebar {
    position: sticky;
    top: var(--spacing-md);
    height: fit-content;
}

.profile-main {
    min-width: 0; /* Fix grid overflow */
}

@media (max-width: 768px) {
    .profile-layout {
        grid-template-columns: 1fr;
    }

    .profile-sidebar {
        position: static;
    }

    .items-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    }

    .tabs-nav {
        flex-direction: column;
    }

    .tab-button {
        width: 100%;
        text-align: center;
    }
}

/* ============================================
   ACCESSIBILITY
   ============================================ */
.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;
}

*:focus-visible {
    outline: 3px solid var(--primary-color);
    outline-offset: 2px;
}

/* ============================================
   PERFORMANCE
   ============================================ */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
