html {overflow-x: hidden;}
body {
    font-family: 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
    margin: 0;
    padding: 20px;
    overflow-x: hidden;
}
.container {
    max-width: 420px;
    margin: 0 auto;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    overflow: hidden;
}
.page-header {
    background: #4a6da7;
    color: white;
    padding: 20px;
    margin-bottom: 0;
}
.page-header h2 {
    margin: 0;
    font-weight: normal;
}
.tab-container {
    display: flex;
    border-bottom: 1px solid #ddd;
}
.tab {
    padding: 12px 24px;
    background: #f8f8f8;
    border: none;
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    outline: none;
}
.tab.active {
    background: #fff;
    border-bottom: 3px solid #4a6da7;
    color: #4a6da7;
}
.tab-content {
    display: none;
    padding: 20px;
}
.tab-content.active {
    display: block;
}
.form-group {
    margin-bottom: 20px;
}
label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}
input[type="text"],
input[type="email"],
input[type="password"],
select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-sizing: border-box;
    font-size: 16px;
}
textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    box-sizing: border-box;
    font-size: 16px;
    min-height: 100px;
    resize: vertical;
}
input[type="submit"],
button[type="submit"] {
    width: 100%;
    padding: 10px;
    border: none;
    border-radius: 4px;
    box-sizing: border-box;
    font-size: 16px;
    background-color: #007BFF; /* 鮮やかなブルー */
    color: white;              /* 白い文字 */
    cursor: pointer;
    transition: background-color 0.2s;
}

input[type="submit"]:hover,
button[type="submit"]:hover {
    background-color: #0056b3; /* 濃いブルーに */
}
.btn {
    background: #4a6da7;
    color: white;
    border: none;
    padding: 10px 10px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    white-space: nowrap;
    transition: background 0.3s;
}
.btn:hover {
    background: #3a5a8f;
}
.btn-secondary {
    background: #6c757d;
}
.btn-secondary:hover {
    background: #5a6268;
}
.btn-danger {
    background: #dc3545;
}
.btn-danger:hover {
    background: #c82333;
}
.unsubscribe-device-btn {
    margin-top: 8px;
    font-size: 0.9em;
    padding: 5px 10px;
}
.device-info { font-weight: bold; }
.current-device { background-color: #e6f4ea; border-left: 4px solid #34a853; }
.endpoint { font-size: 0.8em; word-break: break-all; color: #666; }
.btn-success {
    background: #28a745;
}
.btn-success:hover {
    background: #218838;
}
.confirm-button-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
}

.btn-confirm {
    background-color: #2196F3;
    color: white;
    padding: 10px 20px;
    border-radius: 5px;
    font-weight: bold;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.btn-confirm:hover {
    background-color: #0b7dda;
}
.confirmation-section {
    margin-bottom: 15px;
}

.confirmation-section h4 {
    border-bottom: 1px solid #ddd;
    padding-bottom: 5px;
    margin-bottom: 10px;
}
.controls {
    text-align: right;
    margin-top: 20px;
}
.controls button {
    margin-left: 10px;
}
.message {
    margin-top: 20px;
    padding: 10px;
    border-radius: 4px;
}
.success {
    color: #155724;
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
}
.error {
    color: #721c24;
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
}
.info {
    color: #0c5460;               /* 落ち着いた青系文字色 */
    background-color: #e2f3f8;    /* 薄い青背景 */
    border: 1px solid #bee5eb;    /* 少し濃い青の枠線 */
}
.member-list {
    margin-top: 20px;
    border: 1px solid #ddd;
    border-radius: 4px;
    overflow: hidden;
}
.member-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 15px;
    border-bottom: 1px solid #eee;
}
.member-item:last-child {
    border-bottom: none;
}
.member-item .member-info {
    flex-grow: 1;
}
.member-item .member-actions {
    white-space: nowrap;
}
.invitation-form {
    background: #f9f9f9;
    padding: 10px;
    border-radius: 4px;
    margin-bottom: 20px;
}
.invitation-form .form-row {
    display: flex;
    gap: 5px;
    margin-bottom: 10px;
}
.invitation-form .form-row input {
    flex-grow: 1;
}

.confirmation-panel {
    background: #f8f9fa;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 20px;
    margin: 20px;
}
.confirmation-panel h3 {
    border-bottom: 1px solid #ddd;
    padding-bottom: 10px;
    margin-top: 0;
}
.member-list-confirm {
    margin-bottom: 20px;
}
.member-list-confirm ul {
    list-style-type: none;
    padding-left: 0;
}
.member-list-confirm li {
    padding: 8px 0;
    border-bottom: 1px solid #eee;
}
.member-list-confirm li:last-child {
    border-bottom: none;
}
.buttons-container {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
}
.action-buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 15px;
}

.member-action-btn {
    margin-left: 5px;
    padding: 3px 8px;
    font-size: 12px;
}
.group-box {
    box-sizing: border-box;
    width: 90%;
    max-width: 400px;
    padding: 10px 5px;
    margin: 10px auto;
    background: #f5f5f5;
    border-radius: 10px;
    border: 2px solid #ccc;
    box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.1);
    text-align: center;
    font-size: 18px;
    cursor: pointer;
    transition: 0.3s;
}
.group-box:hover {
    background: #e0e0e0;
}
.new-group {
    background: #4CAF50;
    color: white;
    font-weight: bold;
}
.new-group:hover {
    background: #45a049;
}
.group-box.disabled {
    background-color: rgba(220, 220, 220, 1); /* 無効状態の背景色 */
}

.group-box.enabled {
    background-color: rgba(245, 245, 245, 1); /* 有効状態の背景色（元の背景色） */
}
.edit-box {
    display: inline-block;
    margin-left: 30px;

    width: 40%;
    max-width: 100px;
    padding: 10px 5px;
    margin: 10px 5px;
    background:rgba(235, 235, 235, 1);
    border-radius: 10px;
    box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.2);
    text-align: center;
    font-size: 16px;
    cursor: pointer;
    transition: 0.3s;
}
.edit-box.disabled {
    background: rgba(200, 200, 200, 1); /* 少し暗めにして無効感 */
    color: #888; /* 文字色も薄く */
    cursor: not-allowed; /* マウスカーソルを禁止マークに */
    box-shadow: none; /* 影を消すとさらに無効感 */
    pointer-events: none; /* 完全にクリック無効化 */
}
.edit-box:hover {
    background: #e0e0e0;
}
.text-limit {
    display: block;
    width: 100%;
    white-space: nowrap;  /* 1行で表示 */
    overflow: hidden;  /* はみ出た部分を隠す */
    text-overflow: ellipsis;  /* 省略記号「...」を表示 */
}
.event-details {
    width: 95%;
    max-width: 600px;
    margin: 20px auto;
}

.event-box {
    padding: 5px;
    background: rgba(245, 245, 245, 1);
    border-radius: 10px;
    box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.1);
    text-align: center;
    font-size: 18px;
}

.event-info {
    margin: 15px 0;
    text-align: left;
    padding: 0 10px;
}

.info-row {
    margin: 10px 0;
    display: flex;
    flex-wrap: wrap;
}

.info-label {
    font-weight: bold;
    width: 80px;
    flex-shrink: 0;
}

.info-value {
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;

    line-clamp: 2;                  /* 標準化進行中のプロパティ */
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: normal;
}
.status { margin-top: 20px; padding: 10px; background-color: #f5f5f5; }
.status-badge {
    display: inline-block;
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: bold;
    text-transform: uppercase;
}
.status-active {
    background: #d4edda;
    color: #155724;
}
.status-joined {
    background-color: #fcb263;
}
.status-declined {
    background-color: #808080;
}
.status-pending {
    background-color: #6eb4e6;
}
.status-disabled {
    background: #f8d7da;
}
a.active {
    background-color: #333;
    font-weight: bold;
    text-decoration: underline;
}
.header { background: #f5f5f5; padding: 4px 10px;}
.pagetitle { background: #333; color: white; padding: 4px 0px; text-align: center; }
.menu { background: #5c5c5c; color: white; padding: 4px 10px; text-align: center; }
.nav a { color: white; text-decoration: none; padding: 10px; }
.nav a:hover { background: #555; }
.content { padding: 20px; }
.sub-nav {
    margin-top: 5px;
    font-size: 0.9em;  /* 既存より少し小さい */
}
.sub-nav a {
    color: #ccc;  /* 目立たないようにグレー */
    text-decoration: none;
    padding: 5px;
}
.sub-nav a:hover {
    color: white;  /* ホバー時は明るく */
}
.subscription-item { padding: 10px; border: 1px solid #ddd; margin-bottom: 10px; border-radius: 4px; }
.scroll-x-container {
    position: relative;
}
.scroll-x-hint {
    overflow-x: auto;
    overflow-y: hidden;
    white-space: nowrap;
    padding-left: 1px;
    /* font-size: 60px; */
}
.scroll-x-container::before,
.scroll-x-container::after {
    content: '';
    position: absolute;
    top: 0;
    width: 40px;
    height: 100%;
    pointer-events: none;
    background: linear-gradient(to left, white, transparent);
    z-index: 1;
    display: none;
}
.scroll-x-container.show-left::before {
    display: block;
    left: 0;
    background: linear-gradient(to right, white, transparent);
}

.scroll-x-container.show-right::after {
    display: block;
    right: 0;
    background: linear-gradient(to left, white, transparent);
}
.accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    padding-left: 1em;
    border-left: 2px solid #ccc;
}
.accordion-content.open {
    max-height: 300px; /* 必要に応じて調整 */
}
.non-accordion{
    padding-left: 1em;
    border-left: 2px solid #ccc;
}