/* ========================================
   GLOBAL STYLES
   ======================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: #f9f9f9;
    color: #1a1a1a;
}

html, body {
    height: 100%;
    margin: 0;
    padding: 0;
}

/* ========================================
   LOGIN & SIGNUP PAGE STYLES
   ======================================== */
body.login-page,
body.signup-page {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    padding: 20px;
    background-color: #f9f9f9;
}

.auth-container {
    background: white;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    padding: 48px 40px;
    width: 100%;
    max-width: 420px;
    margin: auto;
}

.brand {
    text-align: center;
    margin-bottom: 32px;
}

.brand h1 {
    font-size: 28px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 8px;
}

.brand p {
    color: #666;
    font-size: 14px;
}

.heading {
    text-align: center;
    margin-bottom: 8px;
}

.heading h2 {
    font-size: 28px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 8px;
}

.heading p {
    color: #666;
    font-size: 14px;
    margin-bottom: 32px;
}

.form-group {
    margin-bottom: 20px;
}

.input-wrapper {
    position: relative;
}

.input-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #999;
    font-size: 18px;
}

.form-control {
    width: 100%;
    padding: 14px 16px 14px 48px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.3s ease;
    background-color: #f9f9f9;
}

.form-control:focus {
    outline: none;
    border-color: #1a1a1a;
    background-color: white;
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.05);
}

.btn {
    width: 100%;
    padding: 14px;
    background-color: #1a1a1a;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 8px;
}

.btn:hover {
    background-color: #333;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.btn:active {
    transform: translateY(0);
}

.footer {
    text-align: center;
    margin-top: 24px;
    color: #666;
    font-size: 14px;
}

.footer a {
    color: #1a1a1a;
    text-decoration: none;
    font-weight: 600;
    margin-left: 4px;
}

.footer a:hover {
    text-decoration: underline;
}

.arrow {
    font-size: 18px;
    transition: transform 0.3s ease;
}

.btn:hover .arrow {
    transform: translateX(4px);
}

/* ========================================
   DASHBOARD STYLES
   ======================================== */

.dashboard-layout {
    display: flex;
    min-height: 100vh;
    background: #f8f9fa;
}

/* Sidebar */
.sidebar {
    width: 260px;
    background: white;
    border-right: 1px solid #e5e7eb;
    display: flex;
    flex-direction: column;
    position: fixed;
    height: 100vh;
    left: 0;
    top: 0;
    z-index: 100;
    flex-shrink: 0;
}

.sidebar-header {
    padding: 24px 20px;
    border-bottom: 1px solid #e5e7eb;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-icon {
    width: 36px;
    height: 36px;
    background: #1a1a1a;
    color: white;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 18px;
}

.logo-text {
    font-size: 20px;
    font-weight: 700;
    color: #1a1a1a;
}

.sidebar-nav {
    flex: 1;
    padding: 20px 12px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    overflow-y: auto;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: #6b7280;
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.2s;
    font-size: 14px;
    font-weight: 500;
}

.nav-item:hover {
    background: #f3f4f6;
    color: #1a1a1a;
}

.nav-item.active {
    background: #1a1a1a;
    color: white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.nav-item i {
    font-size: 18px;
    width: 20px;
    text-align: center;
}

.sidebar-footer {
    padding: 12px;
    border-top: 1px solid #e5e7eb;
    margin-top: auto;
}

/* Main Content - Full Width */
.main-content {
    flex: 1;
    margin-left: 260px;
    width: calc(100% - 260px);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Top Header */
.top-header {
    background: white;
    border-bottom: 1px solid #e5e7eb;
    padding: 16px 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 50;
}

.search-bar {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 10px 16px;
    width: 400px;
}

.search-bar i {
    color: #9ca3af;
}

.search-bar input {
    border: none;
    background: none;
    outline: none;
    flex: 1;
    font-size: 14px;
    color: #1a1a1a;
}

.search-bar input::placeholder {
    color: #9ca3af;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.icon-btn {
    position: relative;
    background: none;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #6b7280;
    transition: all 0.2s;
}

.icon-btn:hover {
    background: #f3f4f6;
    color: #1a1a1a;
}

.icon-btn .badge {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 8px;
    height: 8px;
    background: #ef4444;
    border-radius: 50%;
    border: 2px solid white;
}

.user-profile {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 6px 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.user-profile:hover {
    background: #f3f4f6;
}

.user-info {
    text-align: right;
}

.user-name {
    display: block;
    font-weight: 600;
    font-size: 14px;
    color: #1a1a1a;
}

.user-role {
    display: block;
    font-size: 12px;
    color: #6b7280;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

/* Dashboard Content */
.dashboard-content {
    padding: 32px;
    flex: 1;
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
}

/* Welcome Section - Button on Right */
.welcome-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 32px;
    gap: 20px;
}

.welcome-text {
    flex: 1;
}

.welcome-title {
    font-size: 28px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 4px;
}

.welcome-subtitle {
    color: #6b7280;
    font-size: 14px;
}

.btn-analytics {
    width: auto;
    padding: 12px 20px;
    margin-top: 0;
    flex-shrink: 0;
}

.btn-analytics:hover {
    background-color: #333;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Stats Grid - 3 Cards in One Row */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 32px;
}

.stat-card {
    background: white;
    border-radius: 12px;
    padding: 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.stat-left {
    display: flex;
    align-items: center;
    gap: 16px;
    flex: 1;
}

.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    flex-shrink: 0;
}

.stat-icon.earnings {
    background: #d1fae5;
    color: #059669;
}

.stat-icon.published {
    background: #dbeafe;
    color: #2563eb;
}

.stat-icon.unpublished {
    background: #fef3c7;
    color: #d97706;
}

.stat-value {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.stat-number {
    font-size: 28px;
    font-weight: 700;
    color: #1a1a1a;
}

.stat-label {
    font-size: 14px;
    color: #6b7280;
}

.stat-change {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 6px;
    flex-shrink: 0;
}

.stat-change.positive {
    color: #059669;
    background: #d1fae5;
}

.stat-change.negative {
    color: #dc2626;
    background: #fee2e2;
}

/* Recent Posts */
.recent-posts {
    background: white;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.section-header h2 {
    font-size: 18px;
    font-weight: 700;
    color: #1a1a1a;
}

.view-all {
    color: #6b7280;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: color 0.2s;
}

.view-all:hover {
    color: #1a1a1a;
}

.table-container {
    overflow-x: auto;
}

.posts-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 600px;
}

.posts-table thead {
    border-bottom: 1px solid #e5e7eb;
}

.posts-table th {
    text-align: left;
    padding: 12px 16px;
    font-size: 12px;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.posts-table td {
    padding: 16px;
    border-bottom: 1px solid #f3f4f6;
    font-size: 14px;
    color: #1a1a1a;
}

.posts-table tbody tr:last-child td {
    border-bottom: none;
}

.posts-table tbody tr:hover {
    background: #f9fafb;
}

.post-title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 500;
    color: #1a1a1a;
}

.post-title i {
    color: #9ca3af;
    font-size: 18px;
}

.status-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
}

.status-badge.published {
    background: #d1fae5;
    color: #059669;
}

.status-badge.draft {
    background: #f3f4f6;
    color: #6b7280;
}

.action-buttons {
    display: flex;
    gap: 8px;
}

.action-btn {
    background: none;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #9ca3af;
    transition: all 0.2s;
}

.action-btn:hover {
    background: #f3f4f6;
    color: #1a1a1a;
}

/* Responsive */
@media (max-width: 1200px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }

    .main-content {
        margin-left: 0;
        width: 100%;
    }

    .dashboard-content {
        padding: 20px;
    }

    .welcome-section {
        flex-direction: column;
        align-items: flex-start;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .top-header {
        flex-direction: column;
        gap: 16px;
        align-items: stretch;
    }

    .search-bar {
        width: 100%;
    }

    .header-actions {
        justify-content: space-between;
    }
}

/* ========================================
   MY POSTS PAGE STYLES
   ======================================== */

/* Page Header */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 32px;
    flex-wrap: wrap;
    gap: 20px;
}

.page-title-section {
    flex: 1;
}

.page-title {
    font-size: 28px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 4px;
}

.page-subtitle {
    color: #6b7280;
    font-size: 14px;
}

.page-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.filter-dropdown {
    position: relative;
}

.filter-select {
    padding: 12px 40px 12px 16px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    color: #1a1a1a;
    background: white;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236b7280' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    transition: all 0.2s;
}

.filter-select:hover {
    border-color: #1a1a1a;
}

.filter-select:focus {
    outline: none;
    border-color: #1a1a1a;
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.05);
}

.btn-create {
    padding: 12px 20px;
    gap: 8px;
}

/* Posts Grid */
.posts-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

/* Post Card */
.post-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.post-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.1);
}

.post-card-image {
    position: relative;
    width: 100%;
    height: 200px;
    overflow: hidden;
}

.post-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.post-card:hover .post-card-image img {
    transform: scale(1.05);
}

.post-card-image .status-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.post-card-image .status-badge.published {
    background: #d1fae5;
    color: #059669;
}

.post-card-image .status-badge.draft {
    background: #f3f4f6;
    color: #6b7280;
}

.post-card-content {
    padding: 20px;
}

.post-card-title {
    font-size: 16px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 8px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.post-card-excerpt {
    font-size: 14px;
    color: #6b7280;
    line-height: 1.6;
    margin-bottom: 16px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.post-card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 16px;
    border-bottom: 1px solid #f3f4f6;
    margin-bottom: 16px;
}

.post-stats {
    display: flex;
    gap: 16px;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: #9ca3af;
}

.stat-item i {
    font-size: 12px;
}

.post-date {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: #9ca3af;
}

.post-date i {
    font-size: 12px;
}

.post-card-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.btn-action {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    color: #6b7280;
    background: white;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-action:hover {
    border-color: #1a1a1a;
    color: #1a1a1a;
    background: #f9fafb;
}

.btn-edit {
    flex: 1;
    justify-content: center;
    max-width: 120px;
}

.btn-action-group {
    display: flex;
    gap: 8px;
}

.btn-icon {
    width: 36px;
    height: 36px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #9ca3af;
    transition: all 0.2s;
}

.btn-icon:hover {
    border-color: #ef4444;
    color: #ef4444;
    background: #fef2f2;
}

/* Responsive */
@media (max-width: 1200px) {
    .posts-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .page-header {
        flex-direction: column;
        align-items: stretch;
    }

    .page-actions {
        flex-direction: column;
    }

    .filter-select,
    .btn-create {
        width: 100%;
    }

    .posts-grid {
        grid-template-columns: 1fr;
    }

    .post-card-image {
        height: 180px;
    }
}

/* ========================================
   CREATE POST PAGE STYLES
   ======================================== */

.btn-secondary {
    background: white;
    color: #1a1a1a;
    border: 1px solid #e5e7eb;
}

.btn-secondary:hover {
    background: #f9fafb;
    border-color: #1a1a1a;
}

.btn-save-draft {
    padding: 12px 20px;
    gap: 8px;
}

.btn-publish {
    padding: 12px 20px;
    gap: 8px;
}

.form-section {
    background: white;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.form-label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: #1a1a1a;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 12px;
}

.form-input-large {
    width: 100%;
    padding: 16px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
    color: #1a1a1a;
    transition: all 0.2s;
}

.form-input-large:focus {
    outline: none;
    border-color: #1a1a1a;
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.05);
}

.form-input-large::placeholder {
    color: #9ca3af;
    font-weight: 400;
}

/* Image Upload */
.image-upload-area {
    position: relative;
    width: 100%;
    height: 300px;
    border: 2px dashed #e5e7eb;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    background: #f9fafb;
}

.image-upload-area:hover {
    border-color: #1a1a1a;
    background: #f3f4f6;
}

.upload-content {
    text-align: center;
    color: #9ca3af;
}

.upload-content i {
    font-size: 48px;
    margin-bottom: 16px;
    color: #d1d5db;
}

.upload-content p {
    font-size: 14px;
    font-weight: 500;
    color: #6b7280;
    margin-bottom: 4px;
}

.upload-hint {
    font-size: 12px;
    color: #9ca3af;
}

.file-input {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

/* Editor Toolbar */
.editor-toolbar {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 12px 16px;
    border-bottom: 1px solid #e5e7eb;
    background: #f9fafb;
    border-radius: 8px 8px 0 0;
}

.toolbar-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    border: none;
    background: none;
    border-radius: 6px;
    color: #6b7280;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}

.toolbar-btn:hover {
    background: #e5e7eb;
    color: #1a1a1a;
}

.toolbar-divider {
    width: 1px;
    height: 24px;
    background: #e5e7eb;
    margin: 0 8px;
}

.editor-content {
    width: 100%;
    min-height: 400px;
    padding: 20px;
    border: 1px solid #e5e7eb;
    border-top: none;
    border-radius: 0 0 8px 8px;
    font-size: 15px;
    line-height: 1.8;
    color: #1a1a1a;
    resize: vertical;
    font-family: inherit;
}

.editor-content:focus {
    outline: none;
    border-color: #1a1a1a;
}

.editor-content::placeholder {
    color: #9ca3af;
}

/* ========================================
   PROFILE PAGE STYLES
   ======================================== */

.profile-header {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 24px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.profile-cover {
    width: 100%;
    height: 200px;
    overflow: hidden;
}

.profile-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-info-section {
    display: flex;
    align-items: center;
    gap: 24px;
    padding: 24px;
    margin-top: -60px;
    position: relative;
    flex-wrap: wrap;
}

.profile-avatar-large {
    width: 120px;
    height: 120px;
    border-radius: 12px;
    overflow: hidden;
    border: 4px solid white;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    flex-shrink: 0;
}

.profile-avatar-large img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-details {
    flex: 1;
}

.profile-name {
    font-size: 24px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 4px;
}

.profile-role {
    font-size: 14px;
    color: #6b7280;
}

.profile-actions {
    display: flex;
    gap: 12px;
    flex-shrink: 0;
}

.profile-actions .btn {
    padding: 10px 16px;
    font-size: 14px;
}

.profile-info-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-bottom: 24px;
}

.info-card {
    background: white;
    border-radius: 12px;
    padding: 20px 24px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.info-card i {
    font-size: 18px;
    color: #6b7280;
    width: 20px;
}

.info-card span {
    font-size: 14px;
    color: #1a1a1a;
}

.profile-section {
    background: white;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.section-title {
    font-size: 18px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 16px;
}

.about-text {
    font-size: 14px;
    color: #6b7280;
    line-height: 1.8;
}

.profile-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 24px;
}

.stat-card-profile {
    background: white;
    border-radius: 12px;
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.stat-icon-profile {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    background: #dbeafe;
    color: #2563eb;
    flex-shrink: 0;
}

.stat-icon-profile.views {
    background: #d1fae5;
    color: #059669;
}

.stat-icon-profile.comments {
    background: #fef3c7;
    color: #d97706;
}

.stat-icon-profile.likes {
    background: #fee2e2;
    color: #dc2626;
}

.stat-value-profile {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.stat-number-profile {
    font-size: 24px;
    font-weight: 700;
    color: #1a1a1a;
}

.stat-label-profile {
    font-size: 13px;
    color: #6b7280;
}

/* Activity List */
.activity-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.activity-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    border-radius: 8px;
    transition: background 0.2s;
}

.activity-item:hover {
    background: #f9fafb;
}

.activity-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f3f4f6;
    color: #6b7280;
    flex-shrink: 0;
}

.activity-content {
    flex: 1;
}

.activity-title {
    font-size: 14px;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 4px;
}

.activity-subtitle {
    font-size: 13px;
    color: #6b7280;
}

.activity-time {
    font-size: 13px;
    color: #9ca3af;
    flex-shrink: 0;
}

/* ========================================
   SETTINGS PAGE STYLES
   ======================================== */

.settings-section {
    background: white;
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.settings-section-title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 16px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid #f3f4f6;
}

.settings-section-title i {
    font-size: 18px;
    color: #6b7280;
}

.settings-section-title.danger {
    color: #dc2626;
}

.settings-section-title.danger i {
    color: #dc2626;
}

.settings-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 0;
    border-bottom: 1px solid #f3f4f6;
}

.settings-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.settings-item:first-child {
    padding-top: 0;
}

.settings-item-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f3f4f6;
    color: #6b7280;
    flex-shrink: 0;
}

.settings-item-content {
    flex: 1;
}

.settings-item-title {
    font-size: 14px;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 4px;
}

.settings-item-subtitle {
    font-size: 13px;
    color: #6b7280;
}

.settings-item-action {
    background: none;
    border: none;
    color: #9ca3af;
    cursor: pointer;
    padding: 8px;
    border-radius: 6px;
    transition: all 0.2s;
}

.settings-item-action:hover {
    background: #f3f4f6;
    color: #1a1a1a;
}

/* Toggle Switch */
.toggle-switch {
    position: relative;
    width: 48px;
    height: 26px;
    flex-shrink: 0;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #e5e7eb;
    transition: 0.3s;
    border-radius: 26px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.toggle-switch input:checked + .toggle-slider {
    background-color: #1a1a1a;
}

.toggle-switch input:checked + .toggle-slider:before {
    transform: translateX(22px);
}

/* Danger Zone */
.danger-zone {
    border: 1px solid #fee2e2;
    background: #fef2f2;
}

.danger-zone-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.danger-zone-text {
    flex: 1;
}

.danger-title {
    font-size: 14px;
    font-weight: 600;
    color: #dc2626;
    margin-bottom: 4px;
}

.danger-subtitle {
    font-size: 13px;
    color: #991b1b;
}

.btn-danger {
    background: #dc2626;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
    flex-shrink: 0;
}

.btn-danger:hover {
    background: #b91c1c;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(220, 38, 38, 0.3);
}

/* ========================================
   RESPONSIVE UPDATES
   ======================================== */

@media (max-width: 1200px) {
    .profile-stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .posts-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .page-header {
        flex-direction: column;
        align-items: stretch;
    }

    .page-actions {
        flex-direction: column;
    }

    .filter-select,
    .btn-create,
    .btn-save-draft,
    .btn-publish {
        width: 100%;
    }

    .profile-info-section {
        flex-direction: column;
        text-align: center;
        margin-top: -80px;
    }

    .profile-actions {
        width: 100%;
        justify-content: center;
    }

    .profile-info-cards {
        grid-template-columns: 1fr;
    }

    .profile-stats-grid {
        grid-template-columns: 1fr;
    }

    .posts-grid {
        grid-template-columns: 1fr;
    }

    .settings-item {
        flex-wrap: wrap;
    }

    .danger-zone-content {
        flex-direction: column;
        align-items: flex-start;
    }

    .btn-danger {
        width: 100%;
    }
}

/* ========================================
   EDIT PROFILE PAGE STYLES
   ======================================== */

.edit-profile-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    flex-wrap: wrap;
    gap: 16px;
}

.edit-profile-header .page-title-section {
    display: flex;
    align-items: center;
    gap: 16px;
}

.back-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: white;
    border: 1px solid #e5e7eb;
    color: #6b7280;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
}

.back-btn:hover {
    background: #f3f4f6;
    color: #1a1a1a;
    border-color: #1a1a1a;
}

.btn-save-changes {
    padding: 12px 24px;
    gap: 8px;
    flex-shrink: 0;
}

/* Cover & Avatar Section */
.edit-profile-cover-section {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 24px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    position: relative;
}

.cover-image {
    position: relative;
    width: 100%;
    height: 250px;
    overflow: hidden;
}

.cover-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.change-cover-btn {
    position: absolute;
    bottom: 16px;
    right: 16px;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: rgba(26, 26, 26, 0.9);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.change-cover-btn:hover {
    background: rgba(26, 26, 26, 1);
    transform: translateY(-2px);
}

.avatar-section {
    position: relative;
    padding: 0 24px;
    margin-top: -60px;
}

.avatar-wrapper {
    position: relative;
    width: 120px;
    height: 120px;
    border-radius: 12px;
    overflow: hidden;
    border: 4px solid white;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.avatar-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.change-avatar-btn {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 36px;
    height: 36px;
    background: #1a1a1a;
    color: white;
    border: none;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
}

.change-avatar-btn:hover {
    background: #333;
    transform: scale(1.05);
}

/* Edit Profile Form */
.edit-profile-form {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.form-column {
    flex: 1;
}

.form-card {
    background: white;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.form-card-title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 16px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid #f3f4f6;
}

.form-card-title i {
    font-size: 18px;
    color: #6b7280;
}

.form-group {
    margin-bottom: 20px;
}

.form-group:last-child {
    margin-bottom: 0;
}

.form-label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 8px;
}

.input-with-icon {
    position: relative;
    display: flex;
    align-items: center;
}

.input-with-icon i {
    position: absolute;
    left: 16px;
    color: #9ca3af;
    font-size: 16px;
    z-index: 1;
}

.input-with-icon .form-input {
    width: 100%;
    padding: 14px 16px 14px 48px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    font-size: 14px;
    color: #1a1a1a;
    background: #f9fafb;
    transition: all 0.2s;
}

.input-with-icon .form-input:focus {
    outline: none;
    border-color: #1a1a1a;
    background: white;
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.05);
}

.input-with-icon .form-input::placeholder {
    color: #9ca3af;
}

.form-textarea {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    font-size: 14px;
    color: #1a1a1a;
    background: #f9fafb;
    resize: vertical;
    font-family: inherit;
    line-height: 1.6;
    transition: all 0.2s;
}

.form-textarea:focus {
    outline: none;
    border-color: #1a1a1a;
    background: white;
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.05);
}

.form-hint {
    font-size: 12px;
    color: #9ca3af;
    margin-top: 8px;
}

/* Responsive */
@media (max-width: 1024px) {
    .form-row {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .edit-profile-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .edit-profile-header .page-title-section {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .btn-save-changes {
        width: 100%;
    }

    .cover-image {
        height: 180px;
    }

    .avatar-section {
        padding: 0 16px;
    }

    .avatar-wrapper {
        width: 100px;
        height: 100px;
    }
}

/* ── Create Post: additional fields ─────────────────────────── */

.form-select {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    font-size: 14px;
    color: #1a1a1a;
    background: #f9fafb;
    font-family: inherit;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%236b7280' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    cursor: pointer;
    transition: all 0.2s;
}

.form-select:focus {
    outline: none;
    border-color: #1a1a1a;
    background-color: white;
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.05);
}

.required {
    color: #ef4444;
    margin-left: 2px;
}

.form-actions {
    display: flex;
    gap: 12px;
    align-items: center;
    padding-top: 8px;
}

.btn-submit-review {
    min-width: 180px;
}

.image-preview-img {
    width: 100%;
    max-height: 260px;
    object-fit: cover;
    border-radius: 8px;
}

/* Flash messages */
.flash-message {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 18px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 20px;
    position: relative;
}

.flash-success {
    background: #f0fdf4;
    color: #15803d;
    border: 1px solid #bbf7d0;
}

.flash-error {
    background: #fef2f2;
    color: #b91c1c;
    border: 1px solid #fecaca;
}

.flash-close {
    margin-left: auto;
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
    color: inherit;
    opacity: 0.6;
    line-height: 1;
}

.flash-close:hover {
    opacity: 1;
}