/* 勤怠確認 — Figma「アカスキポータル」トークン準拠（390px カラム・SP優先） */

.timesheet-page {
    --ts-bg-page: #ffffff;
    --ts-bg-app: #f8f6f5;
    --ts-surface: #ffffff;
    --ts-main: #e17713;
    --ts-text: #000000;
    --ts-text-sub: #424752;
    --ts-sub1: #fdf2e7;
    --ts-sub2: #efefef;
    --ts-gray: #c1c1c1;
    --ts-shadow-card: 0 1px 2px rgba(0, 0, 0, 0.05);
    --ts-shadow-bar: 0 1px 2px rgba(0, 0, 0, 0.05);
    --ts-radius-panel: 24px;
    --ts-radius-card: 32px;
    --ts-radius-input: 12px;
    --ts-col-max: 390px;
    --font-display: "Plus Jakarta Sans", "Noto Sans JP", sans-serif;
    --font-numeric: "Manrope", "Noto Sans JP", sans-serif;

    background: var(--ts-bg-page);
    margin: 0;
    min-height: 100vh;
    font-family: "Noto Sans JP", sans-serif;
    color: var(--ts-text);
    -webkit-font-smoothing: antialiased;
    padding-bottom: 0;
}

/* ヘッダーは frames.css の .app-top-bar を使用 */

.ts-demo-banner {
    margin: 0 0 0.5rem;
    padding: 10px 14px;
    font-size: 0.6875rem;
    font-weight: 700;
    line-height: 1.45;
    color: #8b4513;
    background: linear-gradient(135deg, #fdf2e7 0%, #fffdfb 100%);
    border: 1px solid rgba(225, 119, 19, 0.35);
    border-radius: 12px;
    text-align: center;
}

.ts-demo-banner--error {
    color: #5c2a0a;
    background: linear-gradient(135deg, #ffe8dc 0%, #fff5f0 100%);
    border-color: rgba(180, 60, 30, 0.4);
}

.ts-demo-banner__detail {
    display: block;
    margin-top: 6px;
    font-weight: 500;
    font-size: 0.625rem;
    word-break: break-word;
    opacity: 0.92;
}

.ts-demo-banner__hint {
    display: block;
    margin-top: 8px;
    font-weight: 600;
    font-size: 0.6875rem;
    line-height: 1.5;
    text-align: left;
}

.timesheet-page .frame-azure-shift__main.ts-main {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.timesheet-page .ts-eyebrow {
    margin: 0 0 4px;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.75rem;
    line-height: 1.33;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--ts-main);
}

.timesheet-page .ts-heading {
    margin: 0 0 8px;
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.2;
    color: var(--ts-text);
}

.timesheet-page .ts-lead {
    margin: 0;
    font-size: 0.875rem;
    line-height: 1.35;
    color: var(--ts-text-sub);
}

.timesheet-page .ts-panel {
    background: var(--ts-surface);
    border-radius: var(--ts-radius-panel);
    box-shadow: var(--ts-shadow-card);
    box-sizing: border-box;
}

.timesheet-page .ts-panel--form {
    padding: 28px 24px 32px;
}

.timesheet-page .ts-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.timesheet-page .ts-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.timesheet-page .ts-label {
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--ts-main);
}

.timesheet-page .ts-input {
    width: 100%;
    box-sizing: border-box;
    padding: 16px 14px;
    font-size: 1rem;
    font-family: inherit;
    border: none;
    border-radius: var(--ts-radius-input);
    background: var(--ts-sub2);
    color: var(--ts-text);
    transition: box-shadow 0.15s ease;
}

.timesheet-page .ts-input::placeholder {
    color: var(--ts-gray);
}

.timesheet-page .ts-input:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(225, 119, 19, 0.35);
}

.timesheet-page .ts-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 16px 20px;
    font-family: inherit;
    font-size: 0.9375rem;
    font-weight: 700;
    border: none;
    border-radius: var(--ts-radius-input);
    cursor: pointer;
    transition: background 0.15s ease, transform 0.05s ease;
}

.timesheet-page .ts-btn--primary {
    background: var(--ts-main);
    color: #fff;
}

.timesheet-page .ts-btn--primary:hover {
    background: #c9690f;
}

.timesheet-page .ts-btn--primary:active {
    transform: scale(0.99);
}

.timesheet-page .ts-results__head {
    margin-bottom: 4px;
}

.timesheet-page .ts-section-title {
    margin: 0 0 4px;
    font-size: 1.25rem;
    font-weight: 800;
    line-height: 1.3;
    letter-spacing: -0.02em;
    word-break: break-all;
}

.timesheet-page .ts-results__meta {
    margin: 0;
    font-family: var(--font-display);
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--ts-text-sub);
}

.timesheet-page .ts-card-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.timesheet-page .ts-record-card {
    position: relative;
    display: flex;
    background: var(--ts-surface);
    border-radius: var(--ts-radius-card);
    box-shadow: var(--ts-shadow-card);
    overflow: hidden;
    min-height: 0;
}

.timesheet-page .ts-record-card__accent {
    width: 6px;
    flex-shrink: 0;
    background: var(--ts-main);
}

.timesheet-page .ts-record-card__inner {
    flex: 1;
    padding: 20px 18px 20px 16px;
    min-width: 0;
    box-sizing: border-box;
}

.timesheet-page .ts-record-card__date {
    margin: 0 0 12px;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.625rem;
    line-height: 1.5;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--ts-main);
}

.timesheet-page .ts-record-card__times {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
}

.timesheet-page .ts-time-block {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.timesheet-page .ts-time-value {
    font-family: var(--font-numeric);
    font-weight: 800;
    font-size: 1.125rem;
    line-height: 1.45;
    color: var(--ts-text);
}

.timesheet-page .ts-time-label {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.625rem;
    line-height: 1.5;
    text-transform: uppercase;
    color: var(--ts-main);
}

.timesheet-page .ts-time-divider {
    width: 32px;
    height: 2px;
    flex-shrink: 0;
    background: var(--ts-sub1);
    border-radius: 1px;
    align-self: center;
}

.timesheet-page .ts-record-card__comments {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding-top: 12px;
    border-top: 1px solid var(--ts-sub2);
}

.timesheet-page .ts-comment {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.timesheet-page .ts-comment__label {
    font-size: 0.6875rem;
    font-weight: 700;
    color: var(--ts-gray);
}

.timesheet-page .ts-comment__body {
    font-size: 0.8125rem;
    line-height: 1.45;
    color: var(--ts-text-sub);
    word-break: break-word;
}

.timesheet-page .ts-panel--empty {
    padding: 28px 22px 32px;
    text-align: center;
}

.timesheet-page .ts-empty__icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--ts-sub1);
    color: var(--ts-main);
    font-size: 1.5rem;
}

.timesheet-page .ts-empty__title {
    margin: 0 0 10px;
    font-size: 1.125rem;
    font-weight: 700;
    color: #b91c1c;
}

.timesheet-page .ts-empty__text {
    margin: 0;
    font-size: 0.875rem;
    line-height: 1.55;
    color: var(--ts-text-sub);
    text-align: left;
}

.timesheet-page .ts-tips {
    text-align: left;
    background: var(--ts-sub2);
    border-radius: var(--ts-radius-input);
    padding: 16px 18px;
}

.timesheet-page .ts-tips__title {
    margin: 0 0 10px;
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--ts-text);
}

.timesheet-page .ts-tips__list {
    margin: 0;
    padding-left: 1.2rem;
    font-size: 0.8125rem;
    line-height: 1.55;
    color: var(--ts-text-sub);
}

.timesheet-page .ts-tips__list li+li {
    margin-top: 6px;
}

/* --- 勤怠デモ: サマリー・打刻・履歴 --- */
.timesheet-page .ts-summary-panel,
.timesheet-page .ts-punch-panel {
    background: var(--ts-surface);
    border-radius: var(--ts-radius-panel);
    box-shadow: var(--ts-shadow-card);
    padding: 22px 20px 24px;
    box-sizing: border-box;
}

.timesheet-page .ts-summary-panel__title,
.timesheet-page .ts-punch-panel__title {
    margin: 0 0 6px;
    font-size: 1.0625rem;
    font-weight: 800;
    color: var(--ts-text);
}

.timesheet-page .ts-summary-panel__meta {
    margin: 0 0 16px;
    font-size: 0.8125rem;
    color: var(--ts-text-sub);
}

.timesheet-page .ts-summary-panel__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.timesheet-page .ts-summary-item {
    background: var(--ts-sub2);
    border-radius: 14px;
    padding: 14px 12px;
    text-align: center;
}

.timesheet-page .ts-summary-item__label {
    display: block;
    font-size: 0.6875rem;
    font-weight: 700;
    color: var(--ts-text-sub);
    margin-bottom: 6px;
}

.timesheet-page .ts-summary-item__value {
    font-family: var(--font-numeric);
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--ts-main);
}

.timesheet-page .ts-punch-panel__date {
    margin: 0 0 16px;
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--ts-text-sub);
}

.timesheet-page .ts-mode {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-bottom: 16px;
}

.timesheet-page .ts-mode--disabled {
    opacity: 0.55;
    pointer-events: none;
}

.timesheet-page .ts-mode__btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    min-height: 72px;
    padding: 8px 6px;
    border: 1px solid var(--ts-sub2);
    border-radius: 14px;
    background: #fff;
    font-size: 0.6875rem;
    font-weight: 700;
    line-height: 1.35;
    color: var(--ts-text-sub);
    cursor: pointer;
    transition: border-color 0.15s ease, background 0.15s ease;
}

.timesheet-page .ts-mode__btn--active {
    border-color: rgba(225, 119, 19, 0.55);
    background: var(--ts-sub1);
    color: var(--ts-main);
}

.timesheet-page .ts-mode__line:first-child {
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--ts-text);
}

.timesheet-page .ts-punch-error {
    margin: 0 0 12px;
    padding: 10px 12px;
    font-size: 0.8125rem;
    font-weight: 700;
    color: #991b1b;
    background: #fef2f2;
    border-radius: 10px;
}

.timesheet-page .ts-punch-actions {
    margin-bottom: 8px;
}

.timesheet-page .ts-punch-main {
    width: 100%;
    padding: 18px 20px;
    font-size: 1.0625rem;
    font-weight: 800;
    border: none;
    border-radius: 16px;
    cursor: pointer;
    transition: opacity 0.15s ease, transform 0.05s ease;
}

.timesheet-page .ts-punch-main:disabled {
    cursor: not-allowed;
    opacity: 0.55;
}

.timesheet-page .ts-punch-main--in {
    background: linear-gradient(135deg, #e17713 0%, #c9690f 100%);
    color: #fff;
}

.timesheet-page .ts-punch-main--out {
    background: linear-gradient(135deg, #191c21 0%, #424752 100%);
    color: #fff;
}

.timesheet-page .ts-punch-main--done {
    background: var(--ts-sub2);
    color: var(--ts-gray);
}

.timesheet-page .ts-today-detail {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--ts-sub2);
}

.timesheet-page .ts-today-detail__mode {
    margin: 0 0 8px;
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--ts-text-sub);
}

.timesheet-page .ts-deemed-row {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 8px 12px;
    margin-bottom: 8px;
}

.timesheet-page .ts-deemed-label {
    font-size: 0.6875rem;
    font-weight: 700;
    color: var(--ts-main);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.timesheet-page .ts-deemed-times {
    font-family: var(--font-numeric);
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--ts-text);
}

.timesheet-page .ts-deemed-pay {
    margin-left: auto;
    font-family: var(--font-numeric);
    font-weight: 800;
    color: var(--ts-main);
}

.timesheet-page .ts-deemed-hint {
    font-size: 0.75rem;
    color: var(--ts-text-sub);
}

.timesheet-page .ts-actual-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 16px;
    font-size: 0.6875rem;
    color: #9ca3af;
}

.timesheet-page .ts-history-section {
    margin-top: 8px;
}

.timesheet-page .ts-history-lead {
    margin: 0 0 16px;
    font-size: 0.8125rem;
    line-height: 1.55;
    color: var(--ts-text-sub);
}

.timesheet-page .ts-history-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.timesheet-page .ts-history-empty {
    padding: 20px;
    text-align: center;
    font-size: 0.875rem;
    color: var(--ts-text-sub);
    background: var(--ts-sub2);
    border-radius: 14px;
}

.timesheet-page .ts-history-card {
    background: var(--ts-surface);
    border-radius: 18px;
    box-shadow: var(--ts-shadow-card);
    padding: 16px 14px;
    border: 1px solid rgba(0, 0, 0, 0.04);
}

.timesheet-page .ts-history-card__head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
}

.timesheet-page .ts-history-card__date {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 0.9375rem;
    color: var(--ts-text);
}

.timesheet-page .ts-flag-missed {
    font-size: 0.625rem;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: 999px;
    background: #fef3c7;
    color: #92400e;
}

.timesheet-page .ts-history-card__mode {
    margin-left: auto;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--ts-main);
}

.timesheet-page .ts-history-deemed {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 8px;
    align-items: baseline;
}

.timesheet-page .ts-history-deemed__main {
    font-family: var(--font-numeric);
    font-weight: 700;
    font-size: 0.9375rem;
    color: var(--ts-text);
}

.timesheet-page .ts-history-deemed__pay {
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--ts-text-sub);
}

.timesheet-page .ts-history-actual {
    margin: 10px 0 0;
    font-size: 0.6875rem;
    color: #9ca3af;
}

/* --- Figma「打刻(出勤)/(退勤)」: RESOURCE CENTER・デジタル時計・Bento 2 段 --- */
.timesheet-page .ts-punch-figma {
    background: var(--ts-surface);
    border-radius: var(--ts-radius-panel);
    box-shadow: var(--ts-shadow-card);
    padding: 8px 20px 24px;
    box-sizing: border-box;
}

.timesheet-page .ts-punch-hero {
    margin: 0 0 8px;
    padding-top: 8px;
}

.timesheet-page .ts-punch-hero__eyebrow {
    margin: 0 0 4px;
    font-size: 0.75rem;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: 0.04em;
    color: var(--ts-main, #e17713);
}

.timesheet-page .ts-punch-hero__title {
    margin: 0 0 4px;
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.2;
    color: var(--ts-text);
}

.timesheet-page .ts-clock-block {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
    margin: 0 0 1.25rem;
}

.timesheet-page .ts-clock-block__date-pill {
    display: inline-block;
    padding: 6px 16px;
    border-radius: 9999px;
    background: var(--ts-sub2, #efefef);
    font-family: "Plus Jakarta Sans", var(--font-display), sans-serif;
    font-size: 0.875rem;
    font-weight: 600;
    letter-spacing: 0.025em;
    color: var(--ts-main, #e17713);
}

.timesheet-page .ts-clock-block__time {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 6px;
    min-height: 72px;
}

.timesheet-page .ts-clock-block__hhmm {
    font-family: var(--font-numeric), "Manrope", sans-serif;
    font-size: clamp(2.75rem, 14vw, 4.5rem);
    font-weight: 800;
    line-height: 1;
    letter-spacing: -0.03em;
    color: var(--ts-main, #e17713);
}

.timesheet-page .ts-clock-block__ss {
    font-family: "Manrope", var(--font-numeric), sans-serif;
    font-size: 1.35rem;
    font-weight: 700;
    line-height: 1.35;
    letter-spacing: -0.08em;
    color: var(--ts-gray, #c1c1c1);
    align-self: flex-end;
    padding-bottom: 0.35em;
}

.timesheet-page .ts-punch-bento {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 8px;
}

.timesheet-page .ts-punch-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    min-height: 140px;
    padding: 20px 16px;
    border: none;
    border-radius: 24px;
    cursor: pointer;
    transition: transform 0.05s ease, box-shadow 0.15s ease, opacity 0.15s ease;
}

.timesheet-page .ts-punch-card:active:not(:disabled) {
    transform: scale(0.99);
}

.timesheet-page .ts-punch-card.is-active {
    background: var(--ts-main, #e17713);
    color: #fff;
    box-shadow:
        0 4px 6px -4px rgba(0, 71, 141, 0.2),
        0 10px 15px -3px rgba(0, 71, 141, 0.2);
}

.timesheet-page .ts-punch-card.is-idle {
    background: var(--ts-gray, #c1c1c1);
    color: var(--ts-sub2, #efefef);
    cursor: default;
}

.timesheet-page .ts-punch-card:disabled {
    cursor: not-allowed;
    opacity: 0.85;
}

.timesheet-page .ts-punch-card__ja {
    font-size: 1.5rem;
    font-weight: 700;
    line-height: 1.2;
}

.timesheet-page .ts-punch-card.is-active .ts-punch-card__en {
    font-size: 0.75rem;
    font-weight: 400;
    line-height: 1.2;
    color: rgba(255, 255, 255, 0.75);
}

.timesheet-page .ts-punch-card.is-idle .ts-punch-card__en {
    font-size: 0.75rem;
    font-weight: 400;
    line-height: 1.2;
    color: var(--ts-sub2, #efefef);
}

.timesheet-page .ts-punch-done-banner {
    margin: 8px 0 0;
    padding: 12px;
    text-align: center;
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--ts-text-sub);
    background: var(--ts-sub2);
    border-radius: 14px;
}

.timesheet-page .ts-punch-error--soft {
    color: #92400e;
    background: #fffbeb;
    border: 1px solid rgba(225, 119, 19, 0.25);
}