@extends('admin.layouts.app')

@section('title', '대시보드')

@section('content')
    <section class="a-dash">

        {{-- KPI --}}
        <div class="a-grid a-grid--kpi">
            <article class="a-card">
                <div class="a-card__label a-muted">오늘 신규 가입</div>
                <div class="a-card__value">1,284</div>
                <div class="a-card__meta a-muted">전일 대비 +12%</div>
            </article>

            <article class="a-card">
                <div class="a-card__label a-muted">오늘 로그인</div>
                <div class="a-card__value">9,102</div>
                <div class="a-card__meta a-muted">실패/차단 132</div>
            </article>

            <article class="a-card">
                <div class="a-card__label a-muted">미처리 문의</div>
                <div class="a-card__value">37</div>
                <div class="a-card__meta a-muted">신규 11 · 처리중 26</div>
            </article>

            <article class="a-card a-card--accent">
                <div class="a-card__label a-muted">오늘 매출</div>
                <div class="a-card__value">₩ 38,420,000</div>
                <div class="a-card__meta a-muted">거래 412건</div>
            </article>
        </div>

        {{-- Charts Row --}}
        <div class="a-grid a-grid--charts">
            <article class="a-card a-card--lg">
                <div class="a-card__head">
                    <div>
                        <div class="a-card__title">매출 추이</div>
                        <div class="a-card__desc a-muted">최근 14일 기준</div>
                    </div>
                    <div class="a-chip">Daily</div>
                </div>
                <div class="a-chart" data-chart="sales">
                    {{-- 차트 라이브러리 붙이면 canvas/slot 넣기 --}}
                    <div class="a-chart__placeholder a-muted">Chart 영역 (sales)</div>
                </div>
            </article>

            <article class="a-card a-card--lg">
                <div class="a-card__head">
                    <div>
                        <div class="a-card__title">가입/로그인 흐름</div>
                        <div class="a-card__desc a-muted">가입·로그인·실패</div>
                    </div>
                    <div class="a-chip">Realtime</div>
                </div>
                <div class="a-chart" data-chart="flow">
                    <div class="a-chart__placeholder a-muted">Chart 영역 (flow)</div>
                </div>
            </article>
        </div>

        {{-- Tables Row --}}
        <div class="a-grid a-grid--tables">
            <article class="a-card">
                <div class="a-card__head">
                    <div>
                        <div class="a-card__title">최근 문의 접수</div>
                        <div class="a-card__desc a-muted">최신 10건</div>
                    </div>
                    <a class="a-link" href="#">전체보기</a>
                </div>

                <div class="a-table">
                    <div class="a-tr a-th">
                        <div>시간</div><div>유형</div><div>제목</div><div>상태</div>
                    </div>
                    @for($i=0;$i<6;$i++)
                        <div class="a-tr">
                            <div class="a-muted">18:2{{ $i }}</div>
                            <div>1:1</div>
                            <div class="a-ellipsis">핀번호 오류 문의</div>
                            <div><span class="a-pill a-pill--warn">접수</span></div>
                        </div>
                    @endfor
                </div>
            </article>

            <article class="a-card">
                <div class="a-card__head">
                    <div>
                        <div class="a-card__title">정산/출금 대기</div>
                        <div class="a-card__desc a-muted">리스크/지연 모니터링</div>
                    </div>
                    <a class="a-link" href="#">관리</a>
                </div>

                <div class="a-table">
                    <div class="a-tr a-th">
                        <div>요청일</div><div>회원</div><div>금액</div><div>상태</div>
                    </div>
                    @for($i=0;$i<6;$i++)
                        <div class="a-tr">
                            <div class="a-muted">02/0{{ $i+1 }}</div>
                            <div class="a-ellipsis">mem_{{ 1000+$i }}</div>
                            <div>₩ {{ number_format(120000 + ($i*30000)) }}</div>
                            <div><span class="a-pill a-pill--info">대기</span></div>
                        </div>
                    @endfor
                </div>
            </article>
        </div>

    </section>
@endsection
