.secondfi-page {
    width: min(1120px, 100%);
    margin: 0 auto;
    padding: 16px;
    color: #e5edf7;
}

.secondfi-page-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 14px;
    border: 1px solid rgba(96, 165, 250, 0.3);
    border-radius: 8px;
    padding: 15px 18px;
    background:
        linear-gradient(135deg, rgba(37, 99, 235, 0.16), rgba(16, 185, 129, 0.08)),
        rgba(15, 23, 42, 0.82);
    box-shadow: 0 16px 38px rgba(2, 6, 23, 0.2);
}

.secondfi-title-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
    flex: 1 1 auto;
}

.secondfi-title-icon {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    flex: 0 0 auto;
    border-radius: 8px;
    background: linear-gradient(135deg, #22c55e, #2563eb);
    color: #f8fafc;
    box-shadow: 0 0 0 5px rgba(34, 197, 94, 0.1);
}

.secondfi-page-head h1 {
    min-width: 0;
    overflow: hidden;
    margin: 0;
    color: #f8fafc;
    font-size: 24px;
    font-weight: 900;
    line-height: 1.1;
    letter-spacing: 0;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.secondfi-head-badge {
    flex: 0 0 auto;
    border: 1px solid rgba(45, 212, 191, 0.34);
    border-radius: 999px;
    padding: 7px 11px;
    background: rgba(20, 184, 166, 0.1);
    color: #99f6e4;
    font-size: 12px;
    font-weight: 800;
}

.secondfi-panel {
    border: 1px solid rgba(148, 163, 184, 0.22);
    border-radius: 8px;
    background: rgba(15, 23, 42, 0.84);
    box-shadow: 0 16px 40px rgba(2, 6, 23, 0.24);
}

.secondfi-query {
    padding: 22px;
}

.secondfi-label-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 8px;
}

.secondfi-form label {
    flex: 0 0 auto;
    color: #cbd5e1;
    font-size: 13px;
    font-weight: 800;
}

.secondfi-label-row span {
    min-width: 0;
    overflow: hidden;
    color: #94a3b8;
    font-size: 12px;
    font-weight: 700;
    text-align: right;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.secondfi-input-row {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 10px;
}

.secondfi-input-row input {
    min-width: 0;
    height: 46px;
    border: 1px solid rgba(148, 163, 184, 0.32);
    border-radius: 8px;
    padding: 0 14px;
    background: rgba(2, 6, 23, 0.62);
    color: #f8fafc;
    font-size: 14px;
    font-family: inherit;
}

.secondfi-input-row input:focus {
    outline: none;
    border-color: rgba(96, 165, 250, 0.78);
    box-shadow: 0 0 0 3px rgba(96, 165, 250, 0.14);
}

.secondfi-input-row button {
    height: 46px;
    border: 0;
    border-radius: 8px;
    padding: 0 18px;
    background: #2563eb;
    color: #ffffff;
    font-weight: 900;
    cursor: pointer;
}

.secondfi-input-row button:disabled {
    opacity: 0.62;
    cursor: wait;
}

.secondfi-input-row button i {
    margin-right: 7px;
}

.secondfi-loading,
.secondfi-error {
    margin-top: 14px;
}

.secondfi-loading {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #bfdbfe;
    font-size: 14px;
    font-weight: 700;
}

.secondfi-spinner {
    width: 18px;
    height: 18px;
    border: 3px solid rgba(147, 197, 253, 0.26);
    border-top-color: #93c5fd;
    border-radius: 50%;
    animation: secondfi-spin 0.8s linear infinite;
}

@keyframes secondfi-spin {
    to { transform: rotate(360deg); }
}

.secondfi-error {
    border: 1px solid rgba(248, 113, 113, 0.34);
    border-radius: 8px;
    padding: 11px 12px;
    background: rgba(127, 29, 29, 0.22);
    color: #fecaca;
    font-size: 14px;
    font-weight: 800;
}

.secondfi-result,
.secondfi-watch {
    margin-top: 14px;
    padding: 18px;
}

.secondfi-status {
    display: flex;
    align-items: center;
    gap: 14px;
    border-radius: 8px;
    padding: 14px;
}

.secondfi-status.detected {
    border: 1px solid rgba(248, 113, 113, 0.42);
    background: rgba(127, 29, 29, 0.24);
}

.secondfi-status.clear {
    border: 1px solid rgba(52, 211, 153, 0.34);
    background: rgba(6, 95, 70, 0.2);
}

.secondfi-status-icon {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.08);
    font-size: 18px;
}

.secondfi-status h2 {
    margin: 0;
    font-size: 20px;
    line-height: 1.25;
}

.secondfi-status p {
    margin: 5px 0 0;
    color: #cbd5e1;
    font-size: 14px;
}

.secondfi-summary-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin-top: 14px;
}

.secondfi-summary-grid > div {
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 8px;
    padding: 12px;
    background: rgba(30, 41, 59, 0.52);
}

.secondfi-summary-grid span,
.secondfi-stake span {
    display: block;
    color: #94a3b8;
    font-size: 12px;
    font-weight: 800;
}

.secondfi-summary-grid strong {
    display: block;
    margin-top: 6px;
    color: #f8fafc;
    font-size: 15px;
}

.secondfi-stake {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-top: 12px;
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 8px;
    padding: 11px 12px;
    background: rgba(2, 6, 23, 0.36);
}

.secondfi-stake code,
.secondfi-watch-item code,
.secondfi-match-card code {
    color: #bfdbfe;
    font-family: Consolas, Monaco, monospace;
    font-size: 12px;
    word-break: break-all;
}

.secondfi-match-list {
    display: grid;
    gap: 10px;
    margin-top: 14px;
}

.secondfi-match-card {
    display: grid;
    grid-template-columns: 70px 126px 122px minmax(120px, 1fr) 170px;
    align-items: center;
    gap: 10px;
    border: 1px solid rgba(248, 113, 113, 0.24);
    border-radius: 8px;
    padding: 11px 12px;
    background: rgba(15, 23, 42, 0.72);
}

.secondfi-match-card strong {
    min-width: 0;
    overflow: hidden;
    color: #ffffff;
    font-size: 13px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.secondfi-match-time,
.secondfi-match-amount,
.secondfi-match-link {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.secondfi-match-time,
.secondfi-match-amount {
    color: #cbd5e1;
    font-size: 13px;
}

.secondfi-match-source {
    justify-self: start;
    border-radius: 999px;
    padding: 5px 8px;
    font-size: 12px;
    font-weight: 900;
    white-space: nowrap;
}

.secondfi-match-source.notice {
    background: rgba(16, 185, 129, 0.16);
    color: #bbf7d0;
}

.secondfi-match-source.danger {
    background: rgba(248, 113, 113, 0.14);
    color: #fecaca;
}

.secondfi-match-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    justify-self: end;
    max-width: 100%;
    border: 1px solid rgba(96, 165, 250, 0.28);
    border-radius: 999px;
    padding: 5px 9px;
    background: rgba(37, 99, 235, 0.12);
    color: #93c5fd;
    font-size: 13px;
    font-weight: 800;
    text-decoration: none;
}

.secondfi-match-link span {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
}

.secondfi-match-link i {
    flex: 0 0 auto;
    font-size: 11px;
}

.secondfi-section-title {
    display: flex;
    align-items: center;
    gap: 9px;
    margin-bottom: 12px;
}

.secondfi-section-title h2 {
    margin: 0;
    font-size: 18px;
}

.secondfi-watch-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
}

.secondfi-watch-item {
    display: grid;
    grid-template-columns: 74px 132px minmax(0, 1fr);
    align-items: center;
    gap: 12px;
    border: 1px solid rgba(148, 163, 184, 0.18);
    border-radius: 8px;
    padding: 12px;
    background: rgba(30, 41, 59, 0.4);
}

.secondfi-watch-item strong {
    color: #f8fafc;
    font-size: 13px;
    text-align: center;
    white-space: nowrap;
}

.secondfi-watch-item span {
    justify-self: center;
    border-radius: 999px;
    padding: 5px 9px;
    font-size: 11px;
    font-weight: 900;
    white-space: nowrap;
}

.secondfi-watch-item code {
    justify-self: start;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.secondfi-watch-item span.notice {
    background: rgba(59, 130, 246, 0.16);
    color: #bfdbfe;
}

.secondfi-watch-item span.danger {
    background: rgba(248, 113, 113, 0.14);
    color: #fecaca;
}

.hidden {
    display: none !important;
}

@media (max-width: 900px) {
    .secondfi-summary-grid,
}

@media (max-width: 640px) {
    .secondfi-page {
        padding: 10px;
    }

    .secondfi-query,
    .secondfi-result,
    .secondfi-watch {
        padding: 14px;
    }

    .secondfi-page-head {
        align-items: center;
        flex-direction: row;
        gap: 8px;
        padding: 12px;
    }

    .secondfi-page-head h1 {
        font-size: 18px;
    }

    .secondfi-label-row {
        align-items: flex-start;
        flex-direction: column;
        gap: 4px;
    }

    .secondfi-label-row span {
        text-align: left;
        white-space: normal;
    }

    .secondfi-title-icon {
        width: 32px;
        height: 32px;
    }

    .secondfi-head-badge {
        padding: 6px 8px;
        font-size: 11px;
        white-space: nowrap;
    }

    .secondfi-input-row,
    .secondfi-summary-grid {
        grid-template-columns: 1fr;
    }

    .secondfi-input-row button {
        width: 100%;
    }

    .secondfi-status {
        align-items: flex-start;
    }

    .secondfi-stake {
        align-items: flex-start;
        flex-direction: column;
    }

    .secondfi-match-card {
        grid-template-columns: 58px 82px 82px minmax(62px, 1fr) 112px;
        gap: 7px;
        padding: 10px;
    }

    .secondfi-watch-item {
        align-items: center;
        grid-template-columns: 58px 92px minmax(0, 1fr);
        gap: 8px;
    }
}
