/* style.css */
body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    margin: 0;
    padding: 0;
    background-color: #f4f4f4;
    color: #333;
    text-align: center;
}

header {
    background: #333;
    color: #fff;
    padding: 0.5rem 0; /* 上下のパディングを小さくする */
}

header h1 {
    margin: 0; /* h1の余白をなくす */
}

main {
    padding: 20px;
}

section {
    margin-bottom: 20px;
    padding: 20px;
    background-color: #fff;
    border-radius: 5px;
}

#data-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}

.battery-card {
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 15px;
    margin: 15px;
    background-color: #f9f9f9;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    text-align: left;
    width: 300px;
    height: 200px;
}

.battery-card h3 {
    margin-top: 0;
    color: #007bff;
}

/* 住所以外のテキストは1行に強制し、はみ出た場合は省略する */
.battery-card p {
    margin: 5px 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* 住所の段落のスタイル */
.battery-card p.location-text {
    font-size: 0.9em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.delete-button {
    background-color: #dc3545;
    color: white;
    border: none;
    border-radius: 5px;
    padding: 5px 10px;
    cursor: pointer;
    font-size: 0.9rem;
    align-self: flex-end;
}

.delete-button:hover {
    background-color: #c82333;
}

.charging-status {
    color: #28a745;
}

.battery-card p a {
    color: #007bff;
    text-decoration: none;
}

.battery-card p a:hover {
    text-decoration: underline;
}

/* スマートフォン向けのメディアクエリ */
@media (max-width: 600px) {
    main {
        padding: 10px;
    }

    section {
        padding: 10px;
    }

    .battery-card {
        width: 100%;
        margin: 10px 0;
    }
}