/**
 * GrowthHub Portal — Frontend Styles
 * Mobile-first (375px base), app-like UI
 * Alles namespaced onder .wb-app
 */

/* === CSS Variables (fallbacks) === */
.wb-app {
    --gh-primary: #2563eb !important;
    --gh-secondary: #1e40af !important;
    --gh-accent: #3b82f6 !important;
    --gh-success: #22c55e !important;
    --gh-warning: #f59e0b !important;
    --gh-danger: #ef4444 !important;
    --gh-bg: #f8fafc !important;
    --gh-card-bg: #ffffff !important;
    --gh-text: #1e293b !important;
    --gh-text-muted: #64748b !important;
    --gh-border: #e2e8f0 !important;
    --gh-radius: 12px !important;
    --gh-radius-sm: 8px !important;
    --gh-shadow: 0 1px 3px rgba(0, 0, 0, 0.08), 0 1px 2px rgba(0, 0, 0, 0.06) !important;
    --gh-shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1) !important;
    --gh-transition: all 0.2s ease !important;
}

/* === Reset / Base === */
.wb-app {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif !important;
    font-size: 16px !important;
    line-height: 1.5 !important;
    color: var(--gh-text) !important;
    background: var(--gh-bg) !important;
    max-width: 100% !important;
    margin: 0 auto !important;
    padding: 0 !important;
    -webkit-font-smoothing: antialiased !important;
    -moz-osx-font-smoothing: grayscale !important;
}

.wb-app *,
.wb-app *::before,
.wb-app *::after {
    box-sizing: border-box !important;
}

.wb-app h1,
.wb-app h2,
.wb-app h3,
.wb-app h4,
.wb-app h5,
.wb-app p {
    margin: 0 !important;
    padding: 0 !important;
}

/* === Header === */
.wb-app .wb-header {
    background: linear-gradient(135deg, var(--gh-primary), var(--gh-secondary)) !important;
    color: #ffffff !important;
    padding: 20px 16px !important;
    position: sticky !important;
    top: 0 !important;
    z-index: 100 !important;
}

.wb-app .wb-header-inner {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    max-width: 800px !important;
    margin: 0 auto !important;
}

.wb-app .wb-logo {
    height: 36px !important;
    width: auto !important;
}

.wb-app .wb-title {
    font-size: 20px !important;
    font-weight: 700 !important;
    color: #ffffff !important;
}

.wb-app .wb-user-info {
    text-align: right !important;
}

.wb-app .wb-user-name {
    display: block !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    color: rgba(255, 255, 255, 0.95) !important;
}

.wb-app .wb-project-name {
    display: block !important;
    font-size: 12px !important;
    color: rgba(255, 255, 255, 0.7) !important;
}

/* === Phase Progress Bar === */
.wb-app .wb-phase-bar {
    background: var(--gh-card-bg) !important;
    padding: 20px 16px !important;
    border-bottom: 1px solid var(--gh-border) !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
}

.wb-app .wb-phase-bar-inner {
    display: flex !important;
    align-items: flex-start !important;
    justify-content: space-between !important;
    max-width: 800px !important;
    margin: 0 auto !important;
    min-width: 600px !important;
}

.wb-app .wb-phase-step {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    position: relative !important;
    flex: 1 !important;
    text-align: center !important;
}

.wb-app .wb-phase-number {
    width: 40px !important;
    height: 40px !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-weight: 700 !important;
    font-size: 16px !important;
    border: 3px solid var(--gh-border) !important;
    background: var(--gh-card-bg) !important;
    color: var(--gh-text-muted) !important;
    transition: var(--gh-transition) !important;
    position: relative !important;
    z-index: 2 !important;
}

.wb-app .wb-phase-active .wb-phase-number {
    border-color: var(--gh-primary) !important;
    background: var(--gh-primary) !important;
    color: #ffffff !important;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.2) !important;
}

.wb-app .wb-phase-complete .wb-phase-number {
    border-color: var(--gh-success) !important;
    background: var(--gh-success) !important;
    color: #ffffff !important;
}

.wb-app .wb-phase-locked .wb-phase-number {
    opacity: 0.4 !important;
}

.wb-app .wb-icon-check {
    width: 20px !important;
    height: 20px !important;
}

.wb-app .wb-phase-info {
    margin-top: 8px !important;
}

.wb-app .wb-phase-label {
    display: block !important;
    font-size: 11px !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
    color: var(--gh-text-muted) !important;
    font-weight: 600 !important;
}

.wb-app .wb-phase-active .wb-phase-label {
    color: var(--gh-primary) !important;
}

.wb-app .wb-phase-name {
    display: block !important;
    font-size: 12px !important;
    color: var(--gh-text) !important;
    margin-top: 2px !important;
    font-weight: 500 !important;
}

.wb-app .wb-phase-locked .wb-phase-info {
    opacity: 0.4 !important;
}

.wb-app .wb-phase-connector {
    position: absolute !important;
    top: 20px !important;
    left: calc(50% + 24px) !important;
    width: calc(100% - 48px) !important;
    height: 3px !important;
    background: var(--gh-border) !important;
    z-index: 1 !important;
}

.wb-app .wb-connector-complete {
    background: var(--gh-success) !important;
}

/* === Current Phase Section === */
.wb-app .wb-current-phase {
    padding: 24px 16px 8px !important;
    max-width: 800px !important;
    margin: 0 auto !important;
}

.wb-app .wb-section-header {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
}

.wb-app .wb-section-header h2 {
    font-size: 22px !important;
    font-weight: 700 !important;
    color: var(--gh-text) !important;
}

/* === Progress Ring === */
.wb-app .wb-progress-indicator {
    flex-shrink: 0 !important;
}

.wb-app .wb-progress-ring {
    position: relative !important;
    width: 56px !important;
    height: 56px !important;
}

.wb-app .wb-progress-ring svg {
    transform: rotate(-90deg) !important;
    width: 56px !important;
    height: 56px !important;
}

.wb-app .wb-progress-text {
    position: absolute !important;
    top: 50% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    color: var(--gh-primary) !important;
}

/* === Section Titles === */
.wb-app .wb-section-title {
    font-size: 18px !important;
    font-weight: 600 !important;
    color: var(--gh-text) !important;
    padding: 0 16px !important;
    margin-bottom: 12px !important;
    max-width: 800px !important;
    margin-left: auto !important;
    margin-right: auto !important;
}

/* === Tasks === */
.wb-app .wb-tasks-section,
.wb-app .wb-approvals-section,
.wb-app .wb-calendar-section,
.wb-app .wb-timeline-section {
    padding: 16px 0 !important;
}

.wb-app .wb-task-list,
.wb-app .wb-approval-list {
    padding: 0 16px !important;
    max-width: 800px !important;
    margin: 0 auto !important;
}

.wb-app .wb-task-card,
.wb-app .wb-approval-card {
    background: var(--gh-card-bg) !important;
    border: 1px solid var(--gh-border) !important;
    border-radius: var(--gh-radius) !important;
    padding: 16px !important;
    margin-bottom: 12px !important;
    display: flex !important;
    align-items: flex-start !important;
    gap: 12px !important;
    transition: var(--gh-transition) !important;
    box-shadow: var(--gh-shadow) !important;
}

.wb-app .wb-task-card:hover,
.wb-app .wb-approval-card:hover {
    box-shadow: var(--gh-shadow-md) !important;
    border-color: var(--gh-accent) !important;
}

.wb-app .wb-task-completed {
    opacity: 0.7 !important;
    background: #f0fdf4 !important;
}

.wb-app .wb-task-approval {
    border-left: 4px solid var(--gh-warning) !important;
}

.wb-app .wb-task-status-icon,
.wb-app .wb-approval-icon {
    flex-shrink: 0 !important;
    width: 32px !important;
    height: 32px !important;
}

.wb-app .wb-icon {
    width: 32px !important;
    height: 32px !important;
}

.wb-app .wb-icon-done {
    color: var(--gh-success) !important;
}

.wb-app .wb-icon-approval {
    color: var(--gh-warning) !important;
}

.wb-app .wb-icon-task {
    color: var(--gh-text-muted) !important;
}

.wb-app .wb-approval-icon svg {
    width: 32px !important;
    height: 32px !important;
    color: var(--gh-primary) !important;
}

.wb-app .wb-task-content,
.wb-app .wb-approval-content {
    flex: 1 !important;
    min-width: 0 !important;
}

.wb-app .wb-task-title {
    font-size: 15px !important;
    font-weight: 600 !important;
    color: var(--gh-text) !important;
    margin-bottom: 4px !important;
}

.wb-app .wb-task-desc {
    font-size: 13px !important;
    color: var(--gh-text-muted) !important;
    margin-bottom: 6px !important;
    line-height: 1.4 !important;
}

.wb-app .wb-approval-content h4 {
    font-size: 15px !important;
    font-weight: 600 !important;
    color: var(--gh-text) !important;
    margin-bottom: 4px !important;
}

.wb-app .wb-approval-content p {
    font-size: 13px !important;
    color: var(--gh-text-muted) !important;
}

/* === Badges === */
.wb-app .wb-badge {
    display: inline-block !important;
    padding: 2px 8px !important;
    border-radius: 9999px !important;
    font-size: 11px !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.3px !important;
}

.wb-app .wb-badge-required {
    background: #fef3c7 !important;
    color: #92400e !important;
}

/* === Buttons === */
.wb-app .wb-btn {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 10px 20px !important;
    border-radius: var(--gh-radius-sm) !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    border: none !important;
    cursor: pointer !important;
    transition: var(--gh-transition) !important;
    text-decoration: none !important;
    white-space: nowrap !important;
    min-height: 44px !important;
    line-height: 1 !important;
}

.wb-app .wb-btn-primary {
    background: var(--gh-primary) !important;
    color: #ffffff !important;
}

.wb-app .wb-btn-primary:hover {
    background: var(--gh-secondary) !important;
}

.wb-app .wb-btn-complete {
    background: var(--gh-success) !important;
    color: #ffffff !important;
}

.wb-app .wb-btn-complete:hover {
    background: #16a34a !important;
}

.wb-app .wb-btn-approve {
    background: var(--gh-primary) !important;
    color: #ffffff !important;
}

.wb-app .wb-btn-approve:hover {
    background: var(--gh-secondary) !important;
}

.wb-app .wb-btn-sm {
    padding: 6px 14px !important;
    font-size: 13px !important;
    min-height: 36px !important;
}

.wb-app .wb-btn:disabled,
.wb-app .wb-btn.wb-btn-loading {
    opacity: 0.6 !important;
    cursor: not-allowed !important;
    pointer-events: none !important;
}

.wb-app .wb-task-action,
.wb-app .wb-approval-action {
    flex-shrink: 0 !important;
    align-self: center !important;
}

.wb-app .wb-completed-label {
    font-size: 13px !important;
    color: var(--gh-success) !important;
    font-weight: 600 !important;
}

/* === Calendar === */
.wb-app .wb-calendar-section {
    padding: 16px 0 !important;
}

.wb-app .wb-calendar-month {
    padding: 0 16px !important;
    max-width: 800px !important;
    margin: 0 auto 24px !important;
}

.wb-app .wb-month-title {
    font-size: 16px !important;
    font-weight: 600 !important;
    color: var(--gh-text) !important;
    margin-bottom: 12px !important;
    padding-bottom: 8px !important;
    border-bottom: 2px solid var(--gh-primary) !important;
}

.wb-app .wb-calendar-items {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 12px !important;
}

.wb-app .wb-calendar-card {
    background: var(--gh-card-bg) !important;
    border: 1px solid var(--gh-border) !important;
    border-radius: var(--gh-radius) !important;
    padding: 16px !important;
    box-shadow: var(--gh-shadow) !important;
    transition: var(--gh-transition) !important;
}

.wb-app .wb-calendar-card:hover {
    box-shadow: var(--gh-shadow-md) !important;
}

.wb-app .wb-calendar-approved {
    border-left: 4px solid var(--gh-success) !important;
}

.wb-app .wb-calendar-in_production {
    border-left: 4px solid var(--gh-warning) !important;
}

.wb-app .wb-calendar-published {
    border-left: 4px solid var(--gh-primary) !important;
    opacity: 0.7 !important;
}

.wb-app .wb-calendar-card-header {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    margin-bottom: 8px !important;
}

.wb-app .wb-calendar-type {
    font-size: 11px !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    padding: 3px 8px !important;
    border-radius: 4px !important;
    letter-spacing: 0.3px !important;
}

.wb-app .wb-type-social_post {
    background: #ede9fe !important;
    color: #6d28d9 !important;
}

.wb-app .wb-type-website_page {
    background: #dbeafe !important;
    color: #1d4ed8 !important;
}

.wb-app .wb-calendar-status {
    font-size: 11px !important;
    font-weight: 600 !important;
    padding: 3px 8px !important;
    border-radius: 4px !important;
}

.wb-app .wb-status-planned {
    background: #f1f5f9 !important;
    color: #475569 !important;
}

.wb-app .wb-status-approved {
    background: #dcfce7 !important;
    color: #166534 !important;
}

.wb-app .wb-status-in_production {
    background: #fef3c7 !important;
    color: #92400e !important;
}

.wb-app .wb-status-published {
    background: #dbeafe !important;
    color: #1d4ed8 !important;
}

.wb-app .wb-calendar-title {
    font-size: 15px !important;
    font-weight: 600 !important;
    color: var(--gh-text) !important;
    margin-bottom: 4px !important;
}

.wb-app .wb-calendar-content {
    font-size: 13px !important;
    color: var(--gh-text-muted) !important;
    line-height: 1.4 !important;
    margin-bottom: 8px !important;
}

.wb-app .wb-calendar-date {
    font-size: 12px !important;
    color: var(--gh-text-muted) !important;
    display: block !important;
    margin-bottom: 8px !important;
}

.wb-app .wb-calendar-action {
    margin-top: 8px !important;
}

/* === Timeline === */
.wb-app .wb-timeline {
    padding: 0 16px !important;
    max-width: 800px !important;
    margin: 0 auto !important;
}

.wb-app .wb-timeline-item {
    display: flex !important;
    gap: 16px !important;
    padding-bottom: 24px !important;
    position: relative !important;
}

.wb-app .wb-timeline-item:not(:last-child)::before {
    content: '' !important;
    position: absolute !important;
    left: 16px !important;
    top: 40px !important;
    width: 2px !important;
    height: calc(100% - 40px) !important;
    background: var(--gh-border) !important;
}

.wb-app .wb-tl-past:not(:last-child)::before {
    background: var(--gh-success) !important;
}

.wb-app .wb-timeline-marker {
    width: 34px !important;
    height: 34px !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex-shrink: 0 !important;
    font-weight: 700 !important;
    font-size: 14px !important;
    position: relative !important;
    z-index: 2 !important;
    background: var(--gh-card-bg) !important;
    border: 2px solid var(--gh-border) !important;
    color: var(--gh-text-muted) !important;
}

.wb-app .wb-tl-past .wb-timeline-marker {
    background: var(--gh-success) !important;
    border-color: var(--gh-success) !important;
    color: #ffffff !important;
}

.wb-app .wb-tl-past .wb-timeline-marker svg {
    width: 18px !important;
    height: 18px !important;
}

.wb-app .wb-tl-current .wb-timeline-marker {
    background: var(--gh-primary) !important;
    border-color: var(--gh-primary) !important;
    color: #ffffff !important;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.2) !important;
}

.wb-app .wb-tl-future .wb-timeline-marker {
    opacity: 0.4 !important;
}

.wb-app .wb-timeline-content {
    flex: 1 !important;
    padding-top: 4px !important;
}

.wb-app .wb-timeline-content h4 {
    font-size: 15px !important;
    font-weight: 600 !important;
    color: var(--gh-text) !important;
    margin-bottom: 8px !important;
}

.wb-app .wb-tl-future .wb-timeline-content {
    opacity: 0.4 !important;
}

.wb-app .wb-timeline-progress {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
}

.wb-app .wb-progress-bar-sm {
    flex: 1 !important;
    height: 6px !important;
    background: var(--gh-border) !important;
    border-radius: 3px !important;
    overflow: hidden !important;
}

.wb-app .wb-progress-fill-sm {
    height: 100% !important;
    background: var(--gh-primary) !important;
    border-radius: 3px !important;
    transition: width 0.4s ease !important;
}

.wb-app .wb-tl-past .wb-progress-fill-sm {
    background: var(--gh-success) !important;
}

.wb-app .wb-timeline-progress span {
    font-size: 12px !important;
    color: var(--gh-text-muted) !important;
    font-weight: 500 !important;
    white-space: nowrap !important;
}

.wb-app .wb-timeline-locked {
    font-size: 13px !important;
    color: var(--gh-text-muted) !important;
    font-style: italic !important;
}

/* === Empty State === */
.wb-app .wb-empty-state {
    padding: 32px 16px !important;
    text-align: center !important;
    max-width: 800px !important;
    margin: 0 auto !important;
}

.wb-app .wb-empty-state p {
    font-size: 15px !important;
    color: var(--gh-text-muted) !important;
}

/* === Messages === */
.wb-app .wb-message {
    padding: 16px !important;
    border-radius: var(--gh-radius-sm) !important;
    margin: 16px !important;
    font-size: 14px !important;
}

.wb-app .wb-message-info {
    background: #dbeafe !important;
    color: #1e40af !important;
    border: 1px solid #93c5fd !important;
}

.wb-app .wb-message-warning {
    background: #fef3c7 !important;
    color: #92400e !important;
    border: 1px solid #fcd34d !important;
}

/* === Login Required === */
.wb-app .wb-login-required {
    text-align: center !important;
    padding: 60px 24px !important;
}

.wb-app .wb-login-required h2 {
    font-size: 24px !important;
    font-weight: 700 !important;
    color: var(--gh-text) !important;
    margin-bottom: 12px !important;
}

.wb-app .wb-login-required p {
    font-size: 15px !important;
    color: var(--gh-text-muted) !important;
    margin-bottom: 24px !important;
}

/* === Admin Preview === */
.wb-app .wb-admin-preview-notice {
    background: #fef3c7 !important;
    color: #92400e !important;
    padding: 8px 16px !important;
    text-align: center !important;
    font-size: 13px !important;
    font-weight: 500 !important;
}

/* === Footer === */
.wb-app .wb-footer {
    text-align: center !important;
    padding: 24px 16px !important;
    border-top: 1px solid var(--gh-border) !important;
    margin-top: 32px !important;
}

.wb-app .wb-footer p {
    font-size: 13px !important;
    color: var(--gh-text-muted) !important;
}

/* === Toast Notification === */
.wb-app .wb-toast {
    position: fixed !important;
    bottom: 24px !important;
    left: 50% !important;
    transform: translateX(-50%) translateY(100px) !important;
    background: var(--gh-text) !important;
    color: #ffffff !important;
    padding: 12px 24px !important;
    border-radius: var(--gh-radius-sm) !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    z-index: 9999 !important;
    opacity: 0 !important;
    transition: transform 0.3s ease, opacity 0.3s ease !important;
    max-width: calc(100vw - 32px) !important;
    text-align: center !important;
    box-shadow: var(--gh-shadow-md) !important;
}

.wb-app .wb-toast.wb-toast-visible {
    transform: translateX(-50%) translateY(0) !important;
    opacity: 1 !important;
}

.wb-app .wb-toast-success {
    background: var(--gh-success) !important;
}

.wb-app .wb-toast-error {
    background: var(--gh-danger) !important;
}

/* === Project Selector (Multi-project) === */
.wb-app .wb-project-selector {
    padding: 32px 16px !important;
}

.wb-app .wb-project-selector-inner {
    max-width: 800px !important;
    margin: 0 auto !important;
}

.wb-app .wb-project-selector-title {
    font-size: 24px !important;
    font-weight: 700 !important;
    color: var(--gh-text) !important;
    margin-bottom: 8px !important;
}

.wb-app .wb-project-selector-desc {
    font-size: 15px !important;
    color: var(--gh-text-muted) !important;
    margin-bottom: 24px !important;
}

.wb-app .wb-project-grid {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 16px !important;
}

.wb-app .wb-project-card {
    display: block !important;
    background: var(--gh-card-bg) !important;
    border: 1px solid var(--gh-border) !important;
    border-radius: var(--gh-radius) !important;
    padding: 20px !important;
    text-decoration: none !important;
    color: var(--gh-text) !important;
    box-shadow: var(--gh-shadow) !important;
    transition: var(--gh-transition) !important;
    position: relative !important;
}

.wb-app .wb-project-card:hover {
    box-shadow: var(--gh-shadow-md) !important;
    border-color: var(--gh-primary) !important;
    transform: translateY(-2px) !important;
}

.wb-app .wb-project-card-header {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    margin-bottom: 12px !important;
}

.wb-app .wb-project-card-name {
    font-size: 18px !important;
    font-weight: 700 !important;
    color: var(--gh-text) !important;
}

.wb-app .wb-project-card-status {
    font-size: 11px !important;
    font-weight: 600 !important;
    padding: 3px 10px !important;
    border-radius: 9999px !important;
    text-transform: uppercase !important;
    letter-spacing: 0.3px !important;
}

.wb-app .wb-project-card-status.wb-status-active {
    background: #dcfce7 !important;
    color: #166534 !important;
}

.wb-app .wb-project-card-phase {
    margin-bottom: 12px !important;
}

.wb-app .wb-project-card-phase-label {
    display: block !important;
    font-size: 11px !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
    color: var(--gh-text-muted) !important;
    font-weight: 600 !important;
    margin-bottom: 2px !important;
}

.wb-app .wb-project-card-phase-name {
    display: block !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    color: var(--gh-primary) !important;
}

.wb-app .wb-project-card-progress {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    margin-bottom: 12px !important;
}

.wb-app .wb-project-card-pct {
    font-size: 12px !important;
    color: var(--gh-text-muted) !important;
    font-weight: 500 !important;
    white-space: nowrap !important;
}

.wb-app .wb-project-card-phases {
    display: flex !important;
    gap: 8px !important;
}

.wb-app .wb-phase-dot {
    width: 28px !important;
    height: 28px !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    border: 2px solid var(--gh-border) !important;
    background: var(--gh-card-bg) !important;
    color: var(--gh-text-muted) !important;
}

.wb-app .wb-dot-complete {
    background: var(--gh-success) !important;
    border-color: var(--gh-success) !important;
    color: #fff !important;
}

.wb-app .wb-dot-active {
    background: var(--gh-primary) !important;
    border-color: var(--gh-primary) !important;
    color: #fff !important;
}

.wb-app .wb-dot-locked {
    opacity: 0.35 !important;
}

.wb-app .wb-project-card-arrow {
    position: absolute !important;
    right: 20px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    font-size: 20px !important;
    color: var(--gh-text-muted) !important;
    transition: var(--gh-transition) !important;
}

.wb-app .wb-project-card:hover .wb-project-card-arrow {
    color: var(--gh-primary) !important;
    right: 16px !important;
}

/* === Project Switcher Link === */
.wb-app .wb-switch-project {
    display: block !important;
    font-size: 11px !important;
    color: rgba(255, 255, 255, 0.8) !important;
    text-decoration: none !important;
    margin-top: 4px !important;
    transition: var(--gh-transition) !important;
}

.wb-app .wb-switch-project:hover {
    color: #ffffff !important;
}

/* === Instruction Links === */
.wb-app .wb-instruction-link {
    display: inline-flex !important;
    align-items: center !important;
    gap: 4px !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    color: var(--gh-primary) !important;
    text-decoration: none !important;
    padding: 3px 0 !important;
    transition: var(--gh-transition) !important;
}

.wb-app .wb-instruction-link:hover {
    color: var(--gh-secondary) !important;
    text-decoration: underline !important;
}

.wb-app .wb-instruction-text {
    display: flex !important;
    align-items: flex-start !important;
    gap: 8px !important;
    background: #f0f9ff !important;
    border: 1px solid #bae6fd !important;
    border-radius: var(--gh-radius-sm) !important;
    padding: 10px 14px !important;
    margin-top: 8px !important;
    font-size: 13px !important;
    line-height: 1.5 !important;
    color: var(--gh-text) !important;
}

.wb-app .wb-instruction-text .wb-icon-sm {
    margin-top: 2px !important;
    color: var(--gh-primary) !important;
    flex-shrink: 0 !important;
}

.wb-app .wb-instruction-text span {
    flex: 1 !important;
}

.wb-app .wb-icon-sm {
    width: 16px !important;
    height: 16px !important;
    flex-shrink: 0 !important;
}

.wb-app .wb-task-meta {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 8px !important;
    align-items: center !important;
    margin-top: 6px !important;
}

/* === Comments === */
.wb-app .wb-comment-toggle {
    margin-top: 10px !important;
}

.wb-app .wb-comment-btn {
    display: inline-flex !important;
    align-items: center !important;
    gap: 6px !important;
    background: none !important;
    border: none !important;
    cursor: pointer !important;
    font-size: 13px !important;
    font-weight: 500 !important;
    color: var(--gh-text-muted) !important;
    padding: 4px 0 !important;
    transition: var(--gh-transition) !important;
}

.wb-app .wb-comment-btn:hover {
    color: var(--gh-primary) !important;
}

.wb-app .wb-comment-count {
    font-weight: 700 !important;
    color: var(--gh-primary) !important;
}

.wb-app .wb-comments-panel {
    margin-top: 12px !important;
    padding: 12px !important;
    background: var(--gh-bg) !important;
    border-radius: var(--gh-radius-sm) !important;
    border: 1px solid var(--gh-border) !important;
}

.wb-app .wb-comments-list {
    max-height: 300px !important;
    overflow-y: auto !important;
    margin-bottom: 12px !important;
}

.wb-app .wb-comment-item {
    padding: 8px 0 !important;
    border-bottom: 1px solid var(--gh-border) !important;
}

.wb-app .wb-comment-item:last-child {
    border-bottom: none !important;
}

.wb-app .wb-comment-header {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    margin-bottom: 4px !important;
}

.wb-app .wb-comment-author {
    font-size: 13px !important;
    font-weight: 600 !important;
    color: var(--gh-text) !important;
}

.wb-app .wb-comment-date {
    font-size: 11px !important;
    color: var(--gh-text-muted) !important;
}

.wb-app .wb-comment-text {
    font-size: 13px !important;
    color: var(--gh-text) !important;
    line-height: 1.5 !important;
}

.wb-app .wb-comments-loading,
.wb-app .wb-no-comments {
    font-size: 13px !important;
    color: var(--gh-text-muted) !important;
    text-align: center !important;
    padding: 12px 0 !important;
    font-style: italic !important;
}

.wb-app .wb-comment-form {
    display: flex !important;
    gap: 8px !important;
    align-items: flex-end !important;
}

.wb-app .wb-comment-input {
    flex: 1 !important;
    padding: 8px 12px !important;
    border: 1px solid var(--gh-border) !important;
    border-radius: var(--gh-radius-sm) !important;
    font-size: 13px !important;
    font-family: inherit !important;
    resize: vertical !important;
    min-height: 40px !important;
    background: var(--gh-card-bg) !important;
    color: var(--gh-text) !important;
}

.wb-app .wb-comment-input:focus {
    outline: none !important;
    border-color: var(--gh-primary) !important;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1) !important;
}

/* === Feedback (Approval Iterations) === */
.wb-app .wb-feedback-section {
    margin-top: 12px !important;
    padding-top: 12px !important;
    border-top: 1px dashed var(--gh-border) !important;
}

.wb-app .wb-feedback-form {
    margin-top: 8px !important;
}

.wb-app .wb-feedback-input {
    width: 100% !important;
    padding: 10px 12px !important;
    border: 1px solid var(--gh-border) !important;
    border-radius: var(--gh-radius-sm) !important;
    font-size: 13px !important;
    font-family: inherit !important;
    resize: vertical !important;
    min-height: 60px !important;
    background: var(--gh-card-bg) !important;
    color: var(--gh-text) !important;
    margin-bottom: 8px !important;
}

.wb-app .wb-feedback-input:focus {
    outline: none !important;
    border-color: var(--gh-warning) !important;
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.1) !important;
}

.wb-app .wb-btn-feedback {
    background: var(--gh-warning) !important;
    color: #ffffff !important;
}

.wb-app .wb-btn-feedback:hover {
    background: #d97706 !important;
}

.wb-app .wb-feedback-toggle {
    background: none !important;
    border: none !important;
    cursor: pointer !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    color: var(--gh-primary) !important;
    padding: 4px 0 !important;
    text-decoration: underline !important;
}

.wb-app .wb-feedback-toggle:hover {
    color: var(--gh-secondary) !important;
}

.wb-app .wb-feedback-content {
    background: #f8fafc !important;
    padding: 12px !important;
    border-radius: var(--gh-radius-sm) !important;
    border: 1px solid var(--gh-border) !important;
    font-size: 13px !important;
    color: var(--gh-text) !important;
    line-height: 1.6 !important;
    margin: 8px 0 !important;
    max-height: 200px !important;
    overflow-y: auto !important;
    white-space: pre-wrap !important;
}

.wb-app .wb-feedback-max-reached {
    font-size: 13px !important;
    color: var(--gh-danger) !important;
    font-style: italic !important;
    padding: 8px 0 !important;
}

.wb-app .wb-feedback-history {
    margin-bottom: 8px !important;
}

/* === Badges (additional) === */
.wb-app .wb-badge-iterations {
    background: #ede9fe !important;
    color: #6d28d9 !important;
}

.wb-app .wb-badge-revision {
    background: #fef3c7 !important;
    color: #92400e !important;
}

/* === Approval Revision State === */
.wb-app .wb-approval-revision {
    border-left: 4px solid var(--gh-warning) !important;
}

/* === Responsive: Tablet (≥600px) === */
@media (min-width: 600px) {
    .wb-app .wb-calendar-items {
        grid-template-columns: repeat(2, 1fr) !important;
    }

    .wb-app .wb-task-card,
    .wb-app .wb-approval-card {
        padding: 20px !important;
    }

    .wb-app .wb-header {
        padding: 24px 24px !important;
    }

    .wb-app .wb-project-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }

    .wb-app .wb-comment-form {
        flex-direction: row !important;
    }
}

/* === Responsive: Desktop (≥800px) === */
@media (min-width: 800px) {
    .wb-app .wb-phase-bar-inner {
        min-width: auto !important;
    }

    .wb-app .wb-calendar-items {
        grid-template-columns: repeat(3, 1fr) !important;
    }

    .wb-app .wb-section-header h2 {
        font-size: 26px !important;
    }
}

/* === File Attachments === */
.wb-app .wb-attachment-toggle {
    margin-top: 4px !important;
}

.wb-app .wb-attachment-btn {
    display: inline-flex !important;
    align-items: center !important;
    gap: 6px !important;
    background: none !important;
    border: none !important;
    cursor: pointer !important;
    font-size: 13px !important;
    color: var(--gh-text-muted) !important;
    padding: 6px 0 !important;
    transition: var(--gh-transition) !important;
}

.wb-app .wb-attachment-btn:hover {
    color: var(--gh-primary) !important;
}

.wb-app .wb-attachment-count {
    font-weight: 600 !important;
    color: var(--gh-primary) !important;
}

.wb-app .wb-files-panel {
    margin-top: 8px !important;
    border: 1px solid var(--gh-border) !important;
    border-radius: var(--gh-radius-sm) !important;
    background: #fafbfc !important;
    overflow: hidden !important;
}

.wb-app .wb-files-list {
    max-height: 250px !important;
    overflow-y: auto !important;
    padding: 8px !important;
}

.wb-app .wb-file-item {
    display: flex !important;
    align-items: center !important;
    gap: 8px !important;
    padding: 8px 10px !important;
    border-bottom: 1px solid var(--gh-border) !important;
    font-size: 13px !important;
}

.wb-app .wb-file-item:last-child {
    border-bottom: none !important;
}

.wb-app .wb-file-icon {
    font-size: 16px !important;
    flex-shrink: 0 !important;
}

.wb-app .wb-file-info {
    flex: 1 !important;
    min-width: 0 !important;
}

.wb-app .wb-file-name {
    display: block !important;
    color: var(--gh-primary) !important;
    text-decoration: none !important;
    font-weight: 500 !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}

.wb-app .wb-file-name:hover {
    text-decoration: underline !important;
}

.wb-app .wb-file-meta {
    display: block !important;
    font-size: 11px !important;
    color: var(--gh-text-muted) !important;
    margin-top: 2px !important;
}

.wb-app .wb-file-delete {
    background: none !important;
    border: none !important;
    color: var(--gh-danger) !important;
    cursor: pointer !important;
    font-size: 18px !important;
    padding: 2px 6px !important;
    border-radius: 4px !important;
    line-height: 1 !important;
    flex-shrink: 0 !important;
}

.wb-app .wb-file-delete:hover {
    background: rgba(239, 68, 68, 0.1) !important;
}

.wb-app .wb-no-files {
    padding: 16px !important;
    text-align: center !important;
    color: var(--gh-text-muted) !important;
    font-size: 13px !important;
}

.wb-app .wb-files-loading {
    padding: 16px !important;
    text-align: center !important;
    color: var(--gh-text-muted) !important;
}

.wb-app .wb-file-upload-form {
    padding: 10px 12px !important;
    border-top: 1px solid var(--gh-border) !important;
    background: #f5f6f8 !important;
}

.wb-app .wb-file-upload-row {
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
    flex-wrap: wrap !important;
}

.wb-app .wb-file-upload-label {
    display: inline-flex !important;
    align-items: center !important;
    gap: 6px !important;
    padding: 6px 14px !important;
    background: var(--gh-card-bg) !important;
    border: 1px dashed var(--gh-border) !important;
    border-radius: var(--gh-radius-sm) !important;
    cursor: pointer !important;
    font-size: 13px !important;
    color: var(--gh-text-muted) !important;
    transition: var(--gh-transition) !important;
}

.wb-app .wb-file-upload-label:hover {
    border-color: var(--gh-primary) !important;
    color: var(--gh-primary) !important;
}

.wb-app .wb-file-divider {
    font-size: 12px !important;
    color: var(--gh-text-muted) !important;
}

.wb-app .wb-btn-link-toggle {
    background: none !important;
    border: 1px solid var(--gh-border) !important;
    color: var(--gh-text-muted) !important;
    border-radius: var(--gh-radius-sm) !important;
    padding: 6px 14px !important;
    cursor: pointer !important;
    font-size: 13px !important;
}

.wb-app .wb-btn-link-toggle:hover {
    border-color: var(--gh-primary) !important;
    color: var(--gh-primary) !important;
}

.wb-app .wb-link-form {
    display: flex !important;
    gap: 8px !important;
    margin-top: 8px !important;
    flex-wrap: wrap !important;
}

.wb-app .wb-link-name-input,
.wb-app .wb-link-url-input {
    flex: 1 !important;
    min-width: 120px !important;
    padding: 6px 10px !important;
    border: 1px solid var(--gh-border) !important;
    border-radius: var(--gh-radius-sm) !important;
    font-size: 13px !important;
}

.wb-app .wb-link-url-input {
    flex: 2 !important;
}
