body {
    /* 完全オフライン: Webフォントに依存せず、端末の標準フォント(日本語含む)を使う */
    font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', 'Hiragino Sans',
        'Hiragino Kaku Gothic ProN', 'Yu Gothic UI', 'Noto Sans JP', Meiryo, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}
#certificate-details {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s ease-in-out;
}
.modal-backdrop {
    background-color: rgba(0, 0, 0, 0.5);
}

/* 隠しコマンド発動時の「1UP」風トースト */
@keyframes konami-pop {
    0%   { transform: translate(-50%, 24px) scale(0.5); opacity: 0; }
    18%  { transform: translate(-50%, -10px) scale(1.15); opacity: 1; }
    32%  { transform: translate(-50%, 0) scale(1); opacity: 1; }
    78%  { transform: translate(-50%, 0) scale(1); opacity: 1; }
    100% { transform: translate(-50%, -34px) scale(1); opacity: 0; }
}
.konami-toast {
    position: fixed;
    left: 50%;
    top: 16%;
    z-index: 1000;
    background: #1f2937;
    color: #34d399;
    font-family: monospace;
    font-weight: 800;
    font-size: 1.6rem;
    letter-spacing: 0.12em;
    padding: 0.6rem 1.3rem;
    border: 3px solid #34d399;
    border-radius: 0.5rem;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
    text-shadow: 0 0 8px rgba(52, 211, 153, 0.6);
    animation: konami-pop 1.8s ease-out forwards;
    pointer-events: none;
    white-space: nowrap;
}
@media print {
    @page {
        size: A4 portrait;
    }
    .no-print {
        display: none !important;
    }
    body {
        font-size: 10pt;
        background: #fff !important;
        color: #000 !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }
    .container {
        max-width: 100% !important;
        padding: 0 !important;
        margin: 0 !important;
    }
    main {
        display: block !important;
    }
    .printable-card {
         box-shadow: none !important;
         border: 1px solid #ddd !important;
         border-radius: 0 !important;
         padding: 1rem !important;
         margin-bottom: 1rem;
         page-break-inside: avoid;
    }
    h1, h2, legend { font-size: 14pt !important; }
    #total-cost { font-size: 24pt !important; }
}
