.app-shell {
    transition: opacity 0.18s ease;
}

body[data-app-ready="false"] .app-shell {
    visibility: hidden;
    opacity: 0;
}

body[data-app-ready="true"] .app-shell {
    visibility: visible;
    opacity: 1;
}

.app-loading-screen {
    position: fixed;
    inset: 0;
    z-index: 12000;
    overflow: hidden auto;
    background: var(--gradient-hero);
    transition: opacity 0.18s ease, visibility 0.18s ease;
}

body[data-app-ready="true"] .app-loading-screen {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.app-loading-header {
    padding: 28px 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.app-loading-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.app-loading-hero {
    display: grid;
    justify-items: center;
    gap: 16px;
    padding: 56px 0 0;
}

.skeleton-block {
    position: relative;
    overflow: hidden;
    border-radius: 999px;
    background: rgba(19, 38, 54, 0.72);
    border: 1px solid rgba(110, 154, 186, 0.14);
}

.skeleton-block::after {
    content: "";
    position: absolute;
    inset: 0;
    transform: translateX(-100%);
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.08), transparent);
    animation: skeletonPulse 1.35s ease-in-out infinite;
}

.skeleton-logo {
    width: 220px;
    height: 26px;
}

.skeleton-pill {
    width: 120px;
    height: 42px;
}

.skeleton-circle {
    width: 42px;
    height: 42px;
    border-radius: 50%;
}

.skeleton-kicker {
    width: 148px;
    height: 18px;
}

.skeleton-title {
    height: 56px;
    border-radius: 28px;
}

.skeleton-title-wide {
    width: min(760px, 82vw);
}

.skeleton-title-mid {
    width: min(580px, 66vw);
}

.skeleton-copy {
    width: min(720px, 78vw);
    height: 18px;
}

.skeleton-copy-short {
    width: min(520px, 62vw);
}

.skeleton-search {
    margin-top: 10px;
    width: min(720px, 92vw);
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    border-radius: var(--radius-pill);
    border: 1px solid var(--border-strong);
    background: rgba(7, 17, 26, 0.75);
    box-shadow: var(--shadow-soft);
}

.skeleton-search-input {
    flex: 1;
    height: 44px;
    border-radius: 999px;
}

.skeleton-search-button {
    width: 126px;
    height: 44px;
}

.hero {
    padding: 52px 0 72px;
    text-align: center;
    position: relative;
}

.hero::before {
    content: "";
    position: absolute;
    inset: 0 auto auto 50%;
    width: min(820px, 86vw);
    height: 420px;
    transform: translateX(-50%);
    background: radial-gradient(circle, rgba(34, 199, 168, 0.16), transparent 60%);
    filter: blur(8px);
    pointer-events: none;
}

.hero > * {
    position: relative;
    z-index: 1;
}

.hero-title {
    font-size: clamp(2.8rem, 7vw, 4.9rem);
    font-weight: 800;
    letter-spacing: -0.05em;
    line-height: 0.98;
    max-width: 980px;
    margin: 0 auto 18px;
    animation: fadeInUp 0.65s ease backwards;
}

.hero-subtitle {
    max-width: 760px;
    margin: 0 auto;
    color: var(--text-dim);
    font-size: clamp(1rem, 2vw, 1.16rem);
    animation: fadeInUp 0.65s ease 0.12s backwards;
}

.search-section {
    margin: 34px auto 0;
    max-width: 720px;
    animation: fadeInUp 0.65s ease 0.2s backwards;
}

.search-container {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    border-radius: var(--radius-pill);
    border: 1px solid var(--border-strong);
    background: rgba(7, 17, 26, 0.75);
    box-shadow: var(--shadow-soft);
}

.search-container:focus-within {
    border-color: rgba(34, 199, 168, 0.44);
    box-shadow: 0 0 0 6px rgba(34, 199, 168, 0.08), var(--shadow-soft);
}

.search-input {
    flex: 1;
    background: transparent;
    border: 0;
    color: var(--text);
    font-size: 1.02rem;
    outline: none;
    padding: 0 10px;
}

.search-input::placeholder {
    color: var(--text-faint);
}

.search-button {
    border: 0;
    border-radius: var(--radius-pill);
    padding: 14px 24px;
    background: var(--gradient-accent);
    color: #041018;
    cursor: pointer;
    font-weight: 800;
    white-space: nowrap;
}

.hero-capabilities {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px;
    margin-top: 34px;
    text-align: left;
    animation: fadeInUp 0.65s ease 0.28s backwards;
}

.capability-panel {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(220px, 0.8fr);
    gap: 20px;
    align-items: stretch;
    padding: 24px;
    border-radius: 26px;
    border: 1px solid var(--border);
    background: linear-gradient(180deg, rgba(16, 33, 49, 0.84), rgba(11, 23, 35, 0.96));
    box-shadow: var(--shadow-soft);
}

.capability-copy {
    display: grid;
    gap: 12px;
    align-content: start;
}

.capability-kicker {
    display: inline-flex;
    width: fit-content;
    padding: 6px 10px;
    border-radius: var(--radius-pill);
    background: rgba(77, 163, 255, 0.12);
    color: var(--secondary);
    font-size: 0.72rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.capability-panel h2 {
    font-size: 1.6rem;
    line-height: 1.05;
    letter-spacing: -0.04em;
}

.capability-panel p {
    color: var(--text-dim);
    font-size: 0.96rem;
}

.capability-points {
    display: grid;
    gap: 10px;
    margin: 4px 0 0;
    padding-left: 18px;
    color: var(--text-dim);
}

.capability-points li {
    line-height: 1.5;
}

.capability-points strong {
    color: var(--text);
}

.capability-visual {
    display: grid;
    gap: 12px;
    padding: 16px;
    border-radius: 20px;
    border: 1px solid rgba(110, 154, 186, 0.14);
    background: rgba(7, 17, 26, 0.62);
    align-content: start;
}

.signal-chip {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 14px;
    background: rgba(34, 199, 168, 0.1);
    border: 1px solid rgba(34, 199, 168, 0.14);
}

.signal-grid,
.scan-metrics {
    display: grid;
    gap: 10px;
}

.signal-box {
    display: grid;
    gap: 6px;
    padding: 12px;
    border-radius: 14px;
    background: rgba(19, 38, 54, 0.72);
    border: 1px solid rgba(110, 154, 186, 0.12);
}

.signal-label {
    color: var(--text-faint);
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.signal-value,
.signal-box strong {
    color: var(--text);
    font-size: 0.92rem;
    font-weight: 800;
}

.signal-meta {
    color: var(--text-dim);
    font-size: 0.8rem;
    line-height: 1.4;
}

.features {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
    padding: 24px 0 96px;
}

.feature-card {
    padding: 30px;
    border-radius: 24px;
    min-height: 220px;
}

.feature-card h3 {
    margin-bottom: 14px;
    font-size: 1.32rem;
    color: var(--text);
    letter-spacing: -0.03em;
}

.feature-card p {
    color: var(--text-dim);
}

.result-title {
    font-size: 1.5rem;
    margin-bottom: 18px;
    letter-spacing: -0.03em;
}

.result-body {
    color: var(--text-dim);
    line-height: 1.58;
    font-size: 1rem;
}

.result-body h1,
.result-body h2,
.result-body h3 {
    margin: 22px 0 12px;
    color: var(--text);
    line-height: 1.2;
}

.result-body p,
.result-body ul,
.result-body ol {
    margin-bottom: 14px;
}

.result-body table {
    width: 100%;
    margin: 18px 0 22px;
    border-collapse: collapse;
    border-radius: 16px;
    overflow: hidden;
    background: rgba(7, 17, 26, 0.9);
    border: 1px solid var(--border);
}

.result-body th,
.result-body td {
    padding: 14px 16px;
    text-align: left;
    border-bottom: 1px solid rgba(110, 154, 186, 0.12);
}

.result-body th {
    color: var(--text);
    background: rgba(19, 38, 54, 0.82);
}

.result-body tr:last-child td {
    border-bottom: 0;
}

.result-body .highlight-box,
.portfolio-panel,
.portfolio-summary,
.portfolio-insight,
.portfolio-final {
    padding: 20px;
    border-radius: 18px;
    margin-bottom: 18px;
    border: 1px solid var(--border);
    background: rgba(19, 38, 54, 0.58);
}

.portfolio-final {
    border-left: 4px solid var(--secondary);
}

.portfolio-table-wrap {
    overflow-x: auto;
}

.portfolio-table td.is-buy,
.ticker-val.is-up {
    color: var(--success);
}

.portfolio-table td.is-sell,
.ticker-val.is-down {
    color: var(--danger);
}

.portfolio-table td.is-hold {
    color: var(--warning);
}

.result-disclaimer {
    margin-top: 20px;
    padding: 16px 18px;
    border-radius: 16px;
    border: 1px solid rgba(255, 107, 107, 0.18);
    background: rgba(73, 20, 26, 0.28);
    color: #f2d8d8;
    font-size: 0.9rem;
}

.user-profile-section {
    position: relative;
}

/* Force Horizontal Header Layout on Desktop */
@media (min-width: 901px) {
    header {
        flex-direction: row !important;
        align-items: center !important;
        z-index: 2000 !important; /* Ensure header and its dropdowns are above hero */
    }
    
    .header-right {
        flex-direction: row !important;
        align-items: center !important;
        width: auto !important;
    }

    .header-actions {
        gap: 10px;
    }
}

.user-greeting {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px 8px 8px;
    border-radius: var(--radius-pill);
    border: 1px solid var(--border);
    background: rgba(7, 17, 26, 0.72);
    cursor: pointer;
}

.profile-avatar,
.profile-pic {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: rgba(34, 199, 168, 0.12);
    border: 1px solid rgba(34, 199, 168, 0.24);
    color: var(--text);
    font-weight: 800;
    overflow: hidden;
}

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

.profile-name-short,
.user-name {
    font-weight: 700;
}

.profile-dropdown-overlay {
    position: absolute;
    top: calc(100% + 12px);
    right: 0;
    width: min(420px, calc(100vw - 32px)); /* Ensure it doesn't exceed screen width */
    height: auto;
    display: none;
    z-index: 10000;
    pointer-events: none;
    background: transparent;
    border: none;
    box-shadow: none;
}

.profile-dropdown-overlay.active {
    display: block !important;
    pointer-events: auto !important;
}

@media (max-width: 480px) {
    .profile-dropdown-overlay {
        right: -10px; /* Offset a bit to keep it centered-ish on very small screens if needed */
    }
}

/* Repositioned close button in dropdown context */
#close-profile-modal {
    display: flex !important;
    position: relative;
    top: -4px; /* Slight offset to better align with name baseline */
    right: 0;
    width: 28px;
    height: 28px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid var(--border);
    border-radius: 50%;
    color: var(--text-dim);
    font-size: 18px;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    line-height: 1;
    transition: all 0.2s;
    flex-shrink: 0;
}

#close-profile-modal:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text);
    transform: rotate(90deg);
}

.profile-modal-panel {
    position: relative;
    width: 100%;
    padding: 0;
}

.profile-dropdown-modal,
.profile-dropdown {
    display: block;
    width: 100%;
    min-width: 0;
    margin: 0;
    padding: 22px;
    border-radius: 22px;
    border: 1px solid var(--border-strong);
    background: #0d1c2a;
    background-image: linear-gradient(180deg, rgba(16, 33, 49, 1), rgba(7, 17, 26, 1));
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    animation: fadeInUp 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    isolation: isolate;
}

.profile-header,
.usage-label,
.usage-stats {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.profile-header {
    margin-bottom: 20px;
}

.profile-header-left {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}

.profile-info {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.user-email,
.usage-stats,
.history-card-date,
.history-card-query {
    color: var(--text-faint);
}

.dropdown-menu {
    display: grid;
    gap: 10px;
}

.menu-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    border-radius: 14px;
    text-decoration: none;
    color: var(--text-dim);
}

.menu-item:hover {
    background: rgba(34, 199, 168, 0.08);
    color: var(--text);
}

.menu-item.logout:hover {
    background: rgba(255, 107, 107, 0.08);
}

.usage-info-row {
    display: grid;
    gap: 12px;
}

.usage-tier {
    padding: 4px 10px;
    border-radius: var(--radius-pill);
    background: rgba(77, 163, 255, 0.14);
    color: var(--secondary);
    font-size: 0.82rem;
    font-weight: 700;
    text-transform: uppercase;
}

.usage-progress-container {
    width: 100%;
    height: 10px;
    border-radius: var(--radius-pill);
    background: rgba(255, 255, 255, 0.06);
    overflow: hidden;
}

.usage-progress-bar {
    width: 0;
    height: 100%;
    border-radius: inherit;
    background: var(--primary);
}

.history-list {
    display: grid;
    gap: 16px;
    margin-top: 24px;
}

.history-card {
    padding: 22px;
    border-radius: 20px;
    cursor: pointer;
}

.history-card:hover,
.feature-card:hover,
.blog-card:hover,
.action-card:hover {
    transform: translateY(-3px);
    border-color: rgba(34, 199, 168, 0.3);
}

.history-card-header,
.history-card-footer {
    display: flex;
    justify-content: space-between;
    gap: 12px;
}

.history-card-header {
    margin-bottom: 10px;
}

.history-card-ticker {
    font-weight: 800;
    color: var(--text);
}

.view-indicator {
    color: var(--secondary);
    font-weight: 700;
    font-size: 0.92rem;
}

.admin-table-container {
    margin-top: 22px;
    overflow-x: auto;
}

.admin-table {
    width: 100%;
    min-width: 780px;
    border-collapse: collapse;
}

.admin-table th,
.admin-table td {
    padding: 16px 12px;
    border-bottom: 1px solid var(--border);
    text-align: left;
    vertical-align: middle;
}

.admin-table th {
    color: var(--text);
    font-size: 0.9rem;
}

.admin-table td {
    color: var(--text-dim);
}

.tier-badge {
    display: inline-flex;
    padding: 5px 10px;
    border-radius: var(--radius-pill);
    font-size: 0.76rem;
    font-weight: 800;
    text-transform: uppercase;
}

.tier-owner {
    background: rgba(77, 163, 255, 0.16);
    color: var(--secondary);
}

.tier-admin {
    background: rgba(34, 199, 168, 0.16);
    color: var(--primary);
}

.tier-plus {
    background: rgba(245, 185, 64, 0.16);
    color: var(--warning);
}

.tier-trial {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-dim);
}

.tier-select,
.admin-search-bar {
    border: 1px solid var(--border);
    border-radius: 14px;
    background: rgba(7, 17, 26, 0.82);
    color: var(--text);
}

.tier-select {
    padding: 10px 12px;
}

.admin-search-bar {
    min-width: 260px;
    padding: 12px 14px;
}

.owner-action-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
    margin-top: 24px;
}

.action-card {
    display: grid;
    gap: 12px;
    place-items: start;
    padding: 24px;
    border-radius: 22px;
    cursor: pointer;
}

.action-card.loading {
    opacity: 0.75;
}

.owner-log-modal {
    width: min(1180px, 100%);
}

.owner-log-header h2 {
    margin: 0;
    color: var(--primary);
}

.owner-log-header p {
    margin: 10px 0 0;
    color: var(--text-faint);
}

.owner-log-toolbar {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 16px;
    margin-top: 24px;
}

.owner-log-field {
    display: grid;
    gap: 8px;
    min-width: min(280px, 100%);
}

.owner-log-field span {
    color: var(--text-faint);
    font-size: 0.9rem;
    font-weight: 700;
}

.owner-log-field input {
    width: min(320px, 100%);
    padding: 12px 14px;
    border-radius: 14px;
    border: 1px solid var(--border);
    background: rgba(6, 13, 22, 0.92);
    color: var(--text);
}

.owner-log-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.owner-log-status {
    margin-top: 18px;
    color: var(--text-faint);
    font-size: 0.9rem;
}

.owner-log-viewer {
    margin-top: 16px;
    min-height: 420px;
    max-height: 60vh;
    overflow: auto;
    padding: 18px;
    border-radius: 18px;
    border: 1px solid var(--border);
    background:
        linear-gradient(180deg, rgba(7, 16, 27, 0.98) 0%, rgba(5, 12, 21, 0.98) 100%);
    color: #d6f3ee;
    font-family: Consolas, "SFMono-Regular", Menlo, Monaco, monospace;
    font-size: 0.85rem;
    line-height: 1.55;
    white-space: pre-wrap;
    word-break: break-word;
}

.action-icon {
    font-size: 1.8rem;
}

.action-title {
    font-size: 1.1rem;
    font-weight: 800;
}

.ticker-wrap {
    margin-top: 26px;
    padding: 8px 0;
    border-radius: 14px;
    border: 1px solid var(--border);
    background: linear-gradient(180deg, rgba(7, 17, 26, 0.92), rgba(11, 23, 35, 0.88));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
    overflow: hidden;
    animation: fadeInUp 0.65s ease 0.24s backwards;
}

.ticker {
    display: flex;
    width: max-content;
    min-width: 100%;
    gap: 0;
    align-items: center;
    padding: 0 14px;
    animation: tickerMarquee var(--ticker-duration, 38s) linear infinite;
    will-change: transform;
}

.ticker-item {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    gap: 14px;
    min-width: max-content;
    padding: 8px 18px;
    border-right: 1px solid rgba(110, 154, 186, 0.16);
    background: transparent;
}

.ticker-item.is-watch {
    border-right-color: rgba(77, 163, 255, 0.2);
}

.ticker-item:last-child {
    border-right: 0;
}

.ticker-tag {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    padding: 3px 8px;
    border-radius: 8px;
    background: rgba(34, 199, 168, 0.1);
    color: var(--primary);
    font-size: 0.64rem;
    font-weight: 800;
    letter-spacing: 0.08em;
}

.ticker-item.is-watch .ticker-tag,
.ticker-item.is-watch .ticker-symbol {
    color: var(--secondary);
}

.ticker-symbol {
    display: inline-flex;
    align-items: center;
    margin: 0;
    font-size: 0.94rem;
    font-weight: 800;
    color: var(--text);
    letter-spacing: 0.03em;
}

.ticker-signals {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.ticker-signal {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding-left: 8px;
    border-left: 1px solid rgba(110, 154, 186, 0.12);
    color: var(--text-dim);
    font-size: 0.76rem;
    white-space: nowrap;
}

.ticker-label-text {
    color: var(--text-faint);
    font-size: 0.68rem;
    letter-spacing: 0.08em;
}

.ticker-val {
    color: var(--text);
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}

.ticker-val-target {
    color: var(--success);
}

.ticker-wrap:hover .ticker {
    animation-play-state: paused;
}

@keyframes tickerMarquee {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(calc(var(--ticker-shift, -50%) * -1));
    }
}

.insights-section {
    padding: 0 0 28px;
}

.section-header {
    display: grid;
    gap: 10px;
    margin-bottom: 24px;
}

.section-tag {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    padding: 6px 12px;
    border-radius: var(--radius-pill);
    background: rgba(77, 163, 255, 0.14);
    color: var(--secondary);
    font-size: 0.82rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.section-title {
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    letter-spacing: -0.04em;
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px;
}

.blog-card {
    display: grid;
    overflow: hidden;
    border-radius: 24px;
}

.blog-thumb {
    aspect-ratio: 16 / 9;
    overflow: hidden;
}

.blog-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.28s ease;
}

.blog-card:hover .blog-thumb img {
    transform: scale(1.04);
}

.blog-content {
    display: grid;
    gap: 14px;
    padding: 24px;
}

.blog-category {
    color: var(--secondary);
    font-size: 0.8rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.blog-title {
    font-size: 1.22rem;
    letter-spacing: -0.03em;
    line-height: 1.25;
}

.blog-excerpt {
    color: var(--text-dim);
}

.blog-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--primary);
    font-weight: 800;
    text-decoration: none;
}

@media (max-width: 1024px) {
    .features,
    .blog-grid,
    .owner-action-grid,
    .hero-capabilities {
        grid-template-columns: 1fr;
    }

    .owner-log-toolbar {
        flex-direction: column;
        align-items: stretch;
    }

    .owner-log-field input {
        width: 100%;
    }

    .owner-log-actions {
        justify-content: flex-end;
    }
}

@media (max-width: 768px) {
    .app-loading-header {
        padding-top: 18px;
        padding-bottom: 8px;
    }

    .app-loading-hero {
        gap: 12px;
        padding-top: 44px;
    }

    .skeleton-logo {
        width: 176px;
        height: 22px;
    }

    .skeleton-pill,
    .skeleton-circle {
        height: 38px;
    }

    .skeleton-pill {
        width: 92px;
    }

    .skeleton-circle {
        width: 38px;
    }

    .skeleton-title {
        height: 42px;
    }

    .skeleton-title-wide,
    .skeleton-title-mid,
    .skeleton-copy,
    .skeleton-copy-short {
        width: min(100%, 92vw);
    }

    .skeleton-search {
        width: 100%;
        gap: 10px;
        padding: 8px;
    }

    .skeleton-search-button {
        width: 92px;
    }

    .hero {
        padding-top: 16px;
    }

    .user-profile-section {
        margin-top: 0;
    }

    .header-language-slot {
        margin-left: auto;
    }

    .user-greeting {
        padding: 5px 10px 5px 6px;
    }

    .search-container {
        flex-direction: column;
        border-radius: 26px;
    }

    .search-input,
    .search-button {
        width: 100%;
    }

    .capability-panel {
        grid-template-columns: 1fr;
        padding: 20px;
    }

    .ticker {
        animation-duration: 30s;
    }

    .ticker-item {
        gap: 10px;
        padding: 8px 14px;
    }

    .ticker-signals {
        gap: 8px;
    }

    .admin-search-bar {
        min-width: 0;
        width: 100%;
    }

    .console-header {
        flex-direction: column;
        align-items: stretch;
    }

    .profile-modal-panel {
        width: 100%;
        padding: 12px;
    }

    .result-body table,
    .portfolio-table {
        display: block;
        overflow-x: auto;
    }
}

@media (max-width: 640px) {
    .user-profile-section {
        margin-bottom: 0;
    }

    .header-actions {
        gap: 6px;
    }

    #user-auth-portal .cta-button,
    #login-nav-btn {
        min-height: 42px;
        padding: 4px 14px;
        font-size: 0.92rem;
        line-height: 1;
        box-shadow: 0 10px 20px rgba(25, 184, 154, 0.16);
    }

    .header-language-slot {
        position: static;
        top: auto;
        margin-right: 0;
    }

    .user-greeting {
        gap: 6px;
        padding: 4px 8px 4px 4px;
    }

    .profile-avatar,
    .profile-pic {
        width: 34px;
        height: 34px;
    }

    .profile-name-short {
        font-size: 0.92rem;
    }
}

@keyframes skeletonPulse {
    100% {
        transform: translateX(100%);
    }
}
