Benson & Forsyth's lofty extension to the National Gallery of Ireland in Dublin is a modern classic – and celebration of the union of art, architecture and the city.
If you imagined that the newly completed extension to the National Gallery of Ireland in Dublin might be a sequel to the 1998 National Museum of Scotland in Edinburgh, you will not be disappointed. Both buildings are national repositories of Celtic artefacts. Both abound in those exquisitely executed Le Corbusier-inspired motifs – white walls, irregular deep-set windows and fairface insitu concrete – that are instantly recognisable as the Benson & Forsyth style. And both buildings enrich the cityscape of their respective capitals.

It is no exaggeration to describe the Dublin gallery extension, like its Edinburgh predecessor, as a classic of modern architecture. But not in the commonly accepted sense of cool minimalism with pure, clean-cut geometric volumes. The essence of the Benson & Forsyth style lies in the rich mix of inspired architectural incident. And don't expect a logical layout that can be clearly read from the outside. Instead, delight in the surprises that await you inside.

In 1996, Benson & Forsyth won an international design competition to extend the National Gallery of Ireland, a stuffy neo-Romanesque building facing Merrion Square. A site had been acquired that adjoined the building, occupied by three Georgian double-fronted terrace houses. Being tucked out of sight at the back, the new wing did not need to relate visually to the existing building.

The £20m, 4500 m2 wing comes with its own frontage and public entrance facing Clare Street. In contrast with the grand, freestanding Edinburgh museum, this public frontage has the modest height and width of two of the Georgian houses it replaces. Even so, it has a civic presence that is imposing enough to match the cultural importance of its contents. A flat facade of precision-cut polished limestone has been modelled with devices that include a cylindrical stair tower at one side, a projecting screen on the top floor, and a glazed cut-away shop window to the gallery.

As you enter the building, you pass through a tiny cubic lobby, which project architect Jim Hutchison calls a "decompression zone", and emerge into a lofty, elongated atrium. The atrium stretches up to the roof four storeys above, and on beyond a grand staircase as far as the rear wall, where the extension adjoins the old gallery building. This wedge-shaped hall is too canyon-like and too packed with architectural subplots – projecting staircases, irregular windows, tiny slots revealing ancient building fabric and even a narrow footbridge zooming across diagonally just below the roof – to create a satisfying volume. Its excitement comes from the visitors who animate the hall as they criss-cross between ticket counter, bookshop and restaurant, stream up the staircase to the galleries, mill around on the spacious landing and pick their way single file across the overhead footbridge.

Turn right through wide sliding screens, and you are dazzled by the biggest surprise of all. This is a vast indoor courtyard beneath a glazed roof, or winter garden, which is laid out as the gallery restaurant. What makes the winter garden such a surprise is that it does not lie behind the new narrow street frontage but behind the third Georgian house of the site, which has been retained. Within the courtyard, a freestanding Georgian ballroom has also been retained as a private dining room. As both these historic buildings were gutted long ago, they have been repaired with no attempt to restore ornamental plasterwork and mouldings.

In fact, the preservation of the two Georgian buildings came as a shock to Benson & Forsyth, who by 1998 had won planning permission from Dublin council to demolish and redevelop all three terrace houses. What they had not reckoned with was the Irish planning system, which allows appeals to be made to a national planning inspectorate after permission is granted by the local planning authority.

"The listing of the two buildings put the kibosh on our scheme," recalls Hutchison. "We were given just one weekend to reinvent it." The concept of the original design had been to spread the galleries as a lid across the entire site so that they would all benefit from daylight. The preservation of one-third of the site meant that the galleries would have to be stacked on two floors, with the lower one relying on artificial lighting.

Both floors of galleries are arranged in a comb configuration, with a long gallery and five side galleries as alcoves opening on to it. This arrangement makes for a flexible hanging policy, whether for the permanent collection or temporary exhibitions. The top-floor galleries have lofty funnel forms like oasthouses surmounted by skylights with adjustable external louvres. As well as providing flexible, efficient daylighting, this formation admits slashes of sunlight without endangering the paintings below.

Natural, self-finished and hand-crafted materials abound, including fairface white concrete, self-finished Knauf plasterwork and polished limestone floors. The result is a subdued palette of creamy off-white finishes. Carressing a fairface insitu concrete surface as smooth as an enamelled bathtub, Hutchison praises the "very, very good craftsmanship" of main contractor Michael McNamara.

Like their Edinburgh museum, Benson & Forsyth's Dublin extension is more of an architectural variety show than a pure, classic composition. As well as the spacious, unexpected winter garden, the building contains "fat walls" that have been sculpted with deep-set window seats and nooks, as in a medieval castle. Windows have been carefully placed to frame long-distance views from right across the building and out to the surrounding cityscape, expressing the connection between art, building and the city. And after passing through the whole extension, visitors are offered literal overviews of the atrium and winter garden from the high-level diagonal footbridge. It is this wealth of inspired architectural devices that give the gallery extension its surprise, delight and resonance.