/* ============================================
   SCOUTER - 防御力推定ツール 
   TacticsMaker Dashboard UI Style
   ============================================ */

/* === ヘッダー === */
.scouter-header {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    background: linear-gradient(135deg, rgba(255, 0, 51, 0.06), rgba(255, 77, 109, 0.03));
    border: 1px solid rgba(255, 0, 51, 0.12);
    border-radius: 12px;
    margin-bottom: 16px;
    position: relative;
    overflow: hidden;
}

.scouter-header::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg,
            transparent 0%,
            rgba(255, 0, 51, 0.03) 50%,
            transparent 100%);
    pointer-events: none;
}

/* クロスヘアアイコン */
.scouter-header-icon {
    position: relative;
    width: 48px;
    height: 48px;
    flex-shrink: 0;
    z-index: 1;
}

.scouter-crosshair {
    position: relative;
    width: 100%;
    height: 100%;
}

.scouter-crosshair-ring {
    position: absolute;
    inset: 4px;
    border: 2px solid rgba(255, 0, 51, 0.7);
    border-radius: 50%;
    animation: scouterRingSpin 8s linear infinite;
}

.scouter-crosshair-dot {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 6px;
    height: 6px;
    background: #ff0033;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    box-shadow: 0 0 8px rgba(255, 0, 51, 0.8), 0 0 16px rgba(255, 0, 51, 0.4);
    animation: scouterDotPulse 2s ease-in-out infinite;
}

.scouter-crosshair-line {
    position: absolute;
    background: rgba(255, 0, 51, 0.5);
}

.scouter-ch-h {
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    transform: translateY(-0.5px);
}

.scouter-ch-v {
    left: 50%;
    top: 0;
    bottom: 0;
    width: 1px;
    transform: translateX(-0.5px);
}

@keyframes scouterRingSpin {
    0% {
        transform: rotate(0deg);
        border-color: rgba(255, 0, 51, 0.7);
    }

    25% {
        border-color: rgba(255, 77, 109, 0.5);
    }

    50% {
        transform: rotate(180deg);
        border-color: rgba(255, 0, 51, 0.7);
    }

    75% {
        border-color: rgba(255, 160, 160, 0.5);
    }

    100% {
        transform: rotate(360deg);
        border-color: rgba(255, 0, 51, 0.7);
    }
}

@keyframes scouterDotPulse {

    0%,
    100% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
    }

    50% {
        transform: translate(-50%, -50%) scale(1.5);
        opacity: 0.7;
    }
}

.scouter-header-text {
    z-index: 1;
    flex: 1;
}

.scouter-title {
    font-family: 'Orbitron', monospace;
    font-size: 1.1rem;
    font-weight: 800;
    color: #ff0033;
    letter-spacing: 3px;
    margin: 0;
    text-shadow: 0 0 20px rgba(255, 0, 51, 0.4);
}

.scouter-subtitle {
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.45);
    margin-top: 4px;
    letter-spacing: 1px;
    font-weight: 600;
}

.scouter-header-scan {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: rgba(255, 0, 51, 0.08);
    overflow: hidden;
}

.scouter-scan-line {
    position: absolute;
    top: 0;
    left: -30%;
    width: 30%;
    height: 100%;
    background: linear-gradient(90deg,
            transparent,
            rgba(255, 0, 51, 0.8),
            transparent);
    animation: scouterScanMove 3s linear infinite;
}

@keyframes scouterScanMove {
    0% {
        left: -30%;
    }

    100% {
        left: 130%;
    }
}

/* === 説明テキスト === */
.scouter-description {
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.3);
    line-height: 1.8;
    margin-bottom: 16px;
    padding: 0 4px;
    text-align: center;
}

/* === カード共通 === */
.scouter-card {
    background: rgba(14, 14, 28, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    margin-bottom: 14px;
    overflow: hidden;
    transition: border-color 0.3s ease;
}

.scouter-card:hover {
    border-color: rgba(255, 0, 51, 0.15);
}

.scouter-card-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: rgba(255, 0, 51, 0.04);
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    font-family: 'Orbitron', monospace;
    font-size: 0.7rem;
    font-weight: 700;
    color: #ff4d6d;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.scouter-card-icon {
    font-size: 0.85rem;
}

/* === 設定セクション === */
.scouter-settings-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    padding: 16px;
}

.scouter-form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.scouter-label {
    font-size: 0.68rem;
    color: rgba(255, 255, 255, 0.45);
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.scouter-select,
.scouter-input {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.9);
    padding: 9px 12px;
    font-size: 0.85rem;
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    transition: all 0.25s ease;
    width: 100%;
}

.scouter-select:hover,
.scouter-input:hover {
    border-color: rgba(255, 0, 51, 0.3);
}

.scouter-select:focus,
.scouter-input:focus {
    outline: none;
    border-color: rgba(255, 0, 51, 0.5);
    box-shadow: 0 0 0 3px rgba(255, 0, 51, 0.1);
    background: rgba(0, 0, 0, 0.6);
}

/* === 入力ラッパー === */
.scouter-input-wrapper {
    display: flex;
    align-items: center;
    gap: 4px;
}

.scouter-input-wrapper input {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    color: #ff4d6d;
    padding: 8px 10px;
    font-size: 0.85rem;
    font-family: 'Inter', sans-serif;
    font-weight: 700;
    width: 100px;
    text-align: center;
    transition: all 0.25s ease;
}

.scouter-input-wrapper input:focus {
    outline: none;
    border-color: rgba(255, 0, 51, 0.5);
    box-shadow: 0 0 0 3px rgba(255, 0, 51, 0.1);
    background: rgba(0, 0, 0, 0.6);
    color: rgba(255, 255, 255, 0.95);
}

.scouter-input-suffix {
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.3);
    font-weight: 600;
    flex-shrink: 0;
}

/* === 測定テーブル === */
.scouter-table-wrapper {
    padding: 12px 16px 16px;
    overflow-x: auto;
}

.scouter-table {
    width: 100%;
    border-collapse: collapse;
}

.scouter-table thead tr {
    border-bottom: 2px solid rgba(255, 0, 51, 0.2);
}

.scouter-table th {
    background: rgba(255, 0, 51, 0.08);
    color: #ff4d6d;
    font-size: 0.65rem;
    padding: 10px 12px;
    text-align: center;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    white-space: nowrap;
}

.scouter-table td {
    padding: 10px 8px;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    vertical-align: middle;
}

.scouter-measure-row {
    transition: background 0.2s ease;
}

.scouter-measure-row:hover {
    background: rgba(255, 0, 51, 0.03);
}

.scouter-measure-no {
    font-family: 'Orbitron', monospace;
    font-size: 1rem;
    font-weight: 800;
    color: #ff0033;
    text-shadow: 0 0 8px rgba(255, 0, 51, 0.3);
}

/* === 計算結果値 === */
.scouter-calc-value {
    font-family: 'Orbitron', monospace;
    font-size: 0.95rem;
    font-weight: 700;
    color: #ffd700;
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.3);
    transition: all 0.3s ease;
}

.scouter-calc-value.scouter-updated {
    animation: scouterValueFlash 0.5s ease-out;
}

@keyframes scouterValueFlash {
    0% {
        color: #fff;
        transform: scale(1.3);
        text-shadow: 0 0 20px rgba(255, 255, 255, 0.5);
    }

    100% {
        color: #ffd700;
        transform: scale(1);
        text-shadow: 0 0 10px rgba(255, 215, 0, 0.3);
    }
}

/* === メモ入力 === */
.scouter-memo-input {
    width: 90px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.06);
    color: rgba(255, 255, 255, 0.5);
    border-radius: 6px;
    padding: 5px 8px;
    font-size: 0.72rem;
    font-family: 'Inter', sans-serif;
    transition: all 0.2s ease;
}

.scouter-memo-input:focus {
    outline: none;
    border-color: rgba(255, 0, 51, 0.3);
    color: rgba(255, 255, 255, 0.8);
    background: rgba(0, 0, 0, 0.5);
}

/* === 比較結果 === */
.scouter-comparison {
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-left: 3px solid rgba(255, 0, 51, 0.5);
    border-radius: 0 10px 10px 0;
    padding: 14px 18px;
    margin: 10px 16px 10px;
    transition: all 0.3s ease;
    animation: scouterCompSlideIn 0.4s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.scouter-comparison:hover {
    border-left-color: #ff0033;
    background: rgba(255, 0, 51, 0.02);
}

@keyframes scouterCompSlideIn {
    from {
        opacity: 0;
        transform: translateX(16px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.scouter-comparison-header {
    font-family: 'Orbitron', monospace;
    font-size: 0.68rem;
    font-weight: 700;
    color: #ff4d6d;
    letter-spacing: 1px;
    margin-bottom: 12px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255, 0, 51, 0.1);
}

.scouter-result-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    transition: background 0.2s ease;
}

.scouter-result-row:last-child {
    border-bottom: none;
}

.scouter-result-row:hover {
    background: rgba(255, 0, 51, 0.02);
    padding-left: 4px;
}

.scouter-row-highlight {
    background: rgba(255, 0, 51, 0.04);
    border-radius: 6px;
    padding: 10px 8px;
    margin: 4px -4px;
}

.scouter-result-label {
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.5);
    font-weight: 600;
}

.scouter-result-value {
    font-family: 'Orbitron', monospace;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 1px;
}

.scouter-val-highlight {
    color: #ff0033;
    font-size: 1.25rem;
    text-shadow: 0 0 15px rgba(255, 0, 51, 0.5);
    animation: scouterPulseGlow 2s ease-in-out infinite;
}

@keyframes scouterPulseGlow {

    0%,
    100% {
        text-shadow: 0 0 15px rgba(255, 0, 51, 0.4);
    }

    50% {
        text-shadow: 0 0 25px rgba(255, 0, 51, 0.8);
    }
}

.scouter-val-defense {
    color: #ffd700;
}

.scouter-val-coeff {
    color: #ff6b35;
    text-shadow: 0 0 10px rgba(255, 107, 53, 0.3);
}

.scouter-val-pierce {
    color: #bb86fc;
}

.scouter-val-empty {
    color: rgba(255, 255, 255, 0.2);
    font-size: 0.75rem;
    font-weight: 400;
    font-family: 'Inter', sans-serif;
}

/* === 使い方セクション === */
.scouter-usage {
    background: rgba(14, 14, 28, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 12px;
    overflow: hidden;
    margin-top: 8px;
}

.scouter-usage-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    background: rgba(168, 218, 220, 0.04);
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    font-family: 'Orbitron', monospace;
    font-size: 0.65rem;
    font-weight: 700;
    color: rgba(168, 218, 220, 0.6);
    letter-spacing: 1.5px;
    text-transform: uppercase;
}

.scouter-usage-list {
    padding: 14px 16px 14px 30px;
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.4);
    line-height: 2.2;
    margin: 0;
}

.scouter-usage-list strong {
    color: #ff4d6d;
}

.scouter-usage-detail {
    font-size: 0.65rem;
    color: rgba(255, 255, 255, 0.25);
    margin-left: 4px;
}

/* === レスポンシブ === */
@media (max-width: 700px) {
    .scouter-settings-grid {
        grid-template-columns: 1fr;
    }

    .scouter-input-wrapper input {
        width: 80px;
    }

    .scouter-title {
        font-size: 0.9rem;
        letter-spacing: 2px;
    }

    .scouter-result-value {
        font-size: 0.85rem;
    }

    .scouter-val-highlight {
        font-size: 1rem;
    }
}