/* ==========================================================================
   FEATURE CARD ANIMATIONS
   Stripe-inspired looping CSS animations for homepage feature cards.
   All durations use calc(Xs * var(--speed)) for hover acceleration.
   ========================================================================== */


/* ── @property registration ── */

@property --speed {
    syntax: '<number>';
    inherits: true;
    initial-value: 1;
}


/* ── Shared rules ── */

.feature-card[data-card] {
    --speed: 1;
    transition: --speed 0.3s ease;
}

.feature-card[data-card].is-hovering {
    --speed: 0.4;
}

.feature-card.is-offscreen .feature-card-preview * {
    animation-play-state: paused !important;
}

html.touch-device .feature-card[data-card] {
    --speed: 1 !important;
}

/* Preview area — flex container for animated content */
.feature-card[data-card] .feature-card-preview {
    display: flex;
    align-items: stretch;
    overflow: hidden;
    padding: 8px 12px 0;
}

/* Shared animated element base */
.fc-counter {
    font-variant-numeric: tabular-nums;
}


/* ── Gradient backgrounds ── */

[data-card="portfolio"] .feature-card-frame {
    background: linear-gradient(135deg, rgba(77,190,190,0.15) 0%, rgba(77,190,190,0.25) 50%, rgba(81,138,200,0.12) 100%);
}
[data-card="portfolio"]:hover .feature-card-frame {
    background: linear-gradient(135deg, rgba(77,190,190,0.23) 0%, rgba(77,190,190,0.33) 50%, rgba(81,138,200,0.20) 100%);
}

[data-card="debt"] .feature-card-frame {
    background: linear-gradient(135deg, rgba(81,138,200,0.15) 0%, rgba(123,97,255,0.22) 100%);
}
[data-card="debt"]:hover .feature-card-frame {
    background: linear-gradient(135deg, rgba(81,138,200,0.23) 0%, rgba(123,97,255,0.30) 100%);
}

[data-card="waterfall"] .feature-card-frame {
    background: linear-gradient(135deg, rgba(77,190,190,0.12) 0%, rgba(77,190,190,0.22) 100%);
}
[data-card="waterfall"]:hover .feature-card-frame {
    background: linear-gradient(135deg, rgba(77,190,190,0.20) 0%, rgba(77,190,190,0.30) 100%);
}

[data-card="ai"] .feature-card-frame {
    background: linear-gradient(135deg, rgba(123,97,255,0.15) 0%, rgba(123,97,255,0.25) 50%, rgba(81,138,200,0.12) 100%);
}
[data-card="ai"]:hover .feature-card-frame {
    background: linear-gradient(135deg, rgba(123,97,255,0.23) 0%, rgba(123,97,255,0.33) 50%, rgba(81,138,200,0.20) 100%);
}

[data-card="ledgers"] .feature-card-frame {
    background: linear-gradient(135deg, rgba(81,138,200,0.12) 0%, rgba(81,138,200,0.22) 100%);
}
[data-card="ledgers"]:hover .feature-card-frame {
    background: linear-gradient(135deg, rgba(81,138,200,0.20) 0%, rgba(81,138,200,0.30) 100%);
}

[data-card="projects"] .feature-card-frame {
    background: linear-gradient(135deg, rgba(77,190,190,0.12) 0%, rgba(77,190,190,0.22) 100%);
}
[data-card="projects"]:hover .feature-card-frame {
    background: linear-gradient(135deg, rgba(77,190,190,0.20) 0%, rgba(77,190,190,0.30) 100%);
}

[data-card="reporting"] .feature-card-frame {
    background: linear-gradient(135deg, rgba(81,138,200,0.12) 0%, rgba(123,97,255,0.20) 100%);
}
[data-card="reporting"]:hover .feature-card-frame {
    background: linear-gradient(135deg, rgba(81,138,200,0.20) 0%, rgba(123,97,255,0.28) 100%);
}


/* ==========================================================================
   CARD 1: PORTFOLIO — "Living Dashboard"
   4 property mini-cards slide in, bars fill, NOI counts, top card lifts.
   10s loop.
   ========================================================================== */

.fc-portfolio {
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 100%;
    padding: 4px;
}

.fc-prop {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    background: rgba(255,255,255,0.75);
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.5);
    backdrop-filter: blur(4px);
    animation: fc-prop-slide calc(10s * var(--speed)) ease-out infinite;
    animation-delay: calc(var(--i, 0) * 0.3s * var(--speed));
    animation-fill-mode: both;
}

.fc-prop:first-child {
    animation-name: fc-prop-slide-lift;
}

.fc-prop-name {
    font-size: 12px;
    font-weight: 600;
    color: var(--m-navy);
    white-space: nowrap;
    min-width: 100px;
}

.fc-prop-bar {
    flex: 1;
    height: 6px;
    background: rgba(77,190,190,0.12);
    border-radius: 3px;
    overflow: hidden;
}

.fc-prop-fill {
    height: 100%;
    background: var(--m-teal);
    border-radius: 3px;
    transform: scaleX(0);
    transform-origin: left;
    animation: fc-bar-fill calc(10s * var(--speed)) ease-out infinite;
    animation-delay: calc((var(--i, 0) * 0.3 + 2) * 1s * var(--speed));
    animation-fill-mode: both;
}

.fc-prop-val {
    font-size: 13px;
    font-weight: 700;
    color: var(--m-navy);
    white-space: nowrap;
    min-width: 44px;
    text-align: right;
}

@keyframes fc-prop-slide {
    0%, 100% { opacity: 0.35; transform: none; }
    10% { opacity: 1; transform: none; }
    80% { opacity: 1; transform: none; }
    90% { opacity: 0.35; transform: none; }
}

@keyframes fc-prop-slide-lift {
    0%, 100% { opacity: 0.35; transform: none; }
    10% { opacity: 1; transform: none; }
    40% { transform: translate(0, 0); box-shadow: none; }
    50% { transform: translate(0, -4px); box-shadow: 0 8px 24px rgba(0,0,0,0.08); }
    65% { transform: translate(0, -4px); box-shadow: 0 8px 24px rgba(0,0,0,0.08); }
    72% { transform: translate(0, 0); box-shadow: none; }
    80% { opacity: 1; transform: translate(0, 0); }
    90% { opacity: 0.35; transform: none; }
}

@keyframes fc-bar-fill {
    0%, 5% { transform: scaleX(0); }
    20% { transform: scaleX(var(--target, 1)); }
    65% { transform: scaleX(var(--target, 1)); }
    78%, 100% { transform: scaleX(0); }
}


/* ==========================================================================
   CARD 2: DEBT — "Amortization Draw-Down"
   6 vertical bars shrink, SVG lines draw, DSCR gauge fills.
   8s loop.
   ========================================================================== */

.fc-debt {
    display: flex;
    width: 100%;
    gap: 16px;
    align-items: flex-end;
    padding: 8px 4px 0;
}

.fc-debt-bars {
    display: flex;
    align-items: flex-end;
    gap: 6px;
    flex: 1;
    height: 100%;
    padding-bottom: 8px;
}

.fc-debt-bar {
    flex: 1;
    height: 100%;
    background: linear-gradient(180deg, var(--m-blue) 0%, rgba(81,138,200,0.4) 100%);
    border-radius: 3px 3px 0 0;
    transform: scaleY(0);
    transform-origin: bottom;
    animation: fc-debt-grow calc(8s * var(--speed)) ease-out infinite;
    animation-delay: calc(var(--i, 0) * 0.15s * var(--speed));
    animation-fill-mode: both;
}

.fc-debt-gauge {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
}

.fc-debt-gauge svg {
    width: 56px;
    height: 56px;
}

.fc-dscr-track {
    fill: none;
    stroke: rgba(81,138,200,0.15);
    stroke-width: 4;
}

.fc-dscr-fill {
    fill: none;
    stroke: var(--m-blue);
    stroke-width: 4;
    stroke-linecap: round;
    stroke-dasharray: 113;
    stroke-dashoffset: 113;
    animation: fc-dscr-draw calc(8s * var(--speed)) ease-out infinite;
    animation-delay: calc(1.5s * var(--speed));
    animation-fill-mode: both;
}

.fc-debt-gauge-label {
    font-size: 10px;
    font-weight: 600;
    color: var(--m-text-light);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.fc-debt-gauge-val {
    font-size: 18px;
    font-weight: 700;
    color: var(--m-navy);
}

@keyframes fc-debt-grow {
    0%, 5% { transform: scaleY(0.08); }
    25% { transform: scaleY(var(--h, 0.5)); }
    65% { transform: scaleY(var(--h, 0.5)); }
    80%, 100% { transform: scaleY(0.08); }
}

@keyframes fc-dscr-draw {
    0%, 5% { stroke-dashoffset: 113; }
    30% { stroke-dashoffset: calc(113 - 113 * 0.71); }
    65% { stroke-dashoffset: calc(113 - 113 * 0.71); }
    80%, 100% { stroke-dashoffset: 113; }
}


/* ==========================================================================
   CARD 3: WATERFALL — "Capital Waterfall"
   Source amount counts, stream flows, 3 tiers fill.
   9s loop.
   ========================================================================== */

.fc-waterfall {
    display: flex;
    flex-direction: column;
    width: 100%;
    gap: 0;
    padding: 4px;
}

.fc-wf-source {
    text-align: center;
    padding: 8px 0;
    opacity: 0;
    animation: fc-wf-fade calc(9s * var(--speed)) ease-out infinite;
    animation-fill-mode: both;
}

.fc-wf-source-amount {
    font-size: 20px;
    font-weight: 700;
    color: var(--m-navy);
}

.fc-wf-source-label {
    font-size: 11px;
    font-weight: 500;
    color: var(--m-text-light);
    margin-top: 2px;
}

.fc-wf-stream {
    width: 2px;
    height: 24px;
    margin: 0 auto;
    background: linear-gradient(180deg, var(--m-teal) 0%, rgba(77,190,190,0.2) 100%);
    background-size: 100% 200%;
    animation: fc-wf-flow calc(9s * var(--speed)) ease-out infinite;
    animation-fill-mode: both;
}

.fc-wf-tiers {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.fc-wf-tier {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    background: rgba(255,255,255,0.6);
    border-radius: 6px;
    border: 1px solid rgba(77,190,190,0.15);
    opacity: 0;
    animation: fc-wf-tier-in calc(9s * var(--speed)) ease-out infinite;
    animation-delay: calc((var(--i, 0) * 0.4 + 2) * 1s * var(--speed));
    animation-fill-mode: both;
}

.fc-wf-tier-name {
    font-size: 11px;
    font-weight: 600;
    color: var(--m-text-light);
    min-width: 70px;
}

.fc-wf-tier-bar {
    flex: 1;
    height: 6px;
    background: rgba(77,190,190,0.12);
    border-radius: 3px;
    overflow: hidden;
}

.fc-wf-tier-fill {
    height: 100%;
    background: var(--m-teal);
    border-radius: 3px;
    transform: scaleX(0);
    transform-origin: left;
    animation: fc-wf-bar calc(9s * var(--speed)) ease-out infinite;
    animation-delay: calc((var(--i, 0) * 0.4 + 2.5) * 1s * var(--speed));
    animation-fill-mode: both;
}

.fc-wf-tier-val {
    font-size: 12px;
    font-weight: 700;
    color: var(--m-navy);
    min-width: 40px;
    text-align: right;
}

@keyframes fc-wf-fade {
    0%, 100% { opacity: 0.35; transform: none; }
    8% { opacity: 1; transform: none; }
    78% { opacity: 1; transform: none; }
    88% { opacity: 0.35; transform: none; }
}

@keyframes fc-wf-flow {
    0%, 8% { opacity: 0.35; background-position: 0 0; }
    15% { opacity: 1; }
    78% { opacity: 1; }
    88%, 100% { opacity: 0.35; background-position: 0 -200%; }
}

@keyframes fc-wf-tier-in {
    0%, 100% { opacity: 0.35; transform: none; }
    12% { opacity: 1; transform: none; }
    72% { opacity: 1; }
    84% { opacity: 0.35; }
}

@keyframes fc-wf-bar {
    0%, 8% { transform: scaleX(0); }
    25% { transform: scaleX(var(--target, 1)); }
    65% { transform: scaleX(var(--target, 1)); }
    80%, 100% { transform: scaleX(0); }
}


/* ==========================================================================
   CARD 4: AI — "Document to Insight"
   Doc lines appear, highlights pulse, particles flow, data points appear,
   chat question fades in, typing dots, response reveals.
   12s loop.
   ========================================================================== */

.fc-ai {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    grid-template-rows: 1fr auto;
    gap: 8px;
    width: 100%;
    padding: 4px;
    min-height: 0;
}

/* Document */
.fc-ai-doc {
    display: flex;
    flex-direction: column;
    gap: 5px;
    padding: 10px;
    background: rgba(255,255,255,0.7);
    border-radius: 6px;
    border: 1px solid rgba(123,97,255,0.12);
}

.fc-ai-line {
    height: 4px;
    border-radius: 2px;
    background: rgba(10,37,64,0.08);
    opacity: 0;
    animation: fc-ai-line-in calc(12s * var(--speed)) ease-out infinite;
    animation-delay: calc(var(--i, 0) * 0.15s * var(--speed));
    animation-fill-mode: both;
}

.fc-ai-line.is-highlight {
    animation-name: fc-ai-highlight;
}

/* Beam / particles */
.fc-ai-beam {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 0 4px;
    min-width: 24px;
}

.fc-ai-particle {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--m-purple);
    opacity: 0;
    animation: fc-ai-particle calc(12s * var(--speed)) ease-in-out infinite;
    animation-delay: calc((var(--i, 0) * 0.3 + 3) * 1s * var(--speed));
    animation-fill-mode: both;
}

/* Data points */
.fc-ai-data {
    display: flex;
    flex-direction: column;
    gap: 6px;
    justify-content: center;
}

.fc-ai-point {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 8px;
    background: rgba(255,255,255,0.7);
    border-radius: 4px;
    border: 1px solid rgba(123,97,255,0.12);
    font-size: 10px;
    font-weight: 600;
    color: var(--m-navy);
    white-space: nowrap;
    opacity: 0;
    animation: fc-ai-data-in calc(12s * var(--speed)) ease-out infinite;
    animation-delay: calc((var(--i, 0) * 0.5 + 4) * 1s * var(--speed));
    animation-fill-mode: both;
}

.fc-ai-point-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--m-purple);
    flex-shrink: 0;
}

/* Chat */
.fc-ai-chat {
    grid-column: 1 / -1;
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 0 2px;
}

.fc-ai-q {
    align-self: flex-end;
    max-width: 75%;
    padding: 6px 10px;
    border-radius: 8px 8px 2px 8px;
    background: var(--m-purple);
    color: white;
    font-size: 10px;
    line-height: 1.4;
    opacity: 0;
    animation: fc-ai-chat-in calc(12s * var(--speed)) ease-out infinite;
    animation-delay: calc(6s * var(--speed));
    animation-fill-mode: both;
}

.fc-ai-a {
    align-self: flex-start;
    max-width: 80%;
    padding: 6px 10px;
    border-radius: 8px 8px 8px 2px;
    background: rgba(255,255,255,0.8);
    border: 1px solid rgba(123,97,255,0.12);
    font-size: 10px;
    line-height: 1.4;
    color: var(--m-text);
    opacity: 0;
    animation: fc-ai-chat-in calc(12s * var(--speed)) ease-out infinite;
    animation-delay: calc(7s * var(--speed));
    animation-fill-mode: both;
    min-height: 18px;
}

.fc-ai-dots {
    display: inline-flex;
    gap: 3px;
}

.fc-ai-dots span {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--m-text-light);
    animation: fc-ai-bounce 0.6s ease-in-out infinite;
}

.fc-ai-dots span:nth-child(2) { animation-delay: 0.1s; }
.fc-ai-dots span:nth-child(3) { animation-delay: 0.2s; }

@keyframes fc-ai-line-in {
    0%, 100% { opacity: 0.35; transform: none; }
    8% { opacity: 1; transform: none; }
    82% { opacity: 1; }
    92% { opacity: 0.35; }
}

@keyframes fc-ai-highlight {
    0%, 100% { opacity: 0.35; transform: none; background: rgba(10,37,64,0.08); }
    8% { opacity: 1; transform: none; }
    18% { background: rgba(10,37,64,0.08); }
    25% { background: rgba(77,190,190,0.25); }
    40% { background: rgba(77,190,190,0.25); }
    50% { background: rgba(77,190,190,0.12); }
    82% { opacity: 1; }
    92% { opacity: 0.35; }
}

@keyframes fc-ai-particle {
    0%, 5% { opacity: 0; transform: translateX(-12px); }
    15% { opacity: 0.8; }
    30% { opacity: 0; transform: translateX(12px); }
    100% { opacity: 0; transform: translateX(12px); }
}

@keyframes fc-ai-data-in {
    0%, 100% { opacity: 0.3; transform: none; }
    10% { opacity: 1; transform: none; }
    68% { opacity: 1; }
    80% { opacity: 0.3; }
}

@keyframes fc-ai-chat-in {
    0%, 100% { opacity: 0.25; transform: none; }
    6% { opacity: 1; transform: none; }
    72% { opacity: 1; }
    84% { opacity: 0.25; }
}

@keyframes fc-ai-bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-3px); }
}


/* ==========================================================================
   CARD 5: LEDGERS — "Sync Pulse"
   Two columns (Proforma / Actuals) with bars and SVG pulse lines.
   7s loop.
   ========================================================================== */

.fc-ledgers {
    display: flex;
    width: 100%;
    gap: 0;
    padding: 4px;
}

.fc-ledger-col {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.fc-ledger-label {
    font-size: 10px;
    font-weight: 600;
    color: var(--m-text-light);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    text-align: center;
    padding-bottom: 4px;
    border-bottom: 1px solid rgba(81,138,200,0.12);
}

.fc-ledger-row {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0 8px;
}

.fc-ledger-bar {
    flex: 1;
    height: 8px;
    border-radius: 4px;
    overflow: hidden;
}

.fc-ledger-bar-inner {
    height: 100%;
    border-radius: 4px;
    transform: scaleX(0);
    transform-origin: left;
    animation-fill-mode: both;
}

/* Proforma bars */
.fc-ledger-col:first-child .fc-ledger-bar {
    background: rgba(81,138,200,0.10);
}
.fc-ledger-col:first-child .fc-ledger-bar-inner {
    background: var(--m-blue);
    animation: fc-ledger-fill calc(7s * var(--speed)) ease-out infinite;
    animation-delay: calc(var(--i, 0) * 0.25s * var(--speed));
}

/* Actuals bars */
.fc-ledger-col:last-child .fc-ledger-bar {
    background: rgba(77,190,190,0.10);
}
.fc-ledger-col:last-child .fc-ledger-bar-inner {
    background: var(--m-teal);
    animation: fc-ledger-fill calc(7s * var(--speed)) ease-out infinite;
    animation-delay: calc((var(--i, 0) * 0.25 + 1) * 1s * var(--speed));
}

/* Pulse connector in the middle */
.fc-ledger-pulse {
    width: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding-top: 20px;
}

.fc-pulse-dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--m-teal);
    opacity: 0;
    animation: fc-pulse-blink calc(7s * var(--speed)) ease-in-out infinite;
    animation-delay: calc((var(--i, 0) * 0.3 + 2.5) * 1s * var(--speed));
    animation-fill-mode: both;
}

/* Actuals variance indicator */
.fc-ledger-flag {
    font-size: 10px;
    font-weight: 700;
    opacity: 0;
    animation: fc-ledger-flag-in calc(7s * var(--speed)) ease-out infinite;
    animation-delay: calc((var(--i, 0) * 0.3 + 3) * 1s * var(--speed));
    animation-fill-mode: both;
}
.fc-ledger-flag.is-pos { color: var(--m-teal); }
.fc-ledger-flag.is-neg { color: #c0392b; }

@keyframes fc-ledger-fill {
    0%, 8% { transform: scaleX(0.06); }
    28% { transform: scaleX(var(--target, 0.8)); }
    65% { transform: scaleX(var(--target, 0.8)); }
    80%, 100% { transform: scaleX(0.06); }
}

@keyframes fc-pulse-blink {
    0% { opacity: 0; transform: scale(0); }
    10% { opacity: 1; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.2); }
    60% { opacity: 1; transform: scale(1); }
    75% { opacity: 1; }
    88%, 100% { opacity: 0; transform: scale(0); }
}

@keyframes fc-ledger-flag-in {
    0%, 100% { opacity: 0.3; }
    12% { opacity: 1; }
    70% { opacity: 1; }
    85% { opacity: 0.3; }
}


/* ==========================================================================
   CARD 6: PROJECTS — "Timeline Build"
   3 Gantt bars draw L→R, today line pulses, budget meter fills.
   8s loop.
   ========================================================================== */

.fc-projects {
    display: flex;
    width: 100%;
    gap: 12px;
    align-items: stretch;
    padding: 4px;
}

.fc-gantt {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 10px;
    justify-content: center;
    position: relative;
}

.fc-gantt-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.fc-gantt-label {
    font-size: 10px;
    font-weight: 600;
    color: var(--m-text-light);
    min-width: 56px;
    white-space: nowrap;
}

.fc-gantt-track {
    flex: 1;
    height: 10px;
    background: rgba(77,190,190,0.08);
    border-radius: 5px;
    overflow: hidden;
    position: relative;
}

.fc-gantt-fill {
    position: absolute;
    top: 0;
    left: var(--start, 0%);
    width: var(--width, 60%);
    height: 100%;
    background: var(--m-teal);
    border-radius: 5px;
    transform: scaleX(0);
    transform-origin: left;
    animation: fc-gantt-draw calc(8s * var(--speed)) ease-out infinite;
    animation-delay: calc(var(--i, 0) * 0.4s * var(--speed));
    animation-fill-mode: both;
}

/* Today line */
.fc-gantt-today {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 65%;
    width: 2px;
    background: var(--m-navy);
    opacity: 0;
    animation: fc-gantt-today-in calc(8s * var(--speed)) ease-out infinite;
    animation-delay: calc(1.5s * var(--speed));
    animation-fill-mode: both;
}

.fc-gantt-today::after {
    content: 'Today';
    position: absolute;
    top: -14px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 8px;
    font-weight: 600;
    color: var(--m-navy);
    white-space: nowrap;
}

/* Budget gauge */
.fc-budget {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    flex-shrink: 0;
    width: 64px;
}

.fc-budget svg {
    width: 52px;
    height: 52px;
}

.fc-budget-track {
    fill: none;
    stroke: rgba(77,190,190,0.12);
    stroke-width: 4;
}

.fc-budget-fill {
    fill: none;
    stroke: var(--m-teal);
    stroke-width: 4;
    stroke-linecap: round;
    stroke-dasharray: 113;
    stroke-dashoffset: 113;
    animation: fc-budget-draw calc(8s * var(--speed)) ease-out infinite;
    animation-delay: calc(2s * var(--speed));
    animation-fill-mode: both;
}

.fc-budget-label {
    font-size: 10px;
    font-weight: 600;
    color: var(--m-text-light);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.fc-budget-val {
    font-size: 16px;
    font-weight: 700;
    color: var(--m-navy);
}

@keyframes fc-gantt-draw {
    0%, 8% { transform: scaleX(0.06); }
    30% { transform: scaleX(1); }
    65% { transform: scaleX(1); }
    80%, 100% { transform: scaleX(0.06); }
}

@keyframes fc-gantt-today-in {
    0%, 100% { opacity: 0.15; }
    15% { opacity: 0.7; }
    55% { opacity: 0.7; }
    60% { opacity: 1; }
    65% { opacity: 0.7; }
    70% { opacity: 1; }
    75% { opacity: 0.7; }
    85% { opacity: 0.15; }
}

@keyframes fc-budget-draw {
    0%, 8% { stroke-dashoffset: calc(113 - 113 * 0.05); }
    30% { stroke-dashoffset: calc(113 - 113 * 0.73); }
    65% { stroke-dashoffset: calc(113 - 113 * 0.73); }
    80%, 100% { stroke-dashoffset: calc(113 - 113 * 0.05); }
}


/* ==========================================================================
   CARD 7: REPORTING — "Report Assembly"
   Page outline fades in, SVG line chart draws, bars rise, rows appear.
   8s loop.
   ========================================================================== */

.fc-report {
    width: 100%;
    padding: 8px;
    display: flex;
    justify-content: center;
}

.fc-report-page {
    width: 100%;
    max-width: 220px;
    padding: 12px;
    background: rgba(255,255,255,0.8);
    border-radius: 6px;
    border: 1px solid rgba(81,138,200,0.15);
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
    display: flex;
    flex-direction: column;
    gap: 8px;
    opacity: 0;
    animation: fc-report-page-in calc(8s * var(--speed)) ease-out infinite;
    animation-fill-mode: both;
}

/* SVG line chart */
.fc-report-chart {
    width: 100%;
    height: 48px;
}

.fc-report-line {
    fill: none;
    stroke: var(--m-blue);
    stroke-width: 2;
    stroke-linecap: round;
    stroke-dasharray: 300;
    stroke-dashoffset: 300;
    animation: fc-report-draw calc(8s * var(--speed)) ease-out infinite;
    animation-delay: calc(1s * var(--speed));
    animation-fill-mode: both;
}

.fc-report-area {
    fill: rgba(81,138,200,0.08);
    opacity: 0;
    animation: fc-report-area-in calc(8s * var(--speed)) ease-out infinite;
    animation-delay: calc(2s * var(--speed));
    animation-fill-mode: both;
}

/* Bar chart */
.fc-report-bars {
    display: flex;
    align-items: flex-end;
    gap: 4px;
    height: 32px;
}

.fc-report-bar {
    flex: 1;
    height: 100%;
    border-radius: 2px 2px 0 0;
    transform: scaleY(0);
    transform-origin: bottom;
    animation: fc-report-bar-rise calc(8s * var(--speed)) ease-out infinite;
    animation-delay: calc((var(--i, 0) * 0.15 + 2) * 1s * var(--speed));
    animation-fill-mode: both;
}

.fc-report-bar:nth-child(odd) { background: var(--m-blue); }
.fc-report-bar:nth-child(even) { background: rgba(81,138,200,0.4); }

/* Table rows */
.fc-report-rows {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.fc-report-row {
    height: 4px;
    border-radius: 2px;
    background: rgba(10,37,64,0.06);
    opacity: 0;
    animation: fc-report-row-in calc(8s * var(--speed)) ease-out infinite;
    animation-delay: calc((var(--i, 0) * 0.2 + 3) * 1s * var(--speed));
    animation-fill-mode: both;
}

@keyframes fc-report-page-in {
    0%, 100% { opacity: 0.35; transform: none; }
    8% { opacity: 1; transform: none; box-shadow: 0 2px 12px rgba(0,0,0,0.04); }
    78% { opacity: 1; }
    88% { opacity: 0.35; }
}

@keyframes fc-report-draw {
    0%, 5% { stroke-dashoffset: 300; }
    30% { stroke-dashoffset: 0; }
    70% { stroke-dashoffset: 0; }
    85%, 100% { stroke-dashoffset: 300; }
}

@keyframes fc-report-area-in {
    0% { opacity: 0; }
    15% { opacity: 1; }
    70% { opacity: 1; }
    85%, 100% { opacity: 0; }
}

@keyframes fc-report-bar-rise {
    0%, 5% { transform: scaleY(0.06); }
    20% { transform: scaleY(var(--h, 0.6)); }
    65% { transform: scaleY(var(--h, 0.6)); }
    80%, 100% { transform: scaleY(0.06); }
}

@keyframes fc-report-row-in {
    0%, 100% { opacity: 0.35; }
    12% { opacity: 1; }
    68% { opacity: 1; }
    82% { opacity: 0.35; }
}


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

@media (max-width: 768px) {
    .fc-prop-name { min-width: 80px; font-size: 11px; }
    .fc-prop-val { font-size: 12px; }

    .fc-ai {
        grid-template-columns: 1fr 20px 1fr;
    }

    .fc-ai-point { font-size: 9px; }
    .fc-ai-q, .fc-ai-a { font-size: 9px; }

    .fc-gantt-label { font-size: 9px; min-width: 48px; }
}

@media (max-width: 480px) {
    .fc-ai {
        grid-template-columns: 1fr;
        grid-template-rows: auto;
    }

    .fc-ai-beam { display: none; }
    .fc-ai-data { flex-direction: row; flex-wrap: wrap; gap: 4px; }
}
